Satisfy Command: The Command uses SatisfyAll/Any. it is used in Directory and. htaccess. We know that there are two mechanisms in Apache access control: client restrictions and user authentication mechanisms. Explanation: client restrictions: & lt; Directory/some/di...
Satisfy command:
This command is used: Satisfy All/Any.
Used in Directory and. htaccess.
We know that there are two mechanisms in Apache access control: client restrictions and user authentication mechanisms. Explanations:
Client restrictions:
Order allow, deny
Deny from all
This is a directory restriction, which limits all IP addresses to access this directory.
User authentication mechanism:
AuthType Basic
AuthName "My Auth File"
AuthUserFile/some/file/path
Require valid-user
This is a user authentication mechanism, which requires the user to give the user name and password to access the contents in the directory.
What if a directory is used by both rules? This is the time for our Satisfy to take effect.
When the value of Satisfy is set to All, access is allowed only when both conditions are met. When The Satisfy value is set to Any, you only need to Satisfy one.
Conditional discriminant order: Which condition is determined first? This is the principle of proximity. you can determine which one you set first.