68de45b58fe04fa5e8b28795bcba13777e51875a
[privoxy.git] / doc / webserver / man-page / privoxy-man-page.html
1
2 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
3 <HTML><HEAD><TITLE>Man page of PRIVOXY</TITLE>
4 <LINK REL="STYLESHEET" TYPE="text/css" HREF="../p_doc.css"></HEAD><BODY>
5 <H1>PRIVOXY</H1>
6 Section:  (1)<BR>Updated: 19 January 2008<BR><A HREF="#index">Index</A>
7 <HR>
8
9 <A NAME="lbAB">&nbsp;</A>
10 <H2>NAME</H2>
11
12 privoxy - Privacy Enhancing Proxy
13 <A NAME="lbAC">&nbsp;</A>
14 <H2>SYNOPSIS</H2>
15
16 <P>
17 <B>privoxy</B> [<B>--help</B> ] [<B>--version</B> ] [<B>--no-daemon</B> ] [<B>--pidfile </B><I>pidfile</I><B></B> ] [<B>--user </B><I>user[.group]</I><B></B> ] [<B>--chroot</B> ] [<B>--pre-chroot-nslookup </B><I>hostname</I><B></B> ] [<B></B><I>configfile</I><B></B> ]
18 <P>
19 <A NAME="lbAD">&nbsp;</A>
20 <H2>OPTIONS</H2>
21
22 <P>
23
24 <B>Privoxy</B> may be invoked with the following command line
25 options:
26 <DL COMPACT>
27 <DT><B>--help</B><DD>
28 Print brief usage info and exit.
29 <DT><B>--version</B><DD>
30 Print version info and exit.
31 <DT><B>--no-daemon</B><DD>
32 Don't  become  a daemon, i.e. don't fork and become process group
33 leader, don't detach from controlling tty, and do all logging there.
34 <DT><B>--pidfile </B><I>pidfile</I><B></B><DD>
35 On startup, write the process ID to <I>pidfile</I>.
36 Delete the <I>pidfile</I> on exit.
37 Failure to create or delete the <I>pidfile</I>
38 is non-fatal. If no <B>--pidfile</B> option is given, no PID file will be used.
39 <DT><B>--user </B><I>user[.group]</I><B></B><DD>
40 After (optionally) writing the PID file, assume the user ID of
41 <I>user</I> and the GID of
42 <I>group</I>, or, if the optional
43 <I>group</I> was not given, the default group of
44 <I>user</I>. Exit if the privileges are not
45 sufficient to do so.
46 <DT><B>--chroot</B><DD>
47 Before changing to the user ID given in the --user option, chroot to
48 that user's home directory, i.e. make the kernel pretend to the
49 <B>Privoxy</B> process that the directory tree starts
50 there. If set up carefully, this can limit the impact of possible
51 vulnerabilities in <B>Privoxy</B> to the files contained in
52 that hierarchy. 
53 <DT><B>--pre-chroot-nslookup </B><I>hostname</I><B></B><DD>
54 Initialize the resolver library using <I>hostname</I>
55 before chroot'ing. On some systems this reduces the number of files
56 that must be copied into the chroot tree.
57 </DL>
58 <P>
59
60 If the <I>configfile</I> is not specified on  the  command  line,
61 <B>Privoxy</B>  will  look for a file named
62 <I>config</I> in the current directory . If no
63 <I>configfile</I> is found, <B>Privoxy</B> will 
64 fail to start.
65 <A NAME="lbAE">&nbsp;</A>
66 <H2>DESCRIPTION</H2>
67
68 <P>
69
70 Privoxy is a non-caching
71 web proxy
72 with advanced filtering capabilities for enhancing privacy,
73 modifying web page data, managing HTTP
74 cookies, 
75 controlling access, and removing ads, banners, pop-ups and other obnoxious
76 Internet junk. Privoxy has a flexible configuration and can be
77 customized to suit individual needs and tastes. Privoxy has application for
78 both stand-alone systems and multi-user networks.
79 <P>
80
81 Privoxy is based on Internet Junkbuster (tm).
82 <A NAME="lbAF">&nbsp;</A>
83 <H2>INSTALLATION AND USAGE</H2>
84
85 <P>
86
87 Browsers can either be individually configured to use
88 <B>Privoxy</B> as a HTTP proxy (recommended),
89 or <B>Privoxy</B> can be combined with a packet
90 filter to build an intercepting proxy
91 (see <I>config</I>).  The default setting is  for
92 localhost,  on port  8118 (configurable in the main config file).  To set the
93 HTTP proxy in Netscape and Mozilla, go through:  <B>Edit</B>;
94 <B>Preferences</B>;  <B>Advanced</B>;
95 <B>Proxies</B>;  <B>Manual Proxy Configuration</B>;
96 <B>View</B>. 
97 <P>
98
99 For Firefox, go through: <B>Tools</B>; 
100 <B>Options</B>; <B>General</B>;
101 <B>Connection Settings</B>;
102 <B>Manual Proxy Configuration</B>. 
103 <P>
104
105 For Internet Explorer, go through: <B>Tools</B>; 
106 <B>Internet Properties</B>; <B>Connections</B>;
107 <B>LAN Settings</B>. 
108 <P>
109
110 The Secure (SSL) Proxy should also be set to the same values, otherwise
111 https: URLs will not be proxied. Note: <B>Privoxy</B> can only
112 proxy HTTP and HTTPS traffic. Do not try it with FTP or other protocols.
113 HTTPS presents some limitations, and not all features will work with HTTPS 
114 connections.
115 <P>
116
117 For other browsers, check the documentation.
118 <A NAME="lbAG">&nbsp;</A>
119 <H2>CONFIGURATION</H2>
120
121 <P>
122
123 <B>Privoxy</B> can be configured with the various configuration
124 files. The default configuration files are: <I>config</I>,
125 <I>default.filter</I>, and
126 <I>default.action</I>. <I>user.action</I> should 
127 be used for locally defined exceptions to the default rules of
128 <I>default.action</I>, and <I>user.filter</I> for 
129 locally defined filters. These are well commented.  On Unix
130 and Unix-like systems, these are located in
131 <I>/etc/privoxy/</I> by default. 
132 <P>
133
134 <B>Privoxy</B> uses the concept of <B>actions</B> 
135 in order to manipulate the data stream between the browser and remote sites.
136 There are various actions available with specific functions for such things 
137 as blocking web sites, managing cookies, etc. These actions can be invoked
138 individually or combined, and used against individual URLs, or groups of URLs 
139 that can be defined using wildcards and regular expressions. The result is
140 that the user has greatly enhanced control and freedom.
141 <P>
142
143 The actions list (ad blocks, etc) can also be configured with your
144 web browser at <A HREF="http://config.privoxy.org/">http://config.privoxy.org/</A> 
145 (assuming the configuration allows it).
146 <B>Privoxy's</B> configuration parameters  can also  be viewed at
147 the same page. In addition, <B>Privoxy</B> can be toggled on/off.
148 This is an internal page, and does not require Internet access.
149 <P>
150
151 See the <I>User Manual</I> for a detailed
152 explanation of installation, general usage, all configuration options, new
153 features and notes on upgrading.
154 <A NAME="lbAH">&nbsp;</A>
155 <H2>SAMPLE CONFIGURATION</H2>
156
157 <P>
158
159 A brief example of what a simple <I>default.action</I>
160 configuration might look like:
161 <P>
162 <PRE>
163  # Define a few useful custom aliases for later use
164  {{alias}}
165
166  # Useful aliases that combine more than one action
167  +crunch-cookies = +crunch-incoming-cookies +crunch-outgoing-cookies
168  -crunch-cookies = -crunch-incoming-cookies -crunch-outgoing-cookies
169  +block-as-image = +block +handle-as-image
170
171  # Fragile sites should have the minimum changes
172  fragile     = -block -deanimate-gifs -fast-redirects -filter \
173                -hide-referer -prevent-cookies -kill-popups
174
175  ## Turn some actions on ################################
176  ## NOTE: Actions are off by default, unless explictily turned on 
177  ## otherwise with the '+' operator.
178
179 { \
180 +deanimate-gifs{last} \
181 +filter{refresh-tags} \
182 +filter{img-reorder} \
183 +filter{banners-by-size} \
184 +filter{webbugs} \
185 +filter{jumping-windows} \
186 +filter{ie-exploits} \
187 +hide-forwarded-for-headers \
188 +hide-from-header{block} \
189 +hide-referrer{conditional-block} \
190 +session-cookies-only \
191 +set-image-blocker{pattern} \
192 }
193 / # '/' Match *all* URL patterns
194
195  
196  # Block all URLs that match these patterns
197  { +block }
198   ad.
199   ad[sv].
200   .*ads.
201   banner?.
202   /.*count(er)?\.(pl|cgi|exe|dll|asp|php[34]?)
203   .hitbox.com 
204   media./.*(ads|banner)
205
206  # Block, and treat these URL patterns as if they were 'images'.
207  # We would expect these to be ads.
208  { +block-as-image }
209   .ad.doubleclick.net
210   .a[0-9].yimg.com/(?:(?!/i/).)*$
211   ad.*.doubleclick.net
212
213  # Make exceptions for these harmless ones that would be 
214  # caught by our +block patterns just above.
215  { -block }
216   adsl.
217   adobe.
218   advice.
219   .*downloads.
220   # uploads or downloads
221   /.*loads
222 </PRE>
223
224 <P>
225
226 Then for a <I>user.action</I>, we would put local,
227 narrowly defined exceptions:
228 <P>
229 <PRE>
230  # Re-define aliases as needed here
231  {{alias}}
232
233  # Useful aliases
234  -crunch-cookies = -crunch-incoming-cookies -crunch-outgoing-cookies
235  
236  # Set personal exceptions to the policies in default.action #######
237
238  # Sites where we want persistent cookies, so allow *all* cookies
239  { -crunch-cookies -session-cookies-only }
240   .redhat.com
241   .sun.com
242   .msdn.microsoft.com
243  
244  # These sites break easily. Use our &quot;fragile&quot; alias here.
245  { fragile }
246   .forbes.com
247   mybank.example.com
248
249  # Replace example.com's style sheet with one of my choosing
250  { +redirect{<A HREF="http://localhost/css-replacements/example.com.css}">http://localhost/css-replacements/example.com.css}</A> }
251   .example.com/stylesheet.css
252 </PRE>
253
254 <P>
255
256 See the comments in the configuration files themselves, or the 
257 <I>User Manual</I>
258 for full explanations of the above syntax, and other <B>Privoxy</B>
259 configuration options.
260 <A NAME="lbAI">&nbsp;</A>
261 <H2>FILES</H2>
262
263 <P>
264 <PRE>
265  
266  <I>/usr/sbin/privoxy</I>
267  <I>/etc/privoxy/config</I>
268  <I>/etc/privoxy/default.action</I>
269  <I>/etc/privoxy/standard.action</I>
270  <I>/etc/privoxy/user.action</I>
271  <I>/etc/privoxy/default.filter</I>
272  <I>/etc/privoxy/user.filter</I>
273  <I>/etc/privoxy/trust</I>
274  <I>/etc/privoxy/templates/*</I>
275  <I>/var/log/privoxy/logfile</I>
276 </PRE>
277
278 <P>
279
280 Various other files should be included, but may vary depending on platform
281 and build configuration. Additional documentation should be included in the local
282 documentation directory.
283 <A NAME="lbAJ">&nbsp;</A>
284 <H2>SIGNALS</H2>
285
286 <P>
287
288 <B>Privoxy</B> terminates on the <B>SIGINT</B>,
289 <B>SIGTERM</B> and <B>SIGABRT</B> signals. Log
290 rotation scripts may cause a re-opening of the logfile by sending a 
291 <B>SIGHUP</B> to <B>Privoxy</B>. Note that unlike
292 other daemons,  <B>Privoxy</B> does not need to be made aware of
293 config file changes by <B>SIGHUP</B> -- it will detect them
294 automatically. 
295 <A NAME="lbAK">&nbsp;</A>
296 <H2>NOTES</H2>
297
298 <P>
299
300 Please see the <I>User Manual</I> on how to contact the
301 developers, for feature requests, reporting problems, and other questions.
302 <A NAME="lbAL">&nbsp;</A>
303 <H2>SEE ALSO</H2>
304
305 <P>
306
307 Other references and sites of interest to <B>Privoxy</B>
308 users:
309 <P>
310
311 <P>
312 <A HREF="http://www.privoxy.org/">http://www.privoxy.org/,</A> 
313 the <B>Privoxy</B> Home page. 
314 <P>
315 <A HREF="http://www.privoxy.org/faq/">http://www.privoxy.org/faq/,</A> 
316 the <B>Privoxy</B> FAQ. 
317 <P>
318 <A HREF="http://sourceforge.net/projects/ijbswa/">http://sourceforge.net/projects/ijbswa/,</A> 
319 the Project Page for <B>Privoxy</B> on 
320 SourceForge.
321 <P>
322 <A HREF="http://config.privoxy.org/">http://config.privoxy.org/,</A>
323 the web-based user interface. <B>Privoxy</B> must be
324 running for this to work. Shortcut: <A HREF="http://p.p/">http://p.p/</A>
325 <P>
326 <A HREF="http://sourceforge.net/tracker/?group_id=11118">http://sourceforge.net/tracker/?group_id=11118</A>&amp;atid=460288, to submit ``misses'' and other
327 configuration related suggestions to the developers. 
328 <P>
329 <A HREF="http://www.junkbusters.com/ht/en/cookies.html">http://www.junkbusters.com/ht/en/cookies.html,</A>
330 an explanation how cookies are used to track web users.
331 <P>
332 <A HREF="http://www.junkbusters.com/ijb.html">http://www.junkbusters.com/ijb.html,</A>
333 the original Internet Junkbuster.
334 <P>
335 <A HREF="http://privacy.net/">http://privacy.net/,</A> a useful site
336 to check what information about you is leaked while you browse the web.
337 <P>
338 <A HREF="http://www.squid-cache.org/">http://www.squid-cache.org/,</A> a popular
339 caching proxy, which is often used together with <B>Privoxy</B>.
340 <P>
341 <A HREF="http://www.pps.jussieu.fr/~jch/software/polipo/">http://www.pps.jussieu.fr/~jch/software/polipo/,</A>
342 <B>Polipo</B> is a caching proxy with advanced features
343 like pipelining, multiplexing and caching of partial instances. In many setups
344 it can be used as <B>Squid</B> replacement.
345 <P>
346 <A HREF="http://tor.eff.org/">http://tor.eff.org/,</A> 
347 <B>Tor</B> can help anonymize web browsing, 
348 web publishing, instant messaging, IRC, SSH, and other applications.
349 <P>
350 <A HREF="http://www.privoxy.org/developer-manual/">http://www.privoxy.org/developer-manual/,</A> 
351 the <B>Privoxy</B> developer manual. 
352 <A NAME="lbAM">&nbsp;</A>
353 <H2>DEVELOPMENT TEAM</H2>
354
355 <P>
356 <PRE>
357  Fabian Keil, lead developer
358  David Schmidt, developer
359  
360  Hal Burgiss
361  Gerry Murphy
362  Roland Rosenfeld
363  Jörg Strohmayer
364 </PRE>
365
366 <A NAME="lbAN">&nbsp;</A>
367 <H2>COPYRIGHT AND LICENSE</H2>
368
369 <A NAME="lbAO">&nbsp;</A>
370 <H3>COPYRIGHT</H3>
371
372 <P>
373
374 Copyright (C) 2001-2007 by Privoxy Developers &lt;<A HREF="mailto:ijbswa-developers@lists.sourceforge.net">ijbswa-developers@lists.sourceforge.net</A>&gt;
375 <P>
376
377 Some source code is based on code Copyright (C) 1997 by Anonymous Coders
378 and Junkbusters, Inc. and licensed under the <I>GNU General Public
379 License</I>.
380 <A NAME="lbAP">&nbsp;</A>
381 <H3>LICENSE</H3>
382
383 <P>
384
385 <B>Privoxy</B> is free software; you can
386 redistribute it and/or modify it under the terms of the 
387 <I>GNU General Public
388 License</I>, version 2, as published by the Free Software Foundation.
389 <P>
390
391 This program is distributed in the hope that it will be useful, but WITHOUT
392 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
393 FITNESS FOR A PARTICULAR PURPOSE.  See the 
394 <I>GNU General Public License</I> for
395 more details, which is available from the Free Software Foundation, Inc, 
396 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
397 <P>
398
399 You should have received a copy of the  <I>GNU General Public License</I>
400 along with this program; if not, write to the  Free Software
401 Foundation, Inc. 51 Franklin Street, Fifth Floor
402 Boston, MA 02110-1301
403 USA 
404 <P>
405
406 <HR>
407 <A NAME="index">&nbsp;</A><H2>Index</H2>
408 <DL>
409 <DT><A HREF="#lbAB">NAME</A><DD>
410 <DT><A HREF="#lbAC">SYNOPSIS</A><DD>
411 <DT><A HREF="#lbAD">OPTIONS</A><DD>
412 <DT><A HREF="#lbAE">DESCRIPTION</A><DD>
413 <DT><A HREF="#lbAF">INSTALLATION AND USAGE</A><DD>
414 <DT><A HREF="#lbAG">CONFIGURATION</A><DD>
415 <DT><A HREF="#lbAH">SAMPLE CONFIGURATION</A><DD>
416 <DT><A HREF="#lbAI">FILES</A><DD>
417 <DT><A HREF="#lbAJ">SIGNALS</A><DD>
418 <DT><A HREF="#lbAK">NOTES</A><DD>
419 <DT><A HREF="#lbAL">SEE ALSO</A><DD>
420 <DT><A HREF="#lbAM">DEVELOPMENT TEAM</A><DD>
421 <DT><A HREF="#lbAN">COPYRIGHT AND LICENSE</A><DD>
422 <DL>
423 <DT><A HREF="#lbAO">COPYRIGHT</A><DD>
424 <DT><A HREF="#lbAP">LICENSE</A><DD>
425 </DL>
426 </DL>
427 <HR>
428 This document was created by
429 man2html,
430 using the manual pages.<BR>
431 Time: 15:18:46 GMT, January 19, 2008
432 </BODY>
433 </HTML>