about summary refs log tree commit diff stats
path: root/tools/datapacker
pre { line-height: 125%; } td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; } span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; } td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; } span.linenos.special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; } .highlight .hll {>Renamed Painting and Keyholder protos
Commit message (Expand)AuthorAgeFilesLines
* Change version schemeStar Rauchenberger2025-09-291-1/+1
* Added display names to portsStar Rauchenberger2025-09-281-0/+1
* [Data] Annotate shuffleable portsStar Rauchenberger2025-09-211-1/+7
* Added strict purple/cyan ending optionsStar Rauchenberger2025-09-191-0/+10
* Add anti-collectable locationStar Rauchenberger2025-09-131-0/+3
* [Data] Add version numberStar Rauchenberger2025-09-101-0/+10
* Added lavender cubes logicStar Rauchenberger2025-09-081-3/+0
* Added door groupsStar Rauchenberger2025-09-073-0/+51
* Added option for Daedalus roof access logicStar Rauchenberger2025-09-031-0/+5
* Added keyholder sanityStar Rauchenberger2025-09-021-0/+12
* Added progressive doorsStar Rauchenberger2025-09-013-2/+51
* Handled cyan doorsStar Rauchenberger2025-08-311-0/+4
* Star Rauchenberger2025-08-272-4/+4
* Added control_centerStar Rauchenberger2025-08-271-0/+4
* Maps have display names nowStar Rauchenberger2025-08-201-0/+17
* Added "endings" object typeStar Rauchenberger2025-08-203-0/+41
* Store IDs in a yaml fileStar Rauchenberger2025-08-191-2/+3
* Minor changes for compiling on WindowsStar Rauchenberger2025-08-161-1/+1
* Assigned IDs for the_galleryStar Rauchenberger2025-08-131-0/+7
* Converted to proto2Star Rauchenberger2025-08-123-14/+14
* Add gravity to paintings/portsStar Rauchenberger2025-08-111-2/+6
* Assigned IDs for the_congruentStar Rauchenberger2025-08-103-0/+91
* Assigned IDs for the_colorfulStar Rauchenberger2025-08-101-0/+9
* Added support for masteriesStar Rauchenberger2025-08-094-5/+140
* Propagate complete_at to packed datafileStar Rauchenberger2025-08-091-2/+6
* Added special IDsStar Rauchenberger2025-08-071-0/+5
* Assign AP IDs to doors and panelsStar Rauchenberger2025-08-071-0/+21
* Started apworldStar Rauchenberger2025-08-071-0/+8
* Process the rest of the defined protosStar Rauchenberger2025-08-072-2/+200
* Protobuf works! Parsing connectionsStar Rauchenberger2025-08-074-3/+473
* Trying out protobuf I guessStar Rauchenberger2025-08-071-0/+21
>data = (unsigned char *) packet; // Initialise a libwifi_frame struct and populate it struct libwifi_frame frame = {0}; int ret = libwifi_get_wifi_frame(&frame, data, data_len, has_radiotap); if (ret != 0) { return; } // Ensure the parsed frame is a data frame if (frame.frame_control.type == TYPE_DATA) { // Ensure the parsed data frame is a WPA handshake if (libwifi_check_wpa_handshake(&frame) > 0) { // Use libwifi to get the EAPOL message part, and also pretty-print it int part = libwifi_check_wpa_message(&frame); printf("WPA Handshake Message: %d (%s)\n", part, libwifi_get_wpa_message_string(&frame)); // Initlaise a WPA Authentication Data struct and populate it struct libwifi_wpa_auth_data data = {0}; libwifi_get_wpa_data(&frame, &data); // Print all of the available WPA Auth data printf("EAPOL: Version: %d\n", data.version); printf("EAPOL: Type: %d\n", data.type); printf("EAPOL: Length: %d\n", data.length); printf("EAPOL: Descriptor: %d\n", data.descriptor); printf("EAPOL: Key Info: Information: 0x%04x\n", data.key_info.information); printf("EAPOL: Key Info: Key Length: %d\n", data.key_info.key_length); printf("EAPOL: Key Info: Replay Counter: %lu\n", data.key_info.replay_counter); printf("EAPOL: Key Info: Nonce: "); for (size_t i = 0; i < sizeof(data.key_info.nonce); ++i) { printf("%02x ", data.key_info.nonce[i]); } printf("\n"); printf("EAPOL: Key Info: IV: "); for (size_t i = 0; i < sizeof(data.key_info.iv); ++i) { printf("%02x ", data.key_info.iv[i]); } printf("\n"); printf("EAPOL: Key Info: RSC: "); for (size_t i = 0; i < sizeof(data.key_info.rsc); ++i) { printf("%02x ", data.key_info.rsc[i]); } printf("\n"); printf("EAPOL: Key Info: ID: "); for (size_t i = 0; i < sizeof(data.key_info.id); ++i) { printf("%02x ", data.key_info.id[i]); } printf("\n"); printf("EAPOL: Key Info: MIC: "); for (size_t i = 0; i < sizeof(data.key_info.mic); ++i) { printf("%02x ", data.key_info.mic[i]); } printf("\n"); printf("EAPOL: Key Info: Key Data Length: %d\n", data.key_info.key_data_length); if (data.key_info.key_data_length) { printf("EAPOL: Key Info: Key Data: "); for (size_t i = 0; i < data.key_info.key_data_length; ++i) { printf("%02x ", data.key_info.key_data[i]); } printf("\n"); } // Cleanup the WPA Data libwifi_free_wpa_data(&data); printf("\n"); } } // Clean up the libwifi frame libwifi_free_wifi_frame(&frame); } void helpexit() { fprintf(stderr, "[!] Usage: ./parse_eapol --file <file.pcap>\n"); exit(EXIT_FAILURE); } int main(int argc, char **argv) { pcap_t *handle = NULL; pcap_dumper_t *dumper = NULL; char errbuf[PCAP_ERRBUF_SIZE]; if (argc < 2) { helpexit(); } if (strcmp(argv[1], "--file") == 0) { if ((handle = pcap_open_offline(argv[2], errbuf)) == NULL) { fprintf(stderr, "[!] Error opening file %s (%s)\n", argv[2], errbuf); exit(EXIT_FAILURE); } } else { helpexit(); } int linktype = pcap_datalink(handle); if (linktype == DLT_IEEE802_11_RADIO) { has_radiotap = 1; } if (linktype != DLT_IEEE802_11 && linktype != DLT_IEEE802_11_RADIO) { fprintf(stderr, "[!] 802.11 and radiotap headers not provided (%d)\n", pcap_datalink(handle)); pcap_close(handle); exit(EXIT_FAILURE); } printf("[+] Setup Complete\n"); dumper = pcap_dump_open(handle, "/tmp/parse_eapol.pcap"); pcap_loop(handle, -1 /*INFINITY*/, &handle_pkt, (unsigned char *) dumper); pcap_dump_close(dumper); pcap_close(handle); return 0; }