Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package otpclient for openSUSE:Factory 
checked in at 2022-11-30 18:53:49
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/otpclient (Old)
 and      /work/SRC/openSUSE:Factory/.otpclient.new.1597 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "otpclient"

Wed Nov 30 18:53:49 2022 rev:18 rq:1039157 version:2.6.4

Changes:
--------
--- /work/SRC/openSUSE:Factory/otpclient/otpclient.changes      2022-07-21 
11:33:55.754979445 +0200
+++ /work/SRC/openSUSE:Factory/.otpclient.new.1597/otpclient.changes    
2022-11-30 18:53:51.740680940 +0100
@@ -1,0 +2,6 @@
+Wed Nov 30 16:31:09 UTC 2022 - Paolo Stivanin <i...@paolostivanin.com>
+
+- Update to 2.6.4:
+  * fix issue when importing AEGIS encrypted backups.
+
+-------------------------------------------------------------------

Old:
----
  v2.6.3.tar.gz
  v2.6.3.tar.gz.asc

New:
----
  otpclient.keyring
  v2.6.4.tar.gz
  v2.6.4.tar.gz.asc

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ otpclient.spec ++++++
--- /var/tmp/diff_new_pack.oHMmiF/_old  2022-11-30 18:53:52.376684528 +0100
+++ /var/tmp/diff_new_pack.oHMmiF/_new  2022-11-30 18:53:52.400684663 +0100
@@ -18,7 +18,7 @@
 
 %define uclname OTPClient
 Name:           otpclient
-Version:        2.6.3
+Version:        2.6.4
 Release:        0
 Summary:        Simple GTK+ client for managing TOTP and HOTP
 License:        GPL-3.0-or-later
@@ -26,6 +26,7 @@
 URL:            https://github.com/paolostivanin/%{name}
 Source0:        
https://github.com/paolostivanin/%{name}/archive/v%{version}.tar.gz
 Source1:        
https://github.com/paolostivanin/%{uclname}/releases/download/v%{version}/v%{version}.tar.gz.asc
+Source2:        otpclient.keyring
 BuildRequires:  cmake
 BuildRequires:  gcc
 BuildRequires:  gcc-c++

++++++ v2.6.3.tar.gz -> v2.6.4.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/OTPClient-2.6.3/CMakeLists.txt 
new/OTPClient-2.6.4/CMakeLists.txt
--- old/OTPClient-2.6.3/CMakeLists.txt  2022-07-20 08:27:18.000000000 +0200
+++ new/OTPClient-2.6.4/CMakeLists.txt  2022-11-30 17:07:46.000000000 +0100
@@ -1,5 +1,5 @@
 cmake_minimum_required(VERSION 3.10)
-project(OTPClient VERSION "2.6.3" LANGUAGES "C")
+project(OTPClient VERSION "2.6.4" LANGUAGES "C")
 
 configure_file("src/common/version.h.in" "version.h")
 include_directories(${PROJECT_BINARY_DIR})
@@ -44,7 +44,7 @@
 pkg_check_modules(BASEENCODE REQUIRED baseencode>=1.0.12)
 pkg_check_modules(PNG REQUIRED libpng>=1.2.0)
 pkg_check_modules(LIBZIP REQUIRED libzip>=1.0.0)
-pkg_check_modules(JANSSON REQUIRED jansson>=2.6.0)
+pkg_check_modules(JANSSON REQUIRED jansson>=2.10.0)
 pkg_check_modules(ZBAR REQUIRED zbar>=0.20)
 pkg_check_modules(GTK3 REQUIRED gtk+-3.0>=3.20.0)
 pkg_check_modules(GLIB2 REQUIRED glib-2.0>=2.48.0)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/OTPClient-2.6.3/README.md 
