libcontrac
A library for contact tracing
|
Daily Tracing Key functionality. More...
#include <stdlib.h>
#include <string.h>
#include <stddef.h>
#include <stdint.h>
#include <openssl/crypto.h>
#include <openssl/kdf.h>
#include <openssl/err.h>
#include <openssl/evp.h>
#include "contrac/contrac.h"
#include "contrac/utils.h"
#include "contrac/log.h"
#include "contrac/dtk.h"
Data Structures | |
struct | Dtk |
The structure used to represent a Daily Tracing Key. More... | |
Macros | |
#define | DTK_INFO_PREFIX "CT-DTK" |
Functions | |
Dtk * | dtk_new () |
void | dtk_delete (Dtk *data) |
bool | dtk_generate_daily_key (Dtk *data, Contrac const *contrac, uint32_t day_number) |
unsigned char const * | dtk_get_daily_key (Dtk const *data) |
uint32_t | dtk_get_day_number (Dtk const *data) |
void | dtk_assign (Dtk *data, unsigned char const *dtk_bytes, uint32_t day_number) |
Daily Tracing Key functionality.
Copyright David Llewellyn-Jones, 2020 Released under the GPLv2.
This class is used to generate and manage the Daily Tracing Key (DTK). It's largely internal. The functionality from Contrac should generally be used in preference to this.