From fc51565933abc802eca17001b916a14e55db5690 Mon Sep 17 00:00:00 2001 From: Michal Hlavinka Date: Feb 01 2017 13:10:18 +0000 Subject: do not crash when using fingerprint reader #1339714 --- diff --git a/ecryptfs-utils-111-nopasswd.patch b/ecryptfs-utils-111-nopasswd.patch new file mode 100644 index 0000000..fd5e38e --- /dev/null +++ b/ecryptfs-utils-111-nopasswd.patch @@ -0,0 +1,14 @@ +diff -up ecryptfs-utils-111/src/pam_ecryptfs/pam_ecryptfs.c.nopasswd ecryptfs-utils-111/src/pam_ecryptfs/pam_ecryptfs.c +--- ecryptfs-utils-111/src/pam_ecryptfs/pam_ecryptfs.c.nopasswd 2017-02-01 14:04:48.313349236 +0100 ++++ ecryptfs-utils-111/src/pam_ecryptfs/pam_ecryptfs.c 2017-02-01 14:05:34.461694263 +0100 +@@ -190,6 +190,10 @@ PAM_EXTERN int pam_sm_authenticate(pam_h + rc); + goto out; + } ++ if (!epd->passphrase) { ++ ecryptfs_syslog(LOG_WARNING, "pam_ecryptfs: No passphrase available"); ++ goto out; ++ } + epd->passphrase = strdup(epd->passphrase); + rc = ecryptfs_read_salt_hex_from_rc(salt_hex); + if (rc) { diff --git a/ecryptfs-utils.spec b/ecryptfs-utils.spec index 41617bf..2d473f1 100644 --- a/ecryptfs-utils.spec +++ b/ecryptfs-utils.spec @@ -5,7 +5,7 @@ Name: ecryptfs-utils Version: 111 -Release: 2%{?dist} +Release: 3%{?dist} Summary: The eCryptfs mount helper and support libraries Group: System Environment/Base License: GPLv2+ @@ -67,6 +67,9 @@ Patch23: ecryptfs-utils-100-sudokeyring.patch # for e-u < 112 Patch24: ecryptfs-utils-111-cve_2016_5224.patch +# do not crash if no password is available #1339714 +Patch25: ecryptfs-utils-111-nopasswd.patch + BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX) Requires: keyutils, cryptsetup-luks, util-linux, gettext BuildRequires: libgcrypt-devel keyutils-libs-devel openssl-devel pam-devel @@ -123,6 +126,7 @@ the interface supplied by the ecryptfs-utils library. %patch22 -p1 -b .selinux %patch23 -p1 -b .sudokeyring %patch24 -p1 -b .cve_2016_5224 +%patch25 -p1 -b .nopasswd %build %global _hardened_build 1 @@ -273,6 +277,9 @@ rm -rf $RPM_BUILD_ROOT %{python_sitearch}/ecryptfs-utils/_libecryptfs.so %changelog +* Wed Feb 01 2017 Michal Hlavinka - 111-3 +- do not crash when using fingerprint reader #1339714 + * Tue Jul 19 2016 Fedora Release Engineering - 111-2 - https://fedoraproject.org/wiki/Changes/Automatic_Provides_for_Python_RPM_Packages