How I got my first bounty on financial sector gateway site by using Previous GraphQL vulnerabilities.
The GraphQL API allowed introspection queries to reveal all type names and fields, and by substituting an authentication type with a test type, an attacker could access sensitive information and perform transactions without proper authorisation.
Published on medium.com
Introduction: I spent at least 7–8 hours learning graphql basics and reading all other bug reports available before discovering this flaw. I discovered api.kivipay.com while researching the target’s subdomains, and discovered that they use graphql instead of Rest-API.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the GraphQL endpoint had introspection enabled and lacked proper authorisation checks on certain types, allowing substitution of an authentication type with a test type to bypass access controls.
Impact
An attacker could access sensitive information of other users and perform any transaction using their own balance and wallet address, potentially leading to financial loss and data exposure.
What the attacker needed
Access to the GraphQL API endpoint; ability to intercept and modify HTTP requests
The fix
The vulnerability was fixed by the organisation, as they patched it immediately.
How it was found
- Route the application's requests through Burp proxy and perform operations such as moving money to a test account.
- Review all HTTP requests and focus on the endpoint generated when sending money to others.
- Identify the GraphQL query that checks if the recipient organisation is registered.
- Look for '__typename: Auth org' in the response.
- Run an introspection query to obtain all __typename and field values.
- Substitute 'Auth org' with the test Auth request to retrieve all information and perform any transaction.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
GraphQL is a way for apps to ask a server for specific data. The server normally has a list of all the data types it knows about, and if it lets anyone see that list, attackers can find hidden parts. Here, the attacker used that list to swap a secure check for a test one, letting them see other people's data and move money.
What is Access control?
A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.