Application Scenario : There is ad Active Directory under Windows, UNIX-like system has LDAP, in the operation and maintenance development tool platform gradually enriched now, unified user management greatly convenient management personnel.
There is no shortage of classic version control management tool SVN, a user authentication method with LDAP combination.
test Environment :
Configuration steps :
1. Install related software
~]# Yum install httpd Subversion mod_dav_svn mod_ldap
Note : In CentOS7 or RHEL7, thehttpd version is 2.4,and in the absence of Mod_authz_ldap, the module software functionality has been integrated into Mod_ LDAP .
2. Modify the configuration file
~]# vim/etc/httpd/conf.modules.d/-ldap.conf
Attach my LDAP structure and the users to be tested:
3. Create an SVN-related directory
~]# mkdir -pv/var/www/svn
~]# cd/var/www/svn/
svn]# svnadmin Create Project1 //svnadmin command is generated by a previously installed subversion-1.7.14-10.el7.x86_64 package
svn]# svnadmin Create Project2
Modify permissions for Project projects
svn]# chown -R Apache. Project1 Project2
4. Create an Access control permission file
~]# vim/etc/httpd/project.acl // new content is shown below
Save, exit;
5. launch Apache(httpd)
~] #systemctl start httpd //Start
~] #systemctl enable httpd //Join Boot
~]# systemctl status httpd //view state
Start success;
6. Landing Page Test
Open the browser and enter HTTP//IP/svn/project1/
The same way, you can test Project2, enter the Project2 user's account number and password.
Login successful, test completed;
Note : If an item does not have a user under it, and you log on to the item with that user, the word "site refuses to show ..." is displayed directly.
That is, if User2 login Project1, enter the user name and password will appear as follows, and no longer jump out of the dialog to give input!
" clear the browser cache or history to jump out of the dialog box"
End.
CENTOS7 using httpd2.4 to configure SVN and use LDAP user authentication