From: Mark Wooding Date: Thu, 23 Feb 2012 03:03:09 +0000 (+0000) Subject: claim-dir, debian/distorted-keys.postinst: Let `keys' run `claim-dir'. X-Git-Tag: 0.99.2~20 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~mdw/git/distorted-keys/commitdiff_plain/fef0a02f50f6573ac84ee4ba3f83d9cd9eb7ae96?hp=d8dbaabf98da677733cd2b316cbf629e99d7e4ed claim-dir, debian/distorted-keys.postinst: Let `keys' run `claim-dir'. Unfortunately, `keys' as created by the `postinst' script doesn't have a shell. Allow callers without shells to run `claim-dir' if they have a particular magical shell configured, and set this magic on the `keys' user. --- diff --git a/debian/distorted-keys.postinst b/debian/distorted-keys.postinst index 99a1809..36b7237 100755 --- a/debian/distorted-keys.postinst +++ b/debian/distorted-keys.postinst @@ -8,7 +8,7 @@ home=/var/lib/distorted-keys ## Make sure the user exists. if ! grep -q ^$user: /etc/passwd; then adduser --quiet --system --group \ - --disabled-password --shell /bin/false \ + --disabled-password --shell /dev/token-shells/userv \ --no-create-home --home $home \ $user fi diff --git a/userv/claim-dir.in b/userv/claim-dir.in index 4cc6032..d5f14db 100644 --- a/userv/claim-dir.in +++ b/userv/claim-dir.in @@ -4,7 +4,9 @@ if ( glob service claim-dir & glob service-user root - & grep calling-user-shell /etc/shells + & ( grep calling-user-shell /etc/shells + | glob calling-user-shell /dev/token-shells/userv + ) ) no-suppress-args null-fd 0