From 178ae3f08b5d2242a19ab7cac2c8ef0adcb1e6c2 Mon Sep 17 00:00:00 2001 From: Andrea Zagli Date: Tue, 13 Sep 2016 10:21:39 +0200 Subject: [PATCH] Adjustments. --- configure.ac | 2 +- doc/zak-authe-gui/examples/zak-authe-gui.conf | 4 ++-- doc/zak-authe-gui/examples/zak-authe-gui_ldap.conf | 4 ++-- src/main.c | 12 ++++++------ 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/configure.ac b/configure.ac index bf00916..a1398d4 100644 --- a/configure.ac +++ b/configure.ac @@ -20,7 +20,7 @@ AC_PROG_CXX # Checks for libraries. PKG_CHECK_MODULES(ZAK_AUTHE_GUI, [gtk+-3.0 >= 3.0.0 - libzakauthe >= 0.5.0]) + libzakauthe >= 0.5.99]) AC_SUBST(ZAK_AUTHE_GUI_CFLAGS) AC_SUBST(ZAK_AUTHE_GUI_LIBS) diff --git a/doc/zak-authe-gui/examples/zak-authe-gui.conf b/doc/zak-authe-gui/examples/zak-authe-gui.conf index 9923c83..aadef65 100644 --- a/doc/zak-authe-gui/examples/zak-authe-gui.conf +++ b/doc/zak-authe-gui/examples/zak-authe-gui.conf @@ -1,3 +1,3 @@ -[AUTE] -plugin=/usr/local/lib/libaute/plugins/libaute-db +[ZAKAUTHE] +plugin=zakauthedb cnc_string=PostgreSQL://postgres:postgres@HOST=localhost;PORT=5432;DB_NAME=autedb diff --git a/doc/zak-authe-gui/examples/zak-authe-gui_ldap.conf b/doc/zak-authe-gui/examples/zak-authe-gui_ldap.conf index e5b6c99..8db5f5f 100644 --- a/doc/zak-authe-gui/examples/zak-authe-gui_ldap.conf +++ b/doc/zak-authe-gui/examples/zak-authe-gui_ldap.conf @@ -1,5 +1,5 @@ -[AUTE] -plugin=/usr/local/lib/libaute/plugins/libaute-smbldap +[ZAKAUTHE] +plugin=zakauthesmbldap host=ldap://10.0.0.102/ base_dn=dc=nodomain users_ou=ou=Users diff --git a/src/main.c b/src/main.c index 6d1a204..4b24b88 100644 --- a/src/main.c +++ b/src/main.c @@ -82,8 +82,6 @@ main (int argc, char **argv) gchar *utente; - gchar *cnc_string; - guint i; gtk_init (&argc, &argv); @@ -98,22 +96,24 @@ main (int argc, char **argv) config = g_key_file_new (); if (!g_key_file_load_from_file (config, argv[1], G_KEY_FILE_NONE, &error)) { - g_error ("Impossibile caricare il file di configurazione specificato: %s.", argv[1]); + g_error ("Impossibile caricare il file di configurazione specificato «%s»: %s.", + argv[1], error != NULL && error->message != NULL ? error->message : "no details"); } /* leggo i parametri per l'autenticazione */ error = NULL; - aute_params = g_key_file_get_keys (config, "AUTE", &n_aute_params, &error); + aute_params = g_key_file_get_keys (config, "ZAKAUTHE", &n_aute_params, &error); if (aute_params == NULL) { - g_error ("Impossibile leggere la configurazione per il sistema di autenticazione."); + g_error ("Impossibile leggere la configurazione per il sistema di autenticazione: %s.", + error != NULL && error->message != NULL ? error->message : "no details"); } sl_aute_params = NULL; for (i = 0; i < n_aute_params; i++) { error = NULL; - sl_aute_params = g_slist_append (sl_aute_params, g_key_file_get_string (config, "AUTE", aute_params[i], &error)); + sl_aute_params = g_slist_append (sl_aute_params, g_key_file_get_string (config, "ZAKAUTHE", aute_params[i], &error)); } g_strfreev (aute_params); -- 2.49.0