githubEdit

Kernel Exploits

gcc compiler fix

Error:

gcc: error trying to exec 'cc1': execvp: No such file or directory

Fix:

1) Search for cc1

find /usr -name cc1 2>/dev/null

Expected path

 /usr/lib/gcc/x86_64-linux-gnu/5/cc1

If cc1 exists but GCC can't find it

2) Set the correct library path

export GCC_EXEC_PREFIX=/usr/lib/gcc/

Error 2:

collect2: fatal error: cannot find 'ld'
compilation terminated.

Fix:

3) Check if ld binary exists

If the binary exists in an unexpected path that is not used by the system

4) Export PATH

Resources: ExploitDB: https://www.exploit-db.com/

LinuxCVEs: https://www.linuxkernelcves.com/

Github repository: https://github.com/SecWiki/linux-kernel-exploits/

Steps:

1: Identify kernel version with

2: Search and find kernel version exploit code

3: Run

PROTIP:

1: Be too specific about kernel version on Google,ExploitDB,searchsploit.

2: Be sure to understand the exploit BEFORE launch.

3: Some exploits need further interaction once run.

Last updated