whatsmeowgo.mau.fi/whatsmeow/util/keys Index | Files

package keys

import "go.mau.fi/whatsmeow/util/keys"

Package keys contains a utility struct for elliptic curve keypairs.

Index

Types

type KeyPair

type KeyPair struct {
	Pub  *[32]byte
	Priv *[32]byte
}

func NewKeyPair

func NewKeyPair() *KeyPair

func NewKeyPairFromPrivateKey

func NewKeyPairFromPrivateKey(priv [32]byte) *KeyPair

func (*KeyPair) CreateSignedPreKey

func (kp *KeyPair) CreateSignedPreKey(keyID uint32) *PreKey

func (*KeyPair) Sign

func (kp *KeyPair) Sign(keyToSign *KeyPair) *[64]byte

type PreKey

type PreKey struct {
	KeyPair
	KeyID     uint32
	Signature *[64]byte
}

func NewPreKey

func NewPreKey(keyID uint32) *PreKey

Source Files

keypair.go

Version
v0.0.0-20250326122532-6680c9a6e9a7 (latest)
Published
Mar 26, 2025
Platform
linux/amd64
Imports
3 packages
Last checked
5 hours ago

Tools for package owners.