new/OTPClient-2.6.4/README.md
--- old/OTPClient-2.6.3/README.md       2022-07-20 08:27:18.000000000 +0200
+++ new/OTPClient-2.6.4/README.md       2022-11-30 17:07:46.000000000 +0100
@@ -10,7 +10,7 @@
 |----------------------------------------------------|-------------|
 | GTK+                                               | 3.20        |
 | Glib                                               | 2.48.0      |
-| jansson                                            | 2.100       |
+| jansson                                            | 2.10       |
 | libgcrypt                                          | 1.6.0       |
 | libzip                                             | 1.0.0       |
 | libpng                                             | 1.2.0       |
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/OTPClient-2.6.3/SECURITY.md 
new/OTPClient-2.6.4/SECURITY.md
--- old/OTPClient-2.6.3/SECURITY.md     2022-07-20 08:27:18.000000000 +0200
+++ new/OTPClient-2.6.4/SECURITY.md     2022-11-30 17:07:46.000000000 +0100
@@ -7,7 +7,7 @@
 | Version | Supported          | EOL         |
 | ------- | ------------------ |-------------|
 | 2.6.x   | :heavy_check_mark: | -           |
-| 2.5.x   | :heavy_check_mark: | 30-Sep-2022 |
+| 2.5.x   | :x: | 31-Aug-2022 |
 | 2.4.x   | :x: | 15-May-2022 |
 | 2.3.x   | :x: | 28-Feb-2021 |
 | 2.2.x   | :x: | 27-May-2020 |
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/OTPClient-2.6.3/data/com.github.paolostivanin.OTPClient.appdata.xml 
new/OTPClient-2.6.4/data/com.github.paolostivanin.OTPClient.appdata.xml
--- old/OTPClient-2.6.3/data/com.github.paolostivanin.OTPClient.appdata.xml     
2022-07-20 08:27:18.000000000 +0200
+++ new/OTPClient-2.6.4/data/com.github.paolostivanin.OTPClient.appdata.xml     
2022-11-30 17:07:46.000000000 +0100
@@ -83,6 +83,14 @@
   </content_rating>
 
   <releases>
+    <release version="2.6.4" date="2022-11-30">
+      <description>
+        <p>OTPClient 2.6.4 fixes an import issue</p>
+        <ul>
+          <li>fix issue when importing encrypted AEGIS backup.</li>
+        </ul>
+      </description>
+    </release>
     <release version="2.6.3" date="2022-07-20">
       <description>
         <p>OTPClient 2.6.3 fixes an issue when setting the migration flag</p>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/OTPClient-2.6.3/src/cli/get-data.c 
new/OTPClient-2.6.4/src/cli/get-data.c
--- old/OTPClient-2.6.3/src/cli/get-data.c      2022-07-20 08:27:18.000000000 
+0200
+++ new/OTPClient-2.6.4/src/cli/get-data.c      2022-11-30 17:07:46.000000000 
+0100
@@ -94,12 +94,12 @@
     cotp_error_t cotp_err;
     const gchar *issuer = json_string_value (json_object_get (obj, "issuer"));
     const gchar *secret = json_string_value (json_object_get (obj, "secret"));
-    gint digits = json_integer_value (json_object_get (obj, "digits"));
+    gint digits = (gint)json_integer_value (json_object_get (obj, "digits"));
     gint algo = get_algo_int_from_str (json_string_value (json_object_get 
(obj, "algo")));
     gint period;
     gint64 counter;
     if (g_ascii_strcasecmp (json_string_value (json_object_get (obj, "type")), 
"TOTP") == 0) {
-        period = json_integer_value (json_object_get (obj, "period"));
+        period = (gint)json_integer_value (json_object_get (obj, "period"));
         gint remaining_seconds = (period > 59 ? 119 : 59) - 
g_date_time_get_second (g_date_time_new_now_local());
         gint token_validity = remaining_seconds % period;
         glong current_ts = time(NULL);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/OTPClient-2.6.3/src/common/aegis.c 
new/OTPClient-2.6.4/src/common/aegis.c
--- old/OTPClient-2.6.3/src/common/aegis.c      2022-07-20 08:27:18.000000000 
+0200
+++ new/OTPClient-2.6.4/src/common/aegis.c      2022-11-30 17:07:46.000000000 
+0100
@@ -38,7 +38,7 @@
         return NULL;
     }
 
