diff options
Diffstat (limited to 'main/session.h')
| -rw-r--r-- | main/session.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/main/session.h b/main/session.h index 36fe722..d3a61bb 100644 --- a/main/session.h +++ b/main/session.h | |||
| @@ -8,6 +8,12 @@ | |||
| 8 | #define SESSION_MAX_CLIENTS 10 | 8 | #define SESSION_MAX_CLIENTS 10 |
| 9 | #define SESSION_MAX_MAC_LEN 18 | 9 | #define SESSION_MAX_MAC_LEN 18 |
| 10 | 10 | ||
| 11 | typedef enum { | ||
| 12 | PAYMENT_METHOD_CASHU, | ||
| 13 | PAYMENT_METHOD_MINING, | ||
| 14 | PAYMENT_METHOD_BYTES | ||
| 15 | } payment_method_t; | ||
| 16 | |||
| 11 | typedef struct { | 17 | typedef struct { |
| 12 | uint32_t client_ip; | 18 | uint32_t client_ip; |
| 13 | char mac[SESSION_MAX_MAC_LEN]; | 19 | char mac[SESSION_MAX_MAC_LEN]; |
| @@ -15,6 +21,7 @@ typedef struct { | |||
| 15 | int64_t start_time_ms; | 21 | int64_t start_time_ms; |
| 16 | uint64_t allotment_bytes; | 22 | uint64_t allotment_bytes; |
| 17 | uint64_t bytes_consumed; | 23 | uint64_t bytes_consumed; |
| 24 | payment_method_t payment_method; | ||
| 18 | bool active; | 25 | bool active; |
| 19 | } session_t; | 26 | } session_t; |
| 20 | 27 | ||