crAPI VAPT
crAPI VAPT
++
Muhzin Nassar
1
1. PROJECT SUMMARY
a) Executive Summary
b) Project Details
c) Scope
2. VULNERABILITIES
a) Broken Authentication
b) Broken Object Level Authorization
c) Improper Asset Management
d) Mass Assignment
e) Server-Side Request Forgery
f) Headers
g) Rate limiting
h) IDOR
i) Token
j) Injection Attack
2
Executive Summary
Project Details
Scope
3
No: Vulnerability Severity Status
4
Broken Authentication
CWE-287 : Vulnerable
CVSS : 8.1
Description
Vulnerable Instance
/identity/api/auth/login
Proof of Concept
5
Step 2: Use wfuzz to Bruteforce the password
Impact
6
broken authentication, they can potentially steal user
identities
Mitigation
Reference
OWASP
CVSS : 7.1
Description
Vulnerable Instance
/Identity/api/v2/vehicle/{resource id}/location
7
Proof of Concept
8
Impact
Reference
OWASP
9
Improper asset management
CWE-282 : Vulnerable
CVSS : 7.5
Description
Vulnerable Instance
/Identity/api/auth/v3/check-otp
Proof of Concept
10
Step 2: v2 can also be found and it doesn’t have any rate
liming headers present
11
Step 3: We can use wfuzz to bruteforce the otp
Impact
12
Operational Inefficiencies: Resource Wastage,
Difficulty in Incident Response
Mitigation
Reference
OWASP
13
Mass Assignment
CWE-915 : Vulnerable
CVSS : 7.1
Description
Vulnerable Instance
/workshop/api/shop/products
Proof of Concept
14
Step 2: Add json parameters equivalent to the response
seen above for exploitation
15
Step 4: With the above changes we can add our own
products, give negative values etc..
Impact
Mitigation
16
Use Strong Validation and Type Checking
Reference
OWASP
CWE-918 : Vulnerable
CVSS : 9.1
Description
17
Vulnerable Instance
/workshop/api/merchant/contact_mechanic
Proof of Concept
18
Step 3: Add common ssrf payloads in the payload
section of burp intruder
19
Step 5: We have 2 positive results and we also got a
response on our webhook URL. SSRF is possible here.
20
Impact
Mitigation
Reference
OWASP
Headers
21
Missing Headers
CWE-693 : Vulnerable
CVSS : 4.8
Description
Vulnerable Instance
/identity/api/v2/users/video
Proof of Concept
22
You can see that the header Content-Security-Policy is
missing in the response.
Impact
Click-jacking
Data Leakage
Mitigation
Reference
OWASP
23
Misconfigured Content-Type Header
CWE-693 : Vulnerable
CVSS : 3.7
Description
Vulnerable Instance
/workshop/api/shop/orders/
Proof of Concept
24
When the Content-Type header is set incorrectly or not
enforced, it can lead to unexpected behavior and
potential security issues.
Impact
Misinterpretation of Data
Data Exposure
Mitigation
Reference
OWASP
25
Header Fingerprinting
CWE-200 : Vulnerable
CVSS : 5.3
Description
Vulnerable Instance
/api/
Proof of Concept
26
As you can see in the response there’s unnecessary
information being relayed.
Impact
Information Disclosure
Easy Reconnaissance
Mitigation
Reverse Proxy
27
Reference
OWASP
Rate limiting
CWE-770 : Vulnerable
CVSS : 9.8
Description
Vulnerable Instance
/login
Proof of Concept
28
Step 1: Attempt logging in with valid email but wrong
password as many time as you can and see if there’s any
limit
29
Headers for rate limiting is not set for login pages
Impact
Credential Stuffing
Denial of Service
Mitigation
Gradual Lockout
30
Reference
OWASP
IDOR
CWE-639 : Vulnerable
CVSS : 7.1
Description
Vulnerable Instance
/workshop/api/shop/orders/
Proof of Concept
31
Step 2: Send that request to burp repeater
32
As you can see this instance is vulnerable to IDOR
Impact
Data Manipulation
Mitigation
Reference
OWASP
33
JWT (JSON Web Token)
CWE-311 : Vulnerable
CVSS : 4.3
Description
Vulnerable Instance
/login
Proof of Concept
Step 1: Use burp proxy and capture the login request and
obtain the jwt token
34
Step 2: Copy this token value and head to jwt.io
Impact
Security Bypass
Inconsistent Security
35
Attacks on Internal Resources
Mitigation
Reference
OWASP
Injection Attack
CWE-943 : Vulnerable
CVSS : 7.1
Description
Vulnerable Instance
/community/api/v2/coupon/validate-coupon
36
Proof of Concept
37
Step 3: Now we’ll be using wfuzz for faster attacks, for
that change the json parameter like the above screenshot
and copy it and construct the wfuzz command
accordingly.
38