Multiple choice › Race conditions
Race conditions
1. Race conditions
Two users buy the last ticket at the same moment and both are told the purchase succeeded. This is an example of:
- Broken authentication
- Cross-site scripting
- A race condition
- A side-channel attack
Answer
C
Race condition: the outcome depends on the timing of two processes using a shared resource. Fix with locking/atomic transactions.