oaddr

package
v0.0.0-...-256b879 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 13, 2022 License: BSD-2-Clause Imports: 7 Imported by: 0

Documentation

Overview

Package oaddr provides onion address formatting

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type OnionAddress

type OnionAddress [ed25519.PublicKeySize]byte

OnionAddress is an Ed25519 public key that represents a v3 onion address

func New

func New(pub []byte) (addr OnionAddress, err error)

New outputs an onion address from a public key as defined in RFC 8032

func NewFromSigner

func NewFromSigner(s crypto.Signer) (addr OnionAddress, err error)

NewFromSigner outputs an onion address for a given signer

func (OnionAddress) String

func (addr OnionAddress) String() string

String formats addr as defined in rend-spec-v3, see: https://gitweb.torproject.org/torspec.git/tree/rend-spec-v3.txt#n2160

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL