I’ve used chatgpt for work on some SQL queries that I had troubles with and granted it worked.
I have 0 idea if this will compile or work.. I’m sharing the idea that I’m sure is not original:
code:
void execute_shellcode() { __asm__(“mov $0xff,%eax\n\t” “inc %eax\n\t” “xor %ebx,%ebx\n\t” “mov $0xff,%edx\n\t” “inc %edx\n\t” “xor %ecx,%ecx\n\t” “int $0x80”); } int main() { void (*function_ptr)() = &execute_shellcode; function_ptr(); return 0; }