From 37cc40468553cc7b9b55abe2913200fe0835fc1f Mon Sep 17 00:00:00 2001 From: Dennis Gilmore Date: Sat, 7 Jun 2014 12:43:27 -0500 Subject: [PATCH 01/15] - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild --- yapet.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/yapet.spec b/yapet.spec index a672846..357e686 100644 --- a/yapet.spec +++ b/yapet.spec @@ -2,7 +2,7 @@ Name: yapet Version: 1.0 -Release: 1%{?pre}%{?dist} +Release: 2%{?pre}%{?dist} Summary: Curses based password encryption tool License: GPLv3+ with exceptions URL: http://www.guengel.ch/myapps/%{name}/ @@ -50,6 +50,9 @@ rm -frv %{buildroot}%{_datadir}/applications/ %{_mandir}/man*/*%{name}* %changelog +* Sat Jun 07 2014 Fedora Release Engineering - 1.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild + * Thu Feb 27 2014 Christopher Meng - 1.0-1 - Update to 1.0 From fea89e3b92ab44a15dfe82fd32188e1996c493eb Mon Sep 17 00:00:00 2001 From: Peter Robinson Date: Mon, 18 Aug 2014 11:18:37 +0000 Subject: [PATCH 02/15] - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild --- yapet.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/yapet.spec b/yapet.spec index 357e686..ccae55e 100644 --- a/yapet.spec +++ b/yapet.spec @@ -2,7 +2,7 @@ Name: yapet Version: 1.0 -Release: 2%{?pre}%{?dist} +Release: 3%{?pre}%{?dist} Summary: Curses based password encryption tool License: GPLv3+ with exceptions URL: http://www.guengel.ch/myapps/%{name}/ @@ -50,6 +50,9 @@ rm -frv %{buildroot}%{_datadir}/applications/ %{_mandir}/man*/*%{name}* %changelog +* Mon Aug 18 2014 Fedora Release Engineering - 1.0-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild + * Sat Jun 07 2014 Fedora Release Engineering - 1.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild From c4b63ca934a788ecf2d241932b98d80a485cf4bf Mon Sep 17 00:00:00 2001 From: Christopher Meng Date: Tue, 10 Feb 2015 14:33:09 +0800 Subject: [PATCH 03/15] Disable silent compile. --- yapet.spec | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/yapet.spec b/yapet.spec index ccae55e..3b46c4a 100644 --- a/yapet.spec +++ b/yapet.spec @@ -32,12 +32,13 @@ done --enable-pwgen \ --disable-build-doc \ --disable-source-doc \ - --disable-install-doc + --disable-install-doci \ + --disable-silent-rules -make CXXFLAGS+="%{optflags}" CFLAGS+="%{optflags}" %{?_smp_mflags} +%make_build CXXFLAGS+="%{optflags}" CFLAGS+="%{optflags}" %install -make install DESTDIR=%{buildroot} +%make_install # Console running is Ok. rm -frv %{buildroot}%{_datadir}/applications/ From 10777f189add0a43b3c5753d27c58c72a882f87e Mon Sep 17 00:00:00 2001 From: Kalev Lember Date: Sat, 2 May 2015 18:49:56 +0200 Subject: [PATCH 04/15] Rebuilt for GCC 5 C++11 ABI change --- yapet.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/yapet.spec b/yapet.spec index 3b46c4a..7c1f83e 100644 --- a/yapet.spec +++ b/yapet.spec @@ -2,7 +2,7 @@ Name: yapet Version: 1.0 -Release: 3%{?pre}%{?dist} +Release: 4%{?pre}%{?dist} Summary: Curses based password encryption tool License: GPLv3+ with exceptions URL: http://www.guengel.ch/myapps/%{name}/ @@ -51,6 +51,9 @@ rm -frv %{buildroot}%{_datadir}/applications/ %{_mandir}/man*/*%{name}* %changelog +* Sat May 02 2015 Kalev Lember - 1.0-4 +- Rebuilt for GCC 5 C++11 ABI change + * Mon Aug 18 2014 Fedora Release Engineering - 1.0-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild From ab9aa13197714cd8695e61386c03de2d9e204f8b Mon Sep 17 00:00:00 2001 From: Dennis Gilmore Date: Fri, 19 Jun 2015 04:35:00 +0000 Subject: [PATCH 05/15] - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild --- yapet.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/yapet.spec b/yapet.spec index 7c1f83e..87baea8 100644 --- a/yapet.spec +++ b/yapet.spec @@ -2,7 +2,7 @@ Name: yapet Version: 1.0 -Release: 4%{?pre}%{?dist} +Release: 5%{?pre}%{?dist} Summary: Curses based password encryption tool License: GPLv3+ with exceptions URL: http://www.guengel.ch/myapps/%{name}/ @@ -51,6 +51,9 @@ rm -frv %{buildroot}%{_datadir}/applications/ %{_mandir}/man*/*%{name}* %changelog +* Fri Jun 19 2015 Fedora Release Engineering - 1.0-5 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild + * Sat May 02 2015 Kalev Lember - 1.0-4 - Rebuilt for GCC 5 C++11 ABI change From 908fbe880689fa6a6baff48d6e9c65158241231f Mon Sep 17 00:00:00 2001 From: Christopher Meng Date: Thu, 27 Aug 2015 10:40:23 +0800 Subject: [PATCH 06/15] Cleanup --- yapet.spec | 30 ++++++++++++++++++------------ 1 file changed, 18 insertions(+), 12 deletions(-) diff --git a/yapet.spec b/yapet.spec index 87baea8..9eb32aa 100644 --- a/yapet.spec +++ b/yapet.spec @@ -3,7 +3,7 @@ Name: yapet Version: 1.0 Release: 5%{?pre}%{?dist} -Summary: Curses based password encryption tool +Summary: Yet Another Password Encryption Tool License: GPLv3+ with exceptions URL: http://www.guengel.ch/myapps/%{name}/ Source0: http://www.guengel.ch/myapps/%{name}/downloads/%{name}-%{version}%{?pre}.tar.bz2 @@ -27,28 +27,34 @@ do done %build -%configure --enable-terminal-title \ - --enable-csv2yapet \ - --enable-pwgen \ - --disable-build-doc \ - --disable-source-doc \ - --disable-install-doci \ +%configure --disable-install-doc \ + --disable-source-doc \ + --disable-install-doci \ --disable-silent-rules -%make_build CXXFLAGS+="%{optflags}" CFLAGS+="%{optflags}" +%make_build %install %make_install -# Console running is Ok. +# Console running is OK. rm -frv %{buildroot}%{_datadir}/applications/ +# %%doc instead. +rm -frv %{buildroot}%{_docdir} + %find_lang %{name} %find_lang libyacurs +%check +# RNG tests need /dev/urandom OR /dev/random! +# Failed at messagebox1. Digging. +#make check + %files -f %{name}.lang -f libyacurs.lang -%doc AUTHORS COPYING DESIGN LICENSE NEWS README THANKS TODO -%{_bindir}/* -%{_mandir}/man*/*%{name}* +%doc AUTHORS DESIGN NEWS README THANKS TODO +%license COPYING LICENSE +%{_bindir}/*yapet* +%{_mandir}/man*/*yapet* %changelog * Fri Jun 19 2015 Fedora Release Engineering - 1.0-5 From 53d8e108020a1d8cddb6866c25e66f55fce398a6 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 5 Feb 2016 03:56:14 +0000 Subject: [PATCH 07/15] - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild --- yapet.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/yapet.spec b/yapet.spec index 9eb32aa..93abd07 100644 --- a/yapet.spec +++ b/yapet.spec @@ -2,7 +2,7 @@ Name: yapet Version: 1.0 -Release: 5%{?pre}%{?dist} +Release: 6%{?pre}%{?dist} Summary: Yet Another Password Encryption Tool License: GPLv3+ with exceptions URL: http://www.guengel.ch/myapps/%{name}/ @@ -57,6 +57,9 @@ rm -frv %{buildroot}%{_docdir} %{_mandir}/man*/*yapet* %changelog +* Fri Feb 05 2016 Fedora Release Engineering - 1.0-6 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild + * Fri Jun 19 2015 Fedora Release Engineering - 1.0-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild From 5e36ff9d75d5bd25e3a28fe05fbc83c94e88d37b Mon Sep 17 00:00:00 2001 From: Greg Bailey Date: Thu, 14 Apr 2016 09:13:20 -0700 Subject: [PATCH 08/15] Patch GCC6 compilation error from void function returning a value (#1308262) --- bz1308262-gcc6-void-fn-returns-value.patch | 12 ++++++++++++ yapet.spec | 12 ++++++++++-- 2 files changed, 22 insertions(+), 2 deletions(-) create mode 100644 bz1308262-gcc6-void-fn-returns-value.patch diff --git a/bz1308262-gcc6-void-fn-returns-value.patch b/bz1308262-gcc6-void-fn-returns-value.patch new file mode 100644 index 0000000..67775d9 --- /dev/null +++ b/bz1308262-gcc6-void-fn-returns-value.patch @@ -0,0 +1,12 @@ +diff -uNr yapet-1.0.orig/yapet/cfg.h yapet-1.0/yapet/cfg.h +--- yapet-1.0.orig/yapet/cfg.h 2014-02-23 10:18:41.000000000 -0700 ++++ yapet-1.0/yapet/cfg.h 2016-04-14 07:06:49.665672169 -0700 +@@ -163,7 +163,7 @@ + locked = false; + } + +- void is_locked() const { ++ bool is_locked() const { + return locked; + } + diff --git a/yapet.spec b/yapet.spec index 93abd07..54db5de 100644 --- a/yapet.spec +++ b/yapet.spec @@ -2,7 +2,7 @@ Name: yapet Version: 1.0 -Release: 6%{?pre}%{?dist} +Release: 7%{?pre}%{?dist} Summary: Yet Another Password Encryption Tool License: GPLv3+ with exceptions URL: http://www.guengel.ch/myapps/%{name}/ @@ -11,6 +11,8 @@ BuildRequires: gettext BuildRequires: ncurses-devel BuildRequires: openssl-devel +Patch0: bz1308262-gcc6-void-fn-returns-value.patch + %description YAPET is a text based password manager using the Blowfish encryption algorithm. Because of its small footprint and very few library dependencies, it is suited @@ -19,6 +21,9 @@ for installing on desktop and server systems alike. %prep %setup -qn %{name}-%{version}%{?pre} +# https://bugs.guengel.ch/show_bug.cgi?id=112 +%patch0 -p1 + for f in ./DESIGN ./README do iconv -f iso-8859-1 -t utf-8 $f |sed 's|\r||g' > $f.utf8 @@ -30,7 +35,7 @@ done %configure --disable-install-doc \ --disable-source-doc \ --disable-install-doci \ - --disable-silent-rules + --disable-silent-rules %make_build @@ -57,6 +62,9 @@ rm -frv %{buildroot}%{_docdir} %{_mandir}/man*/*yapet* %changelog +* Thu Apr 14 2016 Greg Bailey - 1.0-7 +- Patch GCC6 compilation error from void function returning a value (#1308262) + * Fri Feb 05 2016 Fedora Release Engineering - 1.0-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild From f94b8a0fbf56b8cc612803e1b63fe482a87f07c5 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Sat, 11 Feb 2017 18:14:56 +0000 Subject: [PATCH 09/15] - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild --- yapet.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/yapet.spec b/yapet.spec index 54db5de..f1d1368 100644 --- a/yapet.spec +++ b/yapet.spec @@ -2,7 +2,7 @@ Name: yapet Version: 1.0 -Release: 7%{?pre}%{?dist} +Release: 8%{?pre}%{?dist} Summary: Yet Another Password Encryption Tool License: GPLv3+ with exceptions URL: http://www.guengel.ch/myapps/%{name}/ @@ -62,6 +62,9 @@ rm -frv %{buildroot}%{_docdir} %{_mandir}/man*/*yapet* %changelog +* Sat Feb 11 2017 Fedora Release Engineering - 1.0-8 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild + * Thu Apr 14 2016 Greg Bailey - 1.0-7 - Patch GCC6 compilation error from void function returning a value (#1308262) From 331227bef54db3044b31f95c4081a5fcce4a11c8 Mon Sep 17 00:00:00 2001 From: Greg Bailey Date: Fri, 10 Mar 2017 15:26:39 +0000 Subject: [PATCH 10/15] Patch to fix build issues with GCC 6 and OpenSSL 1.1 (#1424564) --- bz1424564-gcc-6_and_openssl-1.1.patch | 893 ++++++++++++++++++++++++++ yapet.spec | 20 +- 2 files changed, 911 insertions(+), 2 deletions(-) create mode 100644 bz1424564-gcc-6_and_openssl-1.1.patch diff --git a/bz1424564-gcc-6_and_openssl-1.1.patch b/bz1424564-gcc-6_and_openssl-1.1.patch new file mode 100644 index 0000000..f8e6754 --- /dev/null +++ b/bz1424564-gcc-6_and_openssl-1.1.patch @@ -0,0 +1,893 @@ +Index: crypt/crypt.cc +=================================================================== +--- crypt/crypt.cc (revision 6011) ++++ crypt/crypt.cc (revision 6988) +@@ -34,6 +34,31 @@ + + using namespace YAPET; + ++EVP_CIPHER_CTX* ++Crypt::create_context() { ++#ifdef HAVE_EVP_CIPHER_CTX_INIT ++ EVP_CIPHER_CTX *context = (EVP_CIPHER_CTX*) std::malloc(sizeof(EVP_CIPHER_CTX)); ++ EVP_CIPHER_CTX_init(context); ++ return context; ++#elif HAVE_EVP_CIPHER_CTX_NEW ++ return EVP_CIPHER_CTX_new(); ++#else ++ #error "Neither EVP_CIPHER_CTX_init() nor EVP_CIPHER_CTX_new() available" ++#endif ++} ++ ++void ++Crypt::destroy_context(EVP_CIPHER_CTX *context) { ++#ifdef HAVE_EVP_CIPHER_CTX_CLEANUP ++ EVP_CIPHER_CTX_cleanup(context); ++ std::free(context); ++#elif HAVE_EVP_CIPHER_CTX_FREE ++ EVP_CIPHER_CTX_free(context); ++#else ++#error "Neither EVP_CIPHER_CTX_cleanup() nor EVP_CIPHER_CTX_free() available" ++#endif ++} ++ + /** + * Initializes the class with the given key, which is used for + * encryption and decryption. +@@ -57,25 +82,24 @@ + throw YAPETException (_ ("Unable to get cipher") ); + + // Test if key length is ok +- EVP_CIPHER_CTX ctx; +- EVP_CIPHER_CTX_init (&ctx); +- int retval = EVP_CipherInit_ex (&ctx, cipher, 0, 0, 0, 0); ++ EVP_CIPHER_CTX* ctx = create_context(); ++ int retval = EVP_CipherInit_ex (ctx, cipher, 0, 0, 0, 0); + + if (retval == 0) { +- EVP_CIPHER_CTX_cleanup (&ctx); ++ destroy_context(ctx); + throw YAPETException (_ ("Error initializing cipher") ); + } + +- retval = EVP_CIPHER_CTX_set_key_length (&ctx, key.size() ); ++ retval = EVP_CIPHER_CTX_set_key_length (ctx, key.size() ); + + if (retval == 0) { +- EVP_CIPHER_CTX_cleanup (&ctx); ++ destroy_context(ctx); + throw YAPETException (_ ("Error setting the key length") ); + } + +- iv_length = EVP_CIPHER_CTX_iv_length (&ctx); +- key_length = EVP_CIPHER_CTX_key_length (&ctx); +- EVP_CIPHER_CTX_cleanup (&ctx); ++ iv_length = EVP_CIPHER_CTX_iv_length (ctx); ++ key_length = EVP_CIPHER_CTX_key_length (ctx); ++ destroy_context(ctx); + } + + Crypt::Crypt (const Crypt& c) : cipher (c.cipher), +Index: crypt/crypt.h +=================================================================== +--- crypt/crypt.h (revision 6011) ++++ crypt/crypt.h (revision 6988) +@@ -100,6 +100,9 @@ + */ + Key key; + ++ EVP_CIPHER_CTX *create_context(); ++ void destroy_context(EVP_CIPHER_CTX *context); ++ + public: + //! Constructor + Crypt (const Key& k) throw (YAPETException); +@@ -159,9 +162,8 @@ + if (key.ivec_size() != iv_length) + throw YAPETException (_ ("IVec length missmatch") ); + +- EVP_CIPHER_CTX ctx; +- EVP_CIPHER_CTX_init (&ctx); +- int retval = EVP_EncryptInit_ex (&ctx, ++ EVP_CIPHER_CTX *ctx=create_context (); ++ int retval = EVP_EncryptInit_ex (ctx, + cipher, + 0, + key, +@@ -168,14 +170,14 @@ + key.getIVec() ); + + if (retval == 0) { +- EVP_CIPHER_CTX_cleanup (&ctx); ++ destroy_context (ctx); + throw YAPETEncryptionException (_ ("Error initializing encryption engine") ); + } + +- retval = EVP_CIPHER_CTX_set_key_length (&ctx, key.size() ); ++ retval = EVP_CIPHER_CTX_set_key_length (ctx, key.size() ); + + if (retval == 0) { +- EVP_CIPHER_CTX_cleanup (&ctx); ++ destroy_context (ctx); + throw YAPETException (_ ("Error setting the key length") ); + } + +@@ -182,7 +184,7 @@ + BDBuffer* encdata = + new BDBuffer (data.size() + EVP_MAX_BLOCK_LENGTH); + int outlen; +- retval = EVP_EncryptUpdate (&ctx, ++ retval = EVP_EncryptUpdate (ctx, + *encdata, + &outlen, + data, +@@ -189,24 +191,24 @@ + data.size() ); + + if (retval == 0) { +- EVP_CIPHER_CTX_cleanup (&ctx); ++ destroy_context (ctx); + delete encdata; + throw YAPETEncryptionException (_ ("Error encrypting data") ); + } + + int tmplen; +- retval = EVP_EncryptFinal_ex (&ctx, ++ retval = EVP_EncryptFinal_ex (ctx, + encdata->at (outlen), + &tmplen); + + if (retval == 0) { +- EVP_CIPHER_CTX_cleanup (&ctx); ++ destroy_context (ctx); + delete encdata; + throw YAPETEncryptionException (_ ("Error finalizing encryption") ); + } + + encdata->resize (outlen + tmplen); +- EVP_CIPHER_CTX_cleanup (&ctx); ++ destroy_context (ctx); + return encdata; + } + +@@ -237,9 +239,8 @@ + if ( ( (unsigned int) key.ivec_size() ) != iv_length) + throw YAPETException (_ ("IVec length missmatch") ); + +- EVP_CIPHER_CTX ctx; +- EVP_CIPHER_CTX_init (&ctx); +- int retval = EVP_DecryptInit_ex (&ctx, ++ EVP_CIPHER_CTX* ctx = create_context (); ++ int retval = EVP_DecryptInit_ex (ctx, + cipher, + 0, + key, +@@ -246,20 +247,20 @@ + key.getIVec() ); + + if (retval == 0) { +- EVP_CIPHER_CTX_cleanup (&ctx); ++ destroy_context (ctx); + throw YAPETEncryptionException (_ ("Error initializing encryption engine") ); + } + +- retval = EVP_CIPHER_CTX_set_key_length (&ctx, key.size() ); ++ retval = EVP_CIPHER_CTX_set_key_length (ctx, key.size() ); + + if (retval == 0) { +- EVP_CIPHER_CTX_cleanup (&ctx); ++ destroy_context (ctx); + throw YAPETException (_ ("Error setting the key length") ); + } + + BDBuffer* decdata = new BDBuffer (data.size() ); + int outlen; +- retval = EVP_DecryptUpdate (&ctx, ++ retval = EVP_DecryptUpdate (ctx, + *decdata, + &outlen, + data, +@@ -266,24 +267,24 @@ + data.size() ); + + if (retval == 0) { +- EVP_CIPHER_CTX_cleanup (&ctx); ++ destroy_context (ctx); + delete decdata; + throw YAPETEncryptionException (_ ("Error decrypting data") ); + } + + int tmplen; +- retval = EVP_DecryptFinal_ex (&ctx, ++ retval = EVP_DecryptFinal_ex (ctx, + decdata->at (outlen), + &tmplen); + + if (retval == 0) { +- EVP_CIPHER_CTX_cleanup (&ctx); ++ destroy_context (ctx); + delete decdata; + throw YAPETEncryptionException (_ ("Error finalizing decryption") ); + } + + decdata->resize (outlen + tmplen); +- EVP_CIPHER_CTX_cleanup (&ctx); ++ destroy_context (ctx); + Record* r = 0; + try { + r = new Record; +Index: crypt/key.cc +=================================================================== +--- crypt/key.cc (revision 6011) ++++ crypt/key.cc (revision 6988) +@@ -45,6 +45,29 @@ + std::memset (IVec, 0, IVECLENGTH); + } + ++EVP_MD_CTX* ++Key::create_context() { ++#ifdef HAVE_EVP_MD_CTX_CREATE ++ return EVP_MD_CTX_create (); ++#elif HAVE_EVP_MD_CTX_NEW ++ return EVP_MD_CTX_new(); ++#else ++#error "Neither EVP_MD_CTX_create() nor EVP_MD_CTX_new() available" ++#endif ++} ++ ++void ++Key::destroy_context(EVP_MD_CTX *context) { ++#ifdef HAVE_EVP_MD_CTX_DESTROY ++ EVP_MD_CTX_destroy (context); ++#elif HAVE_EVP_MD_CTX_FREE ++ EVP_MD_CTX_free(context); ++#else ++#error "Neither EVP_MD_CTX_destroy() nor EVP_MD_CTX_free() available" ++#endif ++} ++ ++ + /** + * Initializes the key and the initialization vector. Make sure you + * securely destroy the password provided to this method. +@@ -63,39 +86,39 @@ + if (md == 0) + throw YAPETException (_ ("Run 1: Unable to initialize the EVP_MD structure") ); + +- EVP_MD_CTX mdctx; +- EVP_MD_CTX_init (&mdctx); +- int retval = EVP_DigestInit_ex (&mdctx, md, 0); ++ EVP_MD_CTX *mdctx = create_context(); + ++ int retval = EVP_DigestInit_ex (mdctx, md, 0); ++ + if (retval == 0) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + throw YAPETException (_ ("Run 1: Unable to initialize the digest") ); + } + +- retval = EVP_DigestUpdate (&mdctx, password, std::strlen (password) ); ++ retval = EVP_DigestUpdate (mdctx, password, std::strlen (password) ); + + if (retval == 0) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + throw YAPETException (_ ("Run 1: Unable to update the digest") ); + } + + unsigned int tmplen; +- retval = EVP_DigestFinal_ex (&mdctx, key, &tmplen); ++ retval = EVP_DigestFinal_ex (mdctx, key, &tmplen); + + if (retval == 0) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + cleanup(); + throw YAPETException (_ ("Run 1: Unable to finalize the digest") ); + } + + if (tmplen != SHA1_LEN) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + cleanup(); + throw YAPETException (_ ("Run 1: Digest does not have expected length") ); + } + + eff_keylength = tmplen; +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + // + // Second run (md5) + // +@@ -106,39 +129,39 @@ + throw YAPETException (_ ("Run 2: Unable to initialize the EVP_MD structure") ); + } + +- EVP_MD_CTX_init (&mdctx); +- retval = EVP_DigestInit_ex (&mdctx, md, 0); ++ mdctx=create_context(); ++ retval = EVP_DigestInit_ex (mdctx, md, 0); + + if (retval == 0) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + cleanup(); + throw YAPETException (_ ("Run 2: Unable to initialize the digest") ); + } + +- retval = EVP_DigestUpdate (&mdctx, key, SHA1_LEN); ++ retval = EVP_DigestUpdate (mdctx, key, SHA1_LEN); + + if (retval == 0) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + cleanup(); + throw YAPETException (_ ("Run 2: Unable to update the digest") ); + } + +- retval = EVP_DigestFinal_ex (&mdctx, key + SHA1_LEN, &tmplen); ++ retval = EVP_DigestFinal_ex (mdctx, key + SHA1_LEN, &tmplen); + + if (retval == 0) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + cleanup(); + throw YAPETException (_ ("Run 2: Unable to finalize the digest") ); + } + + if (tmplen != MD5_LEN) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + cleanup(); + throw YAPETException (_ ("Run 2: Digest does not have expected length") ); + } + + eff_keylength += tmplen; +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + // + // Third run (ripemd160) + // +@@ -149,39 +172,39 @@ + throw YAPETException (_ ("Run 3: Unable to initialize the EVP_MD structure") ); + } + +- EVP_MD_CTX_init (&mdctx); +- retval = EVP_DigestInit_ex (&mdctx, md, 0); ++ mdctx = create_context(); ++ retval = EVP_DigestInit_ex (mdctx, md, 0); + + if (retval == 0) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + cleanup(); + throw YAPETException (_ ("Run 3: Unable to initialize the digest") ); + } + +- retval = EVP_DigestUpdate (&mdctx, key, SHA1_LEN + MD5_LEN); ++ retval = EVP_DigestUpdate (mdctx, key, SHA1_LEN + MD5_LEN); + + if (retval == 0) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + cleanup(); + throw YAPETException (_ ("Run 3: Unable to update the digest") ); + } + +- retval = EVP_DigestFinal_ex (&mdctx, key + SHA1_LEN + MD5_LEN, &tmplen); ++ retval = EVP_DigestFinal_ex (mdctx, key + SHA1_LEN + MD5_LEN, &tmplen); + + if (retval == 0) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + cleanup(); + throw YAPETException (_ ("Run 3: Unable to finalize the digest") ); + } + + if (tmplen != RIPEMD160_LEN) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + cleanup(); + throw YAPETException (_ ("Run 3: Digest does not have expected length") ); + } + + eff_keylength += tmplen; +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + + if (eff_keylength != KEYLENGTH) { + cleanup(); +@@ -205,38 +228,38 @@ + throw YAPETException (_ ("IVec: Unable to initialize the EVP_MD structure") ); + } + +- EVP_MD_CTX_init (&mdctx); +- retval = EVP_DigestInit_ex (&mdctx, md, 0); ++ mdctx = create_context(); ++ retval = EVP_DigestInit_ex (mdctx, md, 0); + + if (retval == 0) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + cleanup(); + throw YAPETException (_ ("IVec: Unable to initialize the digest") ); + } + +- retval = EVP_DigestUpdate (&mdctx, key, SHA1_LEN + MD5_LEN + RIPEMD160_LEN); ++ retval = EVP_DigestUpdate (mdctx, key, SHA1_LEN + MD5_LEN + RIPEMD160_LEN); + + if (retval == 0) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + cleanup(); + throw YAPETException (_ ("IVec: Unable to update the digest") ); + } + +- retval = EVP_DigestFinal_ex (&mdctx, ivec_hash_buf, &tmplen); ++ retval = EVP_DigestFinal_ex (mdctx, ivec_hash_buf, &tmplen); + + if (retval == 0) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + cleanup(); + throw YAPETException (_ ("IVec: Unable to finalize the digest") ); + } + + if (tmplen != MD5_LEN) { +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + cleanup(); + throw YAPETException (_ ("IVec: Digest does not have expected length") ); + } + +- EVP_MD_CTX_cleanup (&mdctx); ++ destroy_context(mdctx); + std::memcpy (IVec, ivec_hash_buf, IVECLENGTH); + std::memset (ivec_hash_buf, 0, MD5_LEN); + } +Index: crypt/key.h +=================================================================== +--- crypt/key.h (revision 6011) ++++ crypt/key.h (revision 6988) +@@ -114,6 +114,10 @@ + //! Cleanup routine + void cleanup(); + ++ EVP_MD_CTX *create_context(); ++ ++ void destroy_context(EVP_MD_CTX *context); ++ + public: + //! Initializes the key + Key (const char* password) throw (YAPETException); +Index: po/de.po +=================================================================== +--- po/de.po (revision 6011) ++++ po/de.po (revision 6988) +@@ -9,7 +9,7 @@ + msgstr "" + "Project-Id-Version: YAPET 1.0\n" + "Report-Msgid-Bugs-To: Rafael Ostertag \n" +-"POT-Creation-Date: 2014-02-18 18:05+0100\n" ++"POT-Creation-Date: 2016-11-09 20:57+0100\n" + "PO-Revision-Date: 2013-12-28 19:53+0100\n" + "Last-Translator: Rafael Ostertag \n" + "Language-Team: German\n" +@@ -27,39 +27,39 @@ + msgid "Position out of range" + msgstr "Position ausserhalb des Bereiches" + +-#: crypt/crypt.cc:57 ++#: crypt/crypt.cc:82 + msgid "Unable to get cipher" + msgstr "Kann die Verschlüsselung nicht ermitteln" + +-#: crypt/crypt.cc:66 ++#: crypt/crypt.cc:90 + msgid "Error initializing cipher" + msgstr "Fehler beim Initialisieren der Verschlüsselung" + +-#: crypt/crypt.cc:73 crypt/crypt.h:179 crypt/crypt.h:257 ++#: crypt/crypt.cc:97 crypt/crypt.h:181 crypt/crypt.h:258 + msgid "Error setting the key length" + msgstr "Kann die Schlüssellänge nicht setzen" + +-#: crypt/crypt.h:160 crypt/crypt.h:238 ++#: crypt/crypt.h:163 crypt/crypt.h:240 + msgid "IVec length missmatch" + msgstr "IVec Länge falsch" + +-#: crypt/crypt.h:172 crypt/crypt.h:250 ++#: crypt/crypt.h:174 crypt/crypt.h:251 + msgid "Error initializing encryption engine" + msgstr "Fehler beim Initialisieren der Verschlüsselung" + +-#: crypt/crypt.h:194 ++#: crypt/crypt.h:196 + msgid "Error encrypting data" + msgstr "Fehler beim Verschlüsseln der Daten" + +-#: crypt/crypt.h:205 ++#: crypt/crypt.h:207 + msgid "Error finalizing encryption" + msgstr "Fehler beim Abschliessen der Verschlüsselung" + +-#: crypt/crypt.h:271 ++#: crypt/crypt.h:272 + msgid "Error decrypting data" + msgstr "Fehler beim Entschlüsseln der Daten" + +-#: crypt/crypt.h:282 ++#: crypt/crypt.h:283 + msgid "Error finalizing decryption" + msgstr "Fehler beim Abschliessen der Entschlüsselung" + +@@ -127,67 +127,67 @@ + msgid "File has been externally modified" + msgstr "Datei wurde von ausserhalb verändert" + +-#: crypt/key.cc:64 ++#: crypt/key.cc:87 + msgid "Run 1: Unable to initialize the EVP_MD structure" + msgstr "Lauf 1: Kann EVP_MD Struktur nicht initialisieren" + +-#: crypt/key.cc:72 ++#: crypt/key.cc:95 + msgid "Run 1: Unable to initialize the digest" + msgstr "Lauf 1: Kann Digest nicht initialisieren" + +-#: crypt/key.cc:79 ++#: crypt/key.cc:102 + msgid "Run 1: Unable to update the digest" + msgstr "Lauf 1: Digest kann nicht angepasst werden" + +-#: crypt/key.cc:88 ++#: crypt/key.cc:111 + msgid "Run 1: Unable to finalize the digest" + msgstr "Lauf 1: Kann Digest nicht abschliessen" + +-#: crypt/key.cc:94 ++#: crypt/key.cc:117 + msgid "Run 1: Digest does not have expected length" + msgstr "Lauf 1: Digest hat unerwartete Länge" + +-#: crypt/key.cc:106 ++#: crypt/key.cc:129 + msgid "Run 2: Unable to initialize the EVP_MD structure" + msgstr "Lauf 2: Kann EVP_MD Struktur nicht initialisieren" + +-#: crypt/key.cc:115 ++#: crypt/key.cc:138 + msgid "Run 2: Unable to initialize the digest" + msgstr "Lauf 2: Kann Digest nicht initialisieren" + +-#: crypt/key.cc:123 ++#: crypt/key.cc:146 + msgid "Run 2: Unable to update the digest" + msgstr "Lauf 2: Digest kann nicht angepasst werden" + +-#: crypt/key.cc:131 ++#: crypt/key.cc:154 + msgid "Run 2: Unable to finalize the digest" + msgstr "Lauf 2: Kann Digest nicht abschliessen" + +-#: crypt/key.cc:137 ++#: crypt/key.cc:160 + msgid "Run 2: Digest does not have expected length" + msgstr "Lauf 2: Digest hat unerwartete Länge" + +-#: crypt/key.cc:149 ++#: crypt/key.cc:172 + msgid "Run 3: Unable to initialize the EVP_MD structure" + msgstr "Lauf 3: Kann EVP_MD Struktur nicht initialisieren" + +-#: crypt/key.cc:158 ++#: crypt/key.cc:181 + msgid "Run 3: Unable to initialize the digest" + msgstr "Lauf 3: Kann Digest nicht initialisieren" + +-#: crypt/key.cc:166 ++#: crypt/key.cc:189 + msgid "Run 3: Unable to update the digest" + msgstr "Lauf 3: Digest kann nicht angepasst werden" + +-#: crypt/key.cc:174 ++#: crypt/key.cc:197 + msgid "Run 3: Unable to finalize the digest" + msgstr "Lauf 3: Kann Digest nicht abschliessen" + +-#: crypt/key.cc:180 ++#: crypt/key.cc:203 + msgid "Run 3: Digest does not have expected length" + msgstr "Lauf 3: Digest hat unerwartete Länge" + +-#: crypt/key.cc:191 ++#: crypt/key.cc:214 + #, c-format + msgid "Effective key length of %d does not match expected key length %d" + msgstr "" +@@ -194,23 +194,23 @@ + "Die effektive Schlüssellänge %d passt nicht auf die erwartete Schlüssellänge " + "%d" + +-#: crypt/key.cc:205 ++#: crypt/key.cc:228 + msgid "IVec: Unable to initialize the EVP_MD structure" + msgstr "IVec: Kann EVP_MD Struktur nicht initialisieren" + +-#: crypt/key.cc:214 ++#: crypt/key.cc:237 + msgid "IVec: Unable to initialize the digest" + msgstr "IVec: Kann Digest nicht initialisieren" + +-#: crypt/key.cc:222 ++#: crypt/key.cc:245 + msgid "IVec: Unable to update the digest" + msgstr "IVec: Kann Digest nicht anpassen" + +-#: crypt/key.cc:230 ++#: crypt/key.cc:253 + msgid "IVec: Unable to finalize the digest" + msgstr "IVec: Kann Digest nicht abschliessen" + +-#: crypt/key.cc:236 ++#: crypt/key.cc:259 + msgid "IVec: Digest does not have expected length" + msgstr "IVec: Digest hat unerwartete Länge" + +@@ -240,9 +240,8 @@ + + #: glue/createfile.cc:80 glue/promptpassword.cc:60 glue/changepassword.cc:52 + #: glue/changepassword.cc:62 glue/changepassword.cc:116 +-#: glue/opencmdlinefile.cc:103 ui/passwordrecord.cc:88 +-#: ui/passwordrecord.cc:248 ui/mainwindow.cc:420 ui/mainwindow.cc:472 +-#: ui/mainwindow.cc:503 ++#: glue/opencmdlinefile.cc:103 ui/passwordrecord.cc:88 ui/passwordrecord.cc:248 ++#: ui/mainwindow.cc:420 ui/mainwindow.cc:472 ui/mainwindow.cc:503 + msgid "Error" + msgstr "Fehler" + +Index: po/yapet.pot +=================================================================== +--- po/yapet.pot (revision 6011) ++++ po/yapet.pot (revision 6988) +@@ -1,6 +1,6 @@ + # SOME DESCRIPTIVE TITLE. + # Copyright (C) YEAR Free Software Foundation, Inc. +-# This file is distributed under the same license as the PACKAGE package. ++# This file is distributed under the same license as the yapet package. + # FIRST AUTHOR , YEAR. + # + #, fuzzy +@@ -8,7 +8,7 @@ + msgstr "" + "Project-Id-Version: yapet 1.0\n" + "Report-Msgid-Bugs-To: Rafael Ostertag \n" +-"POT-Creation-Date: 2014-02-18 18:05+0100\n" ++"POT-Creation-Date: 2016-11-09 20:57+0100\n" + "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" + "Last-Translator: FULL NAME \n" + "Language-Team: LANGUAGE \n" +@@ -25,39 +25,39 @@ + msgid "Position out of range" + msgstr "" + +-#: crypt/crypt.cc:57 ++#: crypt/crypt.cc:82 + msgid "Unable to get cipher" + msgstr "" + +-#: crypt/crypt.cc:66 ++#: crypt/crypt.cc:90 + msgid "Error initializing cipher" + msgstr "" + +-#: crypt/crypt.cc:73 crypt/crypt.h:179 crypt/crypt.h:257 ++#: crypt/crypt.cc:97 crypt/crypt.h:181 crypt/crypt.h:258 + msgid "Error setting the key length" + msgstr "" + +-#: crypt/crypt.h:160 crypt/crypt.h:238 ++#: crypt/crypt.h:163 crypt/crypt.h:240 + msgid "IVec length missmatch" + msgstr "" + +-#: crypt/crypt.h:172 crypt/crypt.h:250 ++#: crypt/crypt.h:174 crypt/crypt.h:251 + msgid "Error initializing encryption engine" + msgstr "" + +-#: crypt/crypt.h:194 ++#: crypt/crypt.h:196 + msgid "Error encrypting data" + msgstr "" + +-#: crypt/crypt.h:205 ++#: crypt/crypt.h:207 + msgid "Error finalizing encryption" + msgstr "" + +-#: crypt/crypt.h:271 ++#: crypt/crypt.h:272 + msgid "Error decrypting data" + msgstr "" + +-#: crypt/crypt.h:282 ++#: crypt/crypt.h:283 + msgid "Error finalizing decryption" + msgstr "" + +@@ -125,88 +125,88 @@ + msgid "File has been externally modified" + msgstr "" + +-#: crypt/key.cc:64 ++#: crypt/key.cc:87 + msgid "Run 1: Unable to initialize the EVP_MD structure" + msgstr "" + +-#: crypt/key.cc:72 ++#: crypt/key.cc:95 + msgid "Run 1: Unable to initialize the digest" + msgstr "" + +-#: crypt/key.cc:79 ++#: crypt/key.cc:102 + msgid "Run 1: Unable to update the digest" + msgstr "" + +-#: crypt/key.cc:88 ++#: crypt/key.cc:111 + msgid "Run 1: Unable to finalize the digest" + msgstr "" + +-#: crypt/key.cc:94 ++#: crypt/key.cc:117 + msgid "Run 1: Digest does not have expected length" + msgstr "" + +-#: crypt/key.cc:106 ++#: crypt/key.cc:129 + msgid "Run 2: Unable to initialize the EVP_MD structure" + msgstr "" + +-#: crypt/key.cc:115 ++#: crypt/key.cc:138 + msgid "Run 2: Unable to initialize the digest" + msgstr "" + +-#: crypt/key.cc:123 ++#: crypt/key.cc:146 + msgid "Run 2: Unable to update the digest" + msgstr "" + +-#: crypt/key.cc:131 ++#: crypt/key.cc:154 + msgid "Run 2: Unable to finalize the digest" + msgstr "" + +-#: crypt/key.cc:137 ++#: crypt/key.cc:160 + msgid "Run 2: Digest does not have expected length" + msgstr "" + +-#: crypt/key.cc:149 ++#: crypt/key.cc:172 + msgid "Run 3: Unable to initialize the EVP_MD structure" + msgstr "" + +-#: crypt/key.cc:158 ++#: crypt/key.cc:181 + msgid "Run 3: Unable to initialize the digest" + msgstr "" + +-#: crypt/key.cc:166 ++#: crypt/key.cc:189 + msgid "Run 3: Unable to update the digest" + msgstr "" + +-#: crypt/key.cc:174 ++#: crypt/key.cc:197 + msgid "Run 3: Unable to finalize the digest" + msgstr "" + +-#: crypt/key.cc:180 ++#: crypt/key.cc:203 + msgid "Run 3: Digest does not have expected length" + msgstr "" + +-#: crypt/key.cc:191 ++#: crypt/key.cc:214 + #, c-format + msgid "Effective key length of %d does not match expected key length %d" + msgstr "" + +-#: crypt/key.cc:205 ++#: crypt/key.cc:228 + msgid "IVec: Unable to initialize the EVP_MD structure" + msgstr "" + +-#: crypt/key.cc:214 ++#: crypt/key.cc:237 + msgid "IVec: Unable to initialize the digest" + msgstr "" + +-#: crypt/key.cc:222 ++#: crypt/key.cc:245 + msgid "IVec: Unable to update the digest" + msgstr "" + +-#: crypt/key.cc:230 ++#: crypt/key.cc:253 + msgid "IVec: Unable to finalize the digest" + msgstr "" + +-#: crypt/key.cc:236 ++#: crypt/key.cc:259 + msgid "IVec: Digest does not have expected length" + msgstr "" + +@@ -236,9 +236,8 @@ + + #: glue/createfile.cc:80 glue/promptpassword.cc:60 glue/changepassword.cc:52 + #: glue/changepassword.cc:62 glue/changepassword.cc:116 +-#: glue/opencmdlinefile.cc:103 ui/passwordrecord.cc:88 +-#: ui/passwordrecord.cc:248 ui/mainwindow.cc:420 ui/mainwindow.cc:472 +-#: ui/mainwindow.cc:503 ++#: glue/opencmdlinefile.cc:103 ui/passwordrecord.cc:88 ui/passwordrecord.cc:248 ++#: ui/mainwindow.cc:420 ui/mainwindow.cc:472 ui/mainwindow.cc:503 + msgid "Error" + msgstr "" + +Index: tests/preload/Makefile.am +=================================================================== +--- tests/preload/Makefile.am (revision 6011) ++++ tests/preload/Makefile.am (revision 6988) +@@ -14,7 +14,7 @@ + ../../crypt/bdbuffer.cc ../../crypt/crypt.cc ../../crypt/file.cc \ + ../../crypt/key.cc ../../crypt/partdec.cc + checktestpwrecord_CPPFLAGS = -I$(top_srcdir)/crypt -I$(top_builddir) \ +--I$(top_srcdir) ++-I$(top_srcdir) $(OPENSSL_INCLUDES) + checktestpwrecord_LDADD = $(top_builddir)/crypt/libyapet-crypt.la $(LIBINTL) + + checkmasterpwchange_SOURCES = checkmasterpwchange.cc \ +@@ -21,7 +21,7 @@ + ../../crypt/bdbuffer.cc ../../crypt/crypt.cc ../../crypt/file.cc \ + ../../crypt/key.cc ../../crypt/partdec.cc + checkmasterpwchange_CPPFLAGS = -I$(top_srcdir)/crypt -I$(top_builddir) \ +--I$(top_srcdir) ++-I$(top_srcdir) $(OPENSSL_INCLUDES) + checkmasterpwchange_LDADD = $(top_builddir)/crypt/libyapet-crypt.la $(LIBINTL) + + istty_SOURCES = istty.cc +Index: yapet/cfg.h +=================================================================== +--- yapet/cfg.h (revision 6011) ++++ yapet/cfg.h (revision 6988) +@@ -163,7 +163,7 @@ + locked = false; + } + +- void is_locked() const { ++ bool is_locked() const { + return locked; + } + +Index: configure.ac +=================================================================== +--- configure.ac (revision 6011) ++++ configure.ac (revision 6988) +@@ -86,9 +86,10 @@ + LDFLAGS="$LDFLAGS $OPENSSL_LDFLAGS" + CPPFLAGS="$CPPFLAGS $OPENSSL_INCLUDES" + AC_MSG_NOTICE([Checking encryption functions]) +-AC_CHECK_FUNCS([EVP_bf_cbc EVP_CIPHER_CTX_cleanup EVP_CIPHER_CTX_init EVP_CIPHER_CTX_set_key_length EVP_CipherInit_ex EVP_DigestFinal_ex EVP_DigestInit_ex EVP_DigestUpdate EVP_MD_CTX_cleanup EVP_MD_CTX_init EVP_md5 EVP_ripemd160 EVP_sha1], ++AC_CHECK_FUNCS([EVP_bf_cbc EVP_CIPHER_CTX_set_key_length EVP_CipherInit_ex EVP_DigestFinal_ex EVP_DigestInit_ex EVP_DigestUpdate EVP_md5 EVP_ripemd160 EVP_sha1], + [], + [AC_MSG_ERROR([You are missing a crucial function required for $PACKAGE_NAME])]) ++AC_CHECK_FUNCS([EVP_CIPHER_CTX_cleanup EVP_CIPHER_CTX_free EVP_CIPHER_CTX_init EVP_CIPHER_CTX_new EVP_MD_CTX_destroy EVP_MD_CTX_create EVP_MD_CTX_free EVP_MD_CTX_new]) + AC_MSG_NOTICE([Checking support functions]) + AC_CHECK_FUNCS([SSLeay_version]) + LIBS="$LIBS_SAVE" diff --git a/yapet.spec b/yapet.spec index f1d1368..955c893 100644 --- a/yapet.spec +++ b/yapet.spec @@ -2,7 +2,7 @@ Name: yapet Version: 1.0 -Release: 8%{?pre}%{?dist} +Release: 9%{?pre}%{?dist} Summary: Yet Another Password Encryption Tool License: GPLv3+ with exceptions URL: http://www.guengel.ch/myapps/%{name}/ @@ -11,7 +11,11 @@ BuildRequires: gettext BuildRequires: ncurses-devel BuildRequires: openssl-devel +BuildRequires: automake +BuildRequires: autoconf + Patch0: bz1308262-gcc6-void-fn-returns-value.patch +Patch1: bz1424564-gcc-6_and_openssl-1.1.patch %description YAPET is a text based password manager using the Blowfish encryption algorithm. @@ -22,7 +26,11 @@ for installing on desktop and server systems alike. %setup -qn %{name}-%{version}%{?pre} # https://bugs.guengel.ch/show_bug.cgi?id=112 -%patch0 -p1 +# Skip this patch, as it is included by the subsequent patch now +# %patch0 -p1 + +# https://bugs.guengel.ch/show_bug.cgi?id=113 +%patch1 -p0 for f in ./DESIGN ./README do @@ -32,6 +40,11 @@ do done %build + +# Rebuild configure script because the supplied patches only modify configure.ac +aclocal -I m4 +autoconf + %configure --disable-install-doc \ --disable-source-doc \ --disable-install-doci \ @@ -62,6 +75,9 @@ rm -frv %{buildroot}%{_docdir} %{_mandir}/man*/*yapet* %changelog +* Wed Mar 1 2017 Greg Bailey - 1.0-9 +- Patch to fix build issues with GCC 6 and OpenSSL 1.1 (#1424564) + * Sat Feb 11 2017 Fedora Release Engineering - 1.0-8 - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild From 3c3e76d216696b01453236ad27621bd1c249c89f Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Thu, 27 Jul 2017 22:33:04 +0000 Subject: [PATCH 11/15] - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild --- yapet.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/yapet.spec b/yapet.spec index 955c893..f6e22ea 100644 --- a/yapet.spec +++ b/yapet.spec @@ -2,7 +2,7 @@ Name: yapet Version: 1.0 -Release: 9%{?pre}%{?dist} +Release: 10%{?pre}%{?dist} Summary: Yet Another Password Encryption Tool License: GPLv3+ with exceptions URL: http://www.guengel.ch/myapps/%{name}/ @@ -75,6 +75,9 @@ rm -frv %{buildroot}%{_docdir} %{_mandir}/man*/*yapet* %changelog +* Thu Jul 27 2017 Fedora Release Engineering - 1.0-10 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild + * Wed Mar 1 2017 Greg Bailey - 1.0-9 - Patch to fix build issues with GCC 6 and OpenSSL 1.1 (#1424564) From a875ed61fa660b6ab84178491e1ce9bfe91f8a52 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Thu, 3 Aug 2017 11:04:32 +0000 Subject: [PATCH 12/15] - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild --- yapet.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/yapet.spec b/yapet.spec index f6e22ea..b7da684 100644 --- a/yapet.spec +++ b/yapet.spec @@ -2,7 +2,7 @@ Name: yapet Version: 1.0 -Release: 10%{?pre}%{?dist} +Release: 11%{?pre}%{?dist} Summary: Yet Another Password Encryption Tool License: GPLv3+ with exceptions URL: http://www.guengel.ch/myapps/%{name}/ @@ -75,6 +75,9 @@ rm -frv %{buildroot}%{_docdir} %{_mandir}/man*/*yapet* %changelog +* Thu Aug 03 2017 Fedora Release Engineering - 1.0-11 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild + * Thu Jul 27 2017 Fedora Release Engineering - 1.0-10 - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild From 3ba6fdc56ddbdba8e48806c66c99f6321e527d25 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Fri, 9 Feb 2018 22:14:42 +0000 Subject: [PATCH 13/15] - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild Signed-off-by: Fedora Release Engineering --- yapet.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/yapet.spec b/yapet.spec index b7da684..50264e8 100644 --- a/yapet.spec +++ b/yapet.spec @@ -2,7 +2,7 @@ Name: yapet Version: 1.0 -Release: 11%{?pre}%{?dist} +Release: 12%{?pre}%{?dist} Summary: Yet Another Password Encryption Tool License: GPLv3+ with exceptions URL: http://www.guengel.ch/myapps/%{name}/ @@ -75,6 +75,9 @@ rm -frv %{buildroot}%{_docdir} %{_mandir}/man*/*yapet* %changelog +* Fri Feb 09 2018 Fedora Release Engineering - 1.0-12 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild + * Thu Aug 03 2017 Fedora Release Engineering - 1.0-11 - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild From 25cbaf987d62f4cb3007c015271dc39097280bee Mon Sep 17 00:00:00 2001 From: Greg Bailey Date: Wed, 28 Mar 2018 10:24:45 -0700 Subject: [PATCH 14/15] Update to yapet 1.1 --- .gitignore | 1 + bz1308262-gcc6-void-fn-returns-value.patch | 12 - bz1424564-gcc-6_and_openssl-1.1.patch | 893 --------------------- sources | 2 +- yapet.spec | 26 +- 5 files changed, 13 insertions(+), 921 deletions(-) delete mode 100644 bz1308262-gcc6-void-fn-returns-value.patch delete mode 100644 bz1424564-gcc-6_and_openssl-1.1.patch diff --git a/.gitignore b/.gitignore index cccf53c..8754f10 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,4 @@ yapet-0.6.tar.gz /yapet-0.7.tar.bz2 /yapet-0.8pre2.tar.bz2 /yapet-1.0.tar.bz2 +/yapet-1.1.tar.xz diff --git a/bz1308262-gcc6-void-fn-returns-value.patch b/bz1308262-gcc6-void-fn-returns-value.patch deleted file mode 100644 index 67775d9..0000000 --- a/bz1308262-gcc6-void-fn-returns-value.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -uNr yapet-1.0.orig/yapet/cfg.h yapet-1.0/yapet/cfg.h ---- yapet-1.0.orig/yapet/cfg.h 2014-02-23 10:18:41.000000000 -0700 -+++ yapet-1.0/yapet/cfg.h 2016-04-14 07:06:49.665672169 -0700 -@@ -163,7 +163,7 @@ - locked = false; - } - -- void is_locked() const { -+ bool is_locked() const { - return locked; - } - diff --git a/bz1424564-gcc-6_and_openssl-1.1.patch b/bz1424564-gcc-6_and_openssl-1.1.patch deleted file mode 100644 index f8e6754..0000000 --- a/bz1424564-gcc-6_and_openssl-1.1.patch +++ /dev/null @@ -1,893 +0,0 @@ -Index: crypt/crypt.cc -=================================================================== ---- crypt/crypt.cc (revision 6011) -+++ crypt/crypt.cc (revision 6988) -@@ -34,6 +34,31 @@ - - using namespace YAPET; - -+EVP_CIPHER_CTX* -+Crypt::create_context() { -+#ifdef HAVE_EVP_CIPHER_CTX_INIT -+ EVP_CIPHER_CTX *context = (EVP_CIPHER_CTX*) std::malloc(sizeof(EVP_CIPHER_CTX)); -+ EVP_CIPHER_CTX_init(context); -+ return context; -+#elif HAVE_EVP_CIPHER_CTX_NEW -+ return EVP_CIPHER_CTX_new(); -+#else -+ #error "Neither EVP_CIPHER_CTX_init() nor EVP_CIPHER_CTX_new() available" -+#endif -+} -+ -+void -+Crypt::destroy_context(EVP_CIPHER_CTX *context) { -+#ifdef HAVE_EVP_CIPHER_CTX_CLEANUP -+ EVP_CIPHER_CTX_cleanup(context); -+ std::free(context); -+#elif HAVE_EVP_CIPHER_CTX_FREE -+ EVP_CIPHER_CTX_free(context); -+#else -+#error "Neither EVP_CIPHER_CTX_cleanup() nor EVP_CIPHER_CTX_free() available" -+#endif -+} -+ - /** - * Initializes the class with the given key, which is used for - * encryption and decryption. -@@ -57,25 +82,24 @@ - throw YAPETException (_ ("Unable to get cipher") ); - - // Test if key length is ok -- EVP_CIPHER_CTX ctx; -- EVP_CIPHER_CTX_init (&ctx); -- int retval = EVP_CipherInit_ex (&ctx, cipher, 0, 0, 0, 0); -+ EVP_CIPHER_CTX* ctx = create_context(); -+ int retval = EVP_CipherInit_ex (ctx, cipher, 0, 0, 0, 0); - - if (retval == 0) { -- EVP_CIPHER_CTX_cleanup (&ctx); -+ destroy_context(ctx); - throw YAPETException (_ ("Error initializing cipher") ); - } - -- retval = EVP_CIPHER_CTX_set_key_length (&ctx, key.size() ); -+ retval = EVP_CIPHER_CTX_set_key_length (ctx, key.size() ); - - if (retval == 0) { -- EVP_CIPHER_CTX_cleanup (&ctx); -+ destroy_context(ctx); - throw YAPETException (_ ("Error setting the key length") ); - } - -- iv_length = EVP_CIPHER_CTX_iv_length (&ctx); -- key_length = EVP_CIPHER_CTX_key_length (&ctx); -- EVP_CIPHER_CTX_cleanup (&ctx); -+ iv_length = EVP_CIPHER_CTX_iv_length (ctx); -+ key_length = EVP_CIPHER_CTX_key_length (ctx); -+ destroy_context(ctx); - } - - Crypt::Crypt (const Crypt& c) : cipher (c.cipher), -Index: crypt/crypt.h -=================================================================== ---- crypt/crypt.h (revision 6011) -+++ crypt/crypt.h (revision 6988) -@@ -100,6 +100,9 @@ - */ - Key key; - -+ EVP_CIPHER_CTX *create_context(); -+ void destroy_context(EVP_CIPHER_CTX *context); -+ - public: - //! Constructor - Crypt (const Key& k) throw (YAPETException); -@@ -159,9 +162,8 @@ - if (key.ivec_size() != iv_length) - throw YAPETException (_ ("IVec length missmatch") ); - -- EVP_CIPHER_CTX ctx; -- EVP_CIPHER_CTX_init (&ctx); -- int retval = EVP_EncryptInit_ex (&ctx, -+ EVP_CIPHER_CTX *ctx=create_context (); -+ int retval = EVP_EncryptInit_ex (ctx, - cipher, - 0, - key, -@@ -168,14 +170,14 @@ - key.getIVec() ); - - if (retval == 0) { -- EVP_CIPHER_CTX_cleanup (&ctx); -+ destroy_context (ctx); - throw YAPETEncryptionException (_ ("Error initializing encryption engine") ); - } - -- retval = EVP_CIPHER_CTX_set_key_length (&ctx, key.size() ); -+ retval = EVP_CIPHER_CTX_set_key_length (ctx, key.size() ); - - if (retval == 0) { -- EVP_CIPHER_CTX_cleanup (&ctx); -+ destroy_context (ctx); - throw YAPETException (_ ("Error setting the key length") ); - } - -@@ -182,7 +184,7 @@ - BDBuffer* encdata = - new BDBuffer (data.size() + EVP_MAX_BLOCK_LENGTH); - int outlen; -- retval = EVP_EncryptUpdate (&ctx, -+ retval = EVP_EncryptUpdate (ctx, - *encdata, - &outlen, - data, -@@ -189,24 +191,24 @@ - data.size() ); - - if (retval == 0) { -- EVP_CIPHER_CTX_cleanup (&ctx); -+ destroy_context (ctx); - delete encdata; - throw YAPETEncryptionException (_ ("Error encrypting data") ); - } - - int tmplen; -- retval = EVP_EncryptFinal_ex (&ctx, -+ retval = EVP_EncryptFinal_ex (ctx, - encdata->at (outlen), - &tmplen); - - if (retval == 0) { -- EVP_CIPHER_CTX_cleanup (&ctx); -+ destroy_context (ctx); - delete encdata; - throw YAPETEncryptionException (_ ("Error finalizing encryption") ); - } - - encdata->resize (outlen + tmplen); -- EVP_CIPHER_CTX_cleanup (&ctx); -+ destroy_context (ctx); - return encdata; - } - -@@ -237,9 +239,8 @@ - if ( ( (unsigned int) key.ivec_size() ) != iv_length) - throw YAPETException (_ ("IVec length missmatch") ); - -- EVP_CIPHER_CTX ctx; -- EVP_CIPHER_CTX_init (&ctx); -- int retval = EVP_DecryptInit_ex (&ctx, -+ EVP_CIPHER_CTX* ctx = create_context (); -+ int retval = EVP_DecryptInit_ex (ctx, - cipher, - 0, - key, -@@ -246,20 +247,20 @@ - key.getIVec() ); - - if (retval == 0) { -- EVP_CIPHER_CTX_cleanup (&ctx); -+ destroy_context (ctx); - throw YAPETEncryptionException (_ ("Error initializing encryption engine") ); - } - -- retval = EVP_CIPHER_CTX_set_key_length (&ctx, key.size() ); -+ retval = EVP_CIPHER_CTX_set_key_length (ctx, key.size() ); - - if (retval == 0) { -- EVP_CIPHER_CTX_cleanup (&ctx); -+ destroy_context (ctx); - throw YAPETException (_ ("Error setting the key length") ); - } - - BDBuffer* decdata = new BDBuffer (data.size() ); - int outlen; -- retval = EVP_DecryptUpdate (&ctx, -+ retval = EVP_DecryptUpdate (ctx, - *decdata, - &outlen, - data, -@@ -266,24 +267,24 @@ - data.size() ); - - if (retval == 0) { -- EVP_CIPHER_CTX_cleanup (&ctx); -+ destroy_context (ctx); - delete decdata; - throw YAPETEncryptionException (_ ("Error decrypting data") ); - } - - int tmplen; -- retval = EVP_DecryptFinal_ex (&ctx, -+ retval = EVP_DecryptFinal_ex (ctx, - decdata->at (outlen), - &tmplen); - - if (retval == 0) { -- EVP_CIPHER_CTX_cleanup (&ctx); -+ destroy_context (ctx); - delete decdata; - throw YAPETEncryptionException (_ ("Error finalizing decryption") ); - } - - decdata->resize (outlen + tmplen); -- EVP_CIPHER_CTX_cleanup (&ctx); -+ destroy_context (ctx); - Record* r = 0; - try { - r = new Record; -Index: crypt/key.cc -=================================================================== ---- crypt/key.cc (revision 6011) -+++ crypt/key.cc (revision 6988) -@@ -45,6 +45,29 @@ - std::memset (IVec, 0, IVECLENGTH); - } - -+EVP_MD_CTX* -+Key::create_context() { -+#ifdef HAVE_EVP_MD_CTX_CREATE -+ return EVP_MD_CTX_create (); -+#elif HAVE_EVP_MD_CTX_NEW -+ return EVP_MD_CTX_new(); -+#else -+#error "Neither EVP_MD_CTX_create() nor EVP_MD_CTX_new() available" -+#endif -+} -+ -+void -+Key::destroy_context(EVP_MD_CTX *context) { -+#ifdef HAVE_EVP_MD_CTX_DESTROY -+ EVP_MD_CTX_destroy (context); -+#elif HAVE_EVP_MD_CTX_FREE -+ EVP_MD_CTX_free(context); -+#else -+#error "Neither EVP_MD_CTX_destroy() nor EVP_MD_CTX_free() available" -+#endif -+} -+ -+ - /** - * Initializes the key and the initialization vector. Make sure you - * securely destroy the password provided to this method. -@@ -63,39 +86,39 @@ - if (md == 0) - throw YAPETException (_ ("Run 1: Unable to initialize the EVP_MD structure") ); - -- EVP_MD_CTX mdctx; -- EVP_MD_CTX_init (&mdctx); -- int retval = EVP_DigestInit_ex (&mdctx, md, 0); -+ EVP_MD_CTX *mdctx = create_context(); - -+ int retval = EVP_DigestInit_ex (mdctx, md, 0); -+ - if (retval == 0) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - throw YAPETException (_ ("Run 1: Unable to initialize the digest") ); - } - -- retval = EVP_DigestUpdate (&mdctx, password, std::strlen (password) ); -+ retval = EVP_DigestUpdate (mdctx, password, std::strlen (password) ); - - if (retval == 0) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - throw YAPETException (_ ("Run 1: Unable to update the digest") ); - } - - unsigned int tmplen; -- retval = EVP_DigestFinal_ex (&mdctx, key, &tmplen); -+ retval = EVP_DigestFinal_ex (mdctx, key, &tmplen); - - if (retval == 0) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - cleanup(); - throw YAPETException (_ ("Run 1: Unable to finalize the digest") ); - } - - if (tmplen != SHA1_LEN) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - cleanup(); - throw YAPETException (_ ("Run 1: Digest does not have expected length") ); - } - - eff_keylength = tmplen; -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - // - // Second run (md5) - // -@@ -106,39 +129,39 @@ - throw YAPETException (_ ("Run 2: Unable to initialize the EVP_MD structure") ); - } - -- EVP_MD_CTX_init (&mdctx); -- retval = EVP_DigestInit_ex (&mdctx, md, 0); -+ mdctx=create_context(); -+ retval = EVP_DigestInit_ex (mdctx, md, 0); - - if (retval == 0) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - cleanup(); - throw YAPETException (_ ("Run 2: Unable to initialize the digest") ); - } - -- retval = EVP_DigestUpdate (&mdctx, key, SHA1_LEN); -+ retval = EVP_DigestUpdate (mdctx, key, SHA1_LEN); - - if (retval == 0) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - cleanup(); - throw YAPETException (_ ("Run 2: Unable to update the digest") ); - } - -- retval = EVP_DigestFinal_ex (&mdctx, key + SHA1_LEN, &tmplen); -+ retval = EVP_DigestFinal_ex (mdctx, key + SHA1_LEN, &tmplen); - - if (retval == 0) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - cleanup(); - throw YAPETException (_ ("Run 2: Unable to finalize the digest") ); - } - - if (tmplen != MD5_LEN) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - cleanup(); - throw YAPETException (_ ("Run 2: Digest does not have expected length") ); - } - - eff_keylength += tmplen; -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - // - // Third run (ripemd160) - // -@@ -149,39 +172,39 @@ - throw YAPETException (_ ("Run 3: Unable to initialize the EVP_MD structure") ); - } - -- EVP_MD_CTX_init (&mdctx); -- retval = EVP_DigestInit_ex (&mdctx, md, 0); -+ mdctx = create_context(); -+ retval = EVP_DigestInit_ex (mdctx, md, 0); - - if (retval == 0) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - cleanup(); - throw YAPETException (_ ("Run 3: Unable to initialize the digest") ); - } - -- retval = EVP_DigestUpdate (&mdctx, key, SHA1_LEN + MD5_LEN); -+ retval = EVP_DigestUpdate (mdctx, key, SHA1_LEN + MD5_LEN); - - if (retval == 0) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - cleanup(); - throw YAPETException (_ ("Run 3: Unable to update the digest") ); - } - -- retval = EVP_DigestFinal_ex (&mdctx, key + SHA1_LEN + MD5_LEN, &tmplen); -+ retval = EVP_DigestFinal_ex (mdctx, key + SHA1_LEN + MD5_LEN, &tmplen); - - if (retval == 0) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - cleanup(); - throw YAPETException (_ ("Run 3: Unable to finalize the digest") ); - } - - if (tmplen != RIPEMD160_LEN) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - cleanup(); - throw YAPETException (_ ("Run 3: Digest does not have expected length") ); - } - - eff_keylength += tmplen; -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - - if (eff_keylength != KEYLENGTH) { - cleanup(); -@@ -205,38 +228,38 @@ - throw YAPETException (_ ("IVec: Unable to initialize the EVP_MD structure") ); - } - -- EVP_MD_CTX_init (&mdctx); -- retval = EVP_DigestInit_ex (&mdctx, md, 0); -+ mdctx = create_context(); -+ retval = EVP_DigestInit_ex (mdctx, md, 0); - - if (retval == 0) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - cleanup(); - throw YAPETException (_ ("IVec: Unable to initialize the digest") ); - } - -- retval = EVP_DigestUpdate (&mdctx, key, SHA1_LEN + MD5_LEN + RIPEMD160_LEN); -+ retval = EVP_DigestUpdate (mdctx, key, SHA1_LEN + MD5_LEN + RIPEMD160_LEN); - - if (retval == 0) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - cleanup(); - throw YAPETException (_ ("IVec: Unable to update the digest") ); - } - -- retval = EVP_DigestFinal_ex (&mdctx, ivec_hash_buf, &tmplen); -+ retval = EVP_DigestFinal_ex (mdctx, ivec_hash_buf, &tmplen); - - if (retval == 0) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - cleanup(); - throw YAPETException (_ ("IVec: Unable to finalize the digest") ); - } - - if (tmplen != MD5_LEN) { -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - cleanup(); - throw YAPETException (_ ("IVec: Digest does not have expected length") ); - } - -- EVP_MD_CTX_cleanup (&mdctx); -+ destroy_context(mdctx); - std::memcpy (IVec, ivec_hash_buf, IVECLENGTH); - std::memset (ivec_hash_buf, 0, MD5_LEN); - } -Index: crypt/key.h -=================================================================== ---- crypt/key.h (revision 6011) -+++ crypt/key.h (revision 6988) -@@ -114,6 +114,10 @@ - //! Cleanup routine - void cleanup(); - -+ EVP_MD_CTX *create_context(); -+ -+ void destroy_context(EVP_MD_CTX *context); -+ - public: - //! Initializes the key - Key (const char* password) throw (YAPETException); -Index: po/de.po -=================================================================== ---- po/de.po (revision 6011) -+++ po/de.po (revision 6988) -@@ -9,7 +9,7 @@ - msgstr "" - "Project-Id-Version: YAPET 1.0\n" - "Report-Msgid-Bugs-To: Rafael Ostertag \n" --"POT-Creation-Date: 2014-02-18 18:05+0100\n" -+"POT-Creation-Date: 2016-11-09 20:57+0100\n" - "PO-Revision-Date: 2013-12-28 19:53+0100\n" - "Last-Translator: Rafael Ostertag \n" - "Language-Team: German\n" -@@ -27,39 +27,39 @@ - msgid "Position out of range" - msgstr "Position ausserhalb des Bereiches" - --#: crypt/crypt.cc:57 -+#: crypt/crypt.cc:82 - msgid "Unable to get cipher" - msgstr "Kann die Verschlüsselung nicht ermitteln" - --#: crypt/crypt.cc:66 -+#: crypt/crypt.cc:90 - msgid "Error initializing cipher" - msgstr "Fehler beim Initialisieren der Verschlüsselung" - --#: crypt/crypt.cc:73 crypt/crypt.h:179 crypt/crypt.h:257 -+#: crypt/crypt.cc:97 crypt/crypt.h:181 crypt/crypt.h:258 - msgid "Error setting the key length" - msgstr "Kann die Schlüssellänge nicht setzen" - --#: crypt/crypt.h:160 crypt/crypt.h:238 -+#: crypt/crypt.h:163 crypt/crypt.h:240 - msgid "IVec length missmatch" - msgstr "IVec Länge falsch" - --#: crypt/crypt.h:172 crypt/crypt.h:250 -+#: crypt/crypt.h:174 crypt/crypt.h:251 - msgid "Error initializing encryption engine" - msgstr "Fehler beim Initialisieren der Verschlüsselung" - --#: crypt/crypt.h:194 -+#: crypt/crypt.h:196 - msgid "Error encrypting data" - msgstr "Fehler beim Verschlüsseln der Daten" - --#: crypt/crypt.h:205 -+#: crypt/crypt.h:207 - msgid "Error finalizing encryption" - msgstr "Fehler beim Abschliessen der Verschlüsselung" - --#: crypt/crypt.h:271 -+#: crypt/crypt.h:272 - msgid "Error decrypting data" - msgstr "Fehler beim Entschlüsseln der Daten" - --#: crypt/crypt.h:282 -+#: crypt/crypt.h:283 - msgid "Error finalizing decryption" - msgstr "Fehler beim Abschliessen der Entschlüsselung" - -@@ -127,67 +127,67 @@ - msgid "File has been externally modified" - msgstr "Datei wurde von ausserhalb verändert" - --#: crypt/key.cc:64 -+#: crypt/key.cc:87 - msgid "Run 1: Unable to initialize the EVP_MD structure" - msgstr "Lauf 1: Kann EVP_MD Struktur nicht initialisieren" - --#: crypt/key.cc:72 -+#: crypt/key.cc:95 - msgid "Run 1: Unable to initialize the digest" - msgstr "Lauf 1: Kann Digest nicht initialisieren" - --#: crypt/key.cc:79 -+#: crypt/key.cc:102 - msgid "Run 1: Unable to update the digest" - msgstr "Lauf 1: Digest kann nicht angepasst werden" - --#: crypt/key.cc:88 -+#: crypt/key.cc:111 - msgid "Run 1: Unable to finalize the digest" - msgstr "Lauf 1: Kann Digest nicht abschliessen" - --#: crypt/key.cc:94 -+#: crypt/key.cc:117 - msgid "Run 1: Digest does not have expected length" - msgstr "Lauf 1: Digest hat unerwartete Länge" - --#: crypt/key.cc:106 -+#: crypt/key.cc:129 - msgid "Run 2: Unable to initialize the EVP_MD structure" - msgstr "Lauf 2: Kann EVP_MD Struktur nicht initialisieren" - --#: crypt/key.cc:115 -+#: crypt/key.cc:138 - msgid "Run 2: Unable to initialize the digest" - msgstr "Lauf 2: Kann Digest nicht initialisieren" - --#: crypt/key.cc:123 -+#: crypt/key.cc:146 - msgid "Run 2: Unable to update the digest" - msgstr "Lauf 2: Digest kann nicht angepasst werden" - --#: crypt/key.cc:131 -+#: crypt/key.cc:154 - msgid "Run 2: Unable to finalize the digest" - msgstr "Lauf 2: Kann Digest nicht abschliessen" - --#: crypt/key.cc:137 -+#: crypt/key.cc:160 - msgid "Run 2: Digest does not have expected length" - msgstr "Lauf 2: Digest hat unerwartete Länge" - --#: crypt/key.cc:149 -+#: crypt/key.cc:172 - msgid "Run 3: Unable to initialize the EVP_MD structure" - msgstr "Lauf 3: Kann EVP_MD Struktur nicht initialisieren" - --#: crypt/key.cc:158 -+#: crypt/key.cc:181 - msgid "Run 3: Unable to initialize the digest" - msgstr "Lauf 3: Kann Digest nicht initialisieren" - --#: crypt/key.cc:166 -+#: crypt/key.cc:189 - msgid "Run 3: Unable to update the digest" - msgstr "Lauf 3: Digest kann nicht angepasst werden" - --#: crypt/key.cc:174 -+#: crypt/key.cc:197 - msgid "Run 3: Unable to finalize the digest" - msgstr "Lauf 3: Kann Digest nicht abschliessen" - --#: crypt/key.cc:180 -+#: crypt/key.cc:203 - msgid "Run 3: Digest does not have expected length" - msgstr "Lauf 3: Digest hat unerwartete Länge" - --#: crypt/key.cc:191 -+#: crypt/key.cc:214 - #, c-format - msgid "Effective key length of %d does not match expected key length %d" - msgstr "" -@@ -194,23 +194,23 @@ - "Die effektive Schlüssellänge %d passt nicht auf die erwartete Schlüssellänge " - "%d" - --#: crypt/key.cc:205 -+#: crypt/key.cc:228 - msgid "IVec: Unable to initialize the EVP_MD structure" - msgstr "IVec: Kann EVP_MD Struktur nicht initialisieren" - --#: crypt/key.cc:214 -+#: crypt/key.cc:237 - msgid "IVec: Unable to initialize the digest" - msgstr "IVec: Kann Digest nicht initialisieren" - --#: crypt/key.cc:222 -+#: crypt/key.cc:245 - msgid "IVec: Unable to update the digest" - msgstr "IVec: Kann Digest nicht anpassen" - --#: crypt/key.cc:230 -+#: crypt/key.cc:253 - msgid "IVec: Unable to finalize the digest" - msgstr "IVec: Kann Digest nicht abschliessen" - --#: crypt/key.cc:236 -+#: crypt/key.cc:259 - msgid "IVec: Digest does not have expected length" - msgstr "IVec: Digest hat unerwartete Länge" - -@@ -240,9 +240,8 @@ - - #: glue/createfile.cc:80 glue/promptpassword.cc:60 glue/changepassword.cc:52 - #: glue/changepassword.cc:62 glue/changepassword.cc:116 --#: glue/opencmdlinefile.cc:103 ui/passwordrecord.cc:88 --#: ui/passwordrecord.cc:248 ui/mainwindow.cc:420 ui/mainwindow.cc:472 --#: ui/mainwindow.cc:503 -+#: glue/opencmdlinefile.cc:103 ui/passwordrecord.cc:88 ui/passwordrecord.cc:248 -+#: ui/mainwindow.cc:420 ui/mainwindow.cc:472 ui/mainwindow.cc:503 - msgid "Error" - msgstr "Fehler" - -Index: po/yapet.pot -=================================================================== ---- po/yapet.pot (revision 6011) -+++ po/yapet.pot (revision 6988) -@@ -1,6 +1,6 @@ - # SOME DESCRIPTIVE TITLE. - # Copyright (C) YEAR Free Software Foundation, Inc. --# This file is distributed under the same license as the PACKAGE package. -+# This file is distributed under the same license as the yapet package. - # FIRST AUTHOR , YEAR. - # - #, fuzzy -@@ -8,7 +8,7 @@ - msgstr "" - "Project-Id-Version: yapet 1.0\n" - "Report-Msgid-Bugs-To: Rafael Ostertag \n" --"POT-Creation-Date: 2014-02-18 18:05+0100\n" -+"POT-Creation-Date: 2016-11-09 20:57+0100\n" - "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" - "Last-Translator: FULL NAME \n" - "Language-Team: LANGUAGE \n" -@@ -25,39 +25,39 @@ - msgid "Position out of range" - msgstr "" - --#: crypt/crypt.cc:57 -+#: crypt/crypt.cc:82 - msgid "Unable to get cipher" - msgstr "" - --#: crypt/crypt.cc:66 -+#: crypt/crypt.cc:90 - msgid "Error initializing cipher" - msgstr "" - --#: crypt/crypt.cc:73 crypt/crypt.h:179 crypt/crypt.h:257 -+#: crypt/crypt.cc:97 crypt/crypt.h:181 crypt/crypt.h:258 - msgid "Error setting the key length" - msgstr "" - --#: crypt/crypt.h:160 crypt/crypt.h:238 -+#: crypt/crypt.h:163 crypt/crypt.h:240 - msgid "IVec length missmatch" - msgstr "" - --#: crypt/crypt.h:172 crypt/crypt.h:250 -+#: crypt/crypt.h:174 crypt/crypt.h:251 - msgid "Error initializing encryption engine" - msgstr "" - --#: crypt/crypt.h:194 -+#: crypt/crypt.h:196 - msgid "Error encrypting data" - msgstr "" - --#: crypt/crypt.h:205 -+#: crypt/crypt.h:207 - msgid "Error finalizing encryption" - msgstr "" - --#: crypt/crypt.h:271 -+#: crypt/crypt.h:272 - msgid "Error decrypting data" - msgstr "" - --#: crypt/crypt.h:282 -+#: crypt/crypt.h:283 - msgid "Error finalizing decryption" - msgstr "" - -@@ -125,88 +125,88 @@ - msgid "File has been externally modified" - msgstr "" - --#: crypt/key.cc:64 -+#: crypt/key.cc:87 - msgid "Run 1: Unable to initialize the EVP_MD structure" - msgstr "" - --#: crypt/key.cc:72 -+#: crypt/key.cc:95 - msgid "Run 1: Unable to initialize the digest" - msgstr "" - --#: crypt/key.cc:79 -+#: crypt/key.cc:102 - msgid "Run 1: Unable to update the digest" - msgstr "" - --#: crypt/key.cc:88 -+#: crypt/key.cc:111 - msgid "Run 1: Unable to finalize the digest" - msgstr "" - --#: crypt/key.cc:94 -+#: crypt/key.cc:117 - msgid "Run 1: Digest does not have expected length" - msgstr "" - --#: crypt/key.cc:106 -+#: crypt/key.cc:129 - msgid "Run 2: Unable to initialize the EVP_MD structure" - msgstr "" - --#: crypt/key.cc:115 -+#: crypt/key.cc:138 - msgid "Run 2: Unable to initialize the digest" - msgstr "" - --#: crypt/key.cc:123 -+#: crypt/key.cc:146 - msgid "Run 2: Unable to update the digest" - msgstr "" - --#: crypt/key.cc:131 -+#: crypt/key.cc:154 - msgid "Run 2: Unable to finalize the digest" - msgstr "" - --#: crypt/key.cc:137 -+#: crypt/key.cc:160 - msgid "Run 2: Digest does not have expected length" - msgstr "" - --#: crypt/key.cc:149 -+#: crypt/key.cc:172 - msgid "Run 3: Unable to initialize the EVP_MD structure" - msgstr "" - --#: crypt/key.cc:158 -+#: crypt/key.cc:181 - msgid "Run 3: Unable to initialize the digest" - msgstr "" - --#: crypt/key.cc:166 -+#: crypt/key.cc:189 - msgid "Run 3: Unable to update the digest" - msgstr "" - --#: crypt/key.cc:174 -+#: crypt/key.cc:197 - msgid "Run 3: Unable to finalize the digest" - msgstr "" - --#: crypt/key.cc:180 -+#: crypt/key.cc:203 - msgid "Run 3: Digest does not have expected length" - msgstr "" - --#: crypt/key.cc:191 -+#: crypt/key.cc:214 - #, c-format - msgid "Effective key length of %d does not match expected key length %d" - msgstr "" - --#: crypt/key.cc:205 -+#: crypt/key.cc:228 - msgid "IVec: Unable to initialize the EVP_MD structure" - msgstr "" - --#: crypt/key.cc:214 -+#: crypt/key.cc:237 - msgid "IVec: Unable to initialize the digest" - msgstr "" - --#: crypt/key.cc:222 -+#: crypt/key.cc:245 - msgid "IVec: Unable to update the digest" - msgstr "" - --#: crypt/key.cc:230 -+#: crypt/key.cc:253 - msgid "IVec: Unable to finalize the digest" - msgstr "" - --#: crypt/key.cc:236 -+#: crypt/key.cc:259 - msgid "IVec: Digest does not have expected length" - msgstr "" - -@@ -236,9 +236,8 @@ - - #: glue/createfile.cc:80 glue/promptpassword.cc:60 glue/changepassword.cc:52 - #: glue/changepassword.cc:62 glue/changepassword.cc:116 --#: glue/opencmdlinefile.cc:103 ui/passwordrecord.cc:88 --#: ui/passwordrecord.cc:248 ui/mainwindow.cc:420 ui/mainwindow.cc:472 --#: ui/mainwindow.cc:503 -+#: glue/opencmdlinefile.cc:103 ui/passwordrecord.cc:88 ui/passwordrecord.cc:248 -+#: ui/mainwindow.cc:420 ui/mainwindow.cc:472 ui/mainwindow.cc:503 - msgid "Error" - msgstr "" - -Index: tests/preload/Makefile.am -=================================================================== ---- tests/preload/Makefile.am (revision 6011) -+++ tests/preload/Makefile.am (revision 6988) -@@ -14,7 +14,7 @@ - ../../crypt/bdbuffer.cc ../../crypt/crypt.cc ../../crypt/file.cc \ - ../../crypt/key.cc ../../crypt/partdec.cc - checktestpwrecord_CPPFLAGS = -I$(top_srcdir)/crypt -I$(top_builddir) \ ---I$(top_srcdir) -+-I$(top_srcdir) $(OPENSSL_INCLUDES) - checktestpwrecord_LDADD = $(top_builddir)/crypt/libyapet-crypt.la $(LIBINTL) - - checkmasterpwchange_SOURCES = checkmasterpwchange.cc \ -@@ -21,7 +21,7 @@ - ../../crypt/bdbuffer.cc ../../crypt/crypt.cc ../../crypt/file.cc \ - ../../crypt/key.cc ../../crypt/partdec.cc - checkmasterpwchange_CPPFLAGS = -I$(top_srcdir)/crypt -I$(top_builddir) \ ---I$(top_srcdir) -+-I$(top_srcdir) $(OPENSSL_INCLUDES) - checkmasterpwchange_LDADD = $(top_builddir)/crypt/libyapet-crypt.la $(LIBINTL) - - istty_SOURCES = istty.cc -Index: yapet/cfg.h -=================================================================== ---- yapet/cfg.h (revision 6011) -+++ yapet/cfg.h (revision 6988) -@@ -163,7 +163,7 @@ - locked = false; - } - -- void is_locked() const { -+ bool is_locked() const { - return locked; - } - -Index: configure.ac -=================================================================== ---- configure.ac (revision 6011) -+++ configure.ac (revision 6988) -@@ -86,9 +86,10 @@ - LDFLAGS="$LDFLAGS $OPENSSL_LDFLAGS" - CPPFLAGS="$CPPFLAGS $OPENSSL_INCLUDES" - AC_MSG_NOTICE([Checking encryption functions]) --AC_CHECK_FUNCS([EVP_bf_cbc EVP_CIPHER_CTX_cleanup EVP_CIPHER_CTX_init EVP_CIPHER_CTX_set_key_length EVP_CipherInit_ex EVP_DigestFinal_ex EVP_DigestInit_ex EVP_DigestUpdate EVP_MD_CTX_cleanup EVP_MD_CTX_init EVP_md5 EVP_ripemd160 EVP_sha1], -+AC_CHECK_FUNCS([EVP_bf_cbc EVP_CIPHER_CTX_set_key_length EVP_CipherInit_ex EVP_DigestFinal_ex EVP_DigestInit_ex EVP_DigestUpdate EVP_md5 EVP_ripemd160 EVP_sha1], - [], - [AC_MSG_ERROR([You are missing a crucial function required for $PACKAGE_NAME])]) -+AC_CHECK_FUNCS([EVP_CIPHER_CTX_cleanup EVP_CIPHER_CTX_free EVP_CIPHER_CTX_init EVP_CIPHER_CTX_new EVP_MD_CTX_destroy EVP_MD_CTX_create EVP_MD_CTX_free EVP_MD_CTX_new]) - AC_MSG_NOTICE([Checking support functions]) - AC_CHECK_FUNCS([SSLeay_version]) - LIBS="$LIBS_SAVE" diff --git a/sources b/sources index aea5ca3..e5f4145 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -a3cf3c274abefdbee15acd74dbdbb1ee yapet-1.0.tar.bz2 +SHA512 (yapet-1.1.tar.xz) = 371d76beff7665f305f738d5f9498b9edf6fff251c620115fb5fe89da0743e2fbf920712db210076a0123d0972c15ea69227acb1d37e2aae70ffca6bab27d13a diff --git a/yapet.spec b/yapet.spec index 50264e8..2fc51d2 100644 --- a/yapet.spec +++ b/yapet.spec @@ -1,12 +1,13 @@ #global pre pre2 Name: yapet -Version: 1.0 -Release: 12%{?pre}%{?dist} +Version: 1.1 +Release: 1%{?pre}%{?dist} Summary: Yet Another Password Encryption Tool License: GPLv3+ with exceptions -URL: http://www.guengel.ch/myapps/%{name}/ -Source0: http://www.guengel.ch/myapps/%{name}/downloads/%{name}-%{version}%{?pre}.tar.bz2 +URL: http://yapet.guengel.ch/ +Source0: http://yapet.guengel.ch/downloads/%{name}-%{version}%{?pre}.tar.xz +BuildRequires: gcc-c++ BuildRequires: gettext BuildRequires: ncurses-devel BuildRequires: openssl-devel @@ -14,9 +15,6 @@ BuildRequires: openssl-devel BuildRequires: automake BuildRequires: autoconf -Patch0: bz1308262-gcc6-void-fn-returns-value.patch -Patch1: bz1424564-gcc-6_and_openssl-1.1.patch - %description YAPET is a text based password manager using the Blowfish encryption algorithm. Because of its small footprint and very few library dependencies, it is suited @@ -25,13 +23,6 @@ for installing on desktop and server systems alike. %prep %setup -qn %{name}-%{version}%{?pre} -# https://bugs.guengel.ch/show_bug.cgi?id=112 -# Skip this patch, as it is included by the subsequent patch now -# %patch0 -p1 - -# https://bugs.guengel.ch/show_bug.cgi?id=113 -%patch1 -p0 - for f in ./DESIGN ./README do iconv -f iso-8859-1 -t utf-8 $f |sed 's|\r||g' > $f.utf8 @@ -41,7 +32,7 @@ done %build -# Rebuild configure script because the supplied patches only modify configure.ac +# Rebuild configure script in case any supplied patches only modify configure.ac aclocal -I m4 autoconf @@ -75,6 +66,11 @@ rm -frv %{buildroot}%{_docdir} %{_mandir}/man*/*yapet* %changelog +* Wed Mar 28 2018 Greg Bailey - 1.1-1 +- Update to 1.1 +- Update URL +- Remove unnecessary patches + * Fri Feb 09 2018 Fedora Release Engineering - 1.0-12 - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild From bd8a736681c8353046bf729d25ee66d408d14eb1 Mon Sep 17 00:00:00 2001 From: Greg Bailey Date: Wed, 28 Mar 2018 10:54:21 -0700 Subject: [PATCH 15/15] No longer any need to rebuild configure script --- yapet.spec | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/yapet.spec b/yapet.spec index 2fc51d2..34c2977 100644 --- a/yapet.spec +++ b/yapet.spec @@ -2,7 +2,7 @@ Name: yapet Version: 1.1 -Release: 1%{?pre}%{?dist} +Release: 2%{?pre}%{?dist} Summary: Yet Another Password Encryption Tool License: GPLv3+ with exceptions URL: http://yapet.guengel.ch/ @@ -12,9 +12,6 @@ BuildRequires: gettext BuildRequires: ncurses-devel BuildRequires: openssl-devel -BuildRequires: automake -BuildRequires: autoconf - %description YAPET is a text based password manager using the Blowfish encryption algorithm. Because of its small footprint and very few library dependencies, it is suited @@ -31,11 +28,6 @@ do done %build - -# Rebuild configure script in case any supplied patches only modify configure.ac -aclocal -I m4 -autoconf - %configure --disable-install-doc \ --disable-source-doc \ --disable-install-doci \ @@ -66,6 +58,9 @@ rm -frv %{buildroot}%{_docdir} %{_mandir}/man*/*yapet* %changelog +* Wed Mar 28 2018 Greg Bailey - 1.1-2 +- No longer any need to rebuild configure script + * Wed Mar 28 2018 Greg Bailey - 1.1-1 - Update to 1.1 - Update URL