-    return encrypted == TRUE ? get_otps_from_encrypted_backup(path, password, 
max_file_size, err) : get_otps_from_plain_backup(path, err);
+    return (encrypted == TRUE) ? get_otps_from_encrypted_backup(path, 
password, max_file_size, err) : get_otps_from_plain_backup(path, err);
 }
 
 
@@ -139,7 +139,7 @@
         gcry_free (master_key);
         return NULL;
     }
-    gchar *decrypted_db = g_malloc0 (out_len);
+    gchar *decrypted_db = gcry_calloc_secure (out_len, 1);
     gcry_cipher_decrypt (hd, decrypted_db, out_len, b64decoded_db, out_len);
     gpg_err = gcry_cipher_checktag(hd, tag, TAG_SIZE);
     if (gpg_err != 0) {
@@ -157,8 +157,7 @@
     gcry_free (master_key);
 
     GSList *otps = parse_json_data (decrypted_db, err);
-
-    g_free (decrypted_db);
+    gcry_free (decrypted_db);
 
     return otps;
 }
@@ -350,7 +349,7 @@
         g_set_error (err, generic_error_gquark (), GENERIC_ERRCODE, "%s", 
jerr.text);
         return NULL;
     }
-    json_t *array = json_object_get(json_object_get(root, "db"), "entries");
+    json_t *array = json_object_get(root, "entries");
     if (array == NULL) {
         g_set_error (err, generic_error_gquark (), GENERIC_ERRCODE, "%s", 
jerr.text);
         json_decref (root);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/OTPClient-2.6.3/src/edit-data.c 
new/OTPClient-2.6.4/src/edit-data.c
--- old/OTPClient-2.6.3/src/edit-data.c 2022-07-20 08:27:18.000000000 +0200
+++ new/OTPClient-2.6.4/src/edit-data.c 2022-11-30 17:07:46.000000000 +0100
@@ -13,11 +13,18 @@
     DatabaseData *db_data;
 } EditData;
 
-static void show_edit_dialog (EditData *edit_data, AppData *app_data, gchar 
*current_label, gchar *current_issuer);
-
-static gchar *get_parse_and_set_data_from_entries (EditData *edit_data, 
GtkWidget *new_lab_entry, GtkWidget *new_iss_entry);
-
-static void set_data_in_lstore_and_json (EditData *edit_data, const gchar 
*label, const gchar *issuer);
+static void   show_edit_dialog                    (EditData   *edit_data,
+                                                   AppData    *app_data,
+                                                   gchar      *current_label,
+                                                   gchar      *current_issuer);
+
+static gchar *get_parse_and_set_data_from_entries (EditData    *edit_data,
+                                                   GtkWidget   *new_lab_entry,
+                                                   GtkWidget   *new_iss_entry);
+
+static void   set_data_in_lstore_and_json         (EditData    *edit_data,
+                                                   const gchar *label,
+                                                   const gchar *issuer);
 
 
 void
@@ -51,7 +58,10 @@
 
 
 static void
