ASCII case bit twiddling

If you pay a special sort of attention, you may notice that the upper-case and lower-case alphabet characters on the ASCII table are always exactly offset from each other by 32. For example, upper-case A is 65, while the lowercase a is 97 As such the way the binary place value works out, you can manipulate the case of a character by setting or clearing the sixth bit… (2^5 = 32, we start counting bits and everything at 0, we’re programmers!) Decimal 32 expressed as hexadecimal is 0x20 and expressed as binary is 00100000 ...

December 10, 2024 · 4 min

Guess the number...

A quick demonstration of how one can use a debugger to interactively inspect variables in a running program… ...

April 5, 2024 · 2 min

Patching Binaries

Exercise Summary The idea of this self-inflicted exercise was to see if I could inspect and patch a binary to change the outcome of some conditional code. In days of long past up I had found tutorials on how to patch a binary to bypass copyright protection schemes. The type that would ask a random question, where the answer found in a manual. You know, the one you would have had if the game wasn’t recieved on bootleg floppy diskettes. ...

March 13, 2021 · 4 min