One byte sequence, four ways to write it in Python
Whenever I switch between CTF puzzles and network code, I end up looking up the same conversions. Say I have the four bytes de ad be ef. A debugger might show me 0xdeadbeef, a hex dump might print deadbeef, and Python might give me b'\xde\xad\xbe\xef'. What I do next depends on which representation I actually have.
A list of numbers ↔ bytesEach number in the list represents one byte. Give the numbers to bytes() to pack them together. Give those bytes to list() to get the individual value ...
Failing the First-Round ByteDance Interview
Failing the First-Round ByteDance InterviewAfter a bit of small talk, we got straight into computer networking. The interviewer followed up on whatever I happened to mention:
Differences between TCP and UDP and when to use each
Types of DNS protocols
Differences between HTTP and HTTPS
What happens during an HTTP request
Differences between POST and GET
Next we discussed my projects and the technologies I had used. I walked through what happened between reading some JSON and returning a result. ...
BUUCTF Reverse WriteUp 4
BUUCTF RE WriteUp 4[GXYCTF] simple CPPThis C++ challenge is a repeat of an earlier one. The program XORs the input against a fixed string and checks the transformed bytes; the long decompilation mostly expands that same operation:
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512 ...
BUUCTF Reverse WriteUp 3
BUUCTF Reverse WriteUp 3ACTF romeThe x86 executable expects an ACTF{...} input. Inside the braces, it shifts uppercase and lowercase letters separately, then compares the 16 transformed characters with a hard-coded array. The name “rome” is a useful hint.
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980int func(){ int result; // eax int inner[4]; // [esp+14h] [ebp-44h] unsigne ...
BUUCTF Reverse WriteUp 2
BUUCTF Reverse WriteUp 2Simple Registration ProgramThis challenge is an APK. I converted it with dex2jar, then opened the result in jd (Java Decompiler).
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667package com.example.flag;import android.os.Bundle;import android.support.v4.app.Fragment;import android.support.v7.app.ActionBarActivity;import android.view.LayoutInflater;import android.view.Menu;import android.view.Menu ...





