Find the Easy Pass

NameFind the Easy Pass
HintFind the password (say PASS) and enter the flag in the form HTB{PASS}
Base PointsEasy - Retired [0]
Rated DifficultyFind the Easy Pass rated difficulty chart
First bloodalamot alamot avatar
CreatorThiseas Thiseas avatar

We start this one out with an EXE file. Running file on it shows that it is a PE32 executable for Windows. When we try to execute it, we are asked for a password. I am starting to really like Ghidra, so let's crack it open in there. This is a lot of code for an easy challenge. We need to find the function that is called when the Check Password button is clicked. We can follow the progression in the Function Graph window of Ghidra.

Ghidra function graph for the Find the Easy Pass executable
Reviewing the executable in Ghidra.

We are looking for anything button-click related. In Defined Strings, I look for the “Wrong Password” popup.

Wrong Password string located in Ghidra
Locating the password validation path through the failure message.

Now that we know the password-check function, we can look for it in the Function Graph. What we find is a function call to FUN_00454138 that displays the success message. The next question is which part of the check function calls it.

Ghidra graph showing the success function call
Tracing the successful password branch.

Digging further shows the location is LAB_00454144. Examining the function immediately before it, FUN_00404628, lets us determine what EDX is pointing to. I set a breakpoint at LAB_00454131, the address of FUN_00404628.

Ghidra did not have a debugger at the time of this writing, so I switched to x64dbg for the remainder. Once the breakpoint is set, run the program and click the Check Password button. EDX holds the flag.

HTB{fortran!}
x64dbg showing the recovered fortran password
The password visible in EDX at the breakpoint.