Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save algotrader-dotcom/2174d58be06d048200b8 to your computer and use it in GitHub Desktop.
Save algotrader-dotcom/2174d58be06d048200b8 to your computer and use it in GitHub Desktop.
Apache reverse proxy basic authentication exclude IP, URI
....
SetEnvIfNoCase Request_URI "^/_ui" noauth
<Proxy *>
AuthType Basic
AuthName "Please Log In"
AuthUserFile /etc/httpd/.htpasswd
Require valid-user
Order deny,allow
Deny from all
Allow from 127.0.0.1, IP1, IP2, IP3 # List IPs
Allow from 58.64.198. # Range IP
Allow from env=noauth # Not authen for url start /_ui/*
Satisfy any
</Proxy>
....
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment