summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--debian/changelog10
-rw-r--r--debian/libpam-modules.install1
-rw-r--r--debian/local/pam-auth-update13
-rw-r--r--debian/local/pam-auth-update.84
-rw-r--r--debian/pam-configs/mkhomedir7
5 files changed, 34 insertions, 1 deletions
diff --git a/debian/changelog b/debian/changelog
index e0a780a9..ff9229d2 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,13 @@
+pam (1.1.8-3.7) unstable; urgency=medium
+
+ * Non-maintainer upload.
+ * libpam-modules: Added a config for pam_mkhomedir, disabled by default.
+ (Closes: #568577)
+ * pam-auth-update: Add support for --enable option which is useful for
+ enabling non-default configs without prompting the admin. (LP: #1192719)
+
+ -- Timo Aaltonen <tjaalton@debian.org> Fri, 02 Feb 2018 16:57:43 +0200
+
pam (1.1.8-3.6) unstable; urgency=medium
* Non-maintainer upload.
diff --git a/debian/libpam-modules.install b/debian/libpam-modules.install
index 191a34ea..5fd57b44 100644
--- a/debian/libpam-modules.install
+++ b/debian/libpam-modules.install
@@ -1,2 +1,3 @@
etc/security/* etc/security
lib/*/security/*.so
+debian/pam-configs/mkhomedir usr/share/pam-configs/
diff --git a/debian/local/pam-auth-update b/debian/local/pam-auth-update
index 60eb1e8f..5fb4f40a 100644
--- a/debian/local/pam-auth-update
+++ b/debian/local/pam-auth-update
@@ -39,7 +39,7 @@ my $blanktemplate = 'libpam-runtime/no_profiles_chosen';
my $titletemplate = 'libpam-runtime/title';
my $confdir = '/etc/pam.d';
my $savedir = '/var/lib/pam';
-my (%profiles, @sorted, @enabled, @conflicts, @new, %removals);
+my (%profiles, @sorted, @enabled, @conflicts, @new, %removals, %to_enable);
my $force = 0;
my $package = 0;
my $priority = 'high';
@@ -89,6 +89,13 @@ while ($#ARGV >= 0) {
}
# --remove implies --package
$package = 1 if (keys(%removals));
+ } elsif ($opt eq '--enable') {
+ while ($#ARGV >= 0) {
+ last if ($ARGV[0] =~ /^--/);
+ $to_enable{shift @ARGV} = 1;
+ }
+ # --enable implies --package
+ $package = 1 if (keys(%to_enable));
}
}
@@ -136,6 +143,10 @@ if (!@enabled) {
$priority = 'high' unless ($force);
}
+# add configs to enable
+push(@enabled,
+ grep { $to_enable{$_} } @sorted);
+
# add any previously-unseen configs
push(@enabled,
grep { $profiles{$_}->{'Default'} eq 'yes' && !$seen{$_} } @sorted);
diff --git a/debian/local/pam-auth-update.8 b/debian/local/pam-auth-update.8
index fd5e2ad4..a5ebdbad 100644
--- a/debian/local/pam-auth-update.8
+++ b/debian/local/pam-auth-update.8
@@ -68,6 +68,10 @@ Indicate that the caller is a package maintainer script; lowers the
priority of debconf questions to `medium' so that the user is not
prompted by default.
.TP
+.B \-\-enable \fIprofile \fR[\fIprofile\fR...]
+Enable the specified profiles in system configuration. This is used to
+enable profiles that are not on by default.
+.TP
.B \-\-remove \fIprofile \fR[\fIprofile\fR...]
Remove the specified profiles from the system configuration.
.B pam\-auth\-update \-\-remove
diff --git a/debian/pam-configs/mkhomedir b/debian/pam-configs/mkhomedir
new file mode 100644
index 00000000..9c27980a
--- /dev/null
+++ b/debian/pam-configs/mkhomedir
@@ -0,0 +1,7 @@
+Name: Create home directory on login
+Default: no
+Priority: 0
+Session-Type: Additional
+Session-Interactive-Only: yes
+Session:
+ optional pam_mkhomedir.so