Introduction to C
C will be your bread and butter for developing your attacks. Yes, there are easier, more modern, less cumbersome languages, but the following is true:
- The abstraction level prevents you from understanding what is happening on the hardware.
- Most of your reversing targets will be C-based.
So, pony up, and learn the language that makes the hardware run!
This is really intended as a crash course that will just allow you to understand the code that comes with this book. There are plenty of resources on C on the internet if you want to dig deeper (and trust me, you will want to).
Operators
C comes with most of the operators you are expecting:
![](https://static.packt-cdn.com/products/9781789619133/graphics/image/B12280_05_Table_5.1.jpg)
You may already be familiar with the majority of the statements:
![](https://static.packt-cdn.com/products/9781789619133/graphics/image/B12280_05_Table_5.2.jpg)
The comments can come in two forms:
![](https://static.packt-cdn.com/products/9781789619133/graphics/image/B12280_05_Table_5.3.jpg)
Numeral bases as literals are also very straightforward:
![](https://static.packt-cdn.com/products/9781789619133/graphics/image/B12280_05_Table_5.4.jpg)
Types
Variables have a type. This is...