A simple library to support serving https.
Dependents: oldheating gps motorhome heating
tls/tls-session.h
- Committer:
- andrewboyson
- Date:
- 2019-09-24
- Revision:
- 10:e269fd7b9500
- Parent:
- 8:5e66a6b4b38c
- Child:
- 14:03a0b8fd6ddc
File content as of revision 10:e269fd7b9500:
#include <stdint.h> #include "sha256.h" #define TLS_KEY_SIZE_MASTER 48 struct TlsSession { uint32_t id; uint32_t lastUsed; bool valid; int slotPriKeyDecryption; uint8_t masterSecret [TLS_KEY_SIZE_MASTER]; }; extern struct TlsSession* TlsSessionNew (void); //Never fails so never returns NULL extern struct TlsSession* TlsSessionOrNull(uint32_t id); //Returns NULL if not found extern void TlsSessionReset (uint32_t id);