all repos — site @ 979c690efb23876304962535456b60f1477946f9

source for my site, found at icyphox.sh

build/static/files/roplevel2.c (view raw)

 1#include <stdio.h>
 2#include <string.h>
 3#include <stdlib.h>
 4#include <unistd.h>
 5
 6void winner(){
 7    printf("Nothing interesting here...\n");
 8    system("# this does nothing...");
 9    exit(0);
10}
11
12void gadget(){
13    __asm__("pop {r0,pc}\n");
14}
15
16int main(){
17    char buff[16];
18    printf("Welcome to ROPLevel2 created by Billy Ellis (@bellis1000)\n");
19    printf("The objective of this level is to execute a shell command of your choice by using a ROP gadget followed by jumping to system()\n");
20    printf("Good luck: ");
21    scanf("%s",buff);
22    printf("Nice try ;)\n");
23    return 0;
24}
25