Archive for the ‘Cpp’ Category
Setup and Use GCC on Windows in 5 Easy Steps
Do you want to be able to compile C, C++, Ada and Fortran programs on Windows without losing time wrestling with a bulk, resource-intensive IDE? You can! The solution is to port the ultra-popular, lightweight GCC (GNU Compiler Collection) often used in *nix systems to Windows via MinGW + Cygwin.
MinGW is the minimalist GNU implementation for Windows.
1. Install Cygwin, which provides many Linux commands/libraries to Windows
3. Make sure that MinGW was added to your PATH by typing PATH in a terminal
If not, you can add it through Window’s GUI interface (just type PATH or Environment in Start on Win 7 or 8 and it will come right up as a search result).
4. In a terminal (cmd or PowerShell) go to the directory containing the code you want to compile, i.e.
5. Type the compile command:
g++ hackr.c -o hackr.exe
where -o is indicating your output file.
This also works with compiling multiple files:
g++ hackr.c econometrics.c hadoop.c overflow.c -o hackeconometrics.exe
This should take at least an hour or 2 less time than installing Microsoft’s Visual Studio (though the latter has it’s virtues) or a similar bulky IDE and will give you fewer headaches by avoiding complicating your life with a million unnecessary options and confusing attempts to “help” you build a simple project.

Software Sec: C / C++ Buffer overflows and Robert Morris
- over-read or over-write
- could be during iteration (running off the end), or direct access (pointer arithmetic)
- this is a general definition; some people use more specific definitions of differing types of buffer overflows
A buffer overflow is a bug that affects low-level code, typically C and C++ with significant sec implications
- dump/steal information
- corrupt information
- run code (payload)
- OS Kernels
- embedded systems
- HPC servers
C: C v. C++, Object Orientation
C++ graphs object oriented programming* tools to the C language
C: When to use C v. C++
You pick C when
In all other cases you should pick C++.
Source: |