fingerprint

package
v0.0.0-...-7f076ca Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2023 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Overview

Package fingerprint provides a way to generate a visually verifiable fingerprint of keys.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Display

type Display struct{}

Display is a structure for displayable fingerprints.

func NewDisplay

func NewDisplay() *Display

NewDisplay will return a new displayable fingerprint.

func (*Display) CreateFor

func (d *Display) CreateFor(localIdentityKey, remoteIdentityKey []byte) string

CreateFor create

type Fingerprint

type Fingerprint struct {
	// contains filtered or unexported fields
}

Fingerprint is a structure for returning a displayable and scannable fingerprint for identity verification.

func NewFingerprint

func NewFingerprint(displayFingerprint *Display) *Fingerprint

NewFingerprint will return a new Fingerprint structure.

func (*Fingerprint) Display

func (f *Fingerprint) Display() *Display

Display will return a fingerprint display structure for getting a string representation of given keys.

func (*Fingerprint) Scan

func (f *Fingerprint) Scan() string

Scan will return a fingerprint scan structure for getting a scannable representation of given keys.

type FingerprintGenerator

type FingerprintGenerator interface {
	CreateFor(localStableIdentifier, remoteStableIdentifier string, localIdentityKey, remoteIdentityKey *identity.Key) *Fingerprint
	CreateForMultiple(localStableIdentifier, remoteStableIdentifier string, localIdentityKey, remoteIdentityKey []*identity.Key) *Fingerprint
}

FingerprintGenerator is an interface for fingerprint generators.

Jump to

Keyboard shortcuts

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