MCPcopy Create free account
hub / github.com/XTLS/Go / Seal

Method Seal

cipher_suites.go:459–462  ·  view source on GitHub ↗
(out, nonce, plaintext, additionalData []byte)

Source from the content-addressed store, hash-verified

457func (f *prefixNonceAEAD) explicitNonceLen() int { return f.NonceSize() }
458
459func (f *prefixNonceAEAD) Seal(out, nonce, plaintext, additionalData []byte) []byte {
460 copy(f.nonce[4:], nonce)
461 return f.aead.Seal(out, f.nonce[:], plaintext, additionalData)
462}
463
464func (f *prefixNonceAEAD) Open(out, nonce, ciphertext, additionalData []byte) ([]byte, error) {
465 copy(f.nonce[4:], nonce)

Callers

nothing calls this directly

Calls 1

SealMethod · 0.45

Tested by

no test coverage detected