Ubuntu 12.04 updates broke VSFTP

ftppamUbuntu

I am running Ubuntu 12.04 LTS. I did some minor updates using apt.
After rebooting vsftp stopped accepting connections system user logins. In the auth log I am getting the following errors

Dec 22 22:03:13 helium vsftpd: PAM unable to dlopen(pam_cracklib.so): /lib/security/pam_cracklib.so: cannot open shared object file: No such file or directory
Dec 22 22:03:13 helium vsftpd: PAM adding faulty module: pam_cracklib.so
Dec 22 22:03:13 helium vsftpd: pam_unix(vsftpd:auth): check pass; user unknown
Dec 22 22:03:13 helium vsftpd: pam_unix(vsftpd:auth): authentication failure; logname= uid=0 euid=0 tty=ftp ruser=cam rhost=192.168.1.121 
Dec 22 22:03:13 helium vsftpd: pam_winbind(vsftpd:auth): getting password (0x00000388)
Dec 22 22:03:13 helium vsftpd: pam_winbind(vsftpd:auth): pam_get_item returned a password

I commented out pam_cracklib.so from common-password, which then errors on the next lib

Dec 22 22:08:57 helium vsftpd: PAM unable to dlopen(pam_shells.so): /lib/security/pam_shells.so: cannot open shared object file: No such file or directory
Dec 22 22:08:57 helium vsftpd: PAM adding faulty module: pam_shells.so
Dec 22 22:08:57 helium vsftpd: pam_unix(vsftpd:auth): check pass; user unknown
Dec 22 22:08:57 helium vsftpd: pam_unix(vsftpd:auth): authentication failure; logname= uid=0 euid=0 tty=ftp ruser=cam rhost=192.168.1.120 
Dec 22 22:08:57 helium vsftpd: pam_winbind(vsftpd:auth): getting password (0x00000388)
Dec 22 22:08:57 helium vsftpd: pam_winbind(vsftpd:auth): pam_get_item returned a password
Dec 22 22:09:00 helium vsftpd: PAM unable to dlopen(pam_shells.so): /lib/security/pam_shells.so: cannot open shared object file: No such file or directory

I then noticed that this directory doesn't exist anymore /lib/security/
It seems to now be located at /lib/x86_64-linux-gnu/security

So I did a symlink between the two, but then I get these errors

Dec 22 22:11:33 helium vsftpd: PAM unable to dlopen(pam_shells.so): /lib/security/pam_shells.so: failed to map segment from shared object: Cannot allocate memory
Dec 22 22:11:33 helium vsftpd: PAM adding faulty module: pam_shells.so
Dec 22 22:11:33 helium vsftpd: pam_unix(vsftpd:auth): check pass; user unknown
Dec 22 22:11:33 helium vsftpd: pam_unix(vsftpd:auth): authentication failure; logname= uid=0 euid=0 tty=ftp ruser=cam rhost=192.168.1.120 
Dec 22 22:11:33 helium vsftpd: pam_winbind(vsftpd:auth): getting password (0x00000388)
Dec 22 22:11:33 helium vsftpd: pam_winbind(vsftpd:auth): pam_get_item returned a password

I am currently running

Package: vsftpd
Status: install ok installed
Priority: extra
Section: net
Installed-Size: 334
Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
Architecture: amd64
Version: 2.3.5-1ubuntu2

I have done a purge and re-install, but I still get the same errors.

My vsftp conf is very simple. Allow local users and chroot users.

Anyone have any ideas?

Best Answer

I followed this thread and used this guys deb package to fix my instance. Has worked for me since. One thing I did have to do was exclude vsftpd from apt so it didn't revert it back on me until the official one is fixed.