From: Michael Tremer Date: Tue, 24 Jun 2025 15:46:32 +0000 (+0000) Subject: daemon: Remove the authentication framework X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=4a66542ff55b3177e3eb66eceb4a47946ae6f38c;p=pakfire.git daemon: Remove the authentication framework Signed-off-by: Michael Tremer --- diff --git a/src/pakfire/daemon.c b/src/pakfire/daemon.c index 13b71f32..7620894a 100644 --- a/src/pakfire/daemon.c +++ b/src/pakfire/daemon.c @@ -65,9 +65,6 @@ struct pakfire_daemon { sd_bus* bus; int inhibitfd; - // Authentication Timer - sd_event_source* auth_timer; - // The control connection struct pakfire_xfer* control; @@ -882,14 +879,6 @@ static int pakfire_daemon_SIGCHLD(sd_event_source* s, const struct signalfd_sigi return 0; } -static int pakfire_daemon_auth(sd_event_source* s, uint64_t usec, void* data) { - struct pakfire_daemon* daemon = data; - - DEBUG(daemon->ctx, "Authenticating...\n"); - - return 0; -} - static int pakfire_daemon_prepare_for_shutdown( sd_bus_message* message, void* data, sd_bus_error* error) { struct pakfire_daemon* daemon = data; @@ -999,21 +988,6 @@ static int pakfire_daemon_setup_loop(struct pakfire_daemon* daemon) { return r; } - // Setup the authentication timer - r = sd_event_add_time_relative(daemon->loop, &daemon->auth_timer, - CLOCK_MONOTONIC, 0, 0, pakfire_daemon_auth, daemon); - if (r < 0) { - ERROR(daemon->ctx, "Could not register the authentication timer: %s\n", strerror(-r)); - return r; - } - - // Authenticate continuously - r = sd_event_source_set_enabled(daemon->auth_timer, SD_EVENT_ON); - if (r < 0) { - ERROR(daemon->ctx, "Could not activate the auth timer: %s\n", strerror(-r)); - return r; - } - // Setup the reconnection timer r = sd_event_add_time_relative(daemon->loop, &daemon->connect_timer, CLOCK_MONOTONIC, 0, 0, pakfire_daemon_connect, daemon); @@ -1079,8 +1053,6 @@ static void pakfire_daemon_free(struct pakfire_daemon* daemon) { // Release shutdown inhibition pakfire_daemon_release_inhibit_shutdown(daemon); - if (daemon->auth_timer) - sd_event_source_unref(daemon->auth_timer); if (daemon->connect_timer) sd_event_source_unref(daemon->connect_timer); if (daemon->stats_timer)