-
Notifications
You must be signed in to change notification settings - Fork 101
fix: brute force docs #161
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
8954f5e
63ac437
477554f
3c65764
98e356a
b18d995
5d90cb5
554e5a1
c039749
2e5c9e4
f3fec4e
24c6eaf
0f119de
141c13d
133ee64
f45c865
fb62621
eb303cf
817f672
45b7499
2d688da
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -655,15 +655,43 @@ claims['address'] = "{ \"address\": { .... } }" # JSON structs can be accessed u | |
|
||
### Overview | ||
|
||
Brute force attacks are attempts to break in to secured areas of a web application by trying exhaustive, | ||
Brute force attacks are attempts to break in to secured areas of a web application by trying exhaustive, | ||
systematic, username/password combinations to discover legitimate authentication credentials. | ||
To prevent brute force attacks, WAF tracks the number of failed attempts to reach login pages | ||
with enforced brute force protection. When brute force patterns are detected, | ||
the WAF policy considers it to be an attack if the failed logon rate increased significantly or | ||
if failed logins reached a maximum threshold. | ||
To prevent brute force attacks, NGINX App Protect WAF monitors IP addresses, usernames, and the number of failed login attempts beyond a maximum threshold. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. "...and the number of failed login attempts per each one of them. Once the number of attempts crosses a configured maximum threshold, a brute force attack is assumed. (remove "beyond a maximum threshold"). |
||
When brute force patterns are detected, the NGINX App Protect WAF policy either trigger an alarm or block the attack if the failed | ||
login attempts reached a maximum threshold for a specific username or coming from a specific IP address. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Replace "When brute force patterns...IP address" with: |
||
To enable brute force protection, at least one login page must be created. | ||
|
||
--- | ||
|
||
### Login page policy example | ||
|
||
A login page specifies the login URL that users must pass through to get authenticated. The configuration of a login URL includes the URL itself, the username and passwords parameters and the validation criteria (how we know that a login was successful or failed) | ||
```json | ||
"login-pages": [ | ||
{ | ||
"accessValidation" : { | ||
"responseContains": "Success" | ||
}, | ||
"authenticationType": "form", | ||
"url" : { | ||
"method" : "*", | ||
"name" : "/html_login", | ||
"protocol" : "http", | ||
"type" : "explicit" | ||
}, | ||
"usernameParameterName": "username", | ||
"passwordParameterName": "password" | ||
} | ||
] | ||
``` | ||
|
||
{{< note >}} For further configuration details, see NGINX App Protect WAF Declarative Policy Guide [Declarative Policy guide]({{< relref "/nap-waf/v4/declarative-policy/policy/#policy/login-pages" >}}). {{< /note >}} | ||
ohad-perets marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
--- | ||
### Brute force policy example | ||
|
||
Example1: A single brute force configuration is applied universally to all login pages. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Add: "If you configured more than one login page, then the attempts of the same source IP address or username across all the login pages are counted". |
||
```json | ||
{ | ||
"policy": { | ||
|
@@ -676,10 +704,6 @@ if failed logins reached a maximum threshold. | |
"brute-force-attack-preventions" : [ | ||
{ | ||
"bruteForceProtectionForAllLoginPages" : true, | ||
"detectionCriteria" : { | ||
"action" : "alarm", | ||
"failedLoginAttemptsRateReached" : 100 | ||
}, | ||
"loginAttemptsFromTheSameIp" : { | ||
"action" : "alarm", | ||
"enabled" : true, | ||
|
@@ -690,16 +714,51 @@ if failed logins reached a maximum threshold. | |
"enabled" : true, | ||
"threshold" : 3 | ||
}, | ||
"measurementPeriod" : 900, | ||
"preventionDuration" : "3600", | ||
"reEnableLoginAfter" : 3600, | ||
"sourceBasedProtectionDetectionPeriod" : 3600 | ||
} | ||
] | ||
} | ||
} | ||
``` | ||
|
||
Example2: Different brute force configurations can be defined for individual login pages. | ||
```json | ||
{ | ||
"policy": { | ||
"name": "BruteForcePolicySpec", | ||
"template": { | ||
"name": "POLICY_TEMPLATE_NGINX_BASE" | ||
}, | ||
"applicationLanguage": "utf-8", | ||
"enforcementMode": "blocking", | ||
"brute-force-attack-preventions" : [ | ||
{ | ||
"bruteForceProtectionForAllLoginPages" : false, | ||
"loginAttemptsFromTheSameIp" : { | ||
"action" : "alarm", | ||
"enabled" : true, | ||
"threshold" : 20 | ||
}, | ||
"loginAttemptsFromTheSameUser" : { | ||
"action" : "alarm", | ||
"enabled" : true, | ||
"threshold" : 3 | ||
}, | ||
"reEnableLoginAfter" : 3600, | ||
"sourceBasedProtectionDetectionPeriod" : 3600, | ||
"url": { | ||
"method": "*", | ||
"name": "/html_login", | ||
"protocol": "http" | ||
} | ||
} | ||
], | ||
|
||
} | ||
} | ||
``` | ||
{{< note >}} For further configuration details, see NGINX App Protect WAF Declarative Policy Guide [Declarative Policy guide]({{< relref "/nap-waf/v4/declarative-policy/policy/#policy/brute-force-attack-preventions" >}}). {{< /note >}} | ||
|
||
## Custom Dimensions Log Entries | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in to --> into