From 2113d7ce2fddd9e8b78c33ef5646f39f420f19d3 Mon Sep 17 00:00:00 2001 From: Iurii Egorov Date: Fri, 6 Sep 2024 15:28:53 +0300 Subject: [PATCH] Auth notifications for unknown peers --- contrib/peer-approver/notification-listener.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/contrib/peer-approver/notification-listener.c b/contrib/peer-approver/notification-listener.c index 010abca..a31c971 100644 --- a/contrib/peer-approver/notification-listener.c +++ b/contrib/peer-approver/notification-listener.c @@ -118,6 +118,7 @@ static int run_callback(char *ifname, char *pubkey, char *endpoint_ip, bool adva { char** new_argv = malloc((cb_argc + 2) * sizeof *new_argv); + new_argv[0] = cb_argv[1]; for (int i = 2; i < cb_argc - 3; i++) { new_argv[i - 1] = cb_argv[i]; } @@ -126,6 +127,7 @@ static int run_callback(char *ifname, char *pubkey, char *endpoint_ip, bool adva new_argv[cb_argc - 2] = endpoint_ip; new_argv[cb_argc - 1] = (advanced_security ? "on\0" : "off\0"); new_argv[cb_argc] = NULL; + //prerr("Calling ") int ret = execv(cb_argv[1], new_argv); free(new_argv); return ret;