Skip to main content
Challenges Bypassing the check via integer overflow
PWN Easy Integer overflow Solves: 5

Bypassing the check via integer overflow

Author: CyberSamSU
Points
20

Many vulnerable programs first accept the size requested by the user (len) in a larger type (for example, 16-bit), but then save it to an internal counter only as a 1-byte (8-bit, mod 256) value. The check is performed precisely on this truncated 8-bit value:

def sorov_qabul_qil(len_16bit):
    len_8bit = len_16bit % 256          # kesish (truncation)!
    if len_8bit < 14:                 # "xavfsiz" tekshiruv
        nusxa_ol(len_16bit)             # LEKIN asl (katta) qiymat bilan nusxalanadi!
    else:
        rad_et()

The buffer size is only 105 bytes. If len_16bit ≤ 105 — everything is safe. Your goal: send a value of len_16bit greater than 105 (meaning copying an amount actually larger than the buffer), but at the same time satisfy the condition len_16bit % 256 < 14 (bypass the check).

Find the smallest value of len_16bit that satisfies these conditions.

Send the answer in the format BAYROQ{PWN_OVERFLOWX_<son>}.

Hints 3
Opening a hint reduces the points you get for solving this challenge.
Hint 1 −2 pts Log in
Hint 2 −4 pts Log in
Hint 3 −6 pts Log in
To submit a flag, log in.

First solvers

1. anonym 27.10.2026
2. Mirjaxon Qaxxarov 27.10.2026
3. Odam 04.11.2026
4. Furqat Turayev 11.11.2026
5. Doston Allayarov 28.11.2026