module Amber::Schema::COSE

Extended Modules

Defined in:

amber/schema/cose.cr

Constant Summary

ALG_CHACHA20_POLY1305 = 24_i64
CONTENT_TYPE = "application/cose"
HEADER_ALGORITHM = 1_i64
HEADER_IV = 5_i64
HEADER_KEY_ID = 4_i64
KEY_SIZE = 32
NONCE_SIZE = 12
TAG_ENCRYPT0 = 16_i64
TAG_SIZE = 16

Instance Method Summary

Instance Method Detail

def configure(provider : KeyProvider) : Nil #

[View source]
def decrypt0(io : IO, provider : KeyProvider, external_aad = Bytes.empty) : Bytes #

[View source]
def encrypt0(plaintext : Bytes, provider : KeyProvider, external_aad = Bytes.empty) : Bytes #

[View source]
def key_provider : KeyProvider | Nil #

[View source]