This website uses cookies

To provide the highest level of service we use cookies on this site.
Your continued use of the site means that you agree to their use in accordance with our terms and conditions.

Pentest Chronicles

How password reset module compromised all accounts within the mobile application

Marcin Zięba

March 6, 2026

Password reset security Every mobile or web application should allow user to reset his/her password. The cause could be as simple as forgotten password, but such mechanism could also save hijacked account (of course if attacker is not able to change user’s email).

The secure design of password reset module should focus on best security practices like:

• Preventing from user/email enumeration,
• Preventing from token guessing,
• Preventing from token reuse,
• Token should have limited lifetime,
• Making sure that account is not locked when password reset has been initiated,
• Password change logging,
• Passkeys correlation*

*If application utilizes passkeys, password reset should be considered as an additional attack vector. This, however, could be a topic for another article). Where all seemed normal During most recent mobile application pentest another point to consider came out, which was a big surprise.

The password reset flow was as normal as in every other application.

Have you forgot your password? Please provide an email which was used during the registration After the button was clicked, as usual, user was taken to login page where another usual information was provided: According to prompted information, user has received an email with password reset link: Then what’s wrong? But what happens if we intercept mobile traffic and check client-server communication?

The request below is sent when the initial reset password button was clicked: The below response contains the surprise – the same token which was delivered to provided email address is provided in the response body: Screenshot below presents a page which is displayed after clicking the link above: Such behavior opens a possibility to provide any email corresponding to existing application user and then simply open a password reset link from a response in order to set a new password for the selected account. Lesson should be learned Such behavior may result with catastrophic effects from technical and legal (GDPR) perspective, if persists on the production system.

Make sure that the mobile application is subject to regular security audits in order to discover vulnerabilities in the APIs before attackers exploit that in the wild.

Additional security countermeasures such as SSL Certificate Pinning should be in place – this should not be treated as a main defense, but more like an extra layer (same as WAF) which could deter attackers by forcing to allocate additional time to for analysis.


Next Pentest Chronicles

When Usernames Become Passwords: A Real-World Case Study of Weak Password Practices

Michał WNękowicz

9 June 2023

In today's world, ensuring the security of our accounts is more crucial than ever. Just as keys protect the doors to our homes, passwords serve as the first line of defense for our data and assets. It's easy to assume that technical individuals, such as developers and IT professionals, always use strong, unique passwords to keep ...

SOCMINT – or rather OSINT of social media

Tomasz Turba

October 15 2022

SOCMINT is the process of gathering and analyzing the information collected from various social networks, channels and communication groups in order to track down an object, gather as much partial data as possible, and potentially to understand its operation. All this in order to analyze the collected information and to achieve that goal by making …

PyScript – or rather Python in your browser + what can be done with it?

michał bentkowski

10 september 2022

PyScript – or rather Python in your browser + what can be done with it? A few days ago, the Anaconda project announced the PyScript framework, which allows Python code to be executed directly in the browser. Additionally, it also covers its integration with HTML and JS code. An execution of the Python code in …

Any questions?

Happy to get a call or email
and help!