Created
December 8, 2012 09:33
-
-
Save ratazzi/4239543 to your computer and use it in GitHub Desktop.
OpenVPN packet header
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
src/openvpn/ssl.c | |
2598- | |
2599- /* get opcode and key ID */ | |
2600- { | |
2601- uint8_t c = *BPTR (buf); | |
2602- op = c >> P_OPCODE_SHIFT; | |
2603: key_id = c & P_KEY_ID_MASK; | |
2604- } | |
src/openvpn/ssl.h | |
49- | |
50-/* Used in the TLS PRF function */ | |
51-#define KEY_EXPANSION_ID "OpenVPN" | |
52- | |
53-/* packet opcode (high 5 bits) and key-id (low 3 bits) are combined in one byte */ | |
54:#define P_KEY_ID_MASK 0x07 | |
55-#define P_OPCODE_SHIFT 3 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment