25 #include "crypto_engine.h"
26 #include "stream_iv.h"
27 #include "stream_key.h"
37 typedef enum { STREAM_DIRECTION_ENCODE, STREAM_DIRECTION_DECODE } wickr_stream_direction;
A data structure representing the stream encoding / decoding key material A stream key holds informat...
Definition: stream_key.h:56
wickr_buffer_t * wickr_stream_ctx_decode(wickr_stream_ctx_t *ctx, const wickr_cipher_result_t *data, const wickr_buffer_t *aad, uint64_t seq_num)
A deterministic random IV generator using a 64 byte secure random seed and HMAC-SHA512.
Definition: stream_iv.h:53
bool wickr_stream_ctx_ref_up(wickr_stream_ctx_t *ctx)
Interface to a set of cryptographic operations used throughout the library. Currently the default imp...
Definition: crypto_engine.h:53
uint64_t last_seq
Definition: stream_ctx.h:71
wickr_stream_ctx_t * wickr_stream_ctx_create(const wickr_crypto_engine_t engine, wickr_stream_key_t *stream_key, wickr_stream_direction direction)
wickr_stream_ctx_t * wickr_stream_ctx_copy(const wickr_stream_ctx_t *ctx)
wickr_cipher_result_t * wickr_stream_ctx_encode(wickr_stream_ctx_t *ctx, const wickr_buffer_t *data, const wickr_buffer_t *aad, uint64_t seq_num)
wickr_crypto_engine_t engine
Definition: stream_ctx.h:68
void wickr_stream_ctx_destroy(wickr_stream_ctx_t **ctx)
Represents an array of bytes and the length of the allocation associated with those bytes.
Definition: buffer.h:51
size_t ref_count
Definition: stream_ctx.h:73
wickr_stream_direction direction
Definition: stream_ctx.h:72
wickr_stream_key_t * key
Definition: stream_ctx.h:69
wickr_stream_iv_t * iv_factory
Definition: stream_ctx.h:70
A context that is used for encrypting or decrypting a sequenced stream of data packets The stream con...
Definition: stream_ctx.h:67