-show_edit_dialog (EditData *edit_data, AppData *app_data, gchar 
*current_label, gchar *current_issuer)
+show_edit_dialog (EditData *edit_data,
+                  AppData  *app_data,
+                  gchar    *current_label,
+                  gchar    *current_issuer)
 {
     GtkBuilder *builder = get_builder_from_partial_path (UI_PARTIAL_PATH);
     GtkWidget *diag = GTK_WIDGET (gtk_builder_get_object (builder, 
"edit_diag_id"));
@@ -102,7 +112,9 @@
 
 
 static gchar *
-get_parse_and_set_data_from_entries (EditData *edit_data, GtkWidget 
*new_lab_entry, GtkWidget *new_iss_entry)
+get_parse_and_set_data_from_entries (EditData  *edit_data,
+                                     GtkWidget *new_lab_entry,
+                                     GtkWidget *new_iss_entry)
 {
     const gchar *new_label = gtk_entry_get_text (GTK_ENTRY (new_lab_entry));
     const gchar *new_issuer = gtk_entry_get_text (GTK_ENTRY (new_iss_entry));
@@ -122,7 +134,9 @@
 
 
 static void
-set_data_in_lstore_and_json (EditData *edit_data, const gchar *label, const 
gchar *issuer)
+set_data_in_lstore_and_json (EditData    *edit_data,
+                             const gchar *label,
+                             const gchar *issuer)
 {
     gtk_list_store_set (edit_data->list_store, &edit_data->iter,
                         COLUMN_ACC_LABEL, label,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/OTPClient-2.6.3/src/file-size.c 
new/OTPClient-2.6.4/src/file-size.c
--- old/OTPClient-2.6.3/src/file-size.c 2022-07-20 08:27:18.000000000 +0200
+++ new/OTPClient-2.6.4/src/file-size.c 2022-11-30 17:07:46.000000000 +0100
@@ -4,22 +4,17 @@
 goffset
 get_file_size (const gchar *file_path)
 {
-    GFileInfo *info;
-    GFile *file;
     GError *error = NULL;
-    const gchar *attributes = "standard::*";
     GFileQueryInfoFlags flags = G_FILE_QUERY_INFO_NOFOLLOW_SYMLINKS;
-    GCancellable *cancellable = NULL;
-    goffset file_size;
 
-    file = g_file_new_for_path (file_path);
-    info = g_file_query_info (G_FILE (file), attributes, flags, cancellable, 
&error);
+    GFile *file = g_file_new_for_path (file_path);
+    GFileInfo *info = g_file_query_info (G_FILE(file), "standard::*", flags, 
NULL, &error);
     if (info == NULL) {
         g_printerr ("%s\n", error->message);
         g_clear_error (&error);
         return -1;
     }
-    file_size = g_file_info_get_size (info);
+    goffset file_size = g_file_info_get_size (info);
 
     g_object_unref (file);
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/OTPClient-2.6.3/src/imports.c 
new/OTPClient-2.6.4/src/imports.c
--- old/OTPClient-2.6.3/src/imports.c   2022-07-20 08:27:18.000000000 +0200
+++ new/OTPClient-2.6.4/src/imports.c   2022-11-30 17:07:46.000000000 +0100
@@ -110,14 +110,18 @@
         content = get_authplus_data (filename, pwd, 
app_data->db_data->max_file_size_from_memlock, &err);
     } else if (g_strcmp0 (action_name, FREEOTPPLUS_IMPORT_ACTION_NAME) == 0) {
         content = get_freeotpplus_data (filename, &err);
-    } else if (g_strcmp0 (action_name, AEGIS_IMPORT_ACTION_NAME) == 0) {
+    } else if (g_strcmp0 (action_name, AEGIS_IMPORT_ACTION_NAME) == 0 || 
g_strcmp0 (action_name, AEGIS_IMPORT_ENC_ACTION_NAME) == 0) {
         content = get_aegis_data (filename, pwd, 
app_data->db_data->max_file_size_from_memlock, g_strcmp0 (action_name, 
AEGIS_IMPORT_ENC_ACTION_NAME) == 0 ? TRUE : FALSE , &err);
     }
 
-    if (content == NULL && err != NULL) {
-        gchar *msg = g_strconcat ("An error occurred while importing, so 
nothing has been added to the database. The error is:\n", err->message, NULL);
+    if (content == NULL) {
+        const gchar *msg = "An error occurred while importing, so nothing has 
been added to the database.";
+        gchar *msg_with_err = NULL;
+        if (err != NULL) {
+            msg_with_err = g_strconcat (msg, " The error is:\n", err->message, 
NULL);
+        }
         show_message_dialog (app_data->main_window, msg, GTK_MESSAGE_ERROR);
-        g_free (msg);
+        g_free (msg_with_err);
         return FALSE;
     }
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/OTPClient-2.6.3/src/lock-app.c 
new/OTPClient-2.6.4/src/lock-app.c
--- old/OTPClient-2.6.3/src/lock-app.c  2022-07-20 08:27:18.000000000 +0200
+++ new/OTPClient-2.6.4/src/lock-app.c  2022-11-30 17:07:46.000000000 +0100
@@ -106,7 +106,6 @@
     GtkBindingSet *binding_set = gtk_binding_set_by_class 
(GTK_WIDGET_GET_CLASS (app_data->main_window));
     gtk_binding_entry_add_signal (binding_set, GDK_KEY_l, GDK_CONTROL_MASK, 
"lock-app", 0);
 
-    //const gchar *services[] = { "org.cinnamon.ScreenSaver", 
"org.freedesktop.ScreenSaver", "org.gnome.ScreenSaver", "com.canonical.Unity" };
     const gchar *paths[] = { "/org/cinnamon/ScreenSaver", 
"/org/freedesktop/ScreenSaver", "/org/gnome/ScreenSaver", 
"/com/canonical/Unity/Session" };
     const gchar *interfaces[] = { "org.cinnamon.ScreenSaver", 
"org.freedesktop.ScreenSaver", "org.gnome.ScreenSaver", 
"com.canonical.Unity.Session" };
     const gchar *signal_names[] = { "ActiveChanged", "ActiveChanged", 
"ActiveChanged", "Locked" };
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/OTPClient-2.6.3/src/ui/otpclient.ui 
new/OTPClient-2.6.4/src/ui/otpclient.ui
--- old/OTPClient-2.6.3/src/ui/otpclient.ui     2022-07-20 08:27:18.000000000 
+0200
+++ new/OTPClient-2.6.4/src/ui/otpclient.ui     2022-11-30 17:07:46.000000000 
+0100
@@ -1610,6 +1610,8 @@
               <object class="GtkSwitch" id="notif_switch_id">
                 <property name="visible">True</property>
                 <property name="can-focus">True</property>
+                <property name="halign">center</property>
+                <property name="valign">center</property>
               </object>
               <packing>
                 <property name="left-attach">1</property>
@@ -1636,6 +1638,8 @@
               <object class="GtkSwitch" id="nextotp_switch_id">
                 <property name="visible">True</property>
                 <property name="can-focus">True</property>
+                <property name="halign">center</property>
+                <property name="valign">center</property>
               </object>
               <packing>
                 <property name="left-attach">1</property>
@@ -1657,6 +1661,8 @@
               <object class="GtkSwitch" id="autolock_switch_id">
                 <property name="visible">True</property>
                 <property name="can-focus">True</property>
+                <property name="halign">center</property>
+                <property name="valign">center</property>
               </object>
               <packing>
                 <property name="left-attach">1</property>
@@ -1709,6 +1715,8 @@
               <object class="GtkSwitch" id="dark_theme_switch_id">
                 <property name="visible">True</property>
                 <property name="can-focus">True</property>
+                <property name="halign">center</property>
+                <property name="valign">center</property>
               </object>
               <packing>
                 <property name="left-attach">1</property>
@@ -1730,6 +1738,8 @@
               <object class="GtkSwitch" id="disable_secret_service_switch_id">
                 <property name="visible">True</property>
                 <property name="can-focus">True</property>
+                <property name="halign">center</property>
+                <property name="valign">center</property>
               </object>
               <packing>
                 <property name="left-attach">1</property>
@@ -2182,7 +2192,6 @@
                   <object class="GtkLabel" id="info_bar_label_id">
                     <property name="visible">True</property>
                     <property name="can-focus">False</property>
-                    <property name="label" translatable="yes">label</property>
                   </object>
                   <packing>
                     <property name="expand">False</property>

Reply via email to