--- /dev/null
+#include <stdio.h>
+
+int main(void)
+{
+ char buf[20];
+ int ok = 0;
+ int i = 0;
+ for(i = 0; i < 20; i++)
+ buf[i] = 0;
+
+ printf("Please enter your password: ");
+ gets(buf);
+
+ if(hash_equal("\x75\x97\xf6\x8c\x1c\x45\xb1\x1a\xde\x48\xa8\xd0\xb3\xe1\xdb\x1c\xec\xbe\x2d", sha256(buf)))
+ printf("You're root!\n");
+ else
+ printf("Wrong password\n");
+ return 0;
+}
--- /dev/null
+You will get root by entiring a password of which the sha256 hash is:
+ 7597f68c1c45b11ade48a8d0b3e1db1cecbe2d
+
+However. There are several variables declared
+buf: array of 20 characters for holding our input
+ok: integer that stores to which function we jump
+i: integer used to loop through the buffer to clear it initially
+
+ok is allocated 28 bytes after buffer. When okay is non-falsey we will gain
+'root access' so putting any non-null byte there will make us gain root. So an
+input of 29 characters where the last characters is not null will give you
+root. For example:
+ 11111111111111111111111111111