Test balance transfers for race conditions
When testing an endpoint that transfers a balance, such as a gift card, try sending two identical transfer requests at the same time. This can be done using two separate browsers or sessions, both logged into the same account, and both pointed at the transfer endpoint. If the server is vulnerable to a race condition, both requests may be processed before the balance is updated, resulting in the destination receiving twice the amount. To confirm, look for the destination balance being updated twice, or the source balance not being deducted correctly. This technique can be applied to any endpoint that checks a balance or limited resource, such as stock counts or usage limits.
Follow #gift-cards, #race-condition or #starbucks for new tips like this one, on your notifications page and, if you choose, in a daily or weekly email.
Comments
No comments yet.