Skip to main content
Challenges ROP chain: calling a function with three arguments
PWN Hard ROP Solves: 7

ROP chain: calling a function with three arguments

Author: CyberSamSU
Points
100

The final goal is to call the bayroq_chiqar(R0, R1, R2) function (address 0x00404D86) with exactly R0=160, R1=167, R2=31. This time there are more distractors in the gadget table — choose carefully:

The "function calling convention" in this challenge is a simple model invented for educational purposes: the function takes its first argument from the R0 register, the second from R1, and if needed the third from R2 (in the real x86-64 System V ABI this happens via rdi, rsi, rdx — the idea is the same, the names are simplified).

AddressInstruction (gadget)
0x00402960POP R3; RET
0x00401AC0POP R0; RET
0x00401A38NOP; RET
0x00401000POP R1; RET
0x00402B88XOR R0, R0; RET
0x00401160POP R2; RET
0x004028F8POP R4; RET
0x00402C68RET

Chain: [gadget_R0, R0-qiymat, gadget_R1, R1-qiymat, gadget_R2, R2-qiymat, maqsad_manzil] — a total of 7 4-byte words, in sequence.

Submit the answer in the format BAYROQ{PWN_R3_<to'liq zanjir, uzluksiz hex satr>}.

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

First solvers

1. Stiv_084100 10.09.2026
2. W.o.X 11.09.2026
3. testrejim 09.10.2026
4. Mirjaxon Qaxxarov 26.10.2026
5. Odam 04.11.2026
6. arcanum 11.11.2026
7. Furqat Turayev 11.11.2026