You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Uses plain text, encrypted, or weakly hashed passwords
23
27
* Uses weak encryption keys / API keys
24
28
@@ -27,10 +31,10 @@ An API is vulnerable if:
27
31
28
32
## Scenario #1
29
33
30
-
[Credential stuffing][1], the use of [lists of known passwords][2], is a common attack.
31
-
If an application does not implement automated threat or credential stuffing
32
-
protections, the application can be used as a password oracle to determine if
33
-
the credentials are valid.
34
+
[Credential stuffing][1], the use of [lists of known passwords][2], is a common
35
+
attack. If an application does not implement automated threat or credential
36
+
stuffing protections, the application can be used as a password oracle to
37
+
determine if the credentials are valid.
34
38
35
39
## Scenario #2
36
40
@@ -44,28 +48,42 @@ within a few minutes.
44
48
45
49
## How To Prevent
46
50
47
-
* Make sure you know all the possible flows to authenticate to the API (mobile/web/deep links that implement one-click authentication/etc)
51
+
* Make sure you know all the possible flows to authenticate to the API (mobile/
52
+
web/deep links that implement one-click authentication/etc)
48
53
* Ask your engineers what flows you missed.
49
-
* Read about your authentication mechanisms. Make sure you understand what and how they are used. OAuth is not authentication, and neither API keys .
50
-
* Don't reinvent the wheel in authentication, token generation, password storage. Use the standards.
51
-
* Credential recovery / forget password endpoints should be treated as login endpoints in terms of brute force, rate limiting and lockout protections.
54
+
* Read about your authentication mechanisms. Make sure you understand what and
55
+
how they are used. OAuth is not authentication, and neither API keys .
56
+
* Don't reinvent the wheel in authentication, token generation, password
57
+
storage. Use the standards.
58
+
* Credential recovery / forget password endpoints should be treated as login
59
+
endpoints in terms of brute force, rate limiting and lockout protections.
52
60
* Use the [OWASP Authentication Cheatsheet][3]
53
61
* Where possible, implement multi-factor authentication.
54
-
* Implement anti brute force mechanisms to mitigate credential stuffing, dictionary attack and brute force attacks on your authentication endpoints. This mechanism should be stricter than the regular rate limiting mechanism on your API.
55
-
* Implement [account lockout][4] / captcha mechanism to prevent brute force against specific users.
56
-
Implement weak-password checks.
57
-
* API keys should not be used for user authentication, but for [client app / project authentication][5].
62
+
* Implement anti brute force mechanisms to mitigate credential stuffing,
63
+
dictionary attack and brute force attacks on your authentication endpoints.
64
+
This mechanism should be stricter than the regular rate limiting mechanism on
65
+
your API.
66
+
* Implement [account lockout][4] / captcha mechanism to prevent brute force
67
+
against specific users. Implement weak-password checks.
68
+
* API keys should not be used for user authentication, but for [client app /
0 commit comments