Debian Codegraph @

docs/index.html

raw ◀ ▶
1 Debian patch touch this file
1 <!DOCTYPE html>
2 <html lang="en">
3 <head>
4 <meta charset="UTF-8">
5 <meta http-equiv="X-UA-Compatible" content="IE=edge">
6 <meta name="viewport" content="width=device-width, initial-scale=1.0">
7 <meta name="generator" content="Asciidoctor 2.0.23">
8 <meta name="keywords" content="antivirus, clamav, fangfrisch, freshclam, refresh, update">
9 <meta name="author" content="Ralph Seichter">
10 <meta name="copyright" content="© 2020-2025 Ralph Seichter">
11 <title>Fangfrisch</title>
12 <style>
13 /*! Asciidoctor default stylesheet | MIT License | https://asciidoctor.org */
14 /* Uncomment the following line when using as a custom stylesheet */
15 /* @import "https://fonts.googleapis.com/css?family=Open+Sans:300,300italic,400,400italic,600,600italic%7CNoto+Serif:400,400italic,700,700italic%7CDroid+Sans+Mono:400,700"; */
16 html{font-family:sans-serif;-webkit-text-size-adjust:100%}
17 a{background:none}
18 a:focus{outline:thin dotted}
19 a:active,a:hover{outline:0}
20 h1{font-size:2em;margin:.67em 0}
21 b,strong{font-weight:bold}
22 abbr{font-size:.9em}
23 abbr[title]{cursor:help;border-bottom:1px dotted #dddddf;text-decoration:none}
24 dfn{font-style:italic}
25 hr{height:0}
26 mark{background:#ff0;color:#000}
27 code,kbd,pre,samp{font-family:monospace;font-size:1em}
28 pre{white-space:pre-wrap}
29 q{quotes:"\201C" "\201D" "\2018" "\2019"}
30 small{font-size:80%}
31 sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}
32 sup{top:-.5em}
33 sub{bottom:-.25em}
34 img{border:0}
35 svg:not(:root){overflow:hidden}
36 figure{margin:0}
37 audio,video{display:inline-block}
38 audio:not([controls]){display:none;height:0}
39 fieldset{border:1px solid silver;margin:0 2px;padding:.35em .625em .75em}
40 legend{border:0;padding:0}
41 button,input,select,textarea{font-family:inherit;font-size:100%;margin:0}
42 button,input{line-height:normal}
43 button,select{text-transform:none}
44 button,html input[type=button],input[type=reset],input[type=submit]{-webkit-appearance:button;cursor:pointer}
45 button[disabled],html input[disabled]{cursor:default}
46 input[type=checkbox],input[type=radio]{padding:0}
47 button::-moz-focus-inner,input::-moz-focus-inner{border:0;padding:0}
48 textarea{overflow:auto;vertical-align:top}
49 table{border-collapse:collapse;border-spacing:0}
50 *,::before,::after{box-sizing:border-box}
51 html,body{font-size:100%}
52 body{background:#fff;color:rgba(0,0,0,.8);padding:0;margin:0;font-family:"Noto Serif","DejaVu Serif",serif;line-height:1;position:relative;cursor:auto;-moz-tab-size:4;-o-tab-size:4;tab-size:4;word-wrap:anywhere;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased}
53 a:hover{cursor:pointer}
54 img,object,embed{max-width:100%;height:auto}
55 object,embed{height:100%}
56 img{-ms-interpolation-mode:bicubic}
57 .left{float:left!important}
58 .right{float:right!important}
59 .text-left{text-align:left!important}
60 .text-right{text-align:right!important}
61 .text-center{text-align:center!important}
62 .text-justify{text-align:justify!important}
63 .hide{display:none}
64 img,object,svg{display:inline-block;vertical-align:middle}
65 textarea{height:auto;min-height:50px}
66 select{width:100%}
67 .subheader,.admonitionblock td.content>.title,.audioblock>.title,.exampleblock>.title,.imageblock>.title,.listingblock>.title,.literalblock>.title,.stemblock>.title,.openblock>.title,.paragraph>.title,.quoteblock>.title,table.tableblock>.title,.verseblock>.title,.videoblock>.title,.dlist>.title,.olist>.title,.ulist>.title,.qlist>.title,.hdlist>.title{line-height:1.45;color:#7a2518;font-weight:400;margin-top:0;margin-bottom:.25em}
68 div,dl,dt,dd,ul,ol,li,h1,h2,h3,#toctitle,.sidebarblock>.content>.title,h4,h5,h6,pre,form,p,blockquote,th,td{margin:0;padding:0}
69 a{color:#2156a5;text-decoration:underline;line-height:inherit}
70 a:hover,a:focus{color:#1d4b8f}
71 a img{border:0}
72 p{line-height:1.6;margin-bottom:1.25em;text-rendering:optimizeLegibility}
73 p aside{font-size:.875em;line-height:1.35;font-style:italic}
74 h1,h2,h3,#toctitle,.sidebarblock>.content>.title,h4,h5,h6{font-family:"Open Sans","DejaVu Sans",sans-serif;font-weight:300;font-style:normal;color:#ba3925;text-rendering:optimizeLegibility;margin-top:1em;margin-bottom:.5em;line-height:1.0125em}
75 h1 small,h2 small,h3 small,#toctitle small,.sidebarblock>.content>.title small,h4 small,h5 small,h6 small{font-size:60%;color:#e99b8f;line-height:0}
76 h1{font-size:2.125em}
77 h2{font-size:1.6875em}
78 h3,#toctitle,.sidebarblock>.content>.title{font-size:1.375em}
79 h4,h5{font-size:1.125em}
80 h6{font-size:1em}
81 hr{border:solid #dddddf;border-width:1px 0 0;clear:both;margin:1.25em 0 1.1875em}
82 em,i{font-style:italic;line-height:inherit}
83 strong,b{font-weight:bold;line-height:inherit}
84 small{font-size:60%;line-height:inherit}
85 code{font-family:"Droid Sans Mono","DejaVu Sans Mono",monospace;font-weight:400;color:rgba(0,0,0,.9)}
86 ul,ol,dl{line-height:1.6;margin-bottom:1.25em;list-style-position:outside;font-family:inherit}
87 ul,ol{margin-left:1.5em}
88 ul li ul,ul li ol{margin-left:1.25em;margin-bottom:0}
89 ul.circle{list-style-type:circle}
90 ul.disc{list-style-type:disc}
91 ul.square{list-style-type:square}
92 ul.circle ul:not([class]),ul.disc ul:not([class]),ul.square ul:not([class]){list-style:inherit}
93 ol li ul,ol li ol{margin-left:1.25em;margin-bottom:0}
94 dl dt{margin-bottom:.3125em;font-weight:bold}
95 dl dd{margin-bottom:1.25em}
96 blockquote{margin:0 0 1.25em;padding:.5625em 1.25em 0 1.1875em;border-left:1px solid #ddd}
97 blockquote,blockquote p{line-height:1.6;color:rgba(0,0,0,.85)}
98 @media screen and (min-width:768px){h1,h2,h3,#toctitle,.sidebarblock>.content>.title,h4,h5,h6{line-height:1.2}
99 h1{font-size:2.75em}
100 h2{font-size:2.3125em}
101 h3,#toctitle,.sidebarblock>.content>.title{font-size:1.6875em}
102 h4{font-size:1.4375em}}
103 table{background:#fff;margin-bottom:1.25em;border:1px solid #dedede;word-wrap:normal}
104 table thead,table tfoot{background:#f7f8f7}
105 table thead tr th,table thead tr td,table tfoot tr th,table tfoot tr td{padding:.5em .625em .625em;font-size:inherit;color:rgba(0,0,0,.8);text-align:left}
106 table tr th,table tr td{padding:.5625em .625em;font-size:inherit;color:rgba(0,0,0,.8)}
107 table tr.even,table tr.alt{background:#f8f8f7}
108 table thead tr th,table tfoot tr th,table tbody tr td,table tr td,table tfoot tr td{line-height:1.6}
109 h1,h2,h3,#toctitle,.sidebarblock>.content>.title,h4,h5,h6{line-height:1.2;word-spacing:-.05em}
110 h1 strong,h2 strong,h3 strong,#toctitle strong,.sidebarblock>.content>.title strong,h4 strong,h5 strong,h6 strong{font-weight:400}
111 .center{margin-left:auto;margin-right:auto}
112 .stretch{width:100%}
113 .clearfix::before,.clearfix::after,.float-group::before,.float-group::after{content:" ";display:table}
114 .clearfix::after,.float-group::after{clear:both}
115 :not(pre).nobreak{word-wrap:normal}
116 :not(pre).nowrap{white-space:nowrap}
117 :not(pre).pre-wrap{white-space:pre-wrap}
118 :not(pre):not([class^=L])>code{font-size:.9375em;font-style:normal!important;letter-spacing:0;padding:.1em .5ex;word-spacing:-.15em;background:#f7f7f8;border-radius:4px;line-height:1.45;text-rendering:optimizeSpeed}
119 pre{color:rgba(0,0,0,.9);font-family:"Droid Sans Mono","DejaVu Sans Mono",monospace;line-height:1.45;text-rendering:optimizeSpeed}
120 pre code,pre pre{color:inherit;font-size:inherit;line-height:inherit}
121 pre>code{display:block}
122 pre.nowrap,pre.nowrap pre{white-space:pre;word-wrap:normal}
123 em em{font-style:normal}
124 strong strong{font-weight:400}
125 .keyseq{color:rgba(51,51,51,.8)}
126 kbd{font-family:"Droid Sans Mono","DejaVu Sans Mono",monospace;display:inline-block;color:rgba(0,0,0,.8);font-size:.65em;line-height:1.45;background:#f7f7f7;border:1px solid #ccc;border-radius:3px;box-shadow:0 1px 0 rgba(0,0,0,.2),inset 0 0 0 .1em #fff;margin:0 .15em;padding:.2em .5em;vertical-align:middle;position:relative;top:-.1em;white-space:nowrap}
127 .keyseq kbd:first-child{margin-left:0}
128 .keyseq kbd:last-child{margin-right:0}
129 .menuseq,.menuref{color:#000}
130 .menuseq b:not(.caret),.menuref{font-weight:inherit}
131 .menuseq{word-spacing:-.02em}
132 .menuseq b.caret{font-size:1.25em;line-height:.8}
133 .menuseq i.caret{font-weight:bold;text-align:center;width:.45em}
134 b.button::before,b.button::after{position:relative;top:-1px;font-weight:400}
135 b.button::before{content:"[";padding:0 3px 0 2px}
136 b.button::after{content:"]";padding:0 2px 0 3px}
137 p a>code:hover{color:rgba(0,0,0,.9)}
138 #header,#content,#footnotes,#footer{width:100%;margin:0 auto;max-width:62.5em;*zoom:1;position:relative;padding-left:.9375em;padding-right:.9375em}
139 #header::before,#header::after,#content::before,#content::after,#footnotes::before,#footnotes::after,#footer::before,#footer::after{content:" ";display:table}
140 #header::after,#content::after,#footnotes::after,#footer::after{clear:both}
141 #content{margin-top:1.25em}
142 #content::before{content:none}
143 #header>h1:first-child{color:rgba(0,0,0,.85);margin-top:2.25rem;margin-bottom:0}
144 #header>h1:first-child+#toc{margin-top:8px;border-top:1px solid #dddddf}
145 #header>h1:only-child{border-bottom:1px solid #dddddf;padding-bottom:8px}
146 #header .details{border-bottom:1px solid #dddddf;line-height:1.45;padding-top:.25em;padding-bottom:.25em;padding-left:.25em;color:rgba(0,0,0,.6);display:flex;flex-flow:row wrap}
147 #header .details span:first-child{margin-left:-.125em}
148 #header .details span.email a{color:rgba(0,0,0,.85)}
149 #header .details br{display:none}
150 #header .details br+span::before{content:"\00a0\2013\00a0"}
151 #header .details br+span.author::before{content:"\00a0\22c5\00a0";color:rgba(0,0,0,.85)}
152 #header .details br+span#revremark::before{content:"\00a0|\00a0"}
153 #header #revnumber{text-transform:capitalize}
154 #header #revnumber::after{content:"\00a0"}
155 #content>h1:first-child:not([class]){color:rgba(0,0,0,.85);border-bottom:1px solid #dddddf;padding-bottom:8px;margin-top:0;padding-top:1rem;margin-bottom:1.25rem}
156 #toc{border-bottom:1px solid #e7e7e9;padding-bottom:.5em}
157 #toc>ul{margin-left:.125em}
158 #toc ul.sectlevel0>li>a{font-style:italic}
159 #toc ul.sectlevel0 ul.sectlevel1{margin:.5em 0}
160 #toc ul{font-family:"Open Sans","DejaVu Sans",sans-serif;list-style-type:none}
161 #toc li{line-height:1.3334;margin-top:.3334em}
162 #toc a{text-decoration:none}
163 #toc a:active{text-decoration:underline}
164 #toctitle{color:#7a2518;font-size:1.2em}
165 @media screen and (min-width:768px){#toctitle{font-size:1.375em}
166 body.toc2{padding-left:15em;padding-right:0}
167 body.toc2 #header>h1:nth-last-child(2){border-bottom:1px solid #dddddf;padding-bottom:8px}
168 #toc.toc2{margin-top:0!important;background:#f8f8f7;position:fixed;width:15em;left:0;top:0;border-right:1px solid #e7e7e9;border-top-width:0!important;border-bottom-width:0!important;z-index:1000;padding:1.25em 1em;height:100%;overflow:auto}
169 #toc.toc2 #toctitle{margin-top:0;margin-bottom:.8rem;font-size:1.2em}
170 #toc.toc2>ul{font-size:.9em;margin-bottom:0}
171 #toc.toc2 ul ul{margin-left:0;padding-left:1em}
172 #toc.toc2 ul.sectlevel0 ul.sectlevel1{padding-left:0;margin-top:.5em;margin-bottom:.5em}
173 body.toc2.toc-right{padding-left:0;padding-right:15em}
174 body.toc2.toc-right #toc.toc2{border-right-width:0;border-left:1px solid #e7e7e9;left:auto;right:0}}
175 @media screen and (min-width:1280px){body.toc2{padding-left:20em;padding-right:0}
176 #toc.toc2{width:20em}
177 #toc.toc2 #toctitle{font-size:1.375em}
178 #toc.toc2>ul{font-size:.95em}
179 #toc.toc2 ul ul{padding-left:1.25em}
180 body.toc2.toc-right{padding-left:0;padding-right:20em}}
181 #content #toc{border:1px solid #e0e0dc;margin-bottom:1.25em;padding:1.25em;background:#f8f8f7;border-radius:4px}
182 #content #toc>:first-child{margin-top:0}
183 #content #toc>:last-child{margin-bottom:0}
184 #footer{max-width:none;background:rgba(0,0,0,.8);padding:1.25em}
185 #footer-text{color:hsla(0,0%,100%,.8);line-height:1.44}
186 #content{margin-bottom:.625em}
187 .sect1{padding-bottom:.625em}
188 @media screen and (min-width:768px){#content{margin-bottom:1.25em}
189 .sect1{padding-bottom:1.25em}}
190 .sect1:last-child{padding-bottom:0}
191 .sect1+.sect1{border-top:1px solid #e7e7e9}
192 #content h1>a.anchor,h2>a.anchor,h3>a.anchor,#toctitle>a.anchor,.sidebarblock>.content>.title>a.anchor,h4>a.anchor,h5>a.anchor,h6>a.anchor{position:absolute;z-index:1001;width:1.5ex;margin-left:-1.5ex;display:block;text-decoration:none!important;visibility:hidden;text-align:center;font-weight:400}
193 #content h1>a.anchor::before,h2>a.anchor::before,h3>a.anchor::before,#toctitle>a.anchor::before,.sidebarblock>.content>.title>a.anchor::before,h4>a.anchor::before,h5>a.anchor::before,h6>a.anchor::before{content:"\00A7";font-size:.85em;display:block;padding-top:.1em}
194 #content h1:hover>a.anchor,#content h1>a.anchor:hover,h2:hover>a.anchor,h2>a.anchor:hover,h3:hover>a.anchor,#toctitle:hover>a.anchor,.sidebarblock>.content>.title:hover>a.anchor,h3>a.anchor:hover,#toctitle>a.anchor:hover,.sidebarblock>.content>.title>a.anchor:hover,h4:hover>a.anchor,h4>a.anchor:hover,h5:hover>a.anchor,h5>a.anchor:hover,h6:hover>a.anchor,h6>a.anchor:hover{visibility:visible}
195 #content h1>a.link,h2>a.link,h3>a.link,#toctitle>a.link,.sidebarblock>.content>.title>a.link,h4>a.link,h5>a.link,h6>a.link{color:#ba3925;text-decoration:none}
196 #content h1>a.link:hover,h2>a.link:hover,h3>a.link:hover,#toctitle>a.link:hover,.sidebarblock>.content>.title>a.link:hover,h4>a.link:hover,h5>a.link:hover,h6>a.link:hover{color:#a53221}
197 details,.audioblock,.imageblock,.literalblock,.listingblock,.stemblock,.videoblock{margin-bottom:1.25em}
198 details{margin-left:1.25rem}
199 details>summary{cursor:pointer;display:block;position:relative;line-height:1.6;margin-bottom:.625rem;outline:none;-webkit-tap-highlight-color:transparent}
200 details>summary::-webkit-details-marker{display:none}
201 details>summary::before{content:"";border:solid transparent;border-left:solid;border-width:.3em 0 .3em .5em;position:absolute;top:.5em;left:-1.25rem;transform:translateX(15%)}
202 details[open]>summary::before{border:solid transparent;border-top:solid;border-width:.5em .3em 0;transform:translateY(15%)}
203 details>summary::after{content:"";width:1.25rem;height:1em;position:absolute;top:.3em;left:-1.25rem}
204 .admonitionblock td.content>.title,.audioblock>.title,.exampleblock>.title,.imageblock>.title,.listingblock>.title,.literalblock>.title,.stemblock>.title,.openblock>.title,.paragraph>.title,.quoteblock>.title,table.tableblock>.title,.verseblock>.title,.videoblock>.title,.dlist>.title,.olist>.title,.ulist>.title,.qlist>.title,.hdlist>.title{text-rendering:optimizeLegibility;text-align:left;font-family:"Noto Serif","DejaVu Serif",serif;font-size:1rem;font-style:italic}
205 table.tableblock.fit-content>caption.title{white-space:nowrap;width:0}
206 .paragraph.lead>p,#preamble>.sectionbody>[class=paragraph]:first-of-type p{font-size:1.21875em;line-height:1.6;color:rgba(0,0,0,.85)}
207 .admonitionblock>table{border-collapse:separate;border:0;background:none;width:100%}
208 .admonitionblock>table td.icon{text-align:center;width:80px}
209 .admonitionblock>table td.icon img{max-width:none}
210 .admonitionblock>table td.icon .title{font-weight:bold;font-family:"Open Sans","DejaVu Sans",sans-serif;text-transform:uppercase}
211 .admonitionblock>table td.content{padding-left:1.125em;padding-right:1.25em;border-left:1px solid #dddddf;color:rgba(0,0,0,.6);word-wrap:anywhere}
212 .admonitionblock>table td.content>:last-child>:last-child{margin-bottom:0}
213 .exampleblock>.content{border:1px solid #e6e6e6;margin-bottom:1.25em;padding:1.25em;background:#fff;border-radius:4px}
214 .sidebarblock{border:1px solid #dbdbd6;margin-bottom:1.25em;padding:1.25em;background:#f3f3f2;border-radius:4px}
215 .sidebarblock>.content>.title{color:#7a2518;margin-top:0;text-align:center}
216 .exampleblock>.content>:first-child,.sidebarblock>.content>:first-child{margin-top:0}
217 .exampleblock>.content>:last-child,.exampleblock>.content>:last-child>:last-child,.exampleblock>.content .olist>ol>li:last-child>:last-child,.exampleblock>.content .ulist>ul>li:last-child>:last-child,.exampleblock>.content .qlist>ol>li:last-child>:last-child,.sidebarblock>.content>:last-child,.sidebarblock>.content>:last-child>:last-child,.sidebarblock>.content .olist>ol>li:last-child>:last-child,.sidebarblock>.content .ulist>ul>li:last-child>:last-child,.sidebarblock>.content .qlist>ol>li:last-child>:last-child{margin-bottom:0}
218 .literalblock pre,.listingblock>.content>pre{border-radius:4px;overflow-x:auto;padding:1em;font-size:.8125em}
219 @media screen and (min-width:768px){.literalblock pre,.listingblock>.content>pre{font-size:.90625em}}
220 @media screen and (min-width:1280px){.literalblock pre,.listingblock>.content>pre{font-size:1em}}
221 .literalblock pre,.listingblock>.content>pre:not(.highlight),.listingblock>.content>pre[class=highlight],.listingblock>.content>pre[class^="highlight "]{background:#f7f7f8}
222 .literalblock.output pre{color:#f7f7f8;background:rgba(0,0,0,.9)}
223 .listingblock>.content{position:relative}
224 .listingblock code[data-lang]::before{display:none;content:attr(data-lang);position:absolute;font-size:.75em;top:.425rem;right:.5rem;line-height:1;text-transform:uppercase;color:inherit;opacity:.5}
225 .listingblock:hover code[data-lang]::before{display:block}
226 .listingblock.terminal pre .command::before{content:attr(data-prompt);padding-right:.5em;color:inherit;opacity:.5}
227 .listingblock.terminal pre .command:not([data-prompt])::before{content:"$"}
228 .listingblock pre.highlightjs{padding:0}
229 .listingblock pre.highlightjs>code{padding:1em;border-radius:4px}
230 .listingblock pre.prettyprint{border-width:0}
231 .prettyprint{background:#f7f7f8}
232 pre.prettyprint .linenums{line-height:1.45;margin-left:2em}
233 pre.prettyprint li{background:none;list-style-type:inherit;padding-left:0}
234 pre.prettyprint li code[data-lang]::before{opacity:1}
235 pre.prettyprint li:not(:first-child) code[data-lang]::before{display:none}
236 table.linenotable{border-collapse:separate;border:0;margin-bottom:0;background:none}
237 table.linenotable td[class]{color:inherit;vertical-align:top;padding:0;line-height:inherit;white-space:normal}
238 table.linenotable td.code{padding-left:.75em}
239 table.linenotable td.linenos,pre.pygments .linenos{border-right:1px solid;opacity:.35;padding-right:.5em;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}
240 pre.pygments span.linenos{display:inline-block;margin-right:.75em}
241 .quoteblock{margin:0 1em 1.25em 1.5em;display:table}
242 .quoteblock:not(.excerpt)>.title{margin-left:-1.5em;margin-bottom:.75em}
243 .quoteblock blockquote,.quoteblock p{color:rgba(0,0,0,.85);font-size:1.15rem;line-height:1.75;word-spacing:.1em;letter-spacing:0;font-style:italic;text-align:justify}
244 .quoteblock blockquote{margin:0;padding:0;border:0}
245 .quoteblock blockquote::before{content:"\201c";float:left;font-size:2.75em;font-weight:bold;line-height:.6em;margin-left:-.6em;color:#7a2518;text-shadow:0 1px 2px rgba(0,0,0,.1)}
246 .quoteblock blockquote>.paragraph:last-child p{margin-bottom:0}
247 .quoteblock .attribution{margin-top:.75em;margin-right:.5ex;text-align:right}
248 .verseblock{margin:0 1em 1.25em}
249 .verseblock pre{font-family:"Open Sans","DejaVu Sans",sans-serif;font-size:1.15rem;color:rgba(0,0,0,.85);font-weight:300;text-rendering:optimizeLegibility}
250 .verseblock pre strong{font-weight:400}
251 .verseblock .attribution{margin-top:1.25rem;margin-left:.5ex}
252 .quoteblock .attribution,.verseblock .attribution{font-size:.9375em;line-height:1.45;font-style:italic}
253 .quoteblock .attribution br,.verseblock .attribution br{display:none}
254 .quoteblock .attribution cite,.verseblock .attribution cite{display:block;letter-spacing:-.025em;color:rgba(0,0,0,.6)}
255 .quoteblock.abstract blockquote::before,.quoteblock.excerpt blockquote::before,.quoteblock .quoteblock blockquote::before{display:none}
256 .quoteblock.abstract blockquote,.quoteblock.abstract p,.quoteblock.excerpt blockquote,.quoteblock.excerpt p,.quoteblock .quoteblock blockquote,.quoteblock .quoteblock p{line-height:1.6;word-spacing:0}
257 .quoteblock.abstract{margin:0 1em 1.25em;display:block}
258 .quoteblock.abstract>.title{margin:0 0 .375em;font-size:1.15em;text-align:center}
259 .quoteblock.excerpt>blockquote,.quoteblock .quoteblock{padding:0 0 .25em 1em;border-left:.25em solid #dddddf}
260 .quoteblock.excerpt,.quoteblock .quoteblock{margin-left:0}
261 .quoteblock.excerpt blockquote,.quoteblock.excerpt p,.quoteblock .quoteblock blockquote,.quoteblock .quoteblock p{color:inherit;font-size:1.0625rem}
262 .quoteblock.excerpt .attribution,.quoteblock .quoteblock .attribution{color:inherit;font-size:.85rem;text-align:left;margin-right:0}
263 p.tableblock:last-child{margin-bottom:0}
264 td.tableblock>.content{margin-bottom:1.25em;word-wrap:anywhere}
265 td.tableblock>.content>:last-child{margin-bottom:-1.25em}
266 table.tableblock,th.tableblock,td.tableblock{border:0 solid #dedede}
267 table.grid-all>*>tr>*{border-width:1px}
268 table.grid-cols>*>tr>*{border-width:0 1px}
269 table.grid-rows>*>tr>*{border-width:1px 0}
270 table.frame-all{border-width:1px}
271 table.frame-ends{border-width:1px 0}
272 table.frame-sides{border-width:0 1px}
273 table.frame-none>colgroup+*>:first-child>*,table.frame-sides>colgroup+*>:first-child>*{border-top-width:0}
274 table.frame-none>:last-child>:last-child>*,table.frame-sides>:last-child>:last-child>*{border-bottom-width:0}
275 table.frame-none>*>tr>:first-child,table.frame-ends>*>tr>:first-child{border-left-width:0}
276 table.frame-none>*>tr>:last-child,table.frame-ends>*>tr>:last-child{border-right-width:0}
277 table.stripes-all>*>tr,table.stripes-odd>*>tr:nth-of-type(odd),table.stripes-even>*>tr:nth-of-type(even),table.stripes-hover>*>tr:hover{background:#f8f8f7}
278 th.halign-left,td.halign-left{text-align:left}
279 th.halign-right,td.halign-right{text-align:right}
280 th.halign-center,td.halign-center{text-align:center}
281 th.valign-top,td.valign-top{vertical-align:top}
282 th.valign-bottom,td.valign-bottom{vertical-align:bottom}
283 th.valign-middle,td.valign-middle{vertical-align:middle}
284 table thead th,table tfoot th{font-weight:bold}
285 tbody tr th{background:#f7f8f7}
286 tbody tr th,tbody tr th p,tfoot tr th,tfoot tr th p{color:rgba(0,0,0,.8);font-weight:bold}
287 p.tableblock>code:only-child{background:none;padding:0}
288 p.tableblock{font-size:1em}
289 ol{margin-left:1.75em}
290 ul li ol{margin-left:1.5em}
291 dl dd{margin-left:1.125em}
292 dl dd:last-child,dl dd:last-child>:last-child{margin-bottom:0}
293 li p,ul dd,ol dd,.olist .olist,.ulist .ulist,.ulist .olist,.olist .ulist{margin-bottom:.625em}
294 ul.checklist,ul.none,ol.none,ul.no-bullet,ol.no-bullet,ol.unnumbered,ul.unstyled,ol.unstyled{list-style-type:none}
295 ul.no-bullet,ol.no-bullet,ol.unnumbered{margin-left:.625em}
296 ul.unstyled,ol.unstyled{margin-left:0}
297 li>p:empty:only-child::before{content:"";display:inline-block}
298 ul.checklist>li>p:first-child{margin-left:-1em}
299 ul.checklist>li>p:first-child>.fa-square-o:first-child,ul.checklist>li>p:first-child>.fa-check-square-o:first-child{width:1.25em;font-size:.8em;position:relative;bottom:.125em}
300 ul.checklist>li>p:first-child>input[type=checkbox]:first-child{margin-right:.25em}
301 ul.inline{display:flex;flex-flow:row wrap;list-style:none;margin:0 0 .625em -1.25em}
302 ul.inline>li{margin-left:1.25em}
303 .unstyled dl dt{font-weight:400;font-style:normal}
304 ol.arabic{list-style-type:decimal}
305 ol.decimal{list-style-type:decimal-leading-zero}
306 ol.loweralpha{list-style-type:lower-alpha}
307 ol.upperalpha{list-style-type:upper-alpha}
308 ol.lowerroman{list-style-type:lower-roman}
309 ol.upperroman{list-style-type:upper-roman}
310 ol.lowergreek{list-style-type:lower-greek}
311 .hdlist>table,.colist>table{border:0;background:none}
312 .hdlist>table>tbody>tr,.colist>table>tbody>tr{background:none}
313 td.hdlist1,td.hdlist2{vertical-align:top;padding:0 .625em}
314 td.hdlist1{font-weight:bold;padding-bottom:1.25em}
315 td.hdlist2{word-wrap:anywhere}
316 .literalblock+.colist,.listingblock+.colist{margin-top:-.5em}
317 .colist td:not([class]):first-child{padding:.4em .75em 0;line-height:1;vertical-align:top}
318 .colist td:not([class]):first-child img{max-width:none}
319 .colist td:not([class]):last-child{padding:.25em 0}
320 .thumb,.th{line-height:0;display:inline-block;border:4px solid #fff;box-shadow:0 0 0 1px #ddd}
321 .imageblock.left{margin:.25em .625em 1.25em 0}
322 .imageblock.right{margin:.25em 0 1.25em .625em}
323 .imageblock>.title{margin-bottom:0}
324 .imageblock.thumb,.imageblock.th{border-width:6px}
325 .imageblock.thumb>.title,.imageblock.th>.title{padding:0 .125em}
326 .image.left,.image.right{margin-top:.25em;margin-bottom:.25em;display:inline-block;line-height:0}
327 .image.left{margin-right:.625em}
328 .image.right{margin-left:.625em}
329 a.image{text-decoration:none;display:inline-block}
330 a.image object{pointer-events:none}
331 sup.footnote,sup.footnoteref{font-size:.875em;position:static;vertical-align:super}
332 sup.footnote a,sup.footnoteref a{text-decoration:none}
333 sup.footnote a:active,sup.footnoteref a:active,#footnotes .footnote a:first-of-type:active{text-decoration:underline}
334 #footnotes{padding-top:.75em;padding-bottom:.75em;margin-bottom:.625em}
335 #footnotes hr{width:20%;min-width:6.25em;margin:-.25em 0 .75em;border-width:1px 0 0}
336 #footnotes .footnote{padding:0 .375em 0 .225em;line-height:1.3334;font-size:.875em;margin-left:1.2em;margin-bottom:.2em}
337 #footnotes .footnote a:first-of-type{font-weight:bold;text-decoration:none;margin-left:-1.05em}
338 #footnotes .footnote:last-of-type{margin-bottom:0}
339 #content #footnotes{margin-top:-.625em;margin-bottom:0;padding:.75em 0}
340 div.unbreakable{page-break-inside:avoid}
341 .big{font-size:larger}
342 .small{font-size:smaller}
343 .underline{text-decoration:underline}
344 .overline{text-decoration:overline}
345 .line-through{text-decoration:line-through}
346 .aqua{color:#00bfbf}
347 .aqua-background{background:#00fafa}
348 .black{color:#000}
349 .black-background{background:#000}
350 .blue{color:#0000bf}
351 .blue-background{background:#0000fa}
352 .fuchsia{color:#bf00bf}
353 .fuchsia-background{background:#fa00fa}
354 .gray{color:#606060}
355 .gray-background{background:#7d7d7d}
356 .green{color:#006000}
357 .green-background{background:#007d00}
358 .lime{color:#00bf00}
359 .lime-background{background:#00fa00}
360 .maroon{color:#600000}
361 .maroon-background{background:#7d0000}
362 .navy{color:#000060}
363 .navy-background{background:#00007d}
364 .olive{color:#606000}
365 .olive-background{background:#7d7d00}
366 .purple{color:#600060}
367 .purple-background{background:#7d007d}
368 .red{color:#bf0000}
369 .red-background{background:#fa0000}
370 .silver{color:#909090}
371 .silver-background{background:#bcbcbc}
372 .teal{color:#006060}
373 .teal-background{background:#007d7d}
374 .white{color:#bfbfbf}
375 .white-background{background:#fafafa}
376 .yellow{color:#bfbf00}
377 .yellow-background{background:#fafa00}
378 span.icon>.fa{cursor:default}
379 a span.icon>.fa{cursor:inherit}
380 .admonitionblock td.icon [class^="fa icon-"]{font-size:2.5em;text-shadow:1px 1px 2px rgba(0,0,0,.5);cursor:default}
381 .admonitionblock td.icon .icon-note::before{content:"\f05a";color:#19407c}
382 .admonitionblock td.icon .icon-tip::before{content:"\f0eb";text-shadow:1px 1px 2px rgba(155,155,0,.8);color:#111}
383 .admonitionblock td.icon .icon-warning::before{content:"\f071";color:#bf6900}
384 .admonitionblock td.icon .icon-caution::before{content:"\f06d";color:#bf3400}
385 .admonitionblock td.icon .icon-important::before{content:"\f06a";color:#bf0000}
386 .conum[data-value]{display:inline-block;color:#fff!important;background:rgba(0,0,0,.8);border-radius:50%;text-align:center;font-size:.75em;width:1.67em;height:1.67em;line-height:1.67em;font-family:"Open Sans","DejaVu Sans",sans-serif;font-style:normal;font-weight:bold}
387 .conum[data-value] *{color:#fff!important}
388 .conum[data-value]+b{display:none}
389 .conum[data-value]::after{content:attr(data-value)}
390 pre .conum[data-value]{position:relative;top:-.125em}
391 b.conum *{color:inherit!important}
392 .conum:not([data-value]):empty{display:none}
393 dt,th.tableblock,td.content,div.footnote{text-rendering:optimizeLegibility}
394 h1,h2,p,td.content,span.alt,summary{letter-spacing:-.01em}
395 p strong,td.content strong,div.footnote strong{letter-spacing:-.005em}
396 p,blockquote,dt,td.content,td.hdlist1,span.alt,summary{font-size:1.0625rem}
397 p{margin-bottom:1.25rem}
398 .sidebarblock p,.sidebarblock dt,.sidebarblock td.content,p.tableblock{font-size:1em}
399 .exampleblock>.content{background:#fffef7;border-color:#e0e0dc;box-shadow:0 1px 4px #e0e0dc}
400 .print-only{display:none!important}
401 @page{margin:1.25cm .75cm}
402 @media print{*{box-shadow:none!important;text-shadow:none!important}
403 html{font-size:80%}
404 a{color:inherit!important;text-decoration:underline!important}
405 a.bare,a[href^="#"],a[href^="mailto:"]{text-decoration:none!important}
406 a[href^="http:"]:not(.bare)::after,a[href^="https:"]:not(.bare)::after{content:"(" attr(href) ")";display:inline-block;font-size:.875em;padding-left:.25em}
407 abbr[title]{border-bottom:1px dotted}
408 abbr[title]::after{content:" (" attr(title) ")"}
409 pre,blockquote,tr,img,object,svg{page-break-inside:avoid}
410 thead{display:table-header-group}
411 svg{max-width:100%}
412 p,blockquote,dt,td.content{font-size:1em;orphans:3;widows:3}
413 h2,h3,#toctitle,.sidebarblock>.content>.title{page-break-after:avoid}
414 #header,#content,#footnotes,#footer{max-width:none}
415 #toc,.sidebarblock,.exampleblock>.content{background:none!important}
416 #toc{border-bottom:1px solid #dddddf!important;padding-bottom:0!important}
417 body.book #header{text-align:center}
418 body.book #header>h1:first-child{border:0!important;margin:2.5em 0 1em}
419 body.book #header .details{border:0!important;display:block;padding:0!important}
420 body.book #header .details span:first-child{margin-left:0!important}
421 body.book #header .details br{display:block}
422 body.book #header .details br+span::before{content:none!important}
423 body.book #toc{border:0!important;text-align:left!important;padding:0!important;margin:0!important}
424 body.book #toc,body.book #preamble,body.book h1.sect0,body.book .sect1>h2{page-break-before:always}
425 .listingblock code[data-lang]::before{display:block}
426 #footer{padding:0 .9375em}
427 .hide-on-print{display:none!important}
428 .print-only{display:block!important}
429 .hide-for-print{display:none!important}
430 .show-for-print{display:inherit!important}}
431 @media amzn-kf8,print{#header>h1:first-child{margin-top:1.25rem}
432 .sect1{padding:0!important}
433 .sect1+.sect1{border:0}
434 #footer{background:none}
435 #footer-text{color:rgba(0,0,0,.6);font-size:.9em}}
436 @media amzn-kf8{#header,#content,#footnotes,#footer{padding:0}}
437 </style>
438 </head>
439 <body class="article toc2 toc-right">
440 <div id="header">
441 <h1>Fangfrisch</h1>
442 <div class="details">
443 <span id="author" class="author">Ralph Seichter</span><br>
444 <span id="email" class="email"><a href="mailto:[email protected]">[email protected]</a></span><br>
445 <span id="revnumber"> 1.9.2,</span>
446 <span id="revdate">2025-04-04</span>
447 </div>
448 <div id="toc" class="toc2">
449 <div id="toctitle">Table of Contents</div>
450 <ul class="sectlevel1">
451 <li><a href="#_license">1. License</a></li>
452 <li><a href="#_update_strategy">2. Update strategy</a></li>
453 <li><a href="#_installation">3. Installation</a>
454 <ul class="sectlevel2">
455 <li><a href="#_create_home_directory">3.1. Create home directory</a></li>
456 <li><a href="#_prepare_and_activate_venv">3.2. Prepare and activate venv</a></li>
457 <li><a href="#_install_via_pypi">3.3. Install via PyPI</a></li>
458 </ul>
459 </li>
460 <li><a href="#_installation_packages">4. Installation packages</a></li>
461 <li><a href="#_configuration">5. Configuration</a>
462 <ul class="sectlevel2">
463 <li><a href="#_default_providers">5.1. Default providers</a></li>
464 <li><a href="#_user_defined_providers">5.2. User-defined providers</a></li>
465 <li><a href="#_semantics">5.3. Semantics</a></li>
466 <li><a href="#_proxy_support">5.4. Proxy support</a></li>
467 </ul>
468 </li>
469 <li><a href="#dbsetup">6. Preparing the database</a></li>
470 <li><a href="#usage">7. Usage</a></li>
471 <li><a href="#_support">8. Support</a>
472 <ul class="sectlevel2">
473 <li><a href="#_reporting_possible_problems">8.1. Reporting possible problems</a></li>
474 <li><a href="#_offering_suggestions">8.2. Offering suggestions</a></li>
475 <li><a href="#_discussion_precedes_contribution">8.3. Discussion precedes contribution</a></li>
476 </ul>
477 </li>
478 <li><a href="#internalconf">Appendix A: Default configuration</a></li>
479 <li><a href="#sampleeff">Appendix B: Effective configuration</a></li>
480 <li><a href="#ffnews">Appendix C: Fangfrisch News</a></li>
481 <li><a href="#dbstructure">Appendix D: Database structure</a>
482 <ul class="sectlevel2">
483 <li><a href="#_accessing_mappings">D.1. Accessing mappings</a></li>
484 </ul>
485 </li>
486 </ul>
487 </div>
488 </div>
489 <div id="content">
490 <div id="preamble">
491 <div class="sectionbody">
492 <div class="paragraph">
493 <p>Fangfrisch (German for "freshly caught") is a sibling of the <a href="https://www.clamav.net">Clam Anti-Virus</a> freshclam utility.
494 It allows downloading virus definition files that are not official ClamAV canon, e.g. from <a href="https://sanesecurity.com">Sanesecurity</a> and <a href="https://urlhaus.abuse.ch">URLhaus</a>.
495 Fangfrisch was designed with security in mind, to be run by an unprivileged user only.
496 For those curious about the development history, a <a href="https://github.com/rseichter/fangfrisch/blob/master/CHANGELOG.rst">changelog</a> is available online.</p>
497 </div>
498 </div>
499 </div>
500 <div class="sect1">
501 <h2 id="_license"><a class="anchor" href="#_license"></a>1. License</h2>
502 <div class="sectionbody">
503 <div class="paragraph">
504 <p>Copyright © 2020-2025 Ralph Seichter</p>
505 </div>
506 <div class="paragraph">
507 <p>This file is part of "Fangfrisch".</p>
508 </div>
509 <div class="paragraph">
510 <p>Fangfrisch is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.</p>
511 </div>
512 <div class="paragraph">
513 <p>Fangfrisch is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
514 See the GNU General Public License for more details.</p>
515 </div>
516 <div class="paragraph">
517 <p>You should have received a copy of the GNU General Public License along with Fangfrisch.
518 If not, see <a href="https://www.gnu.org/licenses/" class="bare">https://www.gnu.org/licenses/</a>.</p>
519 </div>
520 </div>
521 </div>
522 <div class="sect1">
523 <h2 id="_update_strategy"><a class="anchor" href="#_update_strategy"></a>2. Update strategy</h2>
524 <div class="sectionbody">
525 <div class="paragraph">
526 <p>Fangfrisch is expected to run periodically, e.g. using <a href="https://en.wikipedia.org/wiki/Cron">cron</a>.
527 Fangfrisch will attempt to download digests first (if available upstream), and only retrieve corresponding signature files when their recorded digest changes, minimising transfer volumes.</p>
528 </div>
529 <div class="paragraph">
530 <p>I recommend running Fangfrisch at 10 minute intervals.
531 There is no need to worry about overburdening your machine, the network or remote signature providers.
532 Each individual download is recorded in the database, and whenever Fangfrisch is run, it checks those recorded timestamps against the preconfigured provider intervals.
533 No network connections are made for downloaded signature files which are considered "too young to update".</p>
534 </div>
535 <div class="paragraph">
536 <p>Imagine a provider interval setting of 45 minutes.
537 Even if launched every 10 minutes, Fangfrisch will not attempt to download related signature files before 45 minutes have passed since the last recorded successful download.
538 Provider intervals are set to reasonable defaults internally, but you can override them if necessary.</p>
539 </div>
540 </div>
541 </div>
542 <div class="sect1">
543 <h2 id="_installation"><a class="anchor" href="#_installation"></a>3. Installation</h2>
544 <div class="sectionbody">
545 <div class="paragraph">
546 <p>Fangfrisch requires Python version 3.9 or newer.
547 While Fangfrisch was initially written for Python 3.7, security support (the final lifecycle stage) for that version was terminated by the Python Software Foundation in 2023. Python 3.8 reached its EOL in 2024.</p>
548 </div>
549 <div class="paragraph">
550 <p>The recommended installation method is using the <a href="https://packaging.python.org/tutorials/installing-packages/">pip command</a> in a virtual Python environment.
551 Here is an example listing of commands for BASH, to be executed as root, assuming that you will be running Fangfrisch as an unprivileged user who is member of the <strong>clamav</strong> group:</p>
552 </div>
553 <div class="sect2">
554 <h3 id="_create_home_directory"><a class="anchor" href="#_create_home_directory"></a>3.1. Create home directory</h3>
555 <div class="listingblock">
556 <div class="content">
557 <pre>mkdir -m 0770 -p /var/lib/fangfrisch
558 chgrp clamav /var/lib/fangfrisch</pre>
559 </div>
560 </div>
561 <div class="paragraph">
562 <p>This will grant group members the necessary write access to create the database (see <a href="#dbsetup">Section 6</a>).</p>
563 </div>
564 </div>
565 <div class="sect2">
566 <h3 id="_prepare_and_activate_venv"><a class="anchor" href="#_prepare_and_activate_venv"></a>3.2. Prepare and activate venv</h3>
567 <div class="listingblock">
568 <div class="content">
569 <pre>cd /var/lib/fangfrisch
570 python3 -m venv venv
571 source venv/bin/activate</pre>
572 </div>
573 </div>
574 </div>
575 <div class="sect2">
576 <h3 id="_install_via_pypi"><a class="anchor" href="#_install_via_pypi"></a>3.3. Install via <a href="https://pypi.org/project/fangfrisch/">PyPI</a></h3>
577 <div class="listingblock">
578 <div class="content">
579 <pre>pip install fangfrisch</pre>
580 </div>
581 </div>
582 <div class="paragraph">
583 <p>This step will also create an executable launcher script <code>venv/bin/fangfrisch</code>.</p>
584 </div>
585 </div>
586 </div>
587 </div>
588 <div class="sect1">
589 <h2 id="_installation_packages"><a class="anchor" href="#_installation_packages"></a>4. Installation packages</h2>
590 <div class="sectionbody">
591 <div class="paragraph">
592 <p>As an alternative to pip-based installation, there are packages available for the following Linux distributions:</p>
593 </div>
594 <div class="ulist">
595 <ul>
596 <li>
597 <p>Arch Linux: <a href="https://aur.archlinux.org/packages/python-fangfrisch/">packages/python-fangfrisch</a>.
598 Support contact: Arch package maintainer.</p>
599 </li>
600 <li>
601 <p>Clear Linux: <a href="https://github.com/clearlinux-pkgs/fangfrisch">clearlinux-pkgs/fangfrisch</a>.
602 Support contact: Clear Linux package maintainers.</p>
603 </li>
604 <li>
605 <p>Debian Linux: <a href="https://packages.debian.org/sid/fangfrisch">fangfrisch (utils)</a>.
606 Support contact: Debian package maintainers.</p>
607 </li>
608 <li>
609 <p>Gentoo Linux: <a href="https://packages.gentoo.org/packages/app-antivirus/fangfrisch">app-antivirus/fangfrisch</a>.
610 Support contact: Gentoo package maintainers.</p>
611 </li>
612 <li>
613 <p>NixOS: <a href="https://search.nixos.org/packages?type=packages&amp;query=fangfrisch">fangfrisch</a>
614 Support contact: NixOS package maintainers.</p>
615 </li>
616 </ul>
617 </div>
618 </div>
619 </div>
620 <div class="sect1">
621 <h2 id="_configuration"><a class="anchor" href="#_configuration"></a>5. Configuration</h2>
622 <div class="sectionbody">
623 <div class="paragraph">
624 <p>A configuration file is mandatory, uses an INI-File-like structure and must contain a <code>db_url</code> entry.
625 All other settings are optional.
626 However, unless you enable one signature file provider section, Fangfrisch naturally won&#8217;t do much.</p>
627 </div>
628 <div class="paragraph">
629 <p>Use the <code>--conf</code> command line argument (see <a href="#usage">Section 7</a>) to specify the path to your configuration file.
630 Note that there is no default location.</p>
631 </div>
632 <div class="listingblock">
633 <div class="content">
634 <pre># Minimal example configuration, meant for testing.
635
636 [DEFAULT]
637 db_url = sqlite:////var/lib/fangfrisch/db.sqlite
638 local_directory = /var/lib/clamav
639
640 [urlhaus]
641 enabled = yes</pre>
642 </div>
643 </div>
644 <div class="ulist">
645 <ul>
646 <li>
647 <p><strong>cleanup</strong>: Cleanup method used for provider sections.
648 Default: <code>automatic</code>, alternative: <code>disabled</code>.
649 In automatic mode, Fangfrisch will attempt to delete obsolete virus definition files whenever you disable a provider section.
650 Should you disable this option, orphaned files will be left behind, and you need to ensure cleanup by different means.</p>
651 </li>
652 <li>
653 <p><strong>connection_timeout</strong>: Timeout in seconds, used when establishing network connections to download signature files.
654 Default: <code>30</code>.
655 Be aware that longer timeouts increase the risk of multiple Fangfrisch instances running concurrently.
656 This could, in turn, cause database access problems, and network socket congestion.
657 If your Internet connection is fast, I even suggest testing timeout values lower than the default 30 seconds.</p>
658 </li>
659 <li>
660 <p><strong>db_url</strong>: Database URL in <a href="https://docs.sqlalchemy.org/en/13/core/engines.html#supported-databases">SQLAlchemy syntax</a>.
661 Mandatory, no default.
662 Typically, a local <a href="https://www.sqlite.org">SQLite</a> database will suffice.</p>
663 </li>
664 <li>
665 <p><strong>enabled</strong>: Scan this section for URLs?
666 Default: <code>false</code>.</p>
667 </li>
668 <li>
669 <p><strong>integrity_check</strong>: Mechanism for integrity checks.
670 Default: <code>sha256</code>.
671 You can use <code>disabled</code> if the signature file provider offers no checksums.</p>
672 </li>
673 <li>
674 <p><strong>interval</strong>: Interval between downloads.
675 Defaults are provider-dependent.
676 Values can be expressed in human-readable form (e.g. <code>12h</code> or <code>45m</code>).
677 Please respect the limits set by each provider.</p>
678 </li>
679 <li>
680 <p><strong>local_directory</strong>: Downloaded files are stored here.
681 No default, so the current working directory of the Python process is used.
682 As this can vary depending on how you launch Fangfrisch, it is highly recommended to define an absolute path like <code>/var/lib/clamav</code> instead.
683 You can override this option in provider sections to separate downloads based on origin.</p>
684 </li>
685 <li>
686 <p><strong>log_format</strong>: See <a href="https://docs.python.org/3/library/logging.html#logging.Formatter">Formatter class</a> documentation for details.
687 Fangfrisch uses sensible defaults depending on the selected log method.</p>
688 </li>
689 <li>
690 <p><strong>log_level</strong>: Choose one of <code>DEBUG</code>, <code>INFO</code>, <code>WARNING</code> (default), <code>ERROR</code> or <code>FATAL</code>.</p>
691 </li>
692 <li>
693 <p><strong>log_method</strong>: Either <code>console</code> (default, meaning stdout/stderr) or <code>syslog</code>.
694 For the latter, you can also specify a <strong>log_target</strong>.</p>
695 </li>
696 <li>
697 <p><strong>log_target</strong>: The <a href="https://tools.ietf.org/html/rfc5424">syslog</a> target address.
698 Typical values are <code>/dev/log</code> (local Linux domain socket), <code>localhost</code> or <code>host.domain.tld:udpport</code>.
699 If no target is specified, <code>localhost</code> is assumed.
700 The UDP port number defaults to 514.</p>
701 </li>
702 <li>
703 <p><strong>max_size</strong>: Maximum expected file size.
704 The default is <code>10MB</code>, but all predefined providers have individual size limits (see <a href="#internalconf">Appendix A</a>).
705 Values are can be expressed in human-readable form (e.g. <code>250KB</code> or <code>3MB</code>).
706 Fangfrisch attempts to inspect the content length before downloading virus signature files so as not to download files larger than the defined limit.
707 If providers don&#8217;t respond with content length information, Fangfrisch will log a warning but download the data anyway.</p>
708 </li>
709 <li>
710 <p><strong>on_update_exec</strong>: If any files were downloaded during a pass, a command can be executed in after the pass finishes.
711 No default.
712 A typical value is <code>clamdscan --reload</code>.
713 Starting with Fangfrisch 1.9.0, this option may be overridden in individual sections, permitting per-provider actions.</p>
714 </li>
715 <li>
716 <p><strong>on_update_timeout</strong>: Timeout for the <code>on_update_exec</code> command, in seconds.
717 Default: 30.
718 This option may also be overridden in individual sections.</p>
719 </li>
720 </ul>
721 </div>
722 <div class="paragraph">
723 <p><a href="https://docs.python.org/3/library/configparser.html">See here</a> for details about the configuration parser and extended interpolation.
724 <a href="#_semantics">Section 5.3</a> provides additional information on how configuration options are interpreted.</p>
725 </div>
726 <div class="sect2">
727 <h3 id="_default_providers"><a class="anchor" href="#_default_providers"></a>5.1. Default providers</h3>
728 <div class="paragraph">
729 <p>Fangfrisch contains internal defaults for the following providers, listed in alphabetical order:</p>
730 </div>
731 <div class="ulist">
732 <ul>
733 <li>
734 <p><a href="http://sigs.interserver.net/">InterServer</a></p>
735 </li>
736 <li>
737 <p><a href="https://www.malwarepatrol.net">Malwarepatrol</a></p>
738 </li>
739 <li>
740 <p><a href="https://sanesecurity.com">Sanesecurity</a></p>
741 </li>
742 <li>
743 <p><a href="https://www.securiteinfo.com/services/anti-spam-anti-virus/improve-detection-rate-of-zero-day-malwares-for-clamav.shtml">SecuriteInfo</a></p>
744 </li>
745 <li>
746 <p><a href="https://urlhaus.abuse.ch">URLhaus</a></p>
747 </li>
748 </ul>
749 </div>
750 <div class="paragraph">
751 <p>I have also included "Fangfrisch News" (see <a href="#ffnews">Appendix C</a>).
752 Providers can be enabled by specifiying <code>enabled = yes</code> in the desired configuration file sections.</p>
753 </div>
754 <div class="admonitionblock important">
755 <table>
756 <tr>
757 <td class="icon">
758 <div class="title">Important</div>
759 </td>
760 <td class="content">
761 Please make sure to examine the respective settings for yourself before enabling providers.
762 </td>
763 </tr>
764 </table>
765 </div>
766 <div class="paragraph">
767 <p>The defaults may not suit your personal preferences, and some providers require additional configuration, e.g. an access token.</p>
768 </div>
769 <div class="listingblock">
770 <div class="content">
771 <pre># Example configuration
772
773 [DEFAULT]
774 db_url = sqlite:////var/lib/fangfrisch/db.sqlite
775
776 # The following settings are optional. Other sections inherit
777 # values from DEFAULT and may also overwrite values.
778
779 local_directory = /var/lib/clamav
780 max_size = 5MB
781 on_update_exec = clamdscan --reload
782 on_update_timeout = 42
783
784 [interserver]
785 enabled = yes
786
787 [malwarepatrol]
788 enabled = yes
789 # Replace with your personal Malwarepatrol receipt
790 receipt = abcd1234
791
792 [sanesecurity]
793 enabled = yes
794 # Use a non-default mirror
795 prefix = http://mirror.example.com/sanesecurity/
796
797 [securiteinfo]
798 enabled = yes
799 # Replace with your personal SecuriteInfo customer ID
800 customer_id = abcdef123456
801
802 [urlhaus]
803 enabled = yes
804 max_size = 2MB</pre>
805 </div>
806 </div>
807 </div>
808 <div class="sect2">
809 <h3 id="_user_defined_providers"><a class="anchor" href="#_user_defined_providers"></a>5.2. User-defined providers</h3>
810 <div class="paragraph">
811 <p>Fangfrisch is of course not limited to the internal defaults.
812 You can define as many additional virus definition providers as you like.
813 The following defines a fictional provider:</p>
814 </div>
815 <div class="listingblock">
816 <div class="content">
817 <pre>[fictionalprovider]
818 enabled = yes
819 integrity_check = md5
820 interval = 90m
821 prefix = http://fictional-provider.tld/clamav-unofficial/
822
823 # Reference the defined prefix in URL definitions. Values in
824 # other sections can be referenced using ${section:option}.
825 url_eggs = ${prefix}eggs.ndb
826 url_spam = ${prefix}spam.hdb
827
828 # Override local file name for url_spam
829 filename_spam = spam_spam_spam_lovely_spam.db
830
831 # Execute command after each fresh download from url_eggs
832 on_update_eggs = echo Fresh eggs in {path}</pre>
833 </div>
834 </div>
835 </div>
836 <div class="sect2">
837 <h3 id="_semantics"><a class="anchor" href="#_semantics"></a>5.3. Semantics</h3>
838 <div class="paragraph">
839 <p>Fangfrisch will scan enabled sections for lines prefixed with <code>url_</code> to determine download sources for virus definition files.</p>
840 </div>
841 <div class="ulist">
842 <ul>
843 <li>
844 <p>The value of <code>integrity_check</code> determines both the expected filename suffix for digests and the hashing mechanism used for verification.</p>
845 </li>
846 <li>
847 <p>Local file names will be determined by parsing URLs, but can be manually overridden.
848 To change the file name for <code>url_xyz</code>, set <code>filename_xyz</code> to the desired value.</p>
849 </li>
850 <li>
851 <p>To launch a command after data was downloaded for <code>url_xyz</code>, define <code>on_update_xyz</code>.
852 The command string may contain a <code>{path}</code> placeholder, which will be substituted with the full path of the downloaded file.</p>
853 </li>
854 </ul>
855 </div>
856 <div class="paragraph">
857 <p>You can disable refresh operations for selected URLs by assigning either an empty value or setting it to <code>url_xyz = disabled</code>.
858 Note that disabling URLs in this manner does <em>not</em> delete any previously downloaded files.</p>
859 </div>
860 </div>
861 <div class="sect2">
862 <h3 id="_proxy_support"><a class="anchor" href="#_proxy_support"></a>5.4. Proxy support</h3>
863 <div class="paragraph">
864 <p>Fangfrisch relies on the <em>requests</em> library to download files, which supports environment variables like <code>HTTPS_PROXY</code>.
865 Please refer to <a href="https://requests.readthedocs.io/en/latest/user/advanced/#proxies">section Advanced Usage, subsection Proxies</a> in the <em>requests</em> online documentation for details.</p>
866 </div>
867 </div>
868 </div>
869 </div>
870 <div class="sect1">
871 <h2 id="dbsetup"><a class="anchor" href="#dbsetup"></a>6. Preparing the database</h2>
872 <div class="sectionbody">
873 <div class="paragraph">
874 <p>After completing the configuration, make sure to create the database structure by running the <code>initdb</code> command in a root shell as shown below.
875 Running <code>--force initdb</code> will drop existing database tables.
876 For SQLite, deleting the database file is a viable alternative.</p>
877 </div>
878 <div class="listingblock">
879 <div class="content">
880 <pre>sudo -u clamav -- fangfrisch --conf /etc/fangfrisch.conf initdb</pre>
881 </div>
882 </div>
883 <div class="admonitionblock important">
884 <table>
885 <tr>
886 <td class="icon">
887 <div class="title">Important</div>
888 </td>
889 <td class="content">
890 Fangfrisch need never be run as root.
891 Choose an unprivileged user instead (typically <strong>clamav</strong>).
892 </td>
893 </tr>
894 </table>
895 </div>
896 </div>
897 </div>
898 <div class="sect1">
899 <h2 id="usage"><a class="anchor" href="#usage"></a>7. Usage</h2>
900 <div class="sectionbody">
901 <div class="paragraph">
902 <p>Command line arguments are as follows:</p>
903 </div>
904 <div class="listingblock">
905 <div class="content">
906 <pre>usage: fangfrisch [-h] [-c CONF] [-f] [-p PROVIDER]
907 {dumpconf,dumpmappings,initdb,refresh}
908
909 Update and verify unofficial ClamAV signatures.
910
911 positional arguments:
912 {dumpconf,dumpmappings,initdb,refresh}
913
914 options:
915 -h, --help show this help message and exit
916 -c, --conf CONF configuration file
917 -f, --force force action (default: False)
918 -p, --provider PROVIDER
919 provider name filter (regular expression)
920
921 Fangfrisch version 1.9.2. Copyright © 2020-2025 Ralph Seichter.</pre>
922 </div>
923 </div>
924 <div class="paragraph">
925 <p>You can choose among following actions:</p>
926 </div>
927 <div class="ulist">
928 <ul>
929 <li>
930 <p><strong>dumpconf</strong>: Dump the effective configuration to stdout, combining both internal defaults and your own settings.
931 The effective configuration for the example shown in <a href="#_configuration">Section 5</a> is available in <a href="#sampleeff">Appendix B</a>.</p>
932 </li>
933 <li>
934 <p><strong>dumpmappings</strong>: Dump URL-to-filepath mappings, as recorded in the database refresh log, to stdout.
935 See <a href="#dbstructure">Appendix D</a> for details.</p>
936 </li>
937 <li>
938 <p><strong>initdb</strong>: Create the database structure.
939 This needs to be run only once, before the first refresh.
940 Using the <code>--force</code> option will drop existing tables from the database.</p>
941 </li>
942 <li>
943 <p><strong>refresh</strong>: Refresh the configured URLs.
944 The <code>--force</code> option can be used to override download interval settings.</p>
945 </li>
946 </ul>
947 </div>
948 <div class="paragraph">
949 <p>As stated before, Fangfrisch is typically run using cron.
950 Depending on your host OS, you may use a systemd timer as an alternative.
951 An example crontab looks like this:</p>
952 </div>
953 <div class="listingblock">
954 <div class="content">
955 <pre>HOME=/var/lib/fangfrisch
956 LOG_LEVEL=INFO
957 # minute hour day-of-month month day-of-week user command
958 */10 * * * * clamav sleep $((RANDOM \% 42)); venv/bin/fangfrisch --conf /etc/fangfrisch.conf refresh</pre>
959 </div>
960 </div>
961 </div>
962 </div>
963 <div class="sect1">
964 <h2 id="_support"><a class="anchor" href="#_support"></a>8. Support</h2>
965 <div class="sectionbody">
966 <div class="paragraph">
967 <p>The project is hosted on <a href="https://github.com/rseichter/fangfrisch">GitHub</a>.
968 Before opening tickets or contacting the author, <em>always</em> check <a href="https://github.com/rseichter/fangfrisch/issues">existing issues</a> first, including closed ones.
969 This is not meant to discourage you; it just saves time and effort for all involved.
970 Please contact the author <a href="mailto:[email protected]">Ralph Seichter</a> only after having done your own research.
971 Thank you.</p>
972 </div>
973 <div class="sect2">
974 <h3 id="_reporting_possible_problems"><a class="anchor" href="#_reporting_possible_problems"></a>8.1. Reporting possible problems</h3>
975 <div class="paragraph">
976 <p>If you experience problems, please start by trying to figure out underlying issues on your own.
977 Running with DEBUG level logging helps with that.
978 Should your efforts fail, consider filing a GitHub issue.
979 Each issue needs to answer the questions listed below.</p>
980 </div>
981 <div class="paragraph">
982 <p>If you answer question number 1, 2 or 3 with "no", do not file an issue.
983 Please answer all other questions as detailed as you can, within reason.</p>
984 </div>
985 <div class="olist arabic">
986 <ol class="arabic">
987 <li>
988 <p>Have you checked the documentation?</p>
989 </li>
990 <li>
991 <p>Have you checked all existing issues, including closed ones?</p>
992 </li>
993 <li>
994 <p>Have you done your personal best to resolve the issue on your own?</p>
995 </li>
996 <li>
997 <p>What exactly did you do?</p>
998 </li>
999 <li>
1000 <p>What did you expect to happen?</p>
1001 </li>
1002 <li>
1003 <p>What happened instead?</p>
1004 </li>
1005 <li>
1006 <p>What was your exact setup (operating system, Python core version, Python module versions)?</p>
1007 </li>
1008 </ol>
1009 </div>
1010 </div>
1011 <div class="sect2">
1012 <h3 id="_offering_suggestions"><a class="anchor" href="#_offering_suggestions"></a>8.2. Offering suggestions</h3>
1013 <div class="paragraph">
1014 <p>The list of questions is shorter, but important nonetheless:</p>
1015 </div>
1016 <div class="olist arabic">
1017 <ol class="arabic">
1018 <li>
1019 <p>Have you checked the documentation?</p>
1020 </li>
1021 <li>
1022 <p>Have you checked all existing issues, including closed ones?</p>
1023 </li>
1024 <li>
1025 <p>Do you consider the suggested feature helpful for more people than just yourself?</p>
1026 </li>
1027 </ol>
1028 </div>
1029 <div class="paragraph">
1030 <p>If you answered "yes" for all questions, please explain your idea in a sufficiently thorough manner.
1031 Use examples, graphics, and whatever else you think would help others to understand your suggestion.</p>
1032 </div>
1033 </div>
1034 <div class="sect2">
1035 <h3 id="_discussion_precedes_contribution"><a class="anchor" href="#_discussion_precedes_contribution"></a>8.3. Discussion precedes contribution</h3>
1036 <div class="paragraph">
1037 <p>I do not accept any code or documentation contributions which have not been previously agreed upon.
1038 This means the order of steps is as follows:</p>
1039 </div>
1040 <div class="olist arabic">
1041 <ol class="arabic">
1042 <li>
1043 <p>Open an issue or discussion topic first.</p>
1044 </li>
1045 <li>
1046 <p>Have a conversation about the matter at hand.</p>
1047 </li>
1048 <li>
1049 <p>Reach a consensus about both form and content of the contribution.</p>
1050 </li>
1051 <li>
1052 <p>Wait for a yay/nay signal from me.</p>
1053 </li>
1054 </ol>
1055 </div>
1056 <div class="paragraph">
1057 <p>Please do <em>not</em> submit any pull requests before I ask for them, as they will be closed.
1058 This outlined, proven practice will save time for all involved.
1059 See Heather McNamee&#8217;s blog <a href="https://about.gitlab.com/blog/2016/03/03/start-with-an-issue/">Always start with an issue</a> for more information.</p>
1060 </div>
1061 </div>
1062 </div>
1063 </div>
1064 <div class="sect1">
1065 <h2 id="internalconf"><a class="anchor" href="#internalconf"></a>Appendix A: Default configuration</h2>
1066 <div class="sectionbody">
1067 <div class="paragraph">
1068 <p>Fangfrisch contains the following internal configuration settings as defaults.
1069 As a safety measure, all sections are disabled by default.
1070 Entries with the <code>!url_</code> prefix are included for reference only.
1071 These represent data sources which are not recommended for general use.
1072 Possible reasons: Some sources have an elevated risk of false positives, are not free to use, or contain legacy data.
1073 Enabling a section will not enable these specially prefixed entries.</p>
1074 </div>
1075 <div class="listingblock">
1076 <div class="content">
1077 <pre>[DEFAULT]
1078 cleanup = automatic
1079 enabled = no
1080 integrity_check = sha256
1081 log_level = WARNING
1082 log_method = console
1083 max_size = 10MB
1084
1085 [fangfrischnews]
1086 interval = 12h
1087 local_directory = /tmp
1088 max_size = 100KB
1089 script = /path/to/fangfrisch-has-news.sh
1090 on_update_exec = [ ! -x ${script} ] || ${script} ${local_directory}
1091 prefix = https://www.seichter.de/fangfrisch/
1092 url_alerts = ${prefix}fangfrisch_alerts.txt
1093 url_news = ${prefix}fangfrisch_news.txt
1094
1095 [interserver]
1096 interval = 1h
1097 integrity_check = disabled
1098 max_size = 5MB
1099 prefix = http://sigs.interserver.net/
1100 !url_shell_hdb = ${prefix}shell.hdb
1101 !url_shellb_db = ${prefix}shellb.db
1102 url_interserver256 = ${prefix}interserver256.hdb
1103 url_shell_ldb = ${prefix}shell.ldb
1104 filename_shell_ldb = interservershell.ldb
1105 url_topline = ${prefix}interservertopline.db
1106 url_whitelist_fp = ${prefix}whitelist.fp
1107 filename_whitelist_fp = interserverwhitelist.fp
1108
1109 [malwarepatrol]
1110 interval = 1d
1111 integrity_check = disabled
1112 product = 8
1113 receipt = you_forgot_to_configure_receipt
1114 prefix = https://lists.malwarepatrol.net/cgi/getfile?product=${product}&amp;receipt=${receipt}&amp;list=
1115 url_clamav_basic = ${prefix}clamav_basic
1116 filename_clamav_basic = malwarepatrol.db
1117
1118 [sanesecurity]
1119 interval = 1h
1120 prefix = http://mirror.seichter.de/sanesecurity/
1121 !url_foxhole_all_cdb = ${prefix}foxhole_all.cdb
1122 !url_foxhole_all_ndb = ${prefix}foxhole_all.ndb
1123 !url_foxhole_links = ${prefix}foxhole_links.ldb
1124 !url_foxhole_mail = ${prefix}foxhole_mail.cdb
1125 !url_winnow_phish_complete = ${prefix}winnow_phish_complete.ndb
1126 url_badmacro = ${prefix}badmacro.ndb
1127 url_blurl = ${prefix}blurl.ndb
1128 url_bofhland_cracked_url = ${prefix}bofhland_cracked_URL.ndb
1129 url_bofhland_malware_attach = ${prefix}bofhland_malware_attach.hdb
1130 url_bofhland_malware_url = ${prefix}bofhland_malware_URL.ndb
1131 url_bofhland_phishing_url = ${prefix}bofhland_phishing_URL.ndb
1132 url_foxhole_filename = ${prefix}foxhole_filename.cdb
1133 url_foxhole_generic = ${prefix}foxhole_generic.cdb
1134 url_foxhole_js_cdb = ${prefix}foxhole_js.cdb
1135 url_foxhole_js_ndb = ${prefix}foxhole_js.ndb
1136 url_hackingteam = ${prefix}hackingteam.hsb
1137 url_junk = ${prefix}junk.ndb
1138 url_jurlbl = ${prefix}jurlbl.ndb
1139 url_jurlbla = ${prefix}jurlbla.ndb
1140 url_lott = ${prefix}lott.ndb
1141 url_malwareexpert_fp = ${prefix}malware.expert.fp
1142 url_malwareexpert_hdb = ${prefix}malware.expert.hdb
1143 url_malwareexpert_ldb = ${prefix}malware.expert.ldb
1144 url_malwareexpert_ndb = ${prefix}malware.expert.ndb
1145 url_malwarehash = ${prefix}malwarehash.hsb
1146 url_phish = ${prefix}phish.ndb
1147 url_phishtank = ${prefix}phishtank.ndb
1148 url_porcupine = ${prefix}porcupine.ndb
1149 url_rogue = ${prefix}rogue.hdb
1150 url_scam = ${prefix}scam.ndb
1151 url_shelter = ${prefix}shelter.ldb
1152 url_sigwhitelist = ${prefix}sigwhitelist.ign2
1153 url_spamattach = ${prefix}spamattach.hdb
1154 url_spamimg = ${prefix}spamimg.hdb
1155 url_spear = ${prefix}spear.ndb
1156 url_spearl = ${prefix}spearl.ndb
1157 url_ssftm = ${prefix}sanesecurity.ftm
1158 url_winnow_attachments = ${prefix}winnow.attachments.hdb
1159 url_winnow_bad_cw = ${prefix}winnow_bad_cw.hdb
1160 url_winnow_extended_malware = ${prefix}winnow_extended_malware.hdb
1161 url_winnow_extended_malware_links = ${prefix}winnow_extended_malware_links.ndb
1162 url_winnow_malware = ${prefix}winnow_malware.hdb
1163 url_winnow_malware_links = ${prefix}winnow_malware_links.ndb
1164 url_winnow_phish_complete_url = ${prefix}winnow_phish_complete_url.ndb
1165 url_winnow_spam_complete = ${prefix}winnow_spam_complete.ndb
1166
1167 [securiteinfo]
1168 customer_id = you_forgot_to_configure_customer_id
1169 interval = 1h
1170 max_size = 20MB
1171 prefix = https://www.securiteinfo.com/get/signatures/${customer_id}/
1172 !url_0hour = ${prefix}securiteinfo0hour.hdb
1173 !url_old = ${prefix}securiteinfoold.hdb
1174 !url_securiteinfo_mdb = ${prefix}securiteinfo.mdb
1175 !url_securiteinfo_pdb = ${prefix}securiteinfo.pdb
1176 !url_securiteinfo_yara = ${prefix}securiteinfo.yara
1177 url_android = ${prefix}securiteinfoandroid.hdb
1178 url_ascii = ${prefix}securiteinfoascii.hdb
1179 url_html = ${prefix}securiteinfohtml.hdb
1180 url_javascript = ${prefix}javascript.ndb
1181 url_pdf = ${prefix}securiteinfopdf.hdb
1182 url_securiteinfo = ${prefix}securiteinfo.hdb
1183 url_securiteinfo_ign2 = ${prefix}securiteinfo.ign2
1184 url_spam_marketing = ${prefix}spam_marketing.ndb
1185
1186 [urlhaus]
1187 interval = 10m
1188 url_urlhaus = https://urlhaus.abuse.ch/downloads/urlhaus.ndb</pre>
1189 </div>
1190 </div>
1191 </div>
1192 </div>
1193 <div class="sect1">
1194 <h2 id="sampleeff"><a class="anchor" href="#sampleeff"></a>Appendix B: Effective configuration</h2>
1195 <div class="sectionbody">
1196 <div class="paragraph">
1197 <p>The following effective configuration is the result of combining internal defaults (see <a href="#internalconf">Appendix A</a>) with the example settings shown in <a href="#_configuration">Section 5</a>.</p>
1198 </div>
1199 <div class="listingblock">
1200 <div class="content">
1201 <pre>[DEFAULT]
1202 cleanup = automatic
1203 enabled = no
1204 integrity_check = sha256
1205 log_level = WARNING
1206 log_method = console
1207 max_size = 5MB
1208 db_url = sqlite:////var/lib/fangfrisch/db.sqlite
1209 local_directory = /var/lib/clamav
1210 on_update_exec = clamdscan --reload
1211 on_update_timeout = 42
1212
1213 [fangfrischnews]
1214 interval = 12h
1215 local_directory = /tmp
1216 max_size = 100KB
1217 script = /path/to/fangfrisch-has-news.sh
1218 on_update_exec = [ ! -x ${script} ] || ${script} ${local_directory}
1219 prefix = https://www.seichter.de/fangfrisch/
1220 url_alerts = ${prefix}fangfrisch_alerts.txt
1221 url_news = ${prefix}fangfrisch_news.txt
1222
1223 [interserver]
1224 interval = 1h
1225 integrity_check = disabled
1226 max_size = 5MB
1227 prefix = http://sigs.interserver.net/
1228 !url_shell_hdb = ${prefix}shell.hdb
1229 !url_shellb_db = ${prefix}shellb.db
1230 url_interserver256 = ${prefix}interserver256.hdb
1231 url_shell_ldb = ${prefix}shell.ldb
1232 filename_shell_ldb = interservershell.ldb
1233 url_topline = ${prefix}interservertopline.db
1234 url_whitelist_fp = ${prefix}whitelist.fp
1235 filename_whitelist_fp = interserverwhitelist.fp
1236 enabled = yes
1237
1238 [malwarepatrol]
1239 interval = 1d
1240 integrity_check = disabled
1241 product = 8
1242 receipt = abcd1234
1243 prefix = https://lists.malwarepatrol.net/cgi/getfile?product=${product}&amp;receipt=${receipt}&amp;list=
1244 url_clamav_basic = ${prefix}clamav_basic
1245 filename_clamav_basic = malwarepatrol.db
1246 enabled = yes
1247
1248 [sanesecurity]
1249 interval = 1h
1250 prefix = http://mirror.example.com/sanesecurity/
1251 !url_foxhole_all_cdb = ${prefix}foxhole_all.cdb
1252 !url_foxhole_all_ndb = ${prefix}foxhole_all.ndb
1253 !url_foxhole_links = ${prefix}foxhole_links.ldb
1254 !url_foxhole_mail = ${prefix}foxhole_mail.cdb
1255 !url_winnow_phish_complete = ${prefix}winnow_phish_complete.ndb
1256 url_badmacro = ${prefix}badmacro.ndb
1257 url_blurl = ${prefix}blurl.ndb
1258 url_bofhland_cracked_url = ${prefix}bofhland_cracked_URL.ndb
1259 url_bofhland_malware_attach = ${prefix}bofhland_malware_attach.hdb
1260 url_bofhland_malware_url = ${prefix}bofhland_malware_URL.ndb
1261 url_bofhland_phishing_url = ${prefix}bofhland_phishing_URL.ndb
1262 url_foxhole_filename = ${prefix}foxhole_filename.cdb
1263 url_foxhole_generic = ${prefix}foxhole_generic.cdb
1264 url_foxhole_js_cdb = ${prefix}foxhole_js.cdb
1265 url_foxhole_js_ndb = ${prefix}foxhole_js.ndb
1266 url_hackingteam = ${prefix}hackingteam.hsb
1267 url_junk = ${prefix}junk.ndb
1268 url_jurlbl = ${prefix}jurlbl.ndb
1269 url_jurlbla = ${prefix}jurlbla.ndb
1270 url_lott = ${prefix}lott.ndb
1271 url_malwareexpert_fp = ${prefix}malware.expert.fp
1272 url_malwareexpert_hdb = ${prefix}malware.expert.hdb
1273 url_malwareexpert_ldb = ${prefix}malware.expert.ldb
1274 url_malwareexpert_ndb = ${prefix}malware.expert.ndb
1275 url_malwarehash = ${prefix}malwarehash.hsb
1276 url_phish = ${prefix}phish.ndb
1277 url_phishtank = ${prefix}phishtank.ndb
1278 url_porcupine = ${prefix}porcupine.ndb
1279 url_rogue = ${prefix}rogue.hdb
1280 url_scam = ${prefix}scam.ndb
1281 url_shelter = ${prefix}shelter.ldb
1282 url_sigwhitelist = ${prefix}sigwhitelist.ign2
1283 url_spamattach = ${prefix}spamattach.hdb
1284 url_spamimg = ${prefix}spamimg.hdb
1285 url_spear = ${prefix}spear.ndb
1286 url_spearl = ${prefix}spearl.ndb
1287 url_ssftm = ${prefix}sanesecurity.ftm
1288 url_winnow_attachments = ${prefix}winnow.attachments.hdb
1289 url_winnow_bad_cw = ${prefix}winnow_bad_cw.hdb
1290 url_winnow_extended_malware = ${prefix}winnow_extended_malware.hdb
1291 url_winnow_extended_malware_links = ${prefix}winnow_extended_malware_links.ndb
1292 url_winnow_malware = ${prefix}winnow_malware.hdb
1293 url_winnow_malware_links = ${prefix}winnow_malware_links.ndb
1294 url_winnow_phish_complete_url = ${prefix}winnow_phish_complete_url.ndb
1295 url_winnow_spam_complete = ${prefix}winnow_spam_complete.ndb
1296 enabled = yes
1297
1298 [securiteinfo]
1299 customer_id = abcdef123456
1300 interval = 1h
1301 max_size = 20MB
1302 prefix = https://www.securiteinfo.com/get/signatures/${customer_id}/
1303 !url_0hour = ${prefix}securiteinfo0hour.hdb
1304 !url_old = ${prefix}securiteinfoold.hdb
1305 !url_securiteinfo_mdb = ${prefix}securiteinfo.mdb
1306 !url_securiteinfo_pdb = ${prefix}securiteinfo.pdb
1307 !url_securiteinfo_yara = ${prefix}securiteinfo.yara
1308 url_android = ${prefix}securiteinfoandroid.hdb
1309 url_ascii = ${prefix}securiteinfoascii.hdb
1310 url_html = ${prefix}securiteinfohtml.hdb
1311 url_javascript = ${prefix}javascript.ndb
1312 url_pdf = ${prefix}securiteinfopdf.hdb
1313 url_securiteinfo = ${prefix}securiteinfo.hdb
1314 url_securiteinfo_ign2 = ${prefix}securiteinfo.ign2
1315 url_spam_marketing = ${prefix}spam_marketing.ndb
1316 enabled = yes
1317
1318 [urlhaus]
1319 interval = 10m
1320 url_urlhaus = https://urlhaus.abuse.ch/downloads/urlhaus.ndb
1321 enabled = yes
1322 max_size = 2MB</pre>
1323 </div>
1324 </div>
1325 </div>
1326 </div>
1327 <div class="sect1">
1328 <h2 id="ffnews"><a class="anchor" href="#ffnews"></a>Appendix C: Fangfrisch News</h2>
1329 <div class="sectionbody">
1330 <div class="paragraph">
1331 <p>This pseudo provider does not offer antivirus signature files.
1332 It is only meant for me to pass news about Fangfrisch to you, the user, in lieu of a mailing list.
1333 Don&#8217;t expect this to happen on a regular basis.
1334 I am only thinking about release notifications at this point in time.
1335 Still, I kindly ask you to please enable this service by adding the following to your configuration file:</p>
1336 </div>
1337 <div class="listingblock">
1338 <div class="content">
1339 <pre>[fangfrischnews]
1340 enabled = yes
1341 # Uncomment/adapt the following to trigger a script in case of news.
1342 # script = /path/to/script/fangfrisch-has-news.sh</pre>
1343 </div>
1344 </div>
1345 <div class="paragraph">
1346 <p>This will only enable Fangfrisch to occasionally download small text files, nothing more.
1347 You will not need to read the content, nor will anything else happen, unless you modify the <code>script</code> option.
1348 Here is an example script which you could use to have downloaded news items mailed to you.
1349 It needs to be readable for the user account running Fangfrisch, and the sender/recipient addresses obviously have to be adapted.
1350 For your convenience, the latest version of the script can be <a href="https://raw.githubusercontent.com/rseichter/fangfrisch/master/contrib/fangfrisch-has-news.sh">downloaded here</a>.</p>
1351 </div>
1352 <div class="listingblock">
1353 <div class="content">
1354 <pre>#!/usr/bin/env bash
1355 # vim: ts=4 sw=4 noet ft=sh
1356 #
1357 # Example script to process Fangfrisch News.
1358
1359 declare -r MAILFROM="noreply"
1360 declare -r MAILTO="[email protected]"
1361 declare -r SUBJECT="Fangfrisch News are available"
1362
1363 # Choose one of the options below and uncomment the 'declare'
1364 # statements. Until this is done, the script will fail with
1365 # an error message.
1366
1367 # Option 1: Mutt
1368 #declare -r MAILAPP="mutt"
1369 #declare -r MAILAPP_OPT=( "-s" "$SUBJECT" "$MAILTO" )
1370
1371 # Option 2: sendmail
1372 #declare -r MAILAPP="sendmail"
1373 #declare -r MAILAPP_OPT=( "-t" )
1374 #export PATH="$PATH:/usr/sbin"
1375
1376 # Option 3: swaks
1377 #declare -r MAILAPP="swaks"
1378 #declare -r MAILAPP_OPT=( "-d" "-" "-f" "$MAILFROM" "-t" "$MAILTO" )
1379
1380 ### No changes required below this line ###
1381
1382 set -euo pipefail
1383
1384 die() {
1385 echo &gt;&amp;2 "$@"
1386 exit 1
1387 }
1388
1389 usage() {
1390 die "Usage: $(basename "$0") {directory}"
1391 }
1392
1393 gen_header() {
1394 cat &lt;&lt;EOT
1395 Auto-Submitted: auto-generated
1396 From: Fangfrisch News &lt;$MAILFROM&gt;
1397 To: $MAILTO
1398 Subject: $SUBJECT
1399
1400 EOT
1401 # Mail header must end with an empty line!
1402 }
1403
1404 declare -a NEWSITEMS=()
1405
1406 report_news() {
1407 local dir=$1 ni
1408 [ -d "$dir" ] || die "$dir is not a directory"
1409 while IFS= read -r -d '' ni; do
1410 if [ ${#NEWSITEMS[*]} -eq 0 ] &amp;&amp; [ "$MAILAPP" != mutt ]; then
1411 # Mutt does not need the header, others do.
1412 gen_header
1413 fi
1414 NEWSITEMS+=("$ni")
1415 echo -e "\n### $(basename "$ni"):\n"
1416 cat "$ni"
1417 done &lt; &lt;(find "$dir" -maxdepth 1 -type f -name "fangfrisch*.txt" -print0)
1418 }
1419
1420 main() {
1421 local t
1422 [ -n "$MAILAPP" ] || die "MAILAPP is undefined, exiting."
1423 if tty -s; then
1424 # Running in a terminal session
1425 t=$(mktemp)
1426 # shellcheck disable=SC2064
1427 trap "rm $t" EXIT
1428 report_news "$@" | tee "$t" || exit 1
1429 [ ! -s "$t" ] || "$MAILAPP" "${MAILAPP_OPT[@]}" &gt;/dev/null &lt;"$t"
1430 else
1431 report_news "$@" 2&gt;&amp;1 | "$MAILAPP" "${MAILAPP_OPT[@]}" &gt;/dev/null
1432 [ ${#NEWSITEMS[*]} -eq 0 ] || rm -v "${NEWSITEMS[@]}"
1433 fi
1434 }
1435
1436 [ $# -ge 1 ] || usage
1437 main "$@"</pre>
1438 </div>
1439 </div>
1440 </div>
1441 </div>
1442 <div class="sect1">
1443 <h2 id="dbstructure"><a class="anchor" href="#dbstructure"></a>Appendix D: Database structure</h2>
1444 <div class="sectionbody">
1445 <div class="paragraph">
1446 <p>While users can technically access the Fangfrisch backend database directly, its structure and content are considered <strong>private</strong>.
1447 They may change at any time, without notice.</p>
1448 </div>
1449 <div class="sect2">
1450 <h3 id="_accessing_mappings"><a class="anchor" href="#_accessing_mappings"></a>D.1. Accessing mappings</h3>
1451 <div class="paragraph">
1452 <p>In contrast to direct database access, the <strong>dumpmappings</strong> action allows accessing selected parts of database entries in a stable manner.
1453 Specifically, it returns 3-tuples (provider name, URL, local file path).
1454 Elements are separated by horizontal tabulators to facilitate piping the output into <code>awk</code> or similar utilities.
1455 If specified, the <code>provider</code> option is interpreted as a regular expression, and only DB records with matching provider column are returned.
1456 That means if you have providers <em>foo</em> and <em>foobar</em>, you need to use anchoring (e.g. <code>^foo$</code>) if you only wish to match entries for the former provider.
1457 Make sure to use quoting as required by your shell.
1458 Example usage:</p>
1459 </div>
1460 <div class="listingblock">
1461 <div class="content">
1462 <pre># Print all recorded mappings for the [example] provider section.
1463 fangfrisch --conf /etc/fangfrisch.conf --provider '^example$' dumpmappings</pre>
1464 </div>
1465 </div>
1466 <div class="listingblock">
1467 <div class="content">
1468 <pre># Delete all files that were downloaded by Fangfrisch.
1469 # DON'T EXECUTE THIS UNLESS YOU REALLY MEAN IT!
1470 fangfrisch --conf /etc/fangfrisch.conf dumpmappings | awk '{print $3}' | xargs /bin/rm</pre>
1471 </div>
1472 </div>
1473 </div>
1474 </div>
1475 </div>
1476 </div>
1477 <div id="footer">
1478 <div id="footer-text">
1479 1.9.2<br>
1480 </div>
1481 </div>
1482 </body>
1483 </html>