Update Debian Vcs-* fields to point to git repository
[onak.git] / main.c
1 #include <stdio.h>
2 #include <sys/types.h>
3 #include <sys/uio.h>
4 #include <unistd.h>
5
6 #include "armor.h"
7 #include "charfuncs.h"
8 #include "keydb.h"
9 #include "keyid.h"
10 #include "keyindex.h"
11 #include "keystructs.h"
12 #include "parsekey.h"
13
14 int main(int argc, char *argv[])
15 {
16         struct openpgp_packet_list *packets = NULL; 
17 /*
18         , *newpackets = NULL;
19         struct openpgp_packet_list *list_end = NULL;
20         struct openpgp_publickey *keys = NULL;
21         struct openpgp_publickey *newkeys = NULL;
22         void *ctx = NULL;
23
24         fputs("Doing read_openpgp_stream():\n", stderr);
25         read_openpgp_stream(getnextchar, ctx, &packets, 0);
26 */
27         fputs("Doing dearmor_openpgp_stream():\n", stderr);
28         dearmor_openpgp_stream(stdin_getchar, NULL, &packets);
29         fputs("Doing armor_openpgp_stream():\n", stderr);
30         armor_openpgp_stream(stdout_putchar, NULL, packets);
31
32 /*
33         fputs("Doing parse_keys():\n", stderr);
34         parse_keys(packets, &keys);
35
36         printf("Key id is 0x%llX\n", get_keyid(keys));
37
38         key_index(keys, true, false, false);
39
40         initdb(true);
41         fetch_key(get_keyid(keys), &newkeys);
42         cleanupdb();
43
44         printf("New key id is 0x%llX\n", get_keyid(newkeys));
45
46         fputs("Doing flatten_publickey():\n", stderr);
47         flatten_publickey(keys, &newpackets, &list_end);
48
49         fputs("Doing write_openpgp_stream():\n", stderr);
50         write_openpgp_stream(putnextchar, ctx, newpackets);
51 */
52         return 0;
53 }