mirror of
https://github.com/ZeroTier/ZeroTierOne
synced 2025-08-21 05:43:59 -07:00
RPC detection fix
This commit is contained in:
parent
7656e6b9f8
commit
78c0f0a443
4 changed files with 22 additions and 29 deletions
14
netcon/RPC.h
14
netcon/RPC.h
|
@ -7,13 +7,15 @@
|
|||
#define MAGIC_PADDING_SIZE 12
|
||||
#define TOKEN_SIZE MAGIC_SIZE+MAGIC_PADDING_SIZE
|
||||
|
||||
#define RPC_PHRASE "zerotier\0"
|
||||
#define RPC_PHRASE_SIZE 9
|
||||
// 1st section
|
||||
#define IDX_SIGNAL_BYTE 0
|
||||
#define IDX_PID 1
|
||||
#define IDX_TID sizeof(pid_t) + 1
|
||||
#define IDX_COUNT IDX_TID + sizeof(pid_t)
|
||||
#define IDX_TIME IDX_COUNT + sizeof(int)
|
||||
#define IDX_PAYLOAD IDX_TIME + 20 /* 20 being the length of the timestamp string */
|
||||
#define IDX_SIGNAL_PHRASE 0
|
||||
#define IDX_PID IDX_SIGNAL_PHRASE + RPC_PHRASE_SIZE
|
||||
#define IDX_TID sizeof(pid_t) + IDX_PID
|
||||
#define IDX_COUNT IDX_TID + sizeof(pid_t)
|
||||
#define IDX_TIME IDX_COUNT + sizeof(int)
|
||||
#define IDX_PAYLOAD IDX_TIME + 20 /* 20 being the length of the timestamp string */
|
||||
|
||||
// 2nd section
|
||||
#define CMD_ID_IDX 0
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue