Anonymous access control - Payments Status
The payment status endpoint could be queried without any authentication, so anyone who knew or guessed a payment identifier could read that payment's status. An attacker could therefore learn whether a given payment had been processed without logging in.
Originally disclosed on HackerOne
- Fixed in 4 days
- Paid in 4 days
- Disclosed after 4 months
Summary:
Found on the Payments Status function website, it can be accessed anonymously. payment status should only be accessible by accounts that make payments in a state that has successfully logged in.
Steps To Reproduce:
access anonymously (without logging in) to the payment status function as in the example below
- Request:
GET /payments/paym_test_5rjz482tky43reoil9f/status HTTP/2 Host: api.omise.co Sec-Ch-Ua: " Not A;Brand";v="99", "Chromium";v="100", "Google Chrome";v="100" Sec-Ch-Ua-Mobile: ?0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.127 Safari/537.36 Sec-Ch-Ua-Platform: "macOS" Accept: / Sec-Fetch-Site: same-origin Sec-Fetch-Mode: cors Sec-Fetch-Dest: empty Referer: https://api.omise.co/ Accept-Encoding: gzip, deflate Accept-Language: en-US,en;q=0.9
- Response:
HTTP/2 200 OK Date: Thu, 21 Apr 2022 10:57:37 GMT Content-Type: application/json; charset=utf-8 Content-Length: 18 X-Download-Options: noopen X-Permitted-Cross-Domain-Policies: none Referrer-Policy: strict-origin Cache-Control: no-cache, no-store Etag: W/"c9e654e8902aa47de7edcd7ab902ed16" Set-Cookie: locale=en; path=/ X-Request-Id: 26180027472066089 Strict-Transport-Security: max-age=31536000; includeSubDomains
{"processed":true}
Impact
Attackers can see payment status on the account's website without having to log in (anonymous)
Best regards,
CodeSlayer137
Attachments

Context
Omise runs a payments platform, and the report concerns a Payments Status function exposed on api.omise.co. The feature returns the processing state of a payment object: given a payment identifier, it answers whether that payment has been processed. The researcher found that this status lookup could be reached without any authenticated session, even though payment status is information that should only be available to accounts that make payments and are logged in.
Setup
The only precondition was knowledge of a payment identifier in the form used by the API, for example paym_test_5rjz482tky43reoil9f. The request carried a desktop browser user agent (Chrome 100 on macOS).
Finding it
The Payments Status endpoint is meant to be consumed by logged-in accounts that are making payments. When the researcher requested the status of a payment without logging in, the API answered with a normal 200 OK and the payment's processing state instead of rejecting the request. That is the whole of the finding: an authorisation check that should have required a session was missing, so the endpoint behaved as if the caller were entitled to the data.
Exploitation
Step 1: Request the payment status anonymously
The researcher sent a plain GET for the status of a payment object, with no cookie, no authorization header and no API key:
GET /payments/paym_test_5rjz482tky43reoil9f/status HTTP/2
Host: api.omise.co
Sec-Ch-Ua: " Not A;Brand";v="99", "Chromium";v="100", "Google Chrome";v="100"
Sec-Ch-Ua-Mobile: ?0
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.127 Safari/537.36
Sec-Ch-Ua-Platform: "macOS"
Accept: */*
Sec-Fetch-Site: same-origin
Sec-Fetch-Mode: cors
Sec-Fetch-Dest: empty
Referer: https://api.omise.co/
Accept-Encoding: gzip, deflate
Accept-Language: en-US,en;q=0.9
The path carries the payment identifier paym_test_5rjz482tky43reoil9f followed by /status. The headers are ordinary browser defaults; nothing in the request identifies a user or an account.
Step 2: Observe the response
The server returned the status with a success code:
HTTP/2 200 OK
Date: Thu, 21 Apr 2022 10:57:37 GMT
Content-Type: application/json; charset=utf-8
Content-Length: 18
X-Download-Options: noopen
X-Permitted-Cross-Domain-Policies: none
Referrer-Policy: strict-origin
Cache-Control: no-cache, no-store
Etag: W/"[redacted]"
Set-Cookie: locale=en; path=/
X-Request-Id: 26180027472066089
Strict-Transport-Security: max-age=31536000; includeSubDomains
{"processed":true}
The body is a small JSON object, {"processed":true}, telling the caller that the payment has been processed. The response also sets a locale=en cookie, which is unrelated to authentication and does not grant access to anything.

Root cause
The status route under /payments/{id}/status is served without an authorisation check on the caller. Because the handler returns data rather than an error, the missing check is invisible to a client that never sends credentials. The report does not describe the server-side implementation, so the exact reason the check was absent is not stated;
Impact
An attacker who knows a payment identifier can read that payment's status from the API without logging in. The response body in the example contains only the processing state. The researcher's own summary is that attackers can see payment status on the account's website without having to log in.
Fix
The report does not describe a fix or a verification of one. Requests without valid credentials should be rejected rather than answered with the payment state.
Variants to test
- Other per-object sub-resources on the same API, such as
/payments/{id}/...routes beyondstatus. A positive result is a200with object data when no credentials are sent. - The same status route with a syntactically valid but non-existent identifier. A
404for unknown identifiers alongside a200for real ones confirms the endpoint is reachable anonymously and that the identifier is the only gate. - The same route with a session belonging to a different account. A
200there shows a missing ownership check on top of the missing authentication check. - Status or lookup endpoints for other object types (charges, refunds, customers) on the same host. A positive result is any object state returned to an unauthenticated caller.
Hunting notes
This kind of bug hides in small, purpose-built routes that sit beside a main resource: status, state, lookup and callback endpoints that were added for a specific flow and never brought under the same authorisation middleware as the rest of the API. During recon, look for paths with a verb-like suffix after an object identifier, and for endpoints that return tiny JSON bodies, since these are often written as internal helpers and exposed directly. The signal is a 200 with real data when the request carries no cookie, no authorization header and no API key.
What happened, in plain words
Omise is a company that runs a payments platform: businesses use it to take payments from their customers. The report is about a small feature on that platform called Payments Status. You give it the identifier of a payment, and it tells you whether that payment has been processed yet.
The researcher found that this status lookup could be used by anyone at all, without logging in. Normally, payment status is information that should only be visible to accounts that make payments and are signed in. Instead, the API answered a stranger's request with a normal success response and the payment's state.
Background you need first
Before the steps make sense, a few everyday ideas.
What an API is. Think of a restaurant. You do not walk into the kitchen; you tell the waiter what you want, and the waiter brings it back. An API (Application Programming Interface) is the waiter between a program and a service. Here the service is Omise's payment system, and the waiter is a web address that answers requests with data. The address in this report is api.omise.co.
What a request and a response are. Your browser sends a request ("please give me this") and the server sends back a response ("here it is", or "no"). A request has a method, like GET, which means "fetch me something". It has a path, which is the part of the address after the host name, and it has headers, which are small labelled lines carrying extra details.
What JSON is. JSON is a simple text format for data, made of names and values in curly brackets. {"processed":true} means "the field called processed has the value true". It is easy for programs to read.
What a cookie is. A cookie is a small note a website asks your browser to keep and send back on later visits, so the site can remember you. The most familiar use is staying logged in. If a request carries no cookie, the server has no easy way to know who you are.
What an API key is. An API key is a long secret string that a program includes with its requests to prove which account it belongs to, a bit like a membership card shown at the door.
What authentication and authorisation are. Authentication is proving who you are, like showing your passport. Authorisation is deciding what you are allowed to do once you are known, like a passport not letting you into every room. This report is about authorisation: the server never checked whether the caller was allowed to see the payment status.
What access control means. Access control is the set of rules about who may reach what. When those rules are missing or wrong, the weakness is called improper access control. A common form is when a feature that should require a login answers anyone.
What a payment identifier is. Each payment in the system has its own name, a string like paym_test_5rjz482tky43reoil9f. It is how you point at one specific payment, the way a parcel number points at one parcel.
Setup
The only precondition was knowing a payment identifier in the form the API uses, for example paym_test_5rjz482tky43reoil9f. The request was sent with an ordinary desktop browser user agent (Chrome 100 on macOS). A user agent is the line in a request where the browser introduces itself, saying which browser and operating system it is.
Finding it
The Payments Status endpoint is meant to be used by logged-in accounts that are making payments. When the researcher asked for the status of a payment without logging in, the API answered with a normal 200 OK and the payment's processing state, instead of refusing the request. That is the whole of the finding: an authorisation check that should have required a session was missing, so the endpoint behaved as if the caller were entitled to the data.
Exploitation
Step 1: Request the payment status anonymously
The researcher sent a plain GET for the status of a payment object, with no cookie, no authorization header and no API key. The point of leaving all of those out is to prove that the request comes from nobody in particular: if the answer still contains real data, the door was open.
GET /payments/paym_test_5rjz482tky43reoil9f/status HTTP/2
Host: api.omise.co
Sec-Ch-Ua: " Not A;Brand";v="99", "Chromium";v="100", "Google Chrome";v="100"
Sec-Ch-Ua-Mobile: ?0
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.127 Safari/537.36
Sec-Ch-Ua-Platform: "macOS"
Accept: */*
Sec-Fetch-Site: same-origin
Sec-Fetch-Mode: cors
Sec-Fetch-Dest: empty
Referer: https://api.omise.co/
Accept-Encoding: gzip, deflate
Accept-Language: en-US,en;q=0.9
Line by line:
GET /payments/paym_test_5rjz482tky43reoil9f/status HTTP/2is the request itself.GETasks to fetch something. The path points at the payment whose identifier ispaym_test_5rjz482tky43reoil9f, and the/statusat the end asks for that payment's status.HTTP/2is the version of the language the browser and server speak.Host: api.omise.cosays which server the request is addressed to.- The
Sec-Ch-Ua,Sec-Ch-Ua-MobileandSec-Ch-Ua-Platformlines are the browser describing itself: which browser brand and version, whether it is a mobile device, and which operating system. They are filled in automatically. User-Agent: Mozilla/5.0 ...is the longer, older-style version of the same introduction, naming Chrome 100 on macOS.Accept: */*says the browser will accept any kind of answer.Sec-Fetch-Site: same-origin,Sec-Fetch-Mode: corsandSec-Fetch-Dest: emptyare notes the browser adds about where the request came from and what it is for.Referer: https://api.omise.co/says the request was started from a page at the API host itself.Accept-Encoding: gzip, deflatesays the browser can accept a compressed answer, to save bandwidth.Accept-Language: en-US,en;q=0.9says the browser prefers English.
Nothing in this request identifies a user or an account. Every header is an ordinary browser default.
Step 2: Observe the response
The server returned the status with a success code:
HTTP/2 200 OK
Date: Thu, 21 Apr 2022 10:57:37 GMT
Content-Type: application/json; charset=utf-8
Content-Length: 18
X-Download-Options: noopen
X-Permitted-Cross-Domain-Policies: none
Referrer-Policy: strict-origin
Cache-Control: no-cache, no-store
Etag: W/"[redacted]"
Set-Cookie: locale=en; path=/
X-Request-Id: 26180027472066089
Strict-Transport-Security: max-age=31536000; includeSubDomains
{"processed":true}
Line by line:
HTTP/2 200 OKis the status line.200is the code for success, so the server did not refuse the request.Date: Thu, 21 Apr 2022 10:57:37 GMTis when the server answered.Content-Type: application/json; charset=utf-8says the body is JSON text.Content-Length: 18says the body is 18 bytes long.X-Download-Options,X-Permitted-Cross-Domain-PoliciesandReferrer-Policyare security-related settings the server sends to browsers. They are not about who may see the data.Etag: W/"[redacted]"is a fingerprint of this particular version of the answer, used for caching checks.Set-Cookie: locale=en; path=/asks the browser to remember a small note saying the language is English. It is unrelated to authentication and does not grant access to anything.X-Request-Id: 26180027472066089is an internal reference number for this one request, useful when looking it up in logs.Strict-Transport-Security: max-age=31536000; includeSubDomainstells the browser to keep using the secure HTTPS version of the site for the next year.- The blank line separates the headers from the body.
{"processed":true}is the body: a small JSON object saying the payment has been processed.

Root cause
The status route under /payments/{id}/status is served without an authorisation check on the caller. Because the handler returns data rather than an error, the missing check is invisible to a client that never sends credentials. The report does not describe the server-side implementation, so the exact reason the check was absent is not stated;
Impact
An attacker who knows a payment identifier can read that payment's status from the API without logging in. The response body in the example contains only the processing state. The researcher's own summary is that attackers can see payment status on the account's website without having to log in.
Fix
The report does not describe a fix or a verification of one. Requests without valid credentials should be rejected rather than answered with the payment state.
Variants to test
- Other per-object sub-resources on the same API, such as
/payments/{id}/...routes beyondstatus. A positive result is a200with object data when no credentials are sent. - The same status route with a syntactically valid but non-existent identifier. A
404for unknown identifiers alongside a200for real ones confirms the endpoint is reachable anonymously and that the identifier is the only gate. - The same route with a session belonging to a different account. A
200there shows a missing ownership check on top of the missing authentication check. - Status or lookup endpoints for other object types (charges, refunds, customers) on the same host. A positive result is any object state returned to an unauthenticated caller.
Hunting notes
This kind of bug hides in small, purpose-built routes that sit beside a main resource: status, state, lookup and callback endpoints that were added for a specific flow and never brought under the same authorisation middleware as the rest of the API. Middleware is shared code that every request passes through, a bit like a security desk at the entrance of a building; if a new door is added that bypasses the desk, anyone can walk in. During recon, look for paths with a verb-like suffix after an object identifier, and for endpoints that return tiny JSON bodies, since these are often written as internal helpers and exposed directly. The signal is a 200 with real data when the request carries no cookie, no authorization header and no API key.
Glossary
- API: the set of web addresses and rules a program uses to talk to a service and get data back.
- API key: a secret string a program sends to prove which account it belongs to.
- Access control: the rules about who is allowed to reach which data or feature.
- Improper access control: a weakness where those rules are missing or wrong, so someone can reach something they should not.
- Authentication: proving who you are, for example by logging in.
- Authorisation: deciding what a known user is allowed to do.
- Session: the state of being logged in, usually remembered through a cookie.
- Cookie: a small note a site asks the browser to keep and send back on later requests.
- Request: a message a browser or program sends to a server asking for something.
- Response: the server's reply to a request.
- GET: the request method that means "fetch me something".
- Header: a labelled line in a request or response carrying extra details.
- User agent: the header where a browser introduces itself, naming the browser and operating system.
- Referer: the header saying which page a request was started from.
- Host: the header naming the server the request is addressed to.
- JSON: a simple text format for data, made of names and values in curly brackets.
- Status code: the number at the start of a response saying how it went, such as
200for success or404for not found. - 200 OK: the status code meaning the request succeeded.
- 404: the status code meaning the requested thing was not found.
- Endpoint: one specific address on an API that performs one specific job.
- Route: the path part of an address that the server uses to decide which code handles the request.
- Payment identifier: the unique string naming one payment, such as
paym_test_5rjz482tky43reoil9f. - Boolean: a value that is either true or false.
- Middleware: shared code that every request passes through, such as a login check.
- Recon: the early stage of looking around a target to find features and addresses worth testing.
- Bounty: a reward a company pays a researcher for reporting a valid bug.
- Severity: how serious a bug is judged to be, here medium.
- Disclosure: the date a report is made public.
- HackerOne: a website where researchers report bugs to companies and companies pay for them.