> For the complete documentation index, see [llms.txt](https://cybermuhdupa.gitbook.io/ctfme/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://cybermuhdupa.gitbook.io/ctfme/fundamentals/basic.md).

# Basic

Basic things beginner need to master

<img src="https://1159495136-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FTZiHQQ8h7iHu75ZzpL3Q%2Fuploads%2FXbl0dv4KZJD9HtDx8Brf%2Fimage.png?alt=media&amp;token=605ff0d1-6658-451c-9e56-698485b01797" alt="" data-size="original">

* When CTF organizer give you a binary (download file), always run command `file [filename]` on the binary.&#x20;
  * File command will **determine what type of file** are you've downloaded. They will check the magic number or file signature in the binary header.&#x20;
  * Learn more about file signature at [here](https://en.wikipedia.org/wiki/List_of_file_signatures).&#x20;
  * Some of challenge's creator will confuse you up when they change or remove the extension of a binary. Example, the actual binary is `binary.jpg` but they changed it to `binary.exe`. So, the ctf player will thought that it's a `executable` file instead of `image/jpeg` file.
* Run `strings -a [filename]` to **extracts strings** in the given binary. Some clues or artifacts can be found in the `strings` output.
* ***Base64*** is the common encoding used in CTF. Learn about it's characteristics and how to decode it. Some online tools that can help you is this [site](https://www.base64decode.org/). But, the better approach is to decode encoded strings using Linux's terminal. It's because some base64 encoded may a binary file. So, if it's a binary file, online tool like in the link can't provide the decoded binary file. It only can decode strings but not binary file.&#x20;
  * Example of Linux command for base64 is like this `echo "[strings of the base64]" | base64 -d`.
* Learn about **number encoding**. *Hexadecimal*, *binary*, *decimal* and also *ASCII*.&#x20;
  * You can use this [website](https://www.rapidtables.com/convert/number/ascii-hex-bin-dec-converter.html) to convert your strings to each other.&#x20;
