<?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 Januar Nur Santoso on Medium]]></title>
        <description><![CDATA[Stories by Januar Nur Santoso on Medium]]></description>
        <link>https://medium.com/@lazushunting?source=rss-725106871943------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*GaWfpFX75idPPwEf2SpkAQ.jpeg</url>
            <title>Stories by Januar Nur Santoso on Medium</title>
            <link>https://medium.com/@lazushunting?source=rss-725106871943------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 05 Dec 2026 22:55:07 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@lazushunting/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[I Found a Reusable Profile-Update Token — and It Stayed Valid Longer Than Expected]]></title>
            <link>https://medium.com/@lazushunting/i-found-a-reusable-profile-update-token-and-it-stayed-valid-longer-than-expected-04e3abede276?source=rss-725106871943------2</link>
            <guid isPermaLink="false">https://medium.com/p/04e3abede276</guid>
            <dc:creator><![CDATA[Januar Nur Santoso]]></dc:creator>
            <pubDate>Tue, 29 Sep 2026 08:48:33 GMT</pubDate>
            <atom:updated>2026-09-29T08:48:33.225Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*clkMW08mybz7HoW1LQp4hQ.png" /></figure><p>Sometimes, a security finding doesn’t begin with an obvious exploit.</p><p>There is no authentication bypass.<br> No privilege escalation.<br> No access to another user’s account.</p><p>Instead, you find something that feels slightly wrong.</p><p>While testing a profile-update flow, I noticed that the application generated a token for modifying profile information. What caught my attention was what happened when I replayed the request that generated that token.</p><p>The request could be replayed.</p><p>And each replay could generate another profile-update token.</p><p>The authorization context wasn’t being consumed after the operation.</p><p>That raised a simple question:</p><blockquote><strong><em>If this authorization is supposed to protect a profile-update action, why can the same authorized context keep generating new update tokens?</em></strong></blockquote><p>This eventually became a finding that went through several stages: initial discovery, validation by the security team, coordination with a third-party service provider, remediation, and finally a successful retest.</p><h3>The Application Flow</h3><p>The issue appeared during testing of the profile-management functionality.</p><p>After logging into my own account, I navigated to the account page and opened the <strong>Edit Profile</strong> functionality.</p><p>The flow involved an endpoint similar to:</p><pre>GET /auth/mpc/update_profile_page?redirect=1</pre><p>The interesting part wasn’t simply the endpoint itself.</p><p>The endpoint returned a URL pointing to another service, with a token associated with the profile-update process.</p><p>The response contained a structure similar to:</p><pre>https://ua.ctcorpmpc.com/cas-web/<br>#/pages/fio/profile/profile<br>?token=&lt;profile-update-token&gt;<br>&amp;callback=https://connect.testuji.com/auth/mpc/update_profile_page/callback<br>&amp;language=id</pre><p>At that point, the token became interesting from a security perspective.</p><p>It appeared to represent authorization for a profile modification.</p><p>So I started looking at an important property:</p><p><strong>Was this authorization actually single-use?</strong></p><h3>Discovery: Replaying the Request</h3><p>I intercepted the request using an HTTP interception tool and examined how the profile-update flow worked.</p><p>The first request behaved normally.</p><p>It generated a profile-update URL containing a token.</p><p>I used that URL in another browser session and changed my own profile information.</p><p>The update worked.</p><p>Normally, that might have been the end of the test.</p><p>But I still had the original request.</p><p>So instead of starting the entire profile-edit flow again, I replayed the intercepted request.</p><p>The response was interesting.</p><p>A new profile-update token was generated.</p><p>I repeated the process.</p><p>Another token appeared.</p><p>The important observation was that I wasn’t restarting the complete authorization flow each time. I was replaying the previously authorized request while the authenticated session was still valid.</p><p>The application continued issuing new profile-update tokens.</p><p>That changed the nature of the finding.</p><h3>The Behavior in Simple Terms</h3><p>Imagine a system gives you a one-time ticket to change your profile.</p><p>You use the ticket.</p><p>Normally, the ticket should become invalid.</p><p>But imagine the same authorization context could be used to obtain another ticket, then another, and another.</p><p>The problem isn’t necessarily that the ticket allows something the user shouldn’t be able to do.</p><p>The problem is that the <strong>authorization boundary is being reused more broadly than expected</strong>.</p><p>The observed flow looked roughly like this:</p><pre>Authenticated Session<br>        │<br>        ▼<br>Profile Update Request<br>        │<br>        ▼<br>Profile-Update Token<br>        │<br>        ▼<br>Modify Profile</pre><p>What caught my attention was that the request could be replayed:</p><pre>Authenticated Session<br>        │<br>        ▼<br>Replay Original Request<br>        │<br>        ▼<br>New Profile-Update Token<br>        │<br>        ▼<br>Modify Profile Again</pre><p>And the cycle could continue while the authenticated session remained valid.</p><h3>The Technical Detail That Made the Difference</h3><p>One important observation during testing was that restarting the entire flow changed the authentication context.</p><p>When I attempted to repeat the complete process from the beginning, the authentication cookie changed and the request could eventually result in an HTTP 401.</p><p>That behavior was actually useful.</p><p>It suggested that the issue wasn’t simply an unlimited unauthenticated endpoint.</p><p>The replay worked specifically within the still-valid authenticated context.</p><p>In other words, the security boundary appeared to be tied to the existing authenticated session.</p><p>The interesting behavior was:</p><pre>Existing authenticated session<br>        +<br>Previously authorized request<br>        ↓<br>New profile-update token</pre><p>rather than:</p><pre>Unauthenticated request<br>        ↓<br>Profile-update token</pre><p>That distinction matters when assessing the severity.</p><h3>Why This Is Not an Authentication Bypass</h3><p>It would be easy to overstate a finding like this because it involves authentication and profile modification.</p><p>But the evidence did not support that conclusion.</p><p>During testing, I did not find evidence of:</p><ul><li>Authentication bypass</li><li>Cross-account profile modification</li><li>Privilege escalation</li><li>Unauthorized access to another user’s data</li><li>Modification of another user’s profile</li></ul><p>All demonstrated modifications were performed against my own authenticated account.</p><p>The issue was instead about <strong>authorization reuse and transaction boundaries</strong>.</p><p>If the intended security model is that every profile modification should require a newly initiated authorization flow, then allowing the previous context to repeatedly generate update tokens weakens that boundary.</p><h3>The Impact Depends on What the Token Can Change</h3><p>This was also where the impact needed to be assessed carefully.</p><p>If the profile-update flow only allows relatively low-risk fields — such as:</p><ul><li>Display name</li><li>Biography</li><li>Profile picture</li></ul><p>then the practical impact is limited.</p><p>The authenticated user already has permission to modify those fields.</p><p>The replay primarily removes some of the friction from repeating an operation that the user is already authorized to perform.</p><p>However, the situation becomes more interesting if the same mechanism can modify security-sensitive fields.</p><p>For example:</p><pre>Email address<br>Phone number<br>2FA settings<br>Account recovery information</pre><p>Those fields can have much stronger security implications.</p><p>If a sensitive operation is intentionally protected by an additional authorization step or transaction-specific token, allowing the same authorization context to repeatedly generate valid update tokens could reduce the protection provided by that additional step.</p><p>That is why the exact fields covered by the update mechanism matter significantly when evaluating the real-world impact.</p><h3>Proof of Concept</h3><p>The proof of concept was performed entirely against my own account.</p><p>First, I authenticated normally and opened the profile-edit functionality.</p><p>I intercepted the request responsible for initiating the profile-update flow.</p><p>The relevant request was:</p><pre>GET /auth/mpc/update_profile_page?redirect=1</pre><p>The response produced a profile-update URL containing a token.</p><p>I then used that flow to modify my own profile.</p><p>Afterward, rather than restarting the entire process, I replayed the original intercepted request.</p><p>The server generated another profile-update token.</p><p>I could then use the new token to perform another profile modification.</p><p>Repeating the process demonstrated that the authorization context could continue producing new update tokens while the authenticated session remained valid.</p><p>The key observation was therefore not simply:</p><blockquote><em>“I can edit my profile.”</em></blockquote><p>I was already authorized to do that.</p><p>The interesting behavior was:</p><blockquote><strong><em>“The same previously established authorization context can repeatedly produce new profile-update authorizations.”</em></strong></blockquote><h3>Reporting the Finding</h3><p>I reported the issue to the security team with the behavior, reproduction steps, impact analysis, and limitations.</p><p>The initial response was that the report would be validated.</p><p>The investigation then uncovered an important architectural detail.</p><p>The URL involved in the flow pointed to:</p><pre>ua.ctcorpmpc.com</pre><p>which was not directly owned by Detikcom.</p><p>The Detikcom security team nevertheless validated the behavior and coordinated with the owner of the external service.</p><p>This turned the report into something more interesting than a typical one-team bug bounty interaction.</p><p>The issue crossed an integration boundary.</p><h3>Coordinating With a Third Party</h3><p>After validation, the security team informed me that they would follow up with the owner of the external domain.</p><p>There was a period of waiting while the two parties coordinated.</p><p>Eventually, I received confirmation that the external service provider had also validated the issue and was working on a fix.</p><p>At this point, the vulnerability had moved beyond discovery.</p><p>It had entered the remediation stage.</p><p>That part of responsible disclosure is rarely visible in technical write-ups, but it is an important part of real-world security research.</p><p>Finding a vulnerability is only one part of the process.</p><p>Sometimes the harder part is making sure the right team actually owns the component that needs to be fixed.</p><h3>The Fix</h3><p>Later, the security team provided an update that the affected URL was being removed from the flow when the redirect value was manipulated.</p><p>They specifically noted that the parameter:</p><pre>updateProfilePageUri</pre><p>no longer contained the CTCorp MPC URL.</p><p>I was asked to perform a retest.</p><p>Initially, I couldn’t complete the verification because my original test account could no longer log in.</p><p>After communicating the issue with the security team, I eventually performed the retest using a newly created account.</p><p>The response now looked like this:</p><pre>{<br>  &quot;status&quot;: true,<br>  &quot;message&quot;: null,<br>  &quot;data&quot;: {<br>    &quot;updateProfilePageUri&quot;: &quot;&quot;<br>  }<br>}</pre><p>The external profile-update URL was no longer being returned.</p><p>Based on the available behavior, I confirmed that the reported issue had been remediated.</p><h3>What This Finding Taught Me</h3><p>One of the biggest lessons from this case is that <strong>tokens should be analyzed in context, not just in isolation</strong>.</p><p>Finding a token in a response isn’t automatically a vulnerability.</p><p>The important questions are:</p><ul><li>What does the token authorize?</li><li>Who can obtain it?</li><li>How is it bound to the authenticated session?</li><li>Is it tied to a specific transaction?</li><li>Can it be replayed?</li><li>Does it expire?</li><li>Is it invalidated after successful use?</li><li>What happens if the request that generated it is replayed?</li></ul><p>Those questions can reveal weaknesses that aren’t obvious from the initial request.</p><h3>The Developer Perspective</h3><p>From a defensive perspective, a profile-update authorization should ideally have a clearly defined lifecycle.</p><p>For example:</p><pre>Create authorization<br>        ↓<br>Issue token<br>        ↓<br>Perform update<br>        ↓<br>Invalidate authorization</pre><p>If the same authorization context can repeatedly generate new tokens, the lifecycle becomes:</p><pre>Create authorization<br>        ↓<br>Issue token<br>        ↓<br>Perform update<br>        ↓<br>Generate another token<br>        ↓<br>Perform another update<br>        ↓<br>Generate another token<br>        ↓<br>...</pre><p>Whether that behavior is actually a vulnerability depends on the intended security model.</p><p>If repeated token generation is intentional, it should be explicitly designed and documented.</p><p>If the token is intended to authorize a single state-changing transaction, then it should be bound to that transaction and invalidated after successful use.</p><p>Possible defensive measures include transaction-specific tokens, one-time-use authorization, replay detection, and requiring a fresh profile-edit authorization before issuing another update token.</p><h3>Responsible Disclosure Matters</h3><p>What I appreciated most about this case was the communication throughout the process.</p><p>The issue was not simply accepted and immediately closed.</p><p>It went through validation, ownership clarification, third-party coordination, remediation, and retesting.</p><p>That process reinforced an important part of vulnerability research:</p><p><strong>A good report should make it easy for the organization to understand not only what is happening, but also what security boundary is being affected.</strong></p><p>And when the vulnerable component belongs to another service, patience and clear communication become just as important as the technical finding itself.</p><h3>Final Thoughts</h3><p>This wasn’t a dramatic exploit.</p><p>I didn’t take over an account.</p><p>I didn’t access another user’s profile.</p><p>I didn’t bypass authentication.</p><p>Instead, I found something more subtle: a profile-update authorization context that could be replayed to obtain multiple update tokens during the same authenticated session.</p><p>The finding was eventually validated, coordinated with the relevant third party, fixed, and successfully retested.</p><p>For me, the most valuable lesson was simple:</p><p><strong>Don’t only ask what a token can do. Ask how many times the application lets you use the authorization behind that token.</strong></p><p>Sometimes the weakness isn’t in the permission itself.</p><p>It’s in how long that permission lives — and how easily it can be reused.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=04e3abede276" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[I Found a Reflected XSS in a Search Parameter — and It Wasn’t Where I Expected]]></title>
            <link>https://medium.com/@lazushunting/i-found-a-reflected-xss-in-a-search-parameter-and-it-wasnt-where-i-expected-c82cefcef693?source=rss-725106871943------2</link>
            <guid isPermaLink="false">https://medium.com/p/c82cefcef693</guid>
            <dc:creator><![CDATA[Januar Nur Santoso]]></dc:creator>
            <pubDate>Thu, 10 Sep 2026 15:05:15 GMT</pubDate>
            <atom:updated>2026-09-10T15:05:15.459Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OlsZQlhe-m_l4YGefR2jRQ.png" /></figure><p>When I test a website, I don’t always start with the most complicated functionality. Sometimes, the most interesting findings come from features that look completely ordinary.</p><p>This time, it started with a search box.</p><p>I was testing the public website of the Public Knowledge Project (PKP) when I noticed that the search query was reflected back into the page. At first, this didn’t mean much. Reflecting a search term is normal behavior. A website needs to show users what they searched for.</p><p>But there is an important difference between <strong>reflecting input as text</strong> and <strong>reflecting input as HTML</strong>.</p><p>That difference is where things became interesting.</p><p>I decided to see how the application handled special characters and whether the search parameter was properly encoded before being inserted into the page. What initially looked like a simple search feature eventually turned out to allow JavaScript execution in the browser.</p><p>The result was a <strong>Reflected Cross-Site Scripting (XSS)</strong> vulnerability.</p><h3>Starting With a Simple Search Parameter</h3><p>The affected functionality was the search feature on pkp.sfu.ca. The search query was passed through the s parameter, for example:</p><pre>https://pkp.sfu.ca/?paged=1&amp;order=desc&amp;s=search-term</pre><p>There was nothing suspicious about the parameter itself. It was simply responsible for carrying the user’s search query.</p><p>However, whenever I encounter a parameter that is reflected somewhere in the response, I try to understand exactly how the application handles it.</p><p>The first question isn’t necessarily, “Can I execute JavaScript?”</p><p>The better question is:</p><blockquote><strong><em>“Does the application still see my input as data, or can the browser interpret it as part of the page?”</em></strong></blockquote><p>That distinction is fundamental when testing for XSS.</p><p>A search query should be treated as untrusted data. If I search for something like hello, the application should simply display hello. Even if I enter characters such as &lt;, &gt;, &quot;, or &#39;, those characters should remain characters rather than changing the structure of the HTML document.</p><p>So I started looking at what happened when the input contained HTML-like syntax.</p><h3>When the Search Query Became HTML</h3><p>For the proof of concept, I used an input designed to break out of the existing HTML context and create an SVG element with an event handler:</p><pre>&lt;/textarea&gt;&lt;svg onload=alert(document.cookie)&gt;</pre><p>I submitted the payload through the search functionality and observed the resulting page.</p><p>The important part was not simply seeing the payload reflected.</p><p>The browser actually interpreted the injected markup.</p><p>The &lt;/textarea&gt; portion was intended to close the existing HTML context, while the SVG element introduced an onload event that caused JavaScript to execute when the element was parsed.</p><p>The result was a JavaScript alert containing the value accessible through document.cookie.</p><p>At that point, the behavior was clear: the application was not consistently treating the search parameter as inert text. Attacker-controlled input could reach an executable HTML context and be interpreted by the browser.</p><p>This is the core of the vulnerability.</p><p>The browser does not know that a particular string originally came from a harmless search box. Once that string becomes part of the HTML response, the browser simply parses it according to HTML rules.</p><h3>Understanding the Security Boundary</h3><p>One way I like to think about XSS is as a broken boundary between <strong>data and code</strong>.</p><p>A search parameter belongs on the data side of that boundary.</p><p>The user controls it, so the application should assume that it is untrusted.</p><p>The expected flow should look something like:</p><pre>User Input<br>    ↓<br>Search Parameter<br>    ↓<br>Output Encoding<br>    ↓<br>HTML Response<br>    ↓<br>Browser Displays Text</pre><p>But when output encoding is missing or insufficient, the situation can become:</p><pre>User Input<br>    ↓<br>Search Parameter<br>    ↓<br>HTML Response<br>    ↓<br>Browser Interprets Markup<br>    ↓<br>JavaScript Executes</pre><p>That is what makes reflected XSS different from ordinary input reflection.</p><p>Reflection itself is not necessarily a vulnerability. The problem occurs when the reflected value is placed into a context where the browser can interpret attacker-controlled characters as executable content.</p><p>In this case, the intended purpose of the search parameter was simply to represent a search query and display the relevant results. There is no functional reason for a search query to be able to modify the document structure or execute JavaScript.</p><p>The application therefore crossed a security boundary that should have remained intact.</p><h3>What Could an Attacker Actually Do?</h3><p>This is where I think security write-ups need to be careful.</p><p>It would be easy to see JavaScript execution and immediately claim account takeover or cookie theft. But that would go beyond what I actually demonstrated.</p><p>The confirmed behavior was arbitrary JavaScript execution within the affected application’s origin.</p><p>That means an attacker could potentially manipulate the page displayed to a victim and perform client-side actions available to JavaScript running in that origin. Depending on the application’s architecture and the victim’s privileges, the consequences of XSS can vary significantly.</p><p>For example, an attacker could potentially modify page content, create deceptive interfaces, or interact with browser-accessible information belonging to that origin.</p><p>However, document.cookie does not automatically provide access to every cookie associated with a website. Cookies protected with the HttpOnly attribute cannot be read through JavaScript.</p><p>So I would not describe this finding as an automatic session-cookie theft or account takeover vulnerability.</p><p>The more accurate statement is simply that <strong>attacker-controlled JavaScript could be executed in the application’s origin</strong>.</p><p>That distinction matters.</p><h3>A Realistic Attack Scenario</h3><p>A reflected XSS vulnerability usually requires some form of delivery because the malicious input exists inside a crafted request or URL.</p><p>An attacker could construct a URL containing the malicious search parameter and send it to a victim through a social-engineering channel.</p><p>If the victim opens the link, the vulnerable application processes the search parameter and reflects it into the generated HTML. The browser then interprets the injected content and executes the JavaScript in the context of the affected origin.</p><p>The interesting part is that the victim doesn’t necessarily need to type the payload themselves.</p><p>The malicious input can arrive through the URL.</p><p>This is why reflected XSS should not be dismissed simply because the payload isn’t stored permanently on the server.</p><h3>Looking at the Root Cause</h3><p>The underlying issue appeared to be insufficient output encoding when the search input was rendered into the page.</p><p>The fundamental fix is straightforward in principle: <strong>user-controlled input should be encoded according to the context in which it is being rendered.</strong></p><p>If a search term is supposed to appear as text, it needs to remain text.</p><p>For example, characters that have special meaning in HTML should be encoded so that the browser doesn’t interpret them as markup.</p><p>Developers should also avoid inserting untrusted values directly into executable contexts such as HTML event handlers or JavaScript.</p><p>A Content Security Policy can provide another layer of protection, but it shouldn’t be considered a replacement for proper output encoding. The first line of defense should still be preventing untrusted input from becoming executable content in the first place.</p><h3>Responsible Disclosure</h3><p>After confirming the behavior, I reported the vulnerability to the PKP team.</p><p>The initial report was submitted on August 5, 2026. There was some delay before the report reached the appropriate person, so I followed up later to ask for an update.</p><p>Eventually, the team investigated the issue and confirmed that the problem had been fixed.</p><p>Interestingly, the team explained that the vulnerability was not actually located in their open-source PKP software itself. Instead, the issue was found in the WordPress theme used by the PKP website.</p><p>They confirmed that they had fixed the theme for this issue along with several other issues.</p><p>There was no monetary bug bounty involved. PKP explained that they do not operate a traditional bug bounty program, although they encourage responsible vulnerability disclosure for their open-source projects and support researchers pursuing CVEs where appropriate.</p><p>For me, the most important outcome was still the same: the issue was acknowledged, fixed, and removed from the website.</p><h3>What This Finding Taught Me</h3><p>The biggest lesson from this vulnerability wasn’t the XSS payload.</p><p>It was learning to pay attention to <strong>where input is reflected</strong>.</p><p>When testing a parameter, simply seeing your input appear in the response isn’t enough to conclude that XSS exists. You need to understand the context in which that input is placed.</p><p>Is it inside normal HTML?</p><p>Is it inside an attribute?</p><p>Is it inside a JavaScript block?</p><p>Is it inside a &lt;textarea&gt;?</p><p>The answer changes how the browser parses the input and, consequently, what kind of security issue might be possible.</p><p>This is also why blindly throwing payloads at parameters isn’t always the best approach. Understanding the application’s behavior first often tells you much more than trying hundreds of random strings.</p><h3>Final Thoughts</h3><p>This finding started with one of the simplest features a website can have: a search box.</p><p>There was no complicated authentication bypass, no sophisticated exploit chain, and no need to compromise another user’s account.</p><p>It was simply a case where user-controlled input crossed the boundary between <strong>data and executable content</strong>.</p><p>The vulnerability was reported responsibly, confirmed by the team, and ultimately fixed.</p><p>I didn’t receive a monetary reward for the finding, but that doesn’t make the research meaningless. A vulnerability that gets fixed is still a successful security finding.</p><p>For developers, this is a reminder that even simple search parameters deserve proper output encoding.</p><p>For security researchers, it’s another reminder that interesting vulnerabilities don’t always hide inside complicated functionality.</p><p>Sometimes, you just have to look at something ordinary and ask one simple question:</p><p><strong>“What does the browser think this input is?”</strong></p><p>Because if the application thinks it’s text, but the browser thinks it’s code, that’s where things can get interesting.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c82cefcef693" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[I Found an Open Redirect in a Google Login Flow — and It Could Make Phishing More Convincing]]></title>
            <link>https://medium.com/@lazushunting/i-found-an-open-redirect-in-a-google-login-flow-and-it-could-make-phishing-more-convincing-e1de50707001?source=rss-725106871943------2</link>
            <guid isPermaLink="false">https://medium.com/p/e1de50707001</guid>
            <dc:creator><![CDATA[Januar Nur Santoso]]></dc:creator>
            <pubDate>Tue, 08 Sep 2026 09:52:07 GMT</pubDate>
            <atom:updated>2026-09-08T09:52:07.124Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_r0RIfqCZZfdgi8TuGq9lA.png" /></figure><p>When testing an authentication flow, it is easy to focus on the obvious things.</p><p>Can authentication be bypassed?<br> Can someone access another user’s account?<br> Can OAuth tokens be stolen?</p><p>But there is another question that is often overlooked:</p><p><strong>Where does the application send the user after authentication succeeds?</strong></p><p>While testing a Google Login flow, I came across a parameter called redirect_to.</p><p>At first, nothing seemed unusual. The parameter was being used to send users back to an internal page after completing authentication.</p><p>Then I changed its value.</p><p>Instead of pointing to an internal page, I supplied an external domain.</p><p>The Google authentication process still worked.</p><p>But after authentication was completed, the browser was redirected to the external domain I had provided.</p><p>That was the moment I realized I was looking at an <strong>Open Redirect vulnerability</strong>.</p><h3>A Quick Look at the Login Flow</h3><p>The application provides a Google-based authentication mechanism through an endpoint similar to:</p><pre>/google-login/</pre><p>The endpoint accepts a parameter called:</p><pre>redirect_to</pre><p>There is a legitimate reason for having such a parameter.</p><p>For example, imagine a user tries to access their dashboard without being authenticated.</p><p>The application can remember the original destination and send the user there after they successfully log in:</p><pre>User<br>  ↓<br>Login<br>  ↓<br>Google Authentication<br>  ↓<br>Dashboard</pre><p>That is a perfectly reasonable design.</p><p>The security problem begins when the application trusts the destination supplied by the user without sufficiently validating it.</p><h3>Finding the Interesting Parameter</h3><p>I started by observing the normal behavior of the login endpoint.</p><p>A typical URL looked like this:</p><pre>https://linuxenic.com/google-login/?redirect_to=https://linuxenic.com/dashboard/</pre><p>The destination was an internal page, so everything behaved as expected.</p><p>Then came the obvious security question:</p><blockquote><strong><em>What happens if </em></strong><strong><em>redirect_to points somewhere outside the application?</em></strong></blockquote><p>I changed the parameter to an external domain:</p><pre>https://linuxenic.com/google-login/?redirect_to=https://evil.com</pre><p>I opened the URL and went through the normal Google authentication process.</p><p>I wasn’t trying to bypass authentication.</p><p>I wasn’t attempting to steal an OAuth token.</p><p>I simply wanted to see whether the application would validate the redirect destination.</p><p>After successfully selecting a Google account, the browser was redirected to the external URL supplied through redirect_to.</p><p>That was enough to confirm the behavior.</p><h3>Understanding the Vulnerability</h3><p>The issue can be visualized with a very simple flow:</p><pre>User<br>  │<br>  │  /google-login/?redirect_to=external-domain<br>  ▼<br>Application<br>  │<br>  ▼<br>Google Authentication<br>  │<br>  │  Authentication successful<br>  ▼<br>Application<br>  │<br>  │  Uses redirect_to<br>  ▼<br>External Domain</pre><p>The important point is that the vulnerability isn’t necessarily in Google authentication itself.</p><p>The authentication process still works as intended.</p><p>The problem occurs <strong>after authentication</strong>, when the application uses a user-controlled value to determine the next destination.</p><p>If that value is not properly validated, an attacker can potentially turn the application’s login endpoint into a redirector.</p><h3>Why Does This Matter?</h3><p>At first glance, an open redirect can look like a minor issue.</p><p>After all, the attacker isn’t automatically gaining access to an account.</p><p>And that’s exactly why impact assessment matters.</p><p>During testing, I did <strong>not</strong> find evidence of:</p><ul><li>Authentication bypass</li><li>Account takeover</li><li>Unauthorized access to another user’s account</li><li>OAuth access-token leakage</li><li>Authorization-code leakage</li><li>Session-cookie leakage</li></ul><p>So I wouldn’t describe this as an account takeover vulnerability or claim that OAuth itself was compromised.</p><p>The demonstrated impact was more specific:</p><p><strong>The application’s trusted domain could be used to redirect users to an external domain.</strong></p><p>That creates a potential security concern, particularly in phishing and social-engineering scenarios.</p><h3>The Phishing Angle</h3><p>Consider a user receiving a link that begins with a legitimate domain:</p><pre>https://linuxenic.com/google-login/?redirect_to=...</pre><p>The URL starts with a domain the user may already trust.</p><p>The user opens it.</p><p>They see a familiar Google authentication flow.</p><p>After completing authentication, however, the browser is redirected somewhere else.</p><p>For example:</p><pre>Official Domain<br>      ↓<br>Google Login<br>      ↓<br>Authentication<br>      ↓<br>External Website</pre><p>An attacker could potentially use this behavior as one component of a phishing campaign.</p><p>The important distinction is that <strong>the open redirect does not magically make phishing successful</strong>.</p><p>Instead, it can make a malicious link appear more trustworthy because the initial URL originates from a legitimate application domain.</p><p>This is why open redirects are worth investigating even when they do not directly lead to account compromise.</p><h3>Proof of Concept</h3><p>The proof of concept was straightforward.</p><p>I started with a legitimate internal destination:</p><pre>https://linuxenic.com/google-login/?redirect_to=https://linuxenic.com/dashboard/</pre><p>I then changed the destination to an external domain:</p><pre>https://linuxenic.com/google-login/?redirect_to=https://evil.com</pre><p>After opening the URL and completing the Google authentication flow, the resulting navigation was:</p><pre>Google Login<br>     ↓<br>Authentication Successful<br>     ↓<br>External Redirect</pre><p>No authentication bypass was required.</p><p>No victim account needed to be compromised.</p><p>The behavior could be demonstrated simply by controlling the redirect destination.</p><h3>What Is the Root Cause?</h3><p>The underlying problem appears to be insufficient validation of the redirect_to parameter.</p><p>A safer design would look something like this:</p><pre>User-controlled redirect_to<br>          │<br>          ▼<br>       Validate<br>          │<br>     ┌────┴────┐<br>     │         │<br>   Allowed   Invalid<br>     │         │<br>     ▼         ▼<br> Redirect   Default Page</pre><p>Instead of:</p><pre>User-controlled redirect_to<br>          │<br>          ▼<br>    Redirect directly</pre><p>The application should treat redirect destinations as <strong>untrusted input</strong>.</p><p>For example, an internal destination such as:</p><pre>https://linuxenic.com/dashboard/</pre><p>could be accepted.</p><p>An external destination such as:</p><pre>https://example-attacker-domain.com/</pre><p>should be rejected, ignored, or replaced with a safe default.</p><p>Depending on the application’s requirements, developers could also consider using an allowlist, internal destination identifiers, or signed redirect mechanisms.</p><h3>Responsible Disclosure</h3><p>Once I confirmed that the behavior was reproducible and understood its actual impact, I reported the finding through the available bug bounty program.</p><p>One thing I consider particularly important when writing security reports is <strong>not overclaiming</strong>.</p><p>I didn’t report this as an authentication bypass.</p><p>I didn’t claim OAuth token theft.</p><p>I didn’t claim account takeover.</p><p>The report focused on what could actually be demonstrated:</p><blockquote><em>The </em><em>redirect_to parameter could be manipulated to redirect the browser to an external domain after completing the Google Login flow.</em></blockquote><p>That distinction matters.</p><p>A good security report isn’t necessarily the one with the most dramatic severity.</p><p>It’s the one where the technical behavior, impact, and evidence all line up.</p><h3>What Security Researchers Can Learn From This</h3><p>One of my biggest takeaways from this finding is that authentication testing shouldn’t stop at the login screen.</p><p>When looking at an authentication flow, researchers often concentrate on questions like:</p><blockquote><em>Can I bypass authentication?</em></blockquote><p>But there are other questions worth asking:</p><blockquote><em>What happens before authentication?</em></blockquote><blockquote><em>What happens during authentication?</em></blockquote><blockquote><em>And perhaps most importantly, </em><strong><em>what happens immediately after authentication?</em></strong></blockquote><p>Parameters such as:</p><pre>redirect_to<br>next<br>return<br>returnUrl<br>continue</pre><p>are worth paying attention to because they can influence where the browser goes next.</p><p>They may look harmless, but they can cross an important trust boundary.</p><h3>What Developers Can Learn</h3><p>Redirect parameters should be treated as security-sensitive inputs.</p><p>If an application only needs to redirect users internally, the simplest solution is often to restrict destinations to internal paths or trusted origins.</p><p>If external redirects are genuinely required, they should be explicitly controlled through mechanisms such as an allowlist.</p><p>Invalid destinations should fall back to a safe default rather than being processed as-is.</p><p>And, most importantly, the validation should happen server-side.</p><p>A useful security test for authentication flows is therefore not only:</p><blockquote><em>“Can someone get in without authenticating?”</em></blockquote><p>but also:</p><blockquote><strong><em>“Can an attacker control where the user goes after authenticating?”</em></strong></blockquote><h3>Final Thoughts</h3><p>This wasn’t an account takeover.</p><p>It wasn’t an OAuth compromise.</p><p>It was something much smaller: a redirect parameter that trusted user input more than it should have.</p><p>But security often works this way.</p><p>A seemingly insignificant parameter can become interesting when it crosses a trust boundary.</p><p>In this case, the vulnerability wasn’t at the front door.</p><p><strong>It was at the exit.</strong></p><p>And sometimes, when testing an authentication system, that’s exactly where you need to look.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e1de50707001" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[I Found an Open Redirect on a Game Forum — and Why It Still Matters Even Without a Bounty]]></title>
            <link>https://medium.com/@lazushunting/i-found-an-open-redirect-on-a-game-forum-and-why-it-still-matters-even-without-a-bounty-6bd4cb895cd4?source=rss-725106871943------2</link>
            <guid isPermaLink="false">https://medium.com/p/6bd4cb895cd4</guid>
            <dc:creator><![CDATA[Januar Nur Santoso]]></dc:creator>
            <pubDate>Fri, 24 Apr 2026 10:20:39 GMT</pubDate>
            <atom:updated>2026-04-24T10:20:39.930Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*EC9Xj6oZsht_BULzsCJDtg.png" /></figure><p>Not every bug bounty story ends with a payout.</p><p>Sometimes, it ends with a simple “thank you” — and surprisingly, that can be just as valuable.</p><p>This is the story of how I discovered an open redirect vulnerability on forum.theotown.com, reported it responsibly, and learned an important lesson about impact, trust, and why recognition isn’t always tied to rewards.</p><p>TheoTown is a city-building simulation game with an active community forum where users share plugins, ideas, and discussions. Like many modern platforms, the forum includes mechanisms to handle requests securely — one of them being a challenge system designed to validate user interactions before redirecting them to a target page.</p><p>This mechanism is handled through the following endpoint:</p><pre>https://forum.theotown.com/.within.website/x/cmd/anubis/api/pass-challenge</pre><p>At a glance, this endpoint acts as a validation layer before redirecting users. It processes a challenge and then forwards the user to a destination defined by a parameter called redir.</p><p>That parameter is where the issue begins.</p><h3>Recon and Discovery</h3><p>During testing, I observed that the redir parameter directly controlled where the user would be redirected after completing the challenge. Initially, this seemed normal, since redirect parameters are commonly used in authentication or verification flows.</p><p>However, instead of assuming it was secure, I modified the value.</p><p>I replaced the original internal URL with an external domain. Instead of blocking the request or sanitizing the input, the application redirected me immediately to the external site.</p><p>At that moment, it became clear that there was no validation applied to the redirect destination.</p><h3>Technical Analysis</h3><p>The vulnerability exists because the application does not validate the redir parameter before performing a redirect.</p><p>Here is an example of a legitimate URL:</p><pre>https://forum.theotown.com/.within.website/x/cmd/anubis/api/pass-challenge?response=0042a74f3992e7557b9a6171f49c4e9ace2e7d447d17a509ce96786f60a06f6e&amp;nonce=452&amp;redir=https%3A%2F%2Fforum.theotown.com%2Fplugins%2Flist&amp;elapsedTime=151</pre><p>After the challenge is processed, the user is redirected to:</p><pre>https://forum.theotown.com/plugins/list</pre><p>However, if the redir parameter is modified like this:</p><pre>https://forum.theotown.com/.within.website/x/cmd/anubis/api/pass-challenge?response=0042a74f3992e7557b9a6171f49c4e9ace2e7d447d17a509ce96786f60a06f6e&amp;nonce=452&amp;redir=https%3A%2F%2Fgoogle.com&amp;elapsedTime=151</pre><p>The browser will redirect the user to:</p><pre>https://google.com</pre><p>The server responds with an HTTP 301/302 redirect without verifying whether the destination domain is trusted.</p><p>This confirms a classic open redirect vulnerability.</p><h3>Impact</h3><p>The impact of this issue becomes more serious when viewed in a real-world attack scenario.</p><p>An attacker can craft a malicious URL that appears to come from forum.theotown.com. Since the domain looks legitimate, users are more likely to trust it. However, once clicked, the user is redirected to a malicious site controlled by the attacker.</p><p>This technique is commonly used in phishing campaigns, where victims are tricked into entering credentials on fake login pages. Because the initial domain looks trustworthy, the success rate of such attacks increases significantly.</p><p>Additionally, this type of vulnerability can damage the reputation of the platform. If users repeatedly encounter malicious redirects from legitimate links, their trust in the platform may decline over time.</p><h3>Proof of Concept (PoC)</h3><p>To reproduce this behavior, follow these steps:</p><ol><li>Open the following URL in your browser:</li></ol><pre>https://forum.theotown.com/.within.website/x/cmd/anubis/api/pass-challenge?response=0042a74f3992e7557b9a6171f49c4e9ace2e7d447d17a509ce96786f60a06f6e&amp;nonce=452&amp;redir=https%3A%2F%2Fforum.theotown.com%2Fplugins%2Flist&amp;elapsedTime=151</pre><ol><li>After the challenge process completes, you will be redirected to:</li></ol><pre>https://forum.theotown.com/plugins/list</pre><ol><li>Now modify the redir parameter to point to an external domain:</li></ol><pre>https://forum.theotown.com/.within.website/x/cmd/anubis/api/pass-challenge?response=0042a74f3992e7557b9a6171f49c4e9ace2e7d447d17a509ce96786f60a06f6e&amp;nonce=452&amp;redir=https%3A%2F%2Fgoogle.com&amp;elapsedTime=151</pre><ol><li>When accessed, the browser will redirect you to:</li></ol><pre>https://google.com</pre><p>Even if the response and nonce values expire, the vulnerability persists. You can reproduce it by generating a fresh request and modifying the redir parameter.</p><h3>Responsible Disclosure</h3><p>After confirming the issue, I reported it directly to the TheoTown team. The goal was to help improve the platform’s security and prevent misuse of trusted links.</p><p>The response was prompt and professional. The team acknowledged the vulnerability and implemented a fix. They also clarified that they do not operate a bug bounty program.</p><p>Even without a financial reward, the response showed a strong commitment to user security.</p><h3>Insights and Lessons Learned</h3><p>This case highlights how seemingly small issues can have meaningful security implications.</p><p>Open redirect vulnerabilities are often underestimated, but they can play a key role in phishing and social engineering attacks. Proper validation of user input — especially when it affects navigation — is essential.</p><p>It also reinforces an important mindset in bug bounty work: the value of a report is not always measured in payouts. Sometimes, contributing to a safer system is the real outcome.</p><p>This finding started with a simple test and led to a real security improvement.</p><p>The vulnerability was fixed, the issue was acknowledged, and the platform became more secure.</p><p>Not every report results in a bounty, but every valid finding still has value.</p><p>And in the end, that is what makes this work worth doing.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6bd4cb895cd4" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[When a “Request Smuggling” Bug Isn’t One — Lessons from a Misleading Desync Finding]]></title>
            <link>https://medium.com/@lazushunting/when-a-request-smuggling-bug-isnt-one-lessons-from-a-misleading-desync-finding-e8f321b05f4f?source=rss-725106871943------2</link>
            <guid isPermaLink="false">https://medium.com/p/e8f321b05f4f</guid>
            <dc:creator><![CDATA[Januar Nur Santoso]]></dc:creator>
            <pubDate>Mon, 20 Apr 2026 02:54:13 GMT</pubDate>
            <atom:updated>2026-04-20T02:54:13.348Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Wqid71kQ-eUXfVS2e1BRAA.png" /></figure><p>There’s a moment every security researcher experiences at some point: you think you’ve found something serious. The behavior looks suspicious, the response pattern feels off, and everything seems to point toward a well-known class of vulnerability.</p><p>This is a story about one of those moments.</p><p>It started with what looked like a classic <strong>HTTP request smuggling</strong> scenario on Elastic infrastructure. But as the investigation unfolded — and after the report was submitted — the conclusion turned out to be very different from the initial assumption.</p><p>And that’s exactly what makes this case worth talking about.</p><p>Modern web applications rarely rely on a single layer. Instead, they are built on top of multiple components working together: CDNs, reverse proxies, caching layers, and backend servers. In the case of Elastic’s public-facing endpoints, the stack includes edge handling (such as CDN behavior) and backend processing powered by technologies like Nginx and Next.js.</p><p>This layered architecture is powerful, but it also introduces complexity — especially when it comes to how HTTP requests are parsed and handled across different layers.</p><p>One class of vulnerability that often emerges from this complexity is <strong>HTTP Request Smuggling</strong>, where inconsistencies between frontend and backend parsing allow attackers to “smuggle” hidden requests.</p><p>With that in mind, I began testing how Elastic’s infrastructure handled edge cases in HTTP parsing.</p><h3>Recon and Discovery</h3><p>The initial idea was simple: test how the system behaves when receiving unusually large HTTP headers.</p><p>Using a raw TLS connection, I crafted a request with an oversized header — around 63KB in size. This is far beyond typical header limits and is often used to trigger edge-case behavior in proxies and servers.</p><p>When the request was sent, the frontend layer responded exactly as expected:</p><pre>HTTP/1.1 494 Request Header Too Large</pre><p>At first glance, everything looked correct. The request was rejected.</p><p>But the connection didn’t immediately terminate.</p><p>That’s where things became interesting.</p><p>When I appended an additional HTTP request after the oversized header, I observed a second response:</p><pre>HTTP/1.1 404 Not Found</pre><p>This suggested that while the frontend rejected the request, some part of the backend still processed the remaining data. That behavior is often associated with <strong>desynchronization conditions</strong>, where different layers interpret the same connection differently.</p><p>At this point, it started to resemble a potential request smuggling scenario.</p><h3>Technical Analysis</h3><p>To understand what was happening, it’s important to break down the behavior across layers.</p><p>The edge layer (likely CDN or proxy) correctly identified the oversized header and returned a 494 Request Header Too Large response. However, instead of fully terminating the connection, it allowed the remaining bytes in the TCP stream to continue downstream.</p><p>The backend server, which includes Nginx and a Next.js application, appeared to interpret those remaining bytes as a separate HTTP request. As a result, it processed the injected request and returned a 404 Not Found response.</p><p>From a research perspective, this creates a <strong>desynchronization signal</strong>. The frontend and backend are no longer aligned in how they interpret request boundaries.</p><p>In many real-world cases, this kind of mismatch can lead to HTTP request smuggling, where attackers inject hidden requests that bypass security controls at the edge.</p><p>However, detecting a desync pattern is not the same as proving exploitability.</p><p>And that distinction matters.</p><h3>Impact</h3><p>If this behavior were exploitable, the potential impact could be significant. Request smuggling vulnerabilities have historically enabled attackers to bypass WAF protections, access restricted endpoints, poison caches, and even cause response mix-ups between users.</p><p>In this case, the observed behavior suggested the possibility of:</p><ul><li>Injecting unintended backend requests</li><li>Reaching internal or restricted paths indirectly</li><li>Bypassing edge-layer validation mechanisms</li><li>Creating inconsistencies in request-response handling</li></ul><p>However, all of these impacts depend on one critical factor: whether the behavior can be reliably exploited in a way that affects other users or system security.</p><p>And that’s where things became less clear.</p><h3>Proof of Concept (PoC)</h3><p>To reproduce the behavior, I established a raw TLS connection to the target endpoint and sent a crafted HTTP request containing an oversized header, followed by a second request appended in the same stream.</p><p>The payload structure looked like this:</p><pre>( echo -ne &quot;GET /events/elasticon HTTP/1.1\r\n&quot;<br>  echo -ne &quot;Host: www.elastic.co\r\n&quot;<br>  echo -ne &quot;X-Heavy: $(python3 -c &#39;print(\&quot;X\&quot; * 63000)&#39;)\r\n&quot;<br>  echo -ne &quot;\r\n&quot;<br>  echo -ne &quot;GET /admin HTTP/1.1\r\n&quot;<br>  echo -ne &quot;Host: www.elastic.co\r\n\r\n&quot;<br>) | openssl s_client -connect www.elastic.co:443 -quiet</pre><p>The responses were consistent:</p><ul><li>The first response returned HTTP/1.1 494 Request Header Too Large</li><li>The second response returned HTTP/1.1 404 Not Found</li></ul><p>This confirmed that multiple responses could be triggered within a single connection, which initially reinforced the desynchronization hypothesis.</p><h3>Responsible Disclosure</h3><p>After documenting the behavior, I submitted the report through HackerOne to Elastic’s bug bounty program.</p><p>The response from the security team provided an important clarification.</p><p>According to their analysis, the observed behavior does not indicate a security vulnerability. Instead, it is likely the result of <strong>HTTP pipelining</strong>, a known feature of the HTTP protocol where multiple requests can be sent over a single connection without waiting for individual responses.</p><p>They also noted that:</p><ul><li>The behavior does not negatively impact other users</li><li>There is no evidence of successful request smuggling</li><li>Similar reports have been submitted before</li><li>The issue was classified as a duplicate</li></ul><p>The report was ultimately closed with a “Duplicate” status.</p><h3>Insights and Lessons Learned</h3><p>This case highlights a subtle but important lesson in security research: not every unusual behavior is a vulnerability.</p><p>There is a fine line between:</p><ul><li>Observing <strong>desynchronization patterns</strong></li><li>Demonstrating <strong>real exploitability</strong></li></ul><p>In modern infrastructures, especially those involving CDNs and layered proxies, it’s not uncommon to encounter behaviors that resemble known attack patterns. However, without a clear impact — such as bypassing controls or affecting other users — these behaviors may not qualify as security issues.</p><p>Another key takeaway is the importance of understanding protocol-level features like HTTP pipelining. Without that context, it’s easy to misinterpret normal behavior as something malicious.</p><p>At first, this finding looked like a textbook case of HTTP request smuggling. The signals were there: inconsistent responses, multiple layers, and unexpected backend processing.</p><p>But after deeper analysis and feedback from the security team, the conclusion shifted.</p><p>This wasn’t a vulnerability — it was a reminder.</p><p>A reminder that in cybersecurity, curiosity is essential, but so is restraint. Not every anomaly leads to exploitation, and not every pattern confirms a bug.</p><p>Sometimes, the most valuable outcome isn’t a bounty — but a better understanding of how the web really works.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e8f321b05f4f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[I Won a Lichess Puzzle Without Playing — Here’s What I Learned About Trusting the Client]]></title>
            <link>https://medium.com/@lazushunting/i-won-a-lichess-puzzle-without-playing-heres-what-i-learned-about-trusting-the-client-8e051fab26fd?source=rss-725106871943------2</link>
            <guid isPermaLink="false">https://medium.com/p/8e051fab26fd</guid>
            <dc:creator><![CDATA[Januar Nur Santoso]]></dc:creator>
            <pubDate>Thu, 09 Apr 2026 06:38:51 GMT</pubDate>
            <atom:updated>2026-04-09T06:38:51.211Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ghhZHdB6Hphp_FPDYUWk9A.png" /></figure><p>I was casually solving puzzles on Lichess, just like any other day. The goal was simple: sharpen tactics and slowly improve my rating. Everything felt normal until a small question crossed my mind — one of those questions that seems trivial at first but can lead somewhere unexpected.</p><p>What exactly does the server verify when we “solve” a puzzle?</p><p>Is it actually checking the moves we play, or is it simply trusting what the client tells it?</p><p>That curiosity turned into a short exploration — and eventually, into a finding that reveals something interesting about how systems handle trust.</p><p>Lichess offers a puzzle feature designed to help players improve their tactical skills. Each puzzle has a rating, and each user also has a puzzle rating that adjusts based on performance. Solving a puzzle correctly increases your rating, while failing decreases it. Over time, this system is supposed to match players with puzzles appropriate to their skill level.</p><p>From the outside, the workflow is straightforward. A user plays through a puzzle, submits the correct sequence of moves, and the system records the outcome. That outcome is then sent to the server through an endpoint: POST /training/complete/{angle}/{puzzleId}.</p><p>This endpoint is responsible for recording whether the user won or lost the puzzle. Naturally, one would assume that the server validates the solution before accepting the result. That assumption turned out to be worth testing.</p><p>To understand what was happening behind the scenes, I started by observing the network traffic generated when a puzzle is completed. Using browser DevTools, I captured the request sent by the client after solving a puzzle.</p><p>The request included a simple parameter: win=true.</p><p>At this point, the question became more precise. Does the server verify the actual moves played, or does it rely entirely on this parameter?</p><p>To test this, I designed a minimal scenario. I selected a puzzle that I had never attempted before. Instead of solving it, I skipped the interaction entirely and manually sent a request to the completion endpoint with win=true.</p><p>The result was immediate and unexpected.</p><p>The server accepted the request and recorded it as a successful puzzle completion.</p><p>At its core, this issue is about how much the server trusts the client.</p><p>In this case, the server does not validate whether the user actually solved the puzzle. It does not check the sequence of moves, it does not verify that any interaction took place, and it does not require proof that the puzzle was even attempted.</p><p>Instead, it relies solely on the win parameter.</p><p>If the request says win=true, the server records a win and applies a rating change accordingly. This behavior is clearly visible in the response, where a positive ratingDiff is returned even when no moves are provided.</p><p>This falls under <strong>Improper Enforcement of Behavioral Workflow (CWE-841)</strong>. The system fails to enforce the expected sequence of actions before granting a reward.</p><p>A simple analogy would be a system that issues a certificate of completion simply because a user claims they have finished a course, without ever verifying their work.</p><h3>Impact</h3><p>The impact of this issue does not involve data leakage or service disruption, but it directly affects the integrity of the system.</p><p>If abused, this behavior allows users to artificially inflate their puzzle rating without solving any puzzles. At a larger scale, it also enables manipulation of puzzle ratings themselves. Since puzzle difficulty is partially determined by user performance, submitting fake wins can distort how puzzles are ranked.</p><p>In a practical scenario, an attacker could automate the process by continuously retrieving new puzzle IDs and submitting forged completion requests. Within a short period of time, thousands of puzzles could have their ratings skewed without any legitimate gameplay.</p><p>This would affect the recommendation system, potentially giving beginners puzzles that are too difficult and experienced players puzzles that are too easy. Over time, it could also erode user trust in the accuracy of the training system.</p><h3>Proof of Concept (PoC)</h3><p>To validate the finding, I conducted a controlled test using my personal Lichess account (januindo) and a puzzle with ID WLeGr that had not been solved before.</p><p>I began by ensuring that I was logged into the platform through a web browser and that my session cookie was active. Using browser DevTools, I extracted the relevant session values, specifically lila2 and sessionId, which are required to authenticate the request.</p><p>Without interacting with the puzzle at all, I then sent a manual POST request directly to the completion endpoint, explicitly setting win=true.</p><pre>curl -X POST &quot;https://lichess.org/training/complete/mix/WLeGr&quot; \<br>  -H &quot;Content-Type: multipart/form-data&quot; \<br>  -H &quot;Origin: https://lichess.org/&quot; \<br>  -H &quot;Referer: https://lichess.org/training/mix&quot; \<br>  -F &quot;win=true&quot; \<br>  -F &quot;rated=true&quot; \<br>  --cookie &quot;YOUR_COOKIE&quot;</pre><p>The server responded with the following JSON:</p><pre>{<br>  &quot;round&quot;: {<br>    &quot;id&quot;: &quot;WLeGr&quot;,<br>    &quot;win&quot;: true,<br>    &quot;ratingDiff&quot;: 126<br>  },<br>  &quot;next&quot;: {<br>    &quot;game&quot;: { ... },<br>    &quot;puzzle&quot;: { ... },<br>    &quot;user&quot;: { &quot;id&quot;: &quot;januindo&quot;, &quot;rating&quot;: 1607, &quot;provisional&quot;: true },<br>    &quot;angle&quot;: { ... }<br>  }<br>}</pre><p>The important detail here is the ratingDiff value of 126, which indicates a significant rating increase. This happened despite the fact that no moves were submitted and no puzzle interaction took place.</p><p>This confirms that the server accepts the win parameter without validating the actual solution.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/716/1*mKP39SNZnJVKCUgtSEV1_w.jpeg" /></figure><p>After confirming the behavior, I reported the finding to the Lichess Team with the intention of helping improve the robustness of the system.</p><p>The response I received provided an interesting perspective. According to the team, this behavior is intentional. Since puzzles are not treated as competitive games and users are allowed to use external assistance, strict validation is not enforced in the same way.</p><p>They also noted that there is no official leaderboard for puzzles, and the rating system is designed to self-correct over time. As a result, this behavior is not considered a vulnerability within their threat model, but rather a consequence of their design philosophy.</p><p>This case highlights an important principle in system design: anything coming from the client should not be blindly trusted. Even seemingly harmless parameters can become critical if they are used to determine outcomes without verification.</p><p>It also illustrates that not every technical weakness will be classified as a vulnerability. In many cases, the decision depends on the product’s goals, trade-offs, and assumptions about user behavior.</p><p>From a security perspective, this is a classic example of how business logic can be just as important as technical safeguards.</p><p>What started as a simple curiosity during a puzzle session turned into a deeper look at how trust is handled between client and server.</p><p>Technically, the behavior exposes a gap in validation. From a product perspective, however, it reflects a deliberate design choice.</p><p>And that is what makes cases like this interesting. Sometimes, the most valuable insight is not just the flaw itself, but the reasoning behind why it exists.</p><p>It leaves us with a simple but important question:</p><p>How much does your system trust the user?</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8e051fab26fd" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>