Professional Documents
Culture Documents
Pin Setup
Pin Setup
2023-10-25
300 pts
Description
I feel like this PIN verification algorithm is broken. I don't get it. Can you help me get the working PIN?
NOTE: The correct PIN for this challenge is the flag.
Files
dist/pin
Solution
The player is provided a binary file containing a PIN verification algorithm.
The PIN verification algorithm provided by the binary is derived from the Wifi Protected Setup PIN
verification algorithm.
The source code for the algorithm is provided below:
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <unistd.h>
while (1) {
// Sleep for 100 ms
usleep(100000);
if (user_check != calc_check)
{
printf("2");
fflush(stdout);
continue;
}
PIN2 = None
for guess in itertools.product(string.digits, repeat=3):
num = int("".join(guess))
if num <= 99:
continue
Flags
58327296
flag{58327296}