1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
|
% Options for packages loaded elsewhere
\PassOptionsToPackage{unicode$for(hyperrefoptions)$,$hyperrefoptions$$endfor$}{hyperref}
\PassOptionsToPackage{hyphens}{url}
\PassOptionsToPackage{dvipsnames,svgnames,x11names}{xcolor}
\documentclass[a4paper,12pt]{article}
% Material color palette
\usepackage{xcolor}
% https://www.materialpalette.com/orange/deep-purple
\definecolor{DarkPrimaryColor}{HTML}{F57C00} % #F57C00
\definecolor{AccentColor}{HTML}{7C4DFF} % #7C4DFF
\definecolor{LightPrimaryColor}{HTML}{FFE0B2} % #FFE0B2
\definecolor{PrimaryText}{HTML}{212121} % #212121
\definecolor{PrimaryColor}{HTML}{FF9800} % #FF9800
\definecolor{SecondaryText}{HTML}{757575} % #757575
\definecolor{Text}{HTML}{212121} % #212121
\definecolor{Divider}{HTML}{BDBDBD} % #BDBDBD
\usepackage{fontawesome5}
\usepackage[hmargin={2cm,2cm},vmargin={4cm,3cm},headsep=2cm]{geometry}
\usepackage[page,toc]{appendix} % Properly display appendices in TOC
\usepackage{tcolorbox}
\newtcolorbox{info-box}{colback=cyan!5!white,arc=0pt,outer arc=0pt,colframe=cyan!60!black}
\newtcolorbox{warning-box}{colback=orange!5!white,arc=0pt,outer arc=0pt,colframe=orange!80!black}
\newtcolorbox{error-box}{colback=red!5!white,arc=0pt,outer arc=0pt,colframe=red!75!black}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage{amssymb,amsmath}
\usepackage{ifxetex,ifluatex}
\usepackage{fixltx2e} % provides \textsubscript
% use microtype if available
\IfFileExists{microtype.sty}{\usepackage{microtype}}{}
% use upquote if available, for straight quotes in verbatim environments
\IfFileExists{upquote.sty}{\usepackage{upquote}}{}
\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex
\usepackage[utf8]{inputenc}
\usepackage{ucs}
$if(euro)$
\usepackage{eurosym}
$endif$
\else % if luatex or xelatex
\usepackage{fontspec}
\ifxetex
\usepackage{xltxtra,xunicode}
\fi
\defaultfontfeatures{Mapping=tex-text,Scale=MatchLowercase}
\setromanfont{Roboto}
\newcommand{\euro}{€}
$if(mainfont)$
\setmainfont{$mainfont$}
$endif$
$if(sansfont)$
\setsansfont{$sansfont$}
$endif$
$if(monofont)$
\setmonofont{$monofont$}
$endif$
$if(mathfont)$
\setmathfont{$mathfont$}
$endif$
\fi
\usepackage{textcomp}
\usepackage{lastpage}
$if(zero-width-non-joiner)$
%% Support for zero-width non-joiner characters.
\makeatletter
\def\zerowidthnonjoiner{
% Prevent ligatures and adjust kerning, but still support hyphenating.
\texorpdfstring{
\textormath{\nobreak\discretionary{-}{}{\kern.03em}
\ifvmode\else\nobreak\hskip\z@skip\fi}{}
}{}
}
\makeatother
\DeclareUnicodeCharacter{200C}{\zerowidthnonjoiner}
%% End of ZWNJ support
$endif$
% define inline code styling
\definecolor{bgcolor}{HTML}{BAC2DE}
\let\oldtexttt\texttt
\renewcommand{\texttt}[1]{
\colorbox{bgcolor}{\oldtexttt{#1}}
}
% Use upquote if available, for straight quotes in verbatim environments
\IfFileExists{upquote.sty}{\usepackage{upquote}}{}
\IfFileExists{microtype.sty}{% use microtype if available
\usepackage[$for(microtypeoptions)$$microtypeoptions$$sep$,$endfor$]{microtype}
\UseMicrotypeSet[protrusion]{basicmath} % disable protrusion for tt fonts
}{}
$if(indent)$
$else$
\makeatletter
\@ifundefined{KOMAClassName}{% if non-KOMA class
\IfFileExists{parskip.sty}{
\usepackage{parskip}
}{% else
\setlength{\parindent}{0pt}
\setlength{\parskip}{6pt plus 2pt minus 1pt}}
}{% if KOMA class
\KOMAoptions{parskip=half}}
\makeatother
$endif$
$if(verbatim-in-note)$
\usepackage{fancyvrb}
$endif$
$if(lhs)$
\lstnewenvironment{code}{\lstset{language=Haskell,basicstyle=\small\ttfamily}}{}
$endif$
$if(highlighting-macros)$
$highlighting-macros$
$endif$
$if(tables)$
\usepackage{longtable,booktabs,array}
$if(multirow)$
\usepackage{multirow}
$endif$
\usepackage{calc} % for calculating minipage widths
% Correct order of tables after \paragraph or \subparagraph
\usepackage{etoolbox}
\makeatletter
\patchcmd\longtable{\par}{\if@noskipsec\mbox{}\fi\par}{}{}
\makeatother
% Allow footnotes in longtable head/foot
\IfFileExists{footnotehyper.sty}{\usepackage{footnotehyper}}{\usepackage{footnote}}
\makesavenoteenv{longtable}
$endif$
$if(graphics)$
\usepackage[export]{adjustbox}
\usepackage{graphicx}
\makeatletter
\newsavebox\pandoc@box
\newcommand*\pandocbounded[1]{% scales image to fit in text height/width
\sbox\pandoc@box{#1}
\Gscale@div\@tempa{\textheight}{\dimexpr\ht\pandoc@box+\dp\pandoc@box\relax}
\Gscale@div\@tempb{\linewidth}{\wd\pandoc@box}
\ifdim\@tempb\p@<\@tempa\p@\let\@tempa\@tempb\fi% select the smaller of both
\ifdim\@tempa\p@<\p@\scalebox{\@tempa}{\usebox\pandoc@box}
\else\usebox{\pandoc@box}
\fi
}
\setkeys{Gin}{width=\textwidth}
%\def\maxwidth{\ifdim\Gin@nat@width>\linewidth\linewidth\else\Gin@nat@width\fi}
%\def\maxheight{\ifdim\Gin@nat@height>\textheight\textheight\else\Gin@nat@height\fi}
\makeatother
% Scale images if necessary, so that they will not overflow the page
% margins by default, and it is still possible to overwrite the defaults
% using explic$pagestyle$
$endif$
$if(links-as-notes)$
% Make links footnotes instead of hotlinks:
\DeclareRobustCommand{\href}[2]{#2\footnote{\url{#1}}}
$endif$
$if(strikeout)$
\usepackage[normalem]{ulem}
$endif$
\setlength{\emergencystretch}{3em} % prevent overfull lines
\providecommand{\tightlist}{
\setlength{\itemsep}{0pt}\setlength{\parskip}{0pt}}
$if(numbersections)$
\setcounter{secnumdepth}{$if(secnumdepth)$$secnumdepth$$else$5$endif$}
$else$
\setcounter{secnumdepth}{-\maxdimen} % remove section numbering
$endif$
$if(block-headings)$
% Make \paragraph and \subparagraph free-standing
\ifx\paragraph\undefined\else
\let\oldparagraph\paragraph
\renewcommand{\paragraph}[1]{\oldparagraph{#1}\mbox{}}
\fi
\ifx\subparagraph\undefined\else
\let\oldsubparagraph\subparagraph
\renewcommand{\subparagraph}[1]{\oldsubparagraph{#1}\mbox{}}
\fi
$endif$
$if(pagestyle)$
\pagestyle{$pagestyle$}
$else$
\usepackage{fancyhdr}
\pagestyle{fancy}
$endif$
$if(csl-refs)$
\newlength{\cslhangindent}
\setlength{\cslhangindent}{1.5em}
\newlength{\csllabelwidth}
\setlength{\csllabelwidth}{3em}
\newlength{\cslentryspacingunit} % times entry-spacing
\setlength{\cslentryspacingunit}{\parskip}
\newenvironment{CSLReferences}[2] % #1 hanging-ident, #2 entry spacing
{% don't indent paragraphs
\setlength{\parindent}{0pt}
% turn on hanging indent if param 1 is 1
\ifodd #1
\let\oldpar\par
\def\par{\hangindent=\cslhangindent\oldpar}
\fi
% set entry spacing
\setlength{\parskip}{#2\cslentryspacingunit}
}
{}
\usepackage{calc}
\newcommand{\CSLBlock}[1]{#1\hfill\break}
\newcommand{\CSLLeftMargin}[1]{\parbox[t]{\csllabelwidth}{#1}}
\newcommand{\CSLRightInline}[1]{\parbox[t]{\linewidth - \csllabelwidth}{#1}\break}
\newcommand{\CSLIndent}[1]{\hspace{\cslhangindent}#1}
$endif$
$if(lang)$
\usepackage[bidi=default]{babel}
$if(babel-lang)$
\babelprovide[main,import]{$babel-lang$}
$endif$
$for(babel-otherlangs)$
\babelprovide[import]{$babel-otherlangs$}
$endfor$
% get rid of language-specific shorthands (see #6817):
\let\LanguageShortHands\languageshorthands
\def\languageshorthands#1{}
$endif$
$for(header-includes)$
$header-includes$
$endfor$
$if(dir)$
\TeXXeTstate=1
\newcommand{\RL}[1]{\beginR #1\endR}
\newcommand{\LR}[1]{\beginL #1\endL}
\newenvironment{RTL}{\beginR}{\endR}
\newenvironment{LTR}{\beginL}{\endL}
$endif$
$if(natbib)$
\usepackage[$natbiboptions$]{natbib}
\bibliographystyle{$if(biblio-style)$$biblio-style$$else$plainnat$endif$}
$endif$
$if(nocite-ids)$
\nocite{$for(nocite-ids)$$it$$sep$, $endfor$}
$endif$
$if(csquotes)$
\usepackage{csquotes}
$endif$
\IfFileExists{bookmark.sty}{\usepackage{bookmark}}{\usepackage{hyperref}}
\IfFileExists{xurl.sty}{\usepackage{xurl}}{} % add URL line breaks if available
\urlstyle{same} % disable monospaced font for URLs
$if(verbatim-in-note)$
\VerbatimFootnotes % allow verbatim text in footnotes
$endif$
$if(startdate)$$else$ % get last monday date
\usepackage{datenumber,etoolbox}
\newbool{mondate}\ifnumcomp{\arabic{datedayname}}{=}{1}{\setbool{mondate}{true}}{\setbool{mondate}{false}}
\newcommand\lastmon{
\unlessboolexpr{bool {mondate} }{
\addtocounter{datenumber}{-1}
\setdatebynumber{\arabic{datenumber}}
\ifnumcomp{\arabic{datedayname}}{=}{1}{\setbool{mondate}{true}}{\setbool{mondate}{false}}
}
\datedate\setbool{mondate}{false}
}
$endif$
% ---------------------------------------------------------------------------------------------------------
% BEGIN OF VARIABLES
% ---------------------------------------------------------------------------------------------------------
\def\mytitle{$if(title)$$title$$else$Security Testing Report$endif$}
\def\myauthor{$if(author)$$author$$else$Danilo 'danix' Macrì$endif$}
\def\mydate{\today}
\def\defaultmail{danilo.macri@danix.me}
\def\myemail{\href{mailto:$if(email)$$email$}{$email$$else$\defaultmail}{\defaultmail$endif$}}
\def\client{$if(client)$$client$$else$Placeholder$endif$}
\def\activity{$if(activity)$$activity$$else$Placeholder$endif$}
\def\activitytype{$if(activity_type)$$activity_type$$else$Placeholder$endif$}
\def\startdate{$if(startdate)$$startdate$$else$\lastmon$endif$}
\def\engagetime{$if(engagetime)$$engagetime$$else$5$endif$}
\author{{\color{AccentColor} \textbf{\myauthor} - \textbf{\myemail}}}
\title{\vspace{-2cm}\Huge {\color{DarkPrimaryColor}\textbf{\mytitle}}\\{\color{PrimaryText}\textbf{\client} - \textbf{\activity}\\\textbf{\activitytype}}}
\date{{\color{PrimaryText}\textbf{\mydate}}}
\date{{\color{PrimaryText}\textbf{Scan started on \startdate}} - \color{PrimaryColor}\textbf{duration (days): \engagetime}}
% ---------------------------------------------------------------------------------------------------------
% END OF VARIABLES
% ---------------------------------------------------------------------------------------------------------
% ---------------------------------------------------------------------------------------------------------
% BEGIN OF LINK SETUP
% ---------------------------------------------------------------------------------------------------------
\hypersetup{
pdftitle={\mytitle},
pdfauthor={\myauthor},
pdfkeywords={\mytitle, \myauthor, \activity},
colorlinks=true,
linkcolor={AccentColor},
urlcolor={AccentColor},
}
% ---------------------------------------------------------------------------------------------------------
% END OF LINK SETUP
% ---------------------------------------------------------------------------------------------------------
% ---------------------------------------------------------------------------------------------------------
% BEGIN OF HEADER AND FOOTER SETUP
% ---------------------------------------------------------------------------------------------------------
\fancyhead{}
\lfoot{CLASSIFICATION: { \color{AccentColor}$if(classification)$\textbf{$classification$}$else$\textbf{CONFIDENTIAL}$endif$}}
\lhead{{\color{AccentColor} $if(callout)$$callout$$else$\faHouseUser\space \href{https://danix.xyz/}{danix.xyz} $endif$}}
\rfoot{\thepage\ / \pageref{LastPage}}
\cfoot{}
\rhead{{\color{AccentColor} \faEnvelopeOpen\space {{\myemail}}}}
\renewcommand{\footrulewidth}{0.4pt}\setlength{\headheight}{20pt}
% ---------------------------------------------------------------------------------------------------------
% END OF HEADER AND FOOTER SETUP
% ---------------------------------------------------------------------------------------------------------
\usepackage{fvextra}
\definecolor{bg}{HTML}{8E8E8E}
\DefineVerbatimEnvironment{Highlighting}{Verbatim}{
breaklines = true,
fontsize = \footnotesize,
frame = single,
rulecolor = bg,
commandchars = \\\{\},
}
\begin{document}
% ---------------------------------------------------------------------------------------------------------
% BEGIN OF TITLE PAGE
% ---------------------------------------------------------------------------------------------------------
{
\maketitle\thispagestyle{empty}
\hypersetup{pdfborder=0 0 0}\setcounter{page}{0}
}
% ---------------------------------------------------------------------------------------------------------
% END OF TITLE PAGE
% ---------------------------------------------------------------------------------------------------------
%-------------------------------------------------------------------------------------------------------
% BEGIN OF TABLE OF CONTENTS
%-------------------------------------------------------------------------------------------------------
\setcounter{tocdepth}{3}{\hypersetup{hidelinks}\tableofcontents}
\clearpage
%-------------------------------------------------------------------------------------------------------
% END OF TABLE OF CONTENTS
%-------------------------------------------------------------------------------------------------------
%-------------------------------------------------------------------------------------------------------
% BEGIN OF MAIN CONTENT
%-------------------------------------------------------------------------------------------------------
$body$
% Signature image
\begin{figure}[h!]
\includegraphics[width=0.6\textwidth]{/home/danix/Pictures/signature.png}
\end{figure}
%-------------------------------------------------------------------------------------------------------
% END OF MAIN CONTENT
%-------------------------------------------------------------------------------------------------------
%-------------------------------------------------------------------------------------------------------
% BEGIN OF LEGAL
%-------------------------------------------------------------------------------------------------------
$if(legal)$
\pagebreak
\begin{appendices}
\section{Document Legal Data}
\subsection*{Proprietary \& Legal Notice}
This document is the property of {\myauthor}; the contents herein are the intellectual property
and copyright of {\myauthor}. Disclosure of this document and its contents herein does not
grant or construe any transfer or other rights in relation to {\myauthor} intellectual property.
\subsection*{Classification}
This document and information included must be considered "CONFIDENTIAL" between {\myauthor} and
{\client} and cannot be shared to any Third Party, neither copied in any format, without previous
agreement with {\myauthor}.
\subsection*{Disclaimer}
{\myauthor} expressly disclaims any liability, which may arise in any manner and to any party through
publication of this document. Any party acting for or failing to act because of this document
assumes full responsibility for any use made of the information contained herein. This publication
does not constitute an endorsement of the product or products described.
\subsection*{Copyright}
All trademarks or registered trademarks either mentioned or implied are respected. \newline
{\client} and {\myauthor}. All Rights Reserved.
\end{appendices}
\pagebreak
$endif$ % legal
%-------------------------------------------------------------------------------------------------------
% END OF LEGAL
%-------------------------------------------------------------------------------------------------------
\clearpage\end{document}
|