From 40146019e61eeafb13602bcd6243fd26091d8e92 Mon Sep 17 00:00:00 2001 From: Balint Reczey Date: Fri, 20 Jan 2017 20:41:49 +0100 Subject: [PATCH] Sync motd handling with sshd Using patch from Ubuntu Closes: #757148 --- debian/login.pam | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/debian/login.pam b/debian/login.pam index e4a4af26..07ff9540 100644 --- a/debian/login.pam +++ b/debian/login.pam @@ -92,8 +92,10 @@ session optional pam_lastlog.so # Prints the message of the day upon successful login. # (Replaces the `MOTD_FILE' option in login.defs) -session optional pam_exec.so type=open_session stdout /bin/uname -snrvm -session optional pam_motd.so +# This includes a dynamically generated part from /run/motd.dynamic +# and a static (admin-editable) part from /etc/motd. +session optional pam_motd.so motd=/run/motd.dynamic +session optional pam_motd.so noupdate # Prints the status of the user's mailbox upon successful login # (Replaces the `MAIL_CHECK_ENAB' option from login.defs).