diff options
author | Bastian Blank <bastian.blank@credativ.de> | 2015-11-18 08:07:09 +0000 |
---|---|---|
committer | Balint Reczey <balint@balintreczey.hu> | 2017-02-24 00:16:58 +0100 |
commit | a784e094c4827412389e414e70ff12daa184246e (patch) | |
tree | ffa621b998c4e6dc59ccf6d09b1953111b9816e2 | |
parent | 1f9119ef49a1bc5707340d0b9e98e0c40582d73f (diff) | |
download | shadow-a784e094c4827412389e414e70ff12daa184246e.tar.gz |
Imported Debian patch 1:4.2-3+deb8u1debian/1%4.2-3+deb8u1
-rw-r--r-- | debian/changelog | 7 | ||||
-rw-r--r-- | debian/patches/1020_fix_user_busy_errors | 38 | ||||
-rw-r--r-- | debian/patches/series | 1 |
3 files changed, 46 insertions, 0 deletions
diff --git a/debian/changelog b/debian/changelog index 9b85842c..5b0c13ab 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +shadow (1:4.2-3+deb8u1) jessie; urgency=medium + + * Non-maintainer upload. + * Fix error handling in busy user detection. (Closes: #778287) + + -- Bastian Blank <bastian.blank@credativ.de> Wed, 18 Nov 2015 08:07:09 +0000 + shadow (1:4.2-3) unstable; urgency=low * Enforce hardened builds to workaround cdbs sometimes not building diff --git a/debian/patches/1020_fix_user_busy_errors b/debian/patches/1020_fix_user_busy_errors new file mode 100644 index 00000000..2a141cad --- /dev/null +++ b/debian/patches/1020_fix_user_busy_errors @@ -0,0 +1,38 @@ +Description: Fix user_busy to not leave subuid open in case of error. +Author: William Grant <wgrant@ubuntu.com> +Bug: https://bugs.launchpad.net/ubuntu/vivid/+source/shadow/+bug/1436937 + +Index: shadow-4.2/libmisc/user_busy.c +=================================================================== +--- shadow-4.2.orig/libmisc/user_busy.c ++++ shadow-4.2/libmisc/user_busy.c +@@ -175,6 +175,9 @@ static int user_busy_processes (const ch + if (stat ("/", &sbroot) != 0) { + perror ("stat (\"/\")"); + (void) closedir (proc); ++#ifdef ENABLE_SUBIDS ++ sub_uid_close(); ++#endif /* ENABLE_SUBIDS */ + return 0; + } + +@@ -212,6 +215,9 @@ static int user_busy_processes (const ch + + if (check_status (name, tmp_d_name, uid) != 0) { + (void) closedir (proc); ++#ifdef ENABLE_SUBIDS ++ sub_uid_close(); ++#endif /* ENABLE_SUBIDS */ + fprintf (stderr, + _("%s: user %s is currently used by process %d\n"), + Prog, name, pid); +@@ -232,6 +238,9 @@ static int user_busy_processes (const ch + } + if (check_status (name, task_path+6, uid) != 0) { + (void) closedir (proc); ++#ifdef ENABLE_SUBIDS ++ sub_uid_close(); ++#endif /* ENABLE_SUBIDS */ + fprintf (stderr, + _("%s: user %s is currently used by process %d\n"), + Prog, name, pid); diff --git a/debian/patches/series b/debian/patches/series index 9be43fcc..44a06f30 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -34,3 +34,4 @@ #userns/16_add-argument-sanity-checking.patch 1000_configure_userns 1010_vietnamese_translation +1020_fix_user_busy_errors |