libcontrac
A library for contact tracing
|
Random Proximity Identifier functionality. More...
#include <stdlib.h>
#include <string.h>
#include <stddef.h>
#include <stdint.h>
#include <openssl/crypto.h>
#include <openssl/hmac.h>
#include <openssl/err.h>
#include "contrac/contrac.h"
#include "contrac/utils.h"
#include "contrac/log.h"
#include "contrac/rpi.h"
Data Structures | |
struct | Rpi |
The structure used to represent a Rolling Proximity Identifier. More... | |
Macros | |
#define | RPI_INFO_PREFIX "CT-RPI" |
Functions | |
Rpi * | rpi_new () |
void | rpi_delete (Rpi *data) |
bool | rpi_generate_proximity_id (Rpi *data, Dtk const *dtk, uint8_t time_interval_number) |
unsigned char const * | rpi_get_proximity_id (Rpi const *data) |
uint8_t | rpi_get_time_interval_number (Rpi const *data) |
void | rpi_assign (Rpi *data, unsigned char const *rpi_bytes, uint8_t time_interval_number) |
bool | rpi_compare (Rpi const *data, Rpi const *comparitor) |
Random Proximity Identifier functionality.
Copyright David Llewellyn-Jones, 2020 Released under the GPLv2.
This class is used to generate and manage the Random Proximity Identifier (RPI). It's largely internal. The functionality from Contrac should generally be used in preference to this.