Prepwork: Latex reporting.

So a little update for my preparations.

I try to get into the old hacker mode … Right now watching some episodes of mythbusters. That glee of destruction of exploration.

I started reading other persons blogs and found some of their old recon scrips etc.

To be honest I don’t like the idea of scripting my basic recon.

A nmap OS-Discoveryscan is nothing I would run so often that making a script would save me much time (I mean nmap -arguments is not to hard to type).

You might know the xkcd comics:



But a place were automation helps me: Latex …

My report setup is right now:

OSCP Mainfolder (aka workingfolder)

→Report Subfolder


→Subfolder for each host (Folder Names 1 till n)

→Screenshots (in each host subfolder)

My reportfile sits in the Report Subfolder. Each Server etc gets its own folder were I document all my findings in a *.tex template. Host 1 gets folder 1 with host1.tex. Simple.

A Script in my report pulls the “hostreports” into the report.

Sample code would be :

\foreach \c in {1,…,2}{\input{\c/host\c.tex} }

That pulls the file 1/host1.tex into the report. I just have to set the number of the host I found and need to report on.

Inside the Hosttemplate I now have the “reporting template from OS” .. well also the screenshots are imported automatically.

Sample code:

\foreach \x in {1,….,13}

(minimal image import, will do it a little bit more flashy)

You know each screenshot takes 5 seconds to import into Office. Then maybe 5 second to resize. This makes 10 seconds per screenshot. 10 seconds x number required screenshots x number hosts = worth the time.

Caveats right now:

-I have to set the number of reports

-I have to set the folder in each host*.tex for the graphics. So the number of screenshots and the foldernr.

After all not to bad for the first time using a complicated latex multi part document. Right now I’m thinking about using the subfile packet (which would allow easier writing) or not .. well we will see.

Greetings Ucki

Kommentar verfassen

Trage deine Daten unten ein oder klicke ein Icon um dich einzuloggen:

Du kommentierst mit Deinem Abmelden /  Ändern )


Du kommentierst mit Deinem Twitter-Konto. Abmelden /  Ändern )


Du kommentierst mit Deinem Facebook-Konto. Abmelden /  Ändern )

Verbinde mit %s

%d Bloggern gefällt das: