summaryrefslogtreecommitdiffstats
path: root/src/fastd.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/fastd.c')
-rw-r--r--src/fastd.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/fastd.c b/src/fastd.c
index 0c7e6f5..b35f70e 100644
--- a/src/fastd.c
+++ b/src/fastd.c
@@ -625,8 +625,18 @@ int main(int argc, char *argv[]) {
fastd_configure(&ctx, &conf, argc, argv);
ctx.conf = &conf;
+ if (conf.generate_key) {
+ conf.protocol->generate_key(&ctx);
+ exit(0);
+ }
+
conf.protocol_config = conf.protocol->init(&ctx);
+ if (conf.show_key) {
+ conf.protocol->show_key(&ctx);
+ exit(0);
+ }
+
update_time(&ctx);
init_tuntap(&ctx);