sframe

package module
v0.0.0-...-a7686bc Latest Latest
Warning

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

Go to latest
Published: Nov 17, 2023 License: MIT Imports: 11 Imported by: 0

README

SFrame

This project implements SFrame. It is meant to be a reference implementation only and is NOT meant for production use.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AesCtr128HmacSha256Tag32Encryptor

type AesCtr128HmacSha256Tag32Encryptor struct {
}

https://sframe-wg.github.io/sframe/draft-ietf-sframe-enc.html#name-cipher-suites

func (AesCtr128HmacSha256Tag32Encryptor) Decrypt

func (e AesCtr128HmacSha256Tag32Encryptor) Decrypt(key, nonce, aad, ciphertext []byte) ([]byte, error)

func (AesCtr128HmacSha256Tag32Encryptor) Encrypt

func (e AesCtr128HmacSha256Tag32Encryptor) Encrypt(key, nonce, aad, plaintext []byte) ([]byte, error)

func (AesCtr128HmacSha256Tag32Encryptor) Nk

func (AesCtr128HmacSha256Tag32Encryptor) Nn

func (AesCtr128HmacSha256Tag32Encryptor) Nt

type AesCtr128HmacSha256Tag32Suite

type AesCtr128HmacSha256Tag32Suite struct {
}

func (AesCtr128HmacSha256Tag32Suite) AEAD

func (AesCtr128HmacSha256Tag32Suite) Hash

func (s AesCtr128HmacSha256Tag32Suite) Hash() func() hash.Hash

func (AesCtr128HmacSha256Tag32Suite) ID

type AesCtr128HmacSha256Tag64Encryptor

type AesCtr128HmacSha256Tag64Encryptor struct {
}

https://sframe-wg.github.io/sframe/draft-ietf-sframe-enc.html#name-cipher-suites

func (AesCtr128HmacSha256Tag64Encryptor) Decrypt

func (e AesCtr128HmacSha256Tag64Encryptor) Decrypt(key, nonce, aad, ciphertext []byte) ([]byte, error)

func (AesCtr128HmacSha256Tag64Encryptor) Encrypt

func (e AesCtr128HmacSha256Tag64Encryptor) Encrypt(key, nonce, aad, plaintext []byte) ([]byte, error)

func (AesCtr128HmacSha256Tag64Encryptor) Nk

func (AesCtr128HmacSha256Tag64Encryptor) Nn

func (AesCtr128HmacSha256Tag64Encryptor) Nt

type AesCtr128HmacSha256Tag64Suite

type AesCtr128HmacSha256Tag64Suite struct {
}

func (AesCtr128HmacSha256Tag64Suite) AEAD

func (AesCtr128HmacSha256Tag64Suite) Hash

func (s AesCtr128HmacSha256Tag64Suite) Hash() func() hash.Hash

func (AesCtr128HmacSha256Tag64Suite) ID

type AesCtr128HmacSha256Tag80Encryptor

type AesCtr128HmacSha256Tag80Encryptor struct {
}

https://sframe-wg.github.io/sframe/draft-ietf-sframe-enc.html#name-cipher-suites

func (AesCtr128HmacSha256Tag80Encryptor) Decrypt

func (e AesCtr128HmacSha256Tag80Encryptor) Decrypt(key, nonce, aad, ciphertext []byte) ([]byte, error)

func (AesCtr128HmacSha256Tag80Encryptor) Encrypt

func (e AesCtr128HmacSha256Tag80Encryptor) Encrypt(key, nonce, aad, plaintext []byte) ([]byte, error)

func (AesCtr128HmacSha256Tag80Encryptor) Nk

func (AesCtr128HmacSha256Tag80Encryptor) Nn

func (AesCtr128HmacSha256Tag80Encryptor) Nt

type AesCtr128HmacSha256Tag80Suite

type AesCtr128HmacSha256Tag80Suite struct {
}

func (AesCtr128HmacSha256Tag80Suite) AEAD

func (AesCtr128HmacSha256Tag80Suite) Hash

func (s AesCtr128HmacSha256Tag80Suite) Hash() func() hash.Hash

func (AesCtr128HmacSha256Tag80Suite) ID

type AesGcm128Sha256Tag128Encryptor

type AesGcm128Sha256Tag128Encryptor struct {
}

https://sframe-wg.github.io/sframe/draft-ietf-sframe-enc.html#name-cipher-suites

func (AesGcm128Sha256Tag128Encryptor) Decrypt

func (e AesGcm128Sha256Tag128Encryptor) Decrypt(key, nonce, aad, ciphertext []byte) ([]byte, error)

func (AesGcm128Sha256Tag128Encryptor) Encrypt

func (e AesGcm128Sha256Tag128Encryptor) Encrypt(key, nonce, aad, plaintext []byte) ([]byte, error)

func (AesGcm128Sha256Tag128Encryptor) Nk

func (AesGcm128Sha256Tag128Encryptor) Nn

func (AesGcm128Sha256Tag128Encryptor) Nt

type AesGcm128Sha256Tag128Suite

type AesGcm128Sha256Tag128Suite struct {
}

func (AesGcm128Sha256Tag128Suite) AEAD

func (AesGcm128Sha256Tag128Suite) Hash

func (s AesGcm128Sha256Tag128Suite) Hash() func() hash.Hash

func (AesGcm128Sha256Tag128Suite) ID

type AesGcm256Sha256Tag128Encryptor

type AesGcm256Sha256Tag128Encryptor struct {
}

https://sframe-wg.github.io/sframe/draft-ietf-sframe-enc.html#name-cipher-suites

func (AesGcm256Sha256Tag128Encryptor) Decrypt

func (e AesGcm256Sha256Tag128Encryptor) Decrypt(key, nonce, aad, ciphertext []byte) ([]byte, error)

func (AesGcm256Sha256Tag128Encryptor) Encrypt

func (e AesGcm256Sha256Tag128Encryptor) Encrypt(key, nonce, aad, plaintext []byte) ([]byte, error)

func (AesGcm256Sha256Tag128Encryptor) Nk

func (AesGcm256Sha256Tag128Encryptor) Nn

func (AesGcm256Sha256Tag128Encryptor) Nt

type AesGcm256Sha512Tag128Suite

type AesGcm256Sha512Tag128Suite struct {
}

func (AesGcm256Sha512Tag128Suite) AEAD

func (AesGcm256Sha512Tag128Suite) Hash

func (s AesGcm256Sha512Tag128Suite) Hash() func() hash.Hash

func (AesGcm256Sha512Tag128Suite) ID

type Ciphersuite

type Ciphersuite interface {
	AEAD() Encryptor
	Hash() func() hash.Hash
	ID() uint16
}

func NewCiphersuite

func NewCiphersuite(id uint16) (Ciphersuite, error)

type Encryptor

type Encryptor interface {
	Encrypt(key, nonce, aad, plaintext []byte) ([]byte, error)
	Decrypt(key, nonce, aad, ciphertext []byte) ([]byte, error)
	Nk() int
	Nn() int
	Nt() int
}

type SFramer

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

func (SFramer) Decrypt

func (f SFramer) Decrypt(metadata []byte, sframeCiphertext []byte) ([]byte, error)

func (SFramer) Encrypt

func (f SFramer) Encrypt(ctr uint64, kid uint64, metadata []byte, plaintext []byte) ([]byte, error)

type SFramerKey

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

func NewSFramerKey

func NewSFramerKey(kid uint64, baseKey []byte, s Ciphersuite) (SFramerKey, error)

Jump to

Keyboard shortcuts

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