From: Matheus Afonso Martins Moreira Date: Wed, 21 Feb 2024 02:10:13 +0000 (-0300) Subject: faces/totp: define TOTP data structure X-Git-Url: https://git.earman.xyz/?a=commitdiff_plain;h=67907e4e5c2b3347a37e9488549216f71e1a57b2;p=sensor-watch.git faces/totp: define TOTP data structure Aggregates all the data necessary for TOTP generation. --- diff --git a/movement/watch_faces/complication/totp_face.c b/movement/watch_faces/complication/totp_face.c index 242820d..d634baa 100644 --- a/movement/watch_faces/complication/totp_face.c +++ b/movement/watch_faces/complication/totp_face.c @@ -29,6 +29,14 @@ #include "watch_utility.h" #include "TOTP.h" +typedef struct { + unsigned char labels[2]; + hmac_alg algorithm; + uint32_t period; + size_t key_length; + uint8_t *key; +} totp_t; + //////////////////////////////////////////////////////////////////////////////// // Enter your TOTP key data below static const uint8_t num_keys = 2;