Apache2
Posted on sam. 24 novembre 2018 in architecture
Proxy Transmission
Fichiers requis pour le SSL et protection par mot de passe
openssl req -x509 -nodes -days 365 -newkey rsa:4096 -out /etc/apache2/server.crt -keyout /etc/apache2/server.key
htpasswd -c /etc/apache2/.htpasswd user1
a2enmod proxy
a2enmod proxy_http
a2enmod ssl
SSLEngine on
SSLCertificateFile /etc/apache2/server.crt
SSLCertificateKeyFile /etc/apache2/server.key
<Location />
AuthType Basic
AuthName "Authentication Required"
AuthUserFile "/etc/apache2/.htpasswd"
Require valid-user
</Location>
ProxyPass / http://1.2.3.4:9091/
ProxyPassReverse / http://1.2.3.4:9091/
Proxy ownCloud
Authentification LDAP/AD
a2enmod ldap authnz_ldap
#vim /etc/apache2/sites-available/namesite.conf
AuthName "Put in your own prompt message"
AuthType Basic
AuthBasicProvider ldap
AuthLDAPUrl "ldap://cicntp12:389/DC=local,DC=lan?sAMAccountName?sub?(objectClass=*)"
Require valid-user
AuthLDAPBindDN "CN=Username,OU=Users,DC=local,DC=lan"
AuthLDAPBindPassword password