How To Protect a WordPress Site Using Basic Auth in Apache 2.4

Author: , August 25th, 2016

Apache 2.4 changed the security configuration directives a bit. Here is an example using basic auth:

What tripped me up for a while was that I still had the Require all granted directive inside the container, and that needed to be removed for the auth to work.

How To Use wget with Basic Auth

Author: , June 9th, 2016

If you need to use wget to obtain the contents of a web page, but that page has either Basic or Digest Authentication enabled, use the following syntax to gain access: wget –http-user=yourUserNameHere –http-password=yourSecretPasswordHere http://example.org/desired/path/ ~or~ wget http://yourUserNameHere:yourSecretPasswordHere@yourSite.com/desired/path/

How To Protect a Single File in Apache

Author: , June 30th, 2013

In order to protect a file, just replace the Directory directive with Files:

How To Enable SASL Authenticated Email Relay In Postfix

Author: , December 17th, 2010

Below info copied from http://www.postfix.org/SASL_README.html#server_sasl_enable Make sure saslauthd is running first. Edit /etc/postfix/main.cf: smtpd_sasl_type = cyrus smtpd_sasl_auth_enable = yes broken_sasl_auth_clients = yes smtpd_sasl_security_options = noanonymous smtpd_sasl_authenticated_header = yes smtpd_recipient_restrictions = permit_sasl_authenticated {other options that were already there} # postfix reload To test (you supply the items in bold): % telnet server.example.com 25 … 220 server.example.com […]