module Amber::Schema::COSE::ChaCha20Poly1305

Overview

OpenSSL's maintained ChaCha20-Poly1305 implementation. The COSE profile is portable at the wire level; clients can use CryptoKit, WebCrypto-compatible adapters, or any RFC 8439 implementation.

Extended Modules

Defined in:

amber/schema/cose.cr

Constant Summary

EVP_CTRL_AEAD_GET_TAG = 16
EVP_CTRL_AEAD_SET_IVLEN = 9
EVP_CTRL_AEAD_SET_TAG = 17

Instance Method Summary

Instance Method Detail

def open(key : Bytes, nonce : Bytes, ciphertext_and_tag : Bytes, aad = Bytes.empty) : Bytes | Nil #

[View source]
def seal(key : Bytes, nonce : Bytes, plaintext : Bytes, aad = Bytes.empty) : Bytes #

[View source]