Codsmp.zip
$ python3 secret.py Decrypted to payload_decrypted.bin Inspect the result:
workdir/ ├─ README.txt ├─ payload.bin ├─ secret.py └─ archive.enc 2.1 README.txt Welcome to the CODSMP challenge! codsmp.zip
def main(zip_path='codsmp.zip'): work = Path('work') work.mkdir(exist_ok=True) # ----------------------------------------------------------------- # 1. Unzip the original archive subprocess.run(['unzip', '-q', zip_path, '-d', str(work)], check=True) $ python3 secret
# Grab any flag inside the inner archive for f in inner_dir.rglob('*'): if f.is_file(): data = f.read_bytes() flag = extract_flag(data) if flag: print(f'[inner] Flag in f.relative_to(work): flag') [rip+0xb] # 1152 <
0x00001140 <main+40>: 1140: 48 8d 3d 0b 00 00 00 lea rdi,[rip+0xb] # 1152 <main+52> 1147: e8 34 ff ff ff call 1080 <puts@plt> 114c: b8 00 00 00 00 mov eax,0x0 1151: c3 ret