Skip to content

Commit

Permalink
board/common: disable unused pam_lastlog.so from PAM login
Browse files Browse the repository at this point in the history
Fixes the following recurring login warning in syslog.  (We cannot use
pam_lastlog.so since it does not rotate its /var/log/lastlog file.)

login[2819]: PAM unable to dlopen(/lib/security/pam_lastlog.so): /lib/security/pam_lastlog.so: cannot open shared object file: No such file or directory

Follow-up to issue #542

Signed-off-by: Joachim Wiberg <[email protected]>
  • Loading branch information
troglobit committed Aug 30, 2024
1 parent e0483be commit cf1c4c3
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions board/common/post-build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,9 @@ if [ -L "$TARGET_DIR/var/lib/avahi-autoipd" ]; then
mkdir "$TARGET_DIR/var/lib/avahi-autoipd"
fi

# Drop Buildroot default pam_lastlog.so from login chain
sed -i '/^[^#]*pam_lastlog.so/s/^/# /' "$TARGET_DIR/etc/pam.d/login"

# Allow pdmenu (setup) and bash to be login shells, bash is added
# automatically when selected in menuyconfig, but not when BusyBox
# provides a symlink (for ash). The /bin/{true,false} are old UNIX
Expand Down

0 comments on commit cf1c4c3

Please sign in to comment.