<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Chinonsopeter on Medium]]></title>
        <description><![CDATA[Stories by Chinonsopeter on Medium]]></description>
        <link>https://medium.com/@chinonsopeter456?source=rss-c9f42c096466------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*rq5QkrHrbP4LI-llABrrLA.jpeg</url>
            <title>Stories by Chinonsopeter on Medium</title>
            <link>https://medium.com/@chinonsopeter456?source=rss-c9f42c096466------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 02 Dec 2026 06:59:32 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@chinonsopeter456/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Crack the Gate 2]]></title>
            <link>https://medium.com/@chinonsopeter456/crack-the-gate-2-4d8a3c6dddec?source=rss-c9f42c096466------2</link>
            <guid isPermaLink="false">https://medium.com/p/4d8a3c6dddec</guid>
            <category><![CDATA[picoctf]]></category>
            <dc:creator><![CDATA[Chinonsopeter]]></dc:creator>
            <pubDate>Fri, 12 Dec 2025 10:03:21 GMT</pubDate>
            <atom:updated>2025-12-12T10:03:21.112Z</atom:updated>
            <content:encoded><![CDATA[<p>Author: Yahaya Meddy</p><h4>Description</h4><p>The login system has been upgraded with a basic rate-limiting mechanism that locks out repeated failed attempts from the same source. We’ve received a tip that the system might still trust user-controlled headers. Your objective is to bypass the rate-limiting restriction and log in using the known email address: <strong>ctf-player@picoctf.org</strong> and uncover the hidden secret.</p><p>Additional details will be available after launching your challenge instance.</p><p>Hints</p><ol><li>What IP does the server think you’re coming from?</li><li>Read more about <a href="https://www.typeerror.org/docs/http/headers/x-forwarded-for">X-forwarded-For</a></li><li>You can rotate fake IPs to bypass rate limits.</li></ol><p>According to the lab the login system has implemented rate-limiting mechanism to prevent brute-forcing attempt but the system still trusts user-controlled headers, according to the hint i am to read about the x-forwarded-for header and it is a header that can be used to specify the source ip of a request when traffic passes through proxies, CDNs, VPNs, or load balancers.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CouFmYma7C88-J0SJ_4YkQ.png" /><figcaption>Request without the XFF header</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*84TgIgZQCABqYRlUx8xaLw.png" /><figcaption>Request after add the XFF to modify source ip of request</figcaption></figure><p>from the image i know the application cannot block my request if i change the value of the XFF header for every request to brute force the password</p><p>I used turbo intruder on burp to achieve this brute-forcing by changing the value of the password from the password list given and also changing the value of the XFF header for every request and i was able to bypass the rate-limit and get my flag</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8b8BMzwDUYn7s0TkG6oLUg.png" /><figcaption>constructing code on turbo</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2vjzFJHYBR3Y8Qs3wAqBUQ.png" /><figcaption>Image of successful bypass</figcaption></figure><p>Flag: picoCTF{xff_byp4ss_brut3_1663a1a8}</p><p>Defenses:</p><ol><li>To defend against this type of attack the application must treat every user input as malicious and stop trusting it, it must use another variable not controlled by the user to verify source of a request i.e not trusting user supplied XFF header</li><li>The application should use other means of verifying source such as sessions, device fingerprint</li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4d8a3c6dddec" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Crack the Power]]></title>
            <link>https://medium.com/@chinonsopeter456/crack-the-power-d8f5cccf707c?source=rss-c9f42c096466------2</link>
            <guid isPermaLink="false">https://medium.com/p/d8f5cccf707c</guid>
            <category><![CDATA[picoctf]]></category>
            <dc:creator><![CDATA[Chinonsopeter]]></dc:creator>
            <pubDate>Tue, 09 Dec 2025 09:29:20 GMT</pubDate>
            <atom:updated>2025-12-09T09:29:20.697Z</atom:updated>
            <content:encoded><![CDATA[<p>Author: Yahaya Meddy</p><p>Category: Cryptography</p><p>Difficulty: Medium</p><h4>Description</h4><p>We received an encrypted message. The modulus is built from primes large enough that factoring them isn’t an option, at least not today. See if you can make sense of the numbers and reveal the flag.Download the <a href="https://challenge-files.picoctf.net/c_amiable_citadel/03d301dd23ffd797f69f0455c954caf1ac883a876ef4c26f3e60bfac12581cbb/message.txt">message</a>.</p><h4>Hints:</h4><ol><li>When certain values in the encryption setup are smaller than usual, it opens up unexpected shortcuts to recover the plaintext</li><li>Consider whether you can invert the encryption without factoring n</li><li>Read more about Coppersmith’s_attack <a href="https://en.wikipedia.org/wiki/Coppersmith&#39;s_attack">here</a></li></ol><p>In this challenge i was given an RSA encrypted message and i was to exploit a weakness in the encryption and the hints guided me in the correct direction is there any way i can get back the original message without factorizing the modulus n so i read about low public exponent attack in Coppersmith’s_attack seeing as the scenario in which it occurs is a part of the hint:<br>Scenarios where low public exponent attack can occur:</p><ol><li>RSA encryption was used with a small exponent, e</li><li>The message encrypted, m is too small</li><li>The same small message is sent to other people using the same small exponent</li><li>There is no padding</li></ol><p>and if you look at the message file downloaded from pico the exponent e = 20 is small signifying a potential for low public exponent attack.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dDOHJqHkh5lBBallAPGCjw.png" /></figure><blockquote>Let me explain my attack before carrying it out</blockquote><blockquote>if we have a message m and e = 20 and the modulus n is a very large number,</blockquote><blockquote>if (m^e &lt; n)</blockquote><blockquote>then (c = m^e mod n = m^e)</blockquote><blockquote>so i assumed that my ciphertext c = m^e = m²⁰all i had to do was invert it (c^(1/20))back to m and convert the integer to bytes</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*aFInM9k4tZZC0zpHQEY0uw.png" /></figure><p>and the output showed i was right:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/336/1*81dgRYT_-x1Xc9dZPfb0ww.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d8f5cccf707c" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Portswigger Labs My Write-Up — Authentication Vulnerabilites]]></title>
            <link>https://medium.com/@chinonsopeter456/portswigger-labs-my-write-up-authentication-vulnerabilites-6df4c76c5c12?source=rss-c9f42c096466------2</link>
            <guid isPermaLink="false">https://medium.com/p/6df4c76c5c12</guid>
            <category><![CDATA[portswigger-lab]]></category>
            <dc:creator><![CDATA[Chinonsopeter]]></dc:creator>
            <pubDate>Tue, 04 Nov 2025 10:08:45 GMT</pubDate>
            <atom:updated>2025-11-04T10:08:45.005Z</atom:updated>
            <content:encoded><![CDATA[<h3>Portswigger Labs My Write-Up — Authentication Vulnerabilites</h3><h3>Lab: Password reset poisoning via middleware</h3><p>LAB: <a href="https://portswigger.net/web-security/learning-paths/authentication-vulnerabilities/vulnerabilities-in-other-authentication-mechanisms/authentication/other-mechanisms/lab-password-reset-poisoning-via-middleware#"><em>https://portswigger.net/web-security/learning-paths/authentication-vulnerabilities/vulnerabilities-in-other-authentication-mechanisms/authentication/other-mechanisms/lab-password-reset-poisoning-via-middleware#</em></a></p><p>This lab is vulnerable to password reset poisoning. The user carlos will carelessly click on any links in emails that he receives. To solve the lab, log in to Carlos&#39;s account. You can log in to your own account using the following credentials: wiener:peter. Any emails sent to this account can be read via the email client on the exploit server.</p><ol><li>I set up burp to act as proxy to understand how the reset password functionality worked i reset password for a user i control “wiener” a link was sent to the email of the username and i was able to view it cause i own the email</li><li>I clicked the email and generated a new password successfully now i want to do something similar for a user i don’t control “carlos” so i select all the request that was used for the user i control in burp to:</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fGqb5fRsmeyKecer4k3eRA.png" /></figure><p>i changed the username to carlos and added “x-forwarded-host” header to trick the application to generate the url/link with my own specified host using the “x-forwarded-host” header and it worked so instead of the unique url to contain original host <em>“</em><a href="https://0ad50055034705328217a7b5001200ce.web-security-academy.net/"><em>https://0ad50055034705328217a7b5001200ce.web-security-academy.net</em></a><em>” </em>it contains my own hosts which is the address of my exploit server<em> “</em><a href="https://exploit-0acc00d9037605b7820ca640010f00b4.exploit-server.net/"><em>https://exploit-0acc00d9037605b7820ca640010f00b4.exploit-server.net</em></a><em>” </em>so when carlos clicks on the link in his email his browser will try to locate the address resolving the host and communicating to my exploit server which will cause an error on his side but my exploit server would have a log of the request made from “carlos” browser and the unique token would be in the log as shown below:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*v9JvfhjJRsuE0nTlXSKrDg.png" /></figure><p>now i have the token all i have to is create a new password using the token gotten and it worked:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lIRDcsY8l9UZv5dYgtRUiQ.png" /></figure><p>3. After generating a new password i was able to login as user carlos:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*iQKyXxzufl_MHD8wsRP14Q.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6df4c76c5c12" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Portswigger Labs My Write-Up — Authentication Vulnerabilites]]></title>
            <link>https://medium.com/@chinonsopeter456/portswigger-labs-my-write-up-authentication-vulnerabilites-e6989b837eb8?source=rss-c9f42c096466------2</link>
            <guid isPermaLink="false">https://medium.com/p/e6989b837eb8</guid>
            <category><![CDATA[portswigger-lab]]></category>
            <dc:creator><![CDATA[Chinonsopeter]]></dc:creator>
            <pubDate>Mon, 03 Nov 2025 13:55:39 GMT</pubDate>
            <atom:updated>2025-11-03T20:05:53.208Z</atom:updated>
            <content:encoded><![CDATA[<h3>Portswigger Labs My Write-Up — Authentication Vulnerabilites</h3><h3>Lab: Password reset poisoning via middleware</h3><p>LAB: <a href="https://portswigger.net/web-security/learning-paths/authentication-vulnerabilities/vulnerabilities-in-other-authentication-mechanisms/authentication/other-mechanisms/lab-password-reset-poisoning-via-middleware#"><em>https://portswigger.net/web-security/learning-paths/authentication-vulnerabilities/vulnerabilities-in-other-authentication-mechanisms/authentication/other-mechanisms/lab-password-reset-poisoning-via-middleware#</em></a></p><p>This lab is vulnerable to password reset poisoning. The user carlos will carelessly click on any links in emails that he receives. To solve the lab, log in to Carlos&#39;s account. You can log in to your own account using the following credentials: wiener:peter. Any emails sent to this account can be read via the email client on the exploit server.</p><ol><li>I set up burp to act as proxy to understand how the reset password functionality worked i reset password for a user i control “wiener” a link was sent to the email of the username and i was able to view it cause i own the email</li><li>I clicked the email and generated a new password successfully now i want to do something similar for a user i don’t control “carlos” so i select all the request that was used for the user i control in burp to:</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fGqb5fRsmeyKecer4k3eRA.png" /></figure><p>i changed the username to carlos and added “x-forwarded-host” header to trick the application to generate the url/link with my own specified host using the “x-forwarded-host” header and it worked so instead of the unique url to contain original host <em>“</em><a href="https://0ad50055034705328217a7b5001200ce.web-security-academy.net/"><em>https://0ad50055034705328217a7b5001200ce.web-security-academy.net</em></a><em>” </em>it contains my own hosts which is the address of my exploit server<em> “</em><a href="https://exploit-0acc00d9037605b7820ca640010f00b4.exploit-server.net/"><em>https://exploit-0acc00d9037605b7820ca640010f00b4.exploit-server.net</em></a><em>” </em>so when carlos clicks on the link in his email his browser will try to locate the address resolving the host and communicating to my exploit server which will cause an error on his side but my exploit server would have a log of the request made from “carlos” browser and the unique token would be in the log as shown below:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*v9JvfhjJRsuE0nTlXSKrDg.png" /></figure><p>now i have the token all i have to is create a new password using the token gotten and it worked:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lIRDcsY8l9UZv5dYgtRUiQ.png" /></figure><p>3. After generating a new password i was able to login as user carlos:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*iQKyXxzufl_MHD8wsRP14Q.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e6989b837eb8" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Portswigger Labs My Write-Up — Authentication Vulnerabilites]]></title>
            <link>https://medium.com/@chinonsopeter456/portswigger-labs-my-write-up-authentication-vulnerabilites-d89bc64f9c0a?source=rss-c9f42c096466------2</link>
            <guid isPermaLink="false">https://medium.com/p/d89bc64f9c0a</guid>
            <category><![CDATA[web-security-academy]]></category>
            <category><![CDATA[portswigger]]></category>
            <category><![CDATA[web-security]]></category>
            <category><![CDATA[portswigger-lab]]></category>
            <dc:creator><![CDATA[Chinonsopeter]]></dc:creator>
            <pubDate>Mon, 03 Nov 2025 13:04:56 GMT</pubDate>
            <atom:updated>2025-11-03T13:04:56.542Z</atom:updated>
            <content:encoded><![CDATA[<h3>Portswigger Labs My Write-Up — Authentication Vulnerabilites</h3><h3>Lab: Offline password cracking</h3><p>LAB:<em> </em><a href="https://portswigger.net/web-security/learning-paths/authentication-vulnerabilities/vulnerabilities-in-other-authentication-mechanisms/authentication/other-mechanisms/lab-offline-password-cracking#"><em>https://portswigger.net/web-security/learning-paths/authentication-vulnerabilities/vulnerabilities-in-other-authentication-mechanisms/authentication/other-mechanisms/lab-offline-password-cracking#</em></a></p><p>This lab stores the user’s password hash in a cookie. The lab also contains an XSS vulnerability in the comment functionality. To solve the lab, obtain Carlos’s stay-logged-in cookie and use it to crack his password. Then, log in as carlosand delete his account from the &quot;My account&quot; page.</p><ul><li>Your credentials: wiener:peter</li><li>Victim’s username: carlos</li></ul><ol><li>First i check to see if the lab is vulnerable to xss:</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1013/1*4BCdtoKG1fdhTp48IaURlg.png" /><figcaption>image of injection</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/768/1*CrRTEqHdh6diK5sQaTAhzg.png" /><figcaption>image of successful exploit</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*sKf9imZlVWzofAyTVUuyuQ.png" /></figure><p>this indicates that the website is vulnerable to xss so what i do next is craft a payload to steal cookies of people that view comments on the blog site this payload forces a users browser to redirect to a certain url which in this case was my exploit server url and append the cookie of the user to the request this means the browser will make a request to my server and append the user cookie with the request</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*sKf9imZlVWzofAyTVUuyuQ.png" /><figcaption>image of cookie theft payload</figcaption></figure><p>and i got a request on my server, from the logs on the server i was able to see the request made and also the cookie of any user that was victimized:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QzyFL-XAN6TOP7gS8vdysw.png" /><figcaption>image of successful exploit</figcaption></figure><p>2. The “stay-logged-in ” was of interest to me since i already know how it is constructed <em>[base64({user}:{md5(password)}] </em>and how the website uses it to identify users so i wrote a python code to de-construct and show me the password hash of the user from the cookie:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/758/1*z4y6VhkkawJubUt0HBRAsg.png" /></figure><p>then used crackstation to crack the hash and get the password:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SJYj8i46l0aBUGK9IyxhPA.png" /><figcaption>image of the password</figcaption></figure><p>the password is “once upon a time” and now i can login as user carlos and delete his account</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*yp_gUGgvu9RsH61Zi2AZ9Q.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d89bc64f9c0a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Portswigger Labs My Write-Up — Authentication Vulnerabilites]]></title>
            <link>https://medium.com/@chinonsopeter456/portswigger-labs-my-write-up-authentication-vulnerabilites-5a6a61986683?source=rss-c9f42c096466------2</link>
            <guid isPermaLink="false">https://medium.com/p/5a6a61986683</guid>
            <category><![CDATA[portswigger-lab]]></category>
            <dc:creator><![CDATA[Chinonsopeter]]></dc:creator>
            <pubDate>Sun, 02 Nov 2025 21:04:10 GMT</pubDate>
            <atom:updated>2025-11-02T21:04:10.098Z</atom:updated>
            <content:encoded><![CDATA[<h3>Portswigger Labs My Write-Up — Authentication Vulnerabilites</h3><h3>Lab: Brute-forcing a stay-logged-in cookie</h3><p>LAB : <a href="https://portswigger.net/web-security/learning-paths/authentication-vulnerabilities/vulnerabilities-in-other-authentication-mechanisms/authentication/other-mechanisms/lab-brute-forcing-a-stay-logged-in-cookie"><em>https://portswigger.net/web-security/learning-paths/authentication-vulnerabilities/vulnerabilities-in-other-authentication-mechanisms/authentication/other-mechanisms/lab-brute-forcing-a-stay-logged-in-cookie</em></a></p><p>This lab allows users to stay logged in even after they close their browser session. The cookie used to provide this functionality is vulnerable to brute-forcing.</p><p>To solve the lab, brute-force Carlos’s cookie to gain access to his <strong>My account</strong> page.</p><ul><li>Your credentials: wiener:peter</li><li>Victim’s username: carlos</li><li><a href="https://portswigger.net/web-security/authentication/auth-lab-passwords">Candidate passwords</a></li></ul><ol><li>To brute-force carlos’s cookie i have to understand how the stay-logged-in cookies is constructed so i login with the valid credentials given to me and also checked the “stay-logged-in” option, i was redirected to the “my-account” page of the valid user all while intercepting in burp, the stay-logged-in cookie was generated upon successful login and redirection to the “my-account”</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-knKvnXzY933ZIDJqgGU5w.png" /></figure><p>2. I took the cookie to analyze it and discovered that it was base64 encoding of (username:md5hash(password)) now all i have to do to brute force carlos “stay-logged-in” cookie is to construct the cookie with username “carlos” and every other passwords in the passwords list but first i analyzed how the web application uses the cookie by passing in a wrong value as the “stay-logged-in” cookie(i added “j”s)while leaving the session cookie intact but nothing happened</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zEDkFrDHszVnoJ3NqwzJcw.png" /></figure><p>3. I deleted the session cookie and tried again and i got this :</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-ws04H2t8VDSqJmLfprWqA.png" /></figure><p>a redirect to the login page for an invalid “stay-logged-in” cookie so i figured when no session cookie is available which similar to accessing a page after reopening browser the application depends on the “stay-logged-in” cookie to identify the user meaning i have to brute-force carlos cookie and make a successful reques that will take me to his account page, i wrote a python script to automate it:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kVEyho6hiSz8gSjfovQIbA.png" /></figure><p>and from my result i get a potential cookie and even the password that was used so i try to get “my-accounts” page with the given results</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*yRfn8K5pIGblHQnfoReCmw.png" /></figure><p>and it was a successful attempt as i was able to login as carlos. thank you to <a href="https://medium.com/u/ae0adb9b4a17">Rana Khalil</a> your videos do help to guide me alot<br>As always i am open to reviews</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5a6a61986683" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Portswigger Labs My Write-Up — Authentication Vulnerabilites]]></title>
            <link>https://medium.com/@chinonsopeter456/portswigger-labs-my-write-up-authentication-vulnerabilites-6d8b2009312a?source=rss-c9f42c096466------2</link>
            <guid isPermaLink="false">https://medium.com/p/6d8b2009312a</guid>
            <category><![CDATA[portswigger-lab]]></category>
            <dc:creator><![CDATA[Chinonsopeter]]></dc:creator>
            <pubDate>Fri, 31 Oct 2025 22:21:14 GMT</pubDate>
            <atom:updated>2025-11-01T09:19:04.339Z</atom:updated>
            <content:encoded><![CDATA[<h3>Portswigger Labs My Write-Up — Authentication Vulnerabilites</h3><h3>Lab: 2FA broken logic</h3><p>LAB: <a href="https://portswigger.net/web-security/learning-paths/authentication-vulnerabilities/vulnerabilities-in-multi-factor-authentication/authentication/multi-factor/lab-2fa-broken-logic#"><em>https://portswigger.net/web-security/learning-paths/authentication-vulnerabilities/vulnerabilities-in-multi-factor-authentication/authentication/multi-factor/lab-2fa-broken-logic#</em></a></p><p>This lab’s two-factor authentication is vulnerable due to its flawed logic. To solve the lab, access Carlos’s account page.</p><ul><li>Your credentials: wiener:peter</li><li>Victim’s username: carlos</li></ul><p>You also have access to the email server to receive your 2FA verification code.</p><ol><li>I logged in with the valid credentials entered the page for my 2FA authentication and checked my email for the generated code to login successfully as a valid user and all this action was captured by burp so i analyzed each GET and POST request first of all after a successful login my 2FA code was generated for my user as you can see in the image below a GET message was made to the “/login2” directory which generated 2FA code for the current user which i was able to receive through email:</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Ee8R1AvkcN0j-lJSQ2diIQ.png" /><figcaption>image of generating 2FA code for valid user</figcaption></figure><p>and my goal is to check and exploit vulnerability in the 2FA logic</p><p>2. I tried to see if i could generate a 2FA code for another valid user(victim user) that i didn’t have access to “carlos” by making the same request but changing the verify parameter to our victim user:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mXVyPVq5Ge15mkovUOW-5g.png" /><figcaption>image of generating 2FA for victim-user</figcaption></figure><p>3. Seeing no error i assume it worked and now i can try to bruteforce the 4 digit authentication token and after further test i realize the sites does not prevent brute-forcing so i wrote a python code to bruteforce the digits and using python was very much a big headache cause there are 10⁴ possible combinations and making requests with each passcode was going to take long so i researched about multithreading requests in python and wrote a python code to make concurrent requests with many threads:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*padBAbeqwi8TA0rLvlTbsg.png" /><figcaption>image of multithreading in python</figcaption></figure><p>4. I got the valid 4 digit pin after running the code and was able to login to the accounts of user carlos:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*YW1q3HP-DoBnlxlubX0mOQ.png" /></figure><p>5. Took the authenticated session token and accessed the “my-accounts” page with as carlos:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6TzqnrA3Y__DeIAQjyMp5w.png" /><figcaption>image of successful access of my-accounts page</figcaption></figure><p>as always open to review and suggestions</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6d8b2009312a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Portswigger Labs My Write-Up — Authentication Vulnerabilites]]></title>
            <link>https://medium.com/@chinonsopeter456/portswigger-labs-my-write-up-authentication-vulnerabilites-4953f37911ed?source=rss-c9f42c096466------2</link>
            <guid isPermaLink="false">https://medium.com/p/4953f37911ed</guid>
            <category><![CDATA[portswigger-lab]]></category>
            <dc:creator><![CDATA[Chinonsopeter]]></dc:creator>
            <pubDate>Fri, 31 Oct 2025 18:10:11 GMT</pubDate>
            <atom:updated>2025-10-31T18:10:11.230Z</atom:updated>
            <content:encoded><![CDATA[<h3>Portswigger Labs My Write-Up — Authentication Vulnerabilites</h3><h3>Lab: 2FA simple bypass</h3><p>LAB: <a href="https://portswigger.net/web-security/learning-paths/authentication-vulnerabilities/vulnerabilities-in-multi-factor-authentication/authentication/multi-factor/lab-2fa-simple-bypass"><em>https://portswigger.net/web-security/learning-paths/authentication-vulnerabilities/vulnerabilities-in-multi-factor-authentication/authentication/multi-factor/lab-2fa-simple-bypass</em></a></p><p>This lab’s two-factor authentication can be bypassed. You have already obtained a valid username and password, but do not have access to the user’s 2FA verification code. To solve the lab, access Carlos’s account page.</p><ul><li>Your credentials: wiener:peter</li><li>Victim’s credentials carlos:montoya</li></ul><ol><li>I first logged in to the app with the valid credentials and was redirected to a page where i was supposed to provide a valid four(4) digit authentication code</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0l-0dNds7NsEUj6wm13-dw.png" /></figure><p>2. I tried to check if the application enforced the 2FA authentication and tried to access another page of the application since i was already a logged in user and it worked i accessed the my-accounts directory without providing any valid authenticated code :</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zlDUl41QbDNXcvSWq7R3IA.png" /></figure><p>as always open to reviews thank you</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4953f37911ed" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Portswigger Labs My Write-Up — Authentication Vulnerabilites]]></title>
            <link>https://medium.com/@chinonsopeter456/portswigger-labs-my-write-up-authentication-vulnerabilites-a3c5f497175c?source=rss-c9f42c096466------2</link>
            <guid isPermaLink="false">https://medium.com/p/a3c5f497175c</guid>
            <category><![CDATA[portswigger-lab]]></category>
            <dc:creator><![CDATA[Chinonsopeter]]></dc:creator>
            <pubDate>Thu, 30 Oct 2025 20:51:57 GMT</pubDate>
            <atom:updated>2025-10-30T20:51:57.298Z</atom:updated>
            <content:encoded><![CDATA[<h3>Portswigger Labs My Write-Up — Authentication Vulnerabilites</h3><h3>Lab: Broken brute-force protection, multiple credentials per request</h3><p>This lab is vulnerable due to a logic flaw in its brute-force protection. To solve the lab, brute-force Carlos’s password, then access his account page.</p><ul><li>Victim’s username: carlos</li><li><a href="https://portswigger.net/web-security/authentication/auth-lab-passwords">Candidate password</a></li></ul><ol><li>To solve this lab i intercepted the request in burp and according to the lab i have to pass in multiple credentials in a single request upon observing the post request sent from my browser i observed that the application sent my data is json format and i parsed in an array of passwords from the password lists to see if the requests will work and it did</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OL5HqfqNSSPBV5f8JB69oA.png" /><figcaption>image of putting multiple cedentials</figcaption></figure><p>2. The next thing to do was login in to my accounts but i couldn’t login cause i didn’t know the exact password that worked so i took the valid authenticated session token and used it to login as a valid user</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1PoX0zeNMBp91CVxw0KESA.png" /><figcaption>image of a succesful login after accesing my accounts page with an authenticated session token</figcaption></figure><p>and it worked now i have been redirected to the account of the user “carlos”</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a3c5f497175c" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Portswigger Labs My Write-Up — Authentication Vulnerabilites]]></title>
            <link>https://medium.com/@chinonsopeter456/portswigger-labs-my-write-up-authentication-vulnerabilites-71ee0bb99700?source=rss-c9f42c096466------2</link>
            <guid isPermaLink="false">https://medium.com/p/71ee0bb99700</guid>
            <category><![CDATA[portswigger-lab]]></category>
            <dc:creator><![CDATA[Chinonsopeter]]></dc:creator>
            <pubDate>Thu, 30 Oct 2025 19:40:01 GMT</pubDate>
            <atom:updated>2025-10-30T19:40:01.819Z</atom:updated>
            <content:encoded><![CDATA[<h3>Portswigger Labs My Write-Up — Authentication Vulnerabilites</h3><h3>Lab: Username enumeration via account lock</h3><p>LAB: <a href="https://portswigger.net/web-security/authentication/password-based/lab-username-enumeration-via-account-lock"><em>https://portswigger.net/web-security/authentication/password-based/lab-username-enumeration-via-account-lock</em></a></p><p>This lab is vulnerable to username enumeration. It uses account locking, but this contains a logic flaw. To solve the lab, enumerate a valid username, brute-force this user’s password, then access their account page.</p><ol><li>The application uses a flawed application of its security it locks an account after a certain number of tries but i as an attacker doesn’t even know which username is valid so if i get an account locked after a certain number of tries for any of the usernames provided i can deduce that username as a valid username lets start i’ll make at least five password attempts for each username to see which one generates an account locked using burp intruder and from the image below the user “ec2-user” is a valid username cause the account was locked after incorrect password tries</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*g0S-peRus3gsKnjjsg-mPA.png" /><figcaption>result showing a valid username</figcaption></figure><p>2. I know a valid a valid username all that is left is to brute force the password and avoid locking the account and i noticed that after every 3 attempt waiting for a minute before trying again prevents the account from being locked o i write a python program to do this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*W_DgZJ6ihOGkMWXkuNSQog.png" /><figcaption>python code to brute-force user password</figcaption></figure><p>3. After finally getting the password an “jordan” i was able to login successfully as the user “apps”</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4sXkB08RU_NTJ0SRt0k-Sw.png" /><figcaption>image of my successful login</figcaption></figure><p>as always i am open to reviews and feedback</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=71ee0bb99700" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>