diff options
author | Mingli Yu <Mingli.Yu@windriver.com> | 2016-08-12 15:19:56 +0800 |
---|---|---|
committer | Joe MacDonald <joe_macdonald@mentor.com> | 2016-08-16 21:26:11 -0400 |
commit | 1ea6e9a5d2d50ad3184326fb1631a8b9e3f1018c (patch) | |
tree | ec007c9d1cac5e1959b47098c3a0be091c2a672e /meta-networking/recipes-daemons | |
parent | 4307c6a746ef25540c84446c821658062a89bb15 (diff) | |
download | meta-openembedded-1ea6e9a5d2d50ad3184326fb1631a8b9e3f1018c.tar.gz |
proftpd: fix system account login failure
When pam is enabled,
1, Customize the proftpd.conf to use pam to authenticate
2, Add proftpd pam configuration file /etc/pam.d/proftpd
Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Joe MacDonald <joe_macdonald@mentor.com>
Diffstat (limited to 'meta-networking/recipes-daemons')
-rw-r--r-- | meta-networking/recipes-daemons/proftpd/proftpd_1.3.5a.bb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/meta-networking/recipes-daemons/proftpd/proftpd_1.3.5a.bb b/meta-networking/recipes-daemons/proftpd/proftpd_1.3.5a.bb index b6fd4b2e1..2332ef856 100644 --- a/meta-networking/recipes-daemons/proftpd/proftpd_1.3.5a.bb +++ b/meta-networking/recipes-daemons/proftpd/proftpd_1.3.5a.bb | |||
@@ -92,6 +92,15 @@ do_install () { | |||
92 | # create the pub directory | 92 | # create the pub directory |
93 | mkdir -p ${D}/home/${FTPUSER}/pub/ | 93 | mkdir -p ${D}/home/${FTPUSER}/pub/ |
94 | chown -R ${FTPUSER}:${FTPGROUP} ${D}/home/${FTPUSER}/pub | 94 | chown -R ${FTPUSER}:${FTPGROUP} ${D}/home/${FTPUSER}/pub |
95 | if ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'true', 'false', d)}; then | ||
96 | # install proftpd pam configuration | ||
97 | install -d ${D}${sysconfdir}/pam.d | ||
98 | install -m 644 ${S}/contrib/dist/rpm/ftp.pamd ${D}${sysconfdir}/pam.d/proftpd | ||
99 | sed -i '/ftpusers/d' ${D}${sysconfdir}/pam.d/proftpd | ||
100 | # specify the user Authentication config | ||
101 | sed -i '/^MaxInstances/a\AuthPAM on\nAuthPAMConfig proftpd' \ | ||
102 | ${D}${sysconfdir}/proftpd.conf | ||
103 | fi | ||
95 | 104 | ||
96 | install -d ${D}/${systemd_unitdir}/system | 105 | install -d ${D}/${systemd_unitdir}/system |
97 | install -m 644 ${WORKDIR}/proftpd.service ${D}/${systemd_unitdir}/system | 106 | install -m 644 ${WORKDIR}/proftpd.service ${D}/${systemd_unitdir}/system |