How I Got Root Access via Lua Exploit
Transcript
Machine-transcribed by YouTube. Expect errors in names, commands and version numbers.
In particular, the output and write functions can be used in conjunction to achieve an arbitrary file write exploit. Let's break this down a bit. I io.output specifies where a write operation takes place. By default, io.righthello will write hello to the terminal or std out. However, we can change the location by supplying IO output with a file name. If the file does not exist, this file will be created and all subsequent calls to write will be written to the corresponding file. This bypasses the need for us to use the other blacklisted IO functions related to reading and writing files.





