aboutsummaryrefslogtreecommitdiff
path: root/src/proone-print-all-data.c
diff options
context:
space:
mode:
authorDavid Timber <mieabby@gmail.com>2020-08-20 12:23:35 +0930
committerDavid Timber <mieabby@gmail.com>2020-08-20 15:15:57 +0930
commit76d4d6b2bafada7b790e817b7324d53f3d3a0c7f (patch)
treed8b3669fa7b167fc3bf764e971fc6e70bd8d9b49 /src/proone-print-all-data.c
parent7bd3eb3b1ad4209ac4cf4b46f849213d46bc33aa (diff)
Progress ...
* Move DVault out of executable. Dynamically load it on startup * Improved testing scheme * Tidy up prne_*assert* macro series * Protocol: store host credentials in base64 string. No mask * Use the lock shm as a shared_global so the stats can persist * mmap() the executable read-only for later use
Diffstat (limited to 'src/proone-print-all-data.c')
-rw-r--r--src/proone-print-all-data.c44
1 files changed, 0 insertions, 44 deletions
diff --git a/src/proone-print-all-data.c b/src/proone-print-all-data.c
deleted file mode 100644
index c22ff68..0000000
--- a/src/proone-print-all-data.c
+++ /dev/null
@@ -1,44 +0,0 @@
-#include <stdio.h>
-#include <stdlib.h>
-
-#include "dvault.h"
-
-#define TYPE_STR_PADDING "4"
-
-
-int main (void) {
- prne_data_key_t i = PRNE_DATA_KEY_NONE + 1;
- prne_data_type_t type;
-
- prne_init_dvault();
-
- for (i = PRNE_DATA_KEY_NONE + 1; i < NB_PRNE_DATA_KEY; i += 1) {
- type = (prne_data_type_t)PRNE_DATA_DICT[i][0];
-
- printf("%10lld(%" TYPE_STR_PADDING "s): ", (long long)i, prne_data_type_tostr(type));
- switch (type) {
- case PRNE_DATA_TYPE_CSTR:
- printf("%s", prne_dvault_unmask_entry_cstr(i, NULL));
- break;
- case PRNE_DATA_TYPE_BIN: {
- const uint8_t *p;
- size_t size, it;
-
- prne_dvault_unmask_entry_bin(i, &p, &size);
-
- for (it = 0; it < size; it += 1) {
- printf("%02X ", p[it]);
- }
- break;
- }
- default:
- fprintf(stderr, "Error: unknown data type (%d)'%s'\n", (int)type, prne_data_type_tostr(type));
- abort();
- }
-
- printf("\n");
- }
-
- prne_deinit_dvault();
- return 0;
-}