Using LDAP to provide authentication for VSFTPD

Source: Internet
Author: User
Tags ldap
This assumes that the LDAP server has been built, taking Rhds as an example.
Install package: Yum install vsftpd pam_ldap configuration Pam_ldap Edit Profile/etc/pam_ldap.conf, modify the following: BaseDc=wyd,dc=com #搜索LDAP服务器的起始DN URILdaps://ldap.wyd.com #LDAP服务器的地址 SSLYes #使用SSL加密 Tls_cacertfile/ETC/OPENLDAP/CACERTS/MYCA.CRT #指定的CA公钥 Pam_password MD5 Note: When using SSL encryption, the server address specified in the URI must be in the certificate         The CN name match. If the LDAP server does not allow anonymous binding, you need to configure the PAM Edit Profile/etc/pam.d/vsftpd used by the BINDDN and BINDPW configuration vsftpd, add the following two lines Auth Sufficient pam_ldap.so#把这行放在第一个auth项 Account Sufficient pam_ldap.so#把这行放在第一个account项
Configure VSFTPD Edit configuration file/etc/vsftpd/vsftpd.conf, add the following configuration:
Anonymous_enable=no Anon_upload_enable=yes Anon_mkdir_write_enable=yes #开启这项和上一项才能上传 Files and folders Guest_enable=yes Guest_username=samwon #指定LDAP中的用户登录后映射的用户 pam_serv Restart the VSFTPD service after ice_name=vsftpd save.
Effect:
Here Redhat is a user in the Rhds directory service, and you can see that you have successfully logged on to the FTP server.


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.