class Sodium::Cipher::SecretStream::XChaCha20Poly1305

Overview

Libsodium Secret Stream API

This class mimicks the OpenSSL::Cipher interface with minor differences.

See spec/sodium/cipher/secret_stream_spec.cr for examples on how to use this class.

WARNING: Not verified against test vectors.

Defined in:

sodium/cipher/secret_stream.cr

Instance Method Summary

Instance methods inherited from class Sodium::Cipher::SecretStream

additional : Bytes? additional, additional=(additional : Bytes?) additional=, auth_tag_size : Int32 auth_tag_size, decrypt decrypt, encrypt encrypt, final final, header header, header=(buf : Bytes) header=, header_size : Int32 header_size, init_state(header_buf : Bytes) : Nil init_state, key=(key : Bytes | SecureBuffer) key=, key_size : Int32 key_size, random_key random_key, tag : UInt8 tag, tag=(tag) tag=, update(src : Bytes, dst : Bytes)
update(src : Bytes) : Bytes
update

Constructor methods inherited from class Sodium::Cipher::SecretStream

new new

Instance Method Detail

def auth_tag_size : Int32 #

[View source]
def header_size : Int32 #

[View source]
def key_size : Int32 #

[View source]
def tag_final #

[View source]
def tag_push #

[View source]
def tag_rekey #

[View source]
def update(src : Bytes, dst : Bytes) : Bytes #

[View source]