From 0428133610c525457cb16f7ac6a54203a2743d6c Mon Sep 17 00:00:00 2001 From: Fabian Keil Date: Sun, 4 Sep 2011 11:11:17 +0000 Subject: [PATCH] Ditch trailing whitespace --- GNUmakefile.in | 92 +- acconfig.h | 18 +- actionlist.h | 10 +- actions.c | 10 +- actions.h | 14 +- amiga.c | 4 +- amiga.h | 4 +- cgi.c | 190 ++-- cgi.h | 12 +- cgiedit.c | 20 +- cgiedit.h | 10 +- cgisimple.c | 82 +- cgisimple.h | 10 +- configure.in | 50 +- cygwin.h | 6 +- deanimate.c | 42 +- deanimate.h | 12 +- doc/source/authors.sgml | 14 +- doc/source/buildsource.sgml | 46 +- doc/source/config.sgml | 14 +- doc/source/contacting.sgml | 56 +- doc/source/copyright.sgml | 10 +- doc/source/developer-manual.sgml | 593 ++++++------ doc/source/faq.sgml | 541 +++++------ doc/source/history.sgml | 12 +- doc/source/install.sgml | 18 +- doc/source/license.sgml | 10 +- doc/source/p-authors.sgml | 6 +- doc/source/p-config.sgml | 176 ++-- doc/source/privoxy-man-page.sgml | 68 +- doc/source/privoxy.sgml | 6 +- doc/source/readme.sgml | 64 +- doc/source/seealso.sgml | 30 +- doc/source/supported.sgml | 10 +- doc/source/user-manual.sgml | 1220 ++++++++++++------------ encode.c | 20 +- encode.h | 6 +- errlog.c | 50 +- errlog.h | 6 +- filters.c | 32 +- filters.h | 12 +- gateway.c | 8 +- gateway.h | 10 +- jbsockets.c | 26 +- jbsockets.h | 6 +- jcc.c | 42 +- jcc.h | 8 +- list.c | 18 +- list.h | 6 +- loadcfg.h | 8 +- loaders.c | 34 +- loaders.h | 10 +- miscutil.c | 48 +- miscutil.h | 6 +- parsers.c | 86 +- parsers.h | 6 +- pcrs.c | 92 +- project.h | 16 +- ssplit.c | 22 +- ssplit.h | 6 +- templates/blocked | 18 +- templates/cgi-error-404 | 8 +- templates/cgi-error-bad-param | 6 +- templates/cgi-error-disabled | 6 +- templates/cgi-error-file | 4 +- templates/cgi-error-file-read-only | 4 +- templates/cgi-error-modified | 10 +- templates/cgi-error-parse | 8 +- templates/cgi-style.css | 6 +- templates/connect-failed | 6 +- templates/default | 6 +- templates/edit-actions-add-url-form | 2 +- templates/edit-actions-for-url | 24 +- templates/edit-actions-for-url-filter | 4 +- templates/edit-actions-list | 8 +- templates/edit-actions-list-button | 4 +- templates/edit-actions-list-section | 4 +- templates/edit-actions-list-url | 4 +- templates/edit-actions-remove-url-form | 4 +- templates/edit-actions-url-form | 2 +- templates/forwarding-failed | 6 +- templates/mod-local-help | 2 +- templates/mod-support-and-service | 4 +- templates/no-such-domain | 8 +- templates/show-request | 6 +- templates/show-status | 14 +- templates/show-status-file | 8 +- templates/show-url-info | 10 +- templates/show-version | 14 +- templates/toggle | 8 +- templates/toggle-mini | 6 +- templates/untrusted | 12 +- urlmatch.c | 46 +- urlmatch.h | 6 +- w32log.c | 12 +- w32log.h | 4 +- w32res.h | 6 +- w32svrapi.c | 30 +- w32svrapi.h | 6 +- w32taskbar.c | 4 +- w32taskbar.h | 4 +- win32.c | 10 +- win32.h | 6 +- 103 files changed, 2224 insertions(+), 2210 deletions(-) diff --git a/GNUmakefile.in b/GNUmakefile.in index 19b3dcdc..5dfdf6d9 100644 --- a/GNUmakefile.in +++ b/GNUmakefile.in @@ -1,15 +1,15 @@ # Note: Makefile is built automatically from Makefile.in # -# $Id: GNUmakefile.in,v 1.201 2011/08/31 13:36:35 fabiankeil Exp $ +# $Id: GNUmakefile.in,v 1.202 2011/09/04 11:09:05 fabiankeil Exp $ # # Written by and Copyright (C) 2001-2011 members of the # Privoxy team. http://www.privoxy.org/ # # Based on the Internet Junkbuster originally written -# by and Copyright (C) 1997 Anonymous Coders and +# by and Copyright (C) 1997 Anonymous Coders and # Junkbusters Corporation. http://www.junkbusters.com # -# This program is free software; you can redistribute it +# This program 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 2 of the License, or (at @@ -67,15 +67,15 @@ VAR_DEST = @localstatedir@ LOGS_DEST = $(VAR_DEST)/log/privoxy PIDS_DEST = $(VAR_DEST)/run -# if $prefix = /usr/local then the default CONFDEST change from -# CONF_DEST = $(CONF_BASE) to CONF_DEST = $(CONF_BASE)/privoxy +# if $prefix = /usr/local then the default CONFDEST change from +# CONF_DEST = $(CONF_BASE) to CONF_DEST = $(CONF_BASE)/privoxy # by the target rule CONF_DEST # # also if the $prefix is /usr/local and there is no # $(SHARE_DEST)/doc, it checks for $prefix/doc and installs there # instead in this situation # -# finally if $prefix=/usr/local and VAR_DEST=$prefix/var it +# finally if $prefix=/usr/local and VAR_DEST=$prefix/var it # changes this to /var for storing the logs and pidfile # used in source dir only, the install goes to $share_dest/doc/privoxy @@ -91,13 +91,13 @@ RA_MODE = 0664 DIR_MODE = 0755 # Files daemon writes to. RWD_MODE = 0660 -INSTALL_P = -m $(BIN_MODE) +INSTALL_P = -m $(BIN_MODE) INSTALL_T = -m $(RA_MODE) INSTALL_D = -m $(DIR_MODE) -d INSTALL_R = -m $(RWD_MODE) # install options for superuser install -#INSTALL_S = -g @GROUP@ -o @USER@ +#INSTALL_S = -g @GROUP@ -o @USER@ ############################################################################# # Build tools @@ -239,11 +239,11 @@ LIBS = @LIBS@ $(W32_LIB) $(SOCKET_LIB) $(PTHREAD_LIB) # possibly other OSs). SPECIAL_CFLAGS = @SPECIAL_CFLAGS@ -# Add your flags here -OTHER_CFLAGS = +# Add your flags here +OTHER_CFLAGS = CFLAGS = @CFLAGS@ @CPPFLAGS@ $(OTHER_CFLAGS) $(SPECIAL_CFLAGS) -Wall \ - @STATIC_PCRE_ONLY@ -Ipcre + @STATIC_PCRE_ONLY@ -Ipcre LDFLAGS = @LDFLAGS@ $(DEBUG_CFLAGS) $(SPECIAL_CFLAGS) @@ -294,7 +294,7 @@ config.txt: config $(DOSFILTER) default.filter.txt && mv default.filter.txt default.filter trust.txt: trust - $(DOSFILTER) < $< > $@ + $(DOSFILTER) < $< > $@ ############################################################################# # Pre-dist check: @@ -322,9 +322,9 @@ dist-check: ############################################################################# # create tar.gz from CVS: -# This make-target is usually called through 'create-archive'. If you +# This make-target is usually called through 'create-archive'. If you # run 'make create-snapshot' without setting SNAPVERSION, you'll get a -# tar.gz with the current date in the name and as a releasenumber in the +# tar.gz with the current date in the name and as a releasenumber in the # spec-file. But the main usage is to run it as follows (Red Hat example): # make SNAPVERSION=1.6x create-snapshot # This creates a tar.gz. @@ -344,7 +344,7 @@ create-snapshot: ############################################################################# # looks at the version of Makefile and exports a corresponding source-tree -# example: if the Makefile has the sticky tag v_2_9_13, you'll get +# example: if the Makefile has the sticky tag v_2_9_13, you'll get # privoxy-*-2.4.13.tar.gz. ############################################################################# create-archive: @@ -365,7 +365,7 @@ gen-dist: dist-check # add config files for foo in $(CONFIG_FILES); do \ (cd .. && $(TAR) -uvhf --exclude "PACKAGERS" privoxy-$(TARGET_OS)-$(VERSION)-$(CODE_STATUS)-src.tar privoxy-$(VERSION)-$(CODE_STATUS)/$$foo;) \ - done; + done; # add documentation for foo in $(DOC_FILES); do \ (cd .. && $(TAR) -uvhf --exclude "PACKAGERS" privoxy-$(TARGET_OS)-$(VERSION)-$(CODE_STATUS)-src.tar privoxy-$(VERSION)-$(CODE_STATUS)/$$foo;) \ @@ -404,7 +404,7 @@ tarball-dist: dist-check clean clobber cd .. && $(TAR) -cvhf privoxy-$(VERSION)-$(CODE_STATUS)-src.tar $$files ; \ # and zip the archive - $(RM) ../privoxy-$(VERSION)-$(CODE_STATUS) + $(RM) ../privoxy-$(VERSION)-$(CODE_STATUS) $(GZIP_PROG) ../privoxy-$(VERSION)-$(CODE_STATUS)-src.tar @$(ECHO) Tarball distribution created. @@ -429,14 +429,14 @@ tarball-clean: ############################################################################# # developer manual -dok-devel: +dok-devel: $(RM) doc/webserver/developer-manual/*.html $(RM) -r doc/source/developer-manual mkdir -p doc/source/developer-manual cd doc/source/developer-manual && $(DB) ../developer-manual.sgml && cd .. && cp developer-manual/*.html ../webserver/developer-manual/ # user manual -dok-user: +dok-user: $(RM) doc/webserver/user-manual/*.html $(RM) -r doc/source/user-manual/ mkdir -p doc/source/user-manual @@ -447,14 +447,14 @@ dok-user: $(PERL) -pi.bak -e 's/<\/head/\n\n<\/head/i' doc/webserver/user-manual/*html # faq -dok-faq: +dok-faq: $(RM) doc/webserver/faq/*.html $(RM) -r doc/source/faq mkdir -p doc/source/faq cd doc/source/faq && $(DB) ../faq.sgml && cd .. && cp faq/*.html ../webserver/faq/ -# man page, one variation. Try to use the next target, just 'make man'. -dok-man: +# man page, one variation. Try to use the next target, just 'make man'. +dok-man: $(RM) doc/man/* doc/webserver/man-page/*.html echo MAN2HTML is $(MAN2HTML) @if [ $(MAN2HTML) != "false" ]; then \ @@ -466,7 +466,7 @@ dok-man: fi; # Build man page from sgml. This requires the SGMLSpm perl module. -# See CPAN, or your favorite perl repository. This is the preferred +# See CPAN, or your favorite perl repository. This is the preferred # target for man page generation! man: dok-release mkdir -p doc/source/temp && cd doc/source/temp && $(RM) * ;\ @@ -511,7 +511,7 @@ dok-readme: dok-release # for documentation, etc. # # index.html for webserver: -dok-webserver: +dok-webserver: cd doc/source/webserver && $(DB)-notoc -ip-homepage -V nochunks index.sgml > ../../webserver/index.html $(PERL) -pi.bak -e 's/..\/p_doc.css/p_doc.css/;\ s/<\/HEAD/\n<\/HEAD/;\ @@ -521,7 +521,7 @@ dok-webserver: doc/webserver/index.html && $(RM) doc/webserver/*.bak # privoxy-index.html for local documentation: -dok-index: +dok-index: cd doc/source/webserver && $(DB)-notoc -ip-index -V nochunks index.sgml > ../../webserver/privoxy-index.html $(PERL) -pi.bak -e 's/..\/p_doc.css/p_doc.css/;\ s/<\/HEAD/\n<\/HEAD/;\ @@ -535,7 +535,7 @@ dok: dok-release dok-devel dok-user dok-faq dok-readme dok-webserver dok-authors @$(ECHO) Documentation created. ## Make AUTHORS file -dok-authors: +dok-authors: cd doc/source && $(DB) -V nochunks authors.sgml > tmp.html && env -u LANG $(WDUMP) \ tmp.html > ../../AUTHORS && $(RM) tmp.html @@ -568,13 +568,13 @@ dok-release: # mv -f index.html announce.html && $(WDUMP) announce.html > announce.txt # cd $(DOC_TMP) && $(DB) announce.sgml &&\ # mv -f index.html announce-mini.html && $(WDUMP) announce-mini.html > announce-mini.txt &&\ -# mv -f *html *txt ../../.. +# mv -f *html *txt ../../.. # rm -fr $(DOC_TMP) -# The main Privoxy config file, generated from sgml sources. -# NOTE: This will require some hand editing. The new file is outputted +# The main Privoxy config file, generated from sgml sources. +# NOTE: This will require some hand editing. The new file is outputted # as config.new so that problem sections can be compared to previous -# version. This is hardcored to w3m for html/text conversion. Also, +# version. This is hardcored to w3m for html/text conversion. Also, # requires the shell util 'fmt'. config-file: dok-release cd doc/source && $(DB)-notoc -iconfig-file -V nochunks config.sgml > __tmp.html &&\ @@ -593,7 +593,7 @@ config-file: dok-release # config file, alternate version using lynx (perl stuff unfinished). Lynx # does not do so good a job. -config-file-alt: +config-file-alt: cd doc/source && $(ECHO) -e ".h2 JUSTIFY\\nJUSTIFY:FALSE" > __tmp.lynx_cfg &&\ $(DB)-notoc -iconfig-file -V nochunks config.sgml > __tmp.html &&\ lynx -cfg=__tmp.lynx_cfg -width=78 -dump __tmp.html > ../../config.new && $(RM) -r __tmp.* @@ -612,7 +612,7 @@ webserver: clean-editor-files @$(ECHO) You will need to "create" a SF shell first: @$(ECHO) ssh -t SF-USER-ID,ijbswa@shell.sourceforge.net create @$(ECHO) Please make sure your documentation files are up to date. - @$(ECHO) Note that this command updates the home page and copys + @$(ECHO) Note that this command updates the home page and copys @$(ECHO) all stuff to the webserver, it will not remove obsolete documents. @$(ECHO) Note that a botched upload can result in the documentation @$(ECHO) on the website becoming unreachable! Also the CSS files @@ -633,7 +633,7 @@ webserver: clean-editor-files @$(SSH) shell.sourceforge.net 'find /home/groups/i/ij/ijbswa/htdocs/ -type f | xargs chmod 664 2>/dev/null; true' web-actions: clean-editor-files - @$(ECHO) Uploading + @$(ECHO) Uploading @cd doc/webserver/actions; \ upload=`find . -type f -a -not \( -path "*/CVS*" -o -path "*/results*" \)`; \ $(TAR) cf - $$upload | $(SSH) ijbswa.sourceforge.net 'cd /home/groups/i/ij/ijbswa/htdocs/actions; tar xvm' @@ -642,7 +642,7 @@ web-actions: clean-editor-files @$(SSH) ijbswa.sourceforge.net 'find /home/groups/i/ij/ijbswa/htdocs/actions/ -type f | xargs chmod 664 2>/dev/null' @$(SSH) ijbswa.sourceforge.net 'chmod 666 /home/groups/i/ij/ijbswa/htdocs/actions/results/actions-feedback.txt 2>/dev/null' -## +## dok-put: tar --exclude ".cvsignore" --exclude "CVS" --exclude "source" --exclude ".htaccess" \ --exclude "obsolete" --exclude "actions" --exclude "*.zip" --exclude "robots.txt"\ @@ -686,7 +686,7 @@ cgisimple.@OBJEXT@: cgisimple.c cgisimple.h config.h $(PROJECT_H_DEPS) cgi.h lis deanimate.@OBJEXT@: deanimate.c deanimate.h config.h $(PROJECT_H_DEPS) encode.@OBJEXT@: encode.c encode.h config.h errlog.@OBJEXT@: errlog.c errlog.h config.h $(PROJECT_H_DEPS) @WIN_ONLY@w32log.h -filters.@OBJEXT@: filters.c filters.h config.h $(PROJECT_H_DEPS) errlog.h encode.h gateway.h jbsockets.h jcc.h loadcfg.h parsers.h ssplit.h cgi.h deanimate.h urlmatch.h @WIN_ONLY@win32.h +filters.@OBJEXT@: filters.c filters.h config.h $(PROJECT_H_DEPS) errlog.h encode.h gateway.h jbsockets.h jcc.h loadcfg.h parsers.h ssplit.h cgi.h deanimate.h urlmatch.h @WIN_ONLY@win32.h gateway.@OBJEXT@: gateway.c gateway.h config.h $(PROJECT_H_DEPS) errlog.h jbsockets.h jcc.h loadcfg.h jbsockets.@OBJEXT@: jbsockets.c jbsockets.h config.h $(PROJECT_H_DEPS) filters.h jcc.@OBJEXT@: jcc.c jcc.h config.h $(PROJECT_H_DEPS) errlog.h filters.h gateway.h jbsockets.h loadcfg.h loaders.h miscutil.h parsers.h @WIN_ONLY@w32log.h win32.h w32svrapi.h cgi.h @@ -702,12 +702,12 @@ urlmatch.@OBJEXT@: urlmatch.c urlmatch.h config.h $(PROJECT_H_DEPS) errlog.h gnu_regex.@OBJEXT@: gnu_regex.c gnu_regex.h config.h # PCRS -pcrs.@OBJEXT@: pcrs.c pcrs.h config.h @STATIC_PCRE_ONLY@pcre/pcre.h +pcrs.@OBJEXT@: pcrs.c pcrs.h config.h @STATIC_PCRE_ONLY@pcre/pcre.h # PCRE pcre/get.@OBJEXT@: pcre/get.c pcre/config.h pcre/internal.h pcre/pcre.h pcre/maketables.@OBJEXT@: pcre/maketables.c pcre/config.h pcre/internal.h pcre/pcre.h -pcre/pcre.@OBJEXT@: pcre/pcre.c pcre/config.h pcre/internal.h pcre/pcre.h pcre/chartables.c +pcre/pcre.@OBJEXT@: pcre/pcre.c pcre/config.h pcre/internal.h pcre/pcre.h pcre/chartables.c pcre/pcreposix.@OBJEXT@: pcre/pcreposix.c pcre/config.h pcre/internal.h pcre/pcre.h pcre/pcreposix.h pcre/study.@OBJEXT@: pcre/study.c pcre/config.h pcre/internal.h pcre/pcre.h @@ -757,9 +757,9 @@ clobber: clean-editor-files $(RM) -r autom4te.cache # -# FIXME: What is all this? +# FIXME: What is all this? # - $(RM) cscope.* *.pdb *.lib *.exp + $(RM) cscope.* *.pdb *.lib *.exp distclean: clobber @@ -800,11 +800,11 @@ GROUP_T:=$(shell if [ x$(GROUP) = x ] && [ x$(USER) != x ];then \ install-strip: $(MAKE) install STRIP=-s -# FIXME: Test USER and GROUP on Slack to make sure this works as +# FIXME: Test USER and GROUP on Slack to make sure this works as # intended. # -# FIXME: id handling needs help, probably via configure, since 'id -u' is not -# universally reliable (eg Solaris). Group handling could be better. +# FIXME: id handling needs help, probably via configure, since 'id -u' is not +# universally reliable (eg Solaris). Group handling could be better. # Perhaps the whole user/group validation should be done here, and simplified. PROGRAM_V = Privoxy $(VERSION) $(CODE_STATUS) install: CONF_DEST LOG_DEST PID_DEST check_doc GROUP_T @@ -812,7 +812,7 @@ install: CONF_DEST LOG_DEST PID_DEST check_doc GROUP_T @if [ -n "$(USER)" ]; then \ $(ID) $(USER) >/dev/null || exit 1;\ fi - @# Test for valid group. FIXME. USER does not have to belong to GROUP + @# Test for valid group. FIXME. USER does not have to belong to GROUP @# for file ownership purposes. # if [ -n "$(GROUP_T)" ] && [ -n "$(USER)" ] && ! $(GROUPS) $(USER) | $(GREP) "\<$(GROUP_T)\>" >/dev/null; then \ # $(ECHO) Group $(GROUP_T) for User $(USER) is invalid && exit 1 ;\ @@ -875,10 +875,10 @@ install: CONF_DEST LOG_DEST PID_DEST check_doc GROUP_T $(SED) 's+^#\?user-manual .*+user-manual $(prefix)/doc/privoxy/user-manual/+' config.tmp >config.updated ;\ fi;\ $(MV) config config.base - $(MV) config.updated config + $(MV) config.updated config - @# Install the config support files. Test for root install, and abort - @# if there is no privoxy user, and no other user was enabled during + @# Install the config support files. Test for root install, and abort + @# if there is no privoxy user, and no other user was enabled during @# configure. Later, install init script if appropriate. @$(ECHO) Installing templates to $(DESTDIR)$(CONF_DEST)/templates @for i in `find templates -type f`; do \ diff --git a/acconfig.h b/acconfig.h index 9604b1cf..29e95396 100644 --- a/acconfig.h +++ b/acconfig.h @@ -5,7 +5,7 @@ * File : $Source: /cvsroot/ijbswa/current/acconfig.h,v $ * * Purpose : This file should be the first thing included in every - * .c file. (Before even system headers). It contains + * .c file. (Before even system headers). It contains * #define statements for various features. It was * introduced because the compile command line started * getting ludicrously long with feature defines. @@ -14,10 +14,10 @@ * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -64,7 +64,7 @@ */ #undef CODE_STATUS -/* +/* * Should pcre be statically built in instead of linkling with libpcre? * (This is determined by configure depending on the availiability of * libpcre and user preferences). The name is ugly, but pcre needs it. @@ -72,7 +72,7 @@ */ #undef STATIC_PCRE -/* +/* * Should pcrs be statically built in instead of linkling with libpcrs? * (This is determined by configure depending on the availiability of * libpcrs and user preferences). @@ -138,12 +138,12 @@ * * And no, I haven't got that backwards - IE is being weird. * - * Known limitations: + * Known limitations: * 1) If you press shift-reload on a blocked HTML page, you get * the image "blocked" page, not the HTML "blocked" page. - * 2) Once an image "blocked" page has been sent, viewing it + * 2) Once an image "blocked" page has been sent, viewing it * in it's own browser window *should* bring up the HTML - * "blocked" page, but it doesn't. You need to clear the + * "blocked" page, but it doesn't. You need to clear the * browser cache to get the HTML version again. * * These limitations are due to IE making inconsistent choices @@ -237,7 +237,7 @@ #undef HAVE_GMTIME_R #undef HAVE_LOCALTIME_R -/* Define to 'int' if doesn't have it. +/* Define to 'int' if doesn't have it. */ #undef socklen_t diff --git a/actionlist.h b/actionlist.h index 3d4c8182..7476d714 100644 --- a/actionlist.h +++ b/actionlist.h @@ -16,10 +16,10 @@ * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -119,19 +119,19 @@ DEFINE_CGI_PARAM_CUSTOM ("set-image-blocker", ACTION_IMAGE_BLOCKER, #if DEFINE_ACTION_ALIAS -/* +/* * Alternative spellings */ DEFINE_ACTION_STRING ("hide-referer", ACTION_HIDE_REFERER, ACTION_STRING_REFERER) DEFINE_ACTION_BOOL ("prevent-keeping-cookies", ACTION_NO_COOKIE_KEEP) -/* +/* * Pre-3.0.7 (pseudo) compatibility */ DEFINE_ACTION_MULTI ("filter-client-headers", ACTION_MULTI_CLIENT_HEADER_FILTER) DEFINE_ACTION_MULTI ("filter-server-headers", ACTION_MULTI_SERVER_HEADER_FILTER) -/* +/* * Pre-3.0 compatibility */ DEFINE_ACTION_BOOL ("no-cookie-read", ACTION_NO_COOKIE_READ) diff --git a/actions.c b/actions.c index 6751901e..0709ab72 100644 --- a/actions.c +++ b/actions.c @@ -1,4 +1,4 @@ -const char actions_rcs[] = "$Id: actions.c,v 1.69 2011/05/22 10:21:54 fabiankeil Exp $"; +const char actions_rcs[] = "$Id: actions.c,v 1.70 2011/08/17 10:24:55 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/actions.c,v $ @@ -1223,7 +1223,7 @@ static int load_one_actions_file(struct client_state *csp, int fileid) /* too short */ fclose(fp); log_error(LOG_LEVEL_FATAL, - "can't load actions file '%s': invalid line (%lu): %s", + "can't load actions file '%s': invalid line (%lu): %s", csp->config->actions_file[fileid], linenum, buf); return 1; /* never get here */ } @@ -1428,7 +1428,7 @@ static int load_one_actions_file(struct client_state *csp, int fileid) csp->config->actions_file[fileid]); return 1; /* never get here */ } - + num_fields = ssplit(version_string, ".", fields, SZ(fields), TRUE, FALSE); if (num_fields < 1 || atoi(fields[0]) == 0) @@ -1619,7 +1619,7 @@ static int load_one_actions_file(struct client_state *csp, int fileid) * * Description : Converts a actionsfile entry from the internal * structure into a text line. The output is split - * into one line for each action with line continuation. + * into one line for each action with line continuation. * * Parameters : * 1 : action = The action to format. @@ -1815,7 +1815,7 @@ char * actions_to_html(const struct client_state *csp, * the user manual. * * Parameters : - * 1 : csp = Client state (for config) + * 1 : csp = Client state (for config) * 2 : action = Current action spec to be converted * * Returns : A string. Caller must free it. diff --git a/actions.h b/actions.h index 3b57c2b2..b2ab66ce 100644 --- a/actions.h +++ b/actions.h @@ -1,6 +1,6 @@ #ifndef ACTIONS_H_INCLUDED #define ACTIONS_H_INCLUDED -#define ACTIONS_H_VERSION "$Id: actions.h,v 1.18 2008/03/30 14:52:00 fabiankeil Exp $" +#define ACTIONS_H_VERSION "$Id: actions.h,v 1.19 2009/05/16 13:27:20 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/actions.h,v $ @@ -12,10 +12,10 @@ * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -56,27 +56,27 @@ struct action_alias }; -extern jb_err get_actions (char *line, +extern jb_err get_actions (char *line, struct action_alias * alias_list, struct action_spec *cur_action); extern void free_alias_list(struct action_alias *alias_list); extern void init_action(struct action_spec *dest); extern void free_action(struct action_spec *src); -extern jb_err merge_actions (struct action_spec *dest, +extern jb_err merge_actions (struct action_spec *dest, const struct action_spec *src); #if 0 extern int update_action_bits_for_all_tags(struct client_state *csp); #endif extern int update_action_bits_for_tag(struct client_state *csp, const char *tag); -extern jb_err copy_action (struct action_spec *dest, +extern jb_err copy_action (struct action_spec *dest, const struct action_spec *src); extern char * actions_to_text (const struct action_spec *action); extern char * actions_to_html (const struct client_state *csp, const struct action_spec *action); extern void init_current_action (struct current_action_spec *dest); extern void free_current_action (struct current_action_spec *src); -extern jb_err merge_current_action (struct current_action_spec *dest, +extern jb_err merge_current_action (struct current_action_spec *dest, const struct action_spec *src); extern char * current_action_to_html(const struct client_state *csp, const struct current_action_spec *action); diff --git a/amiga.c b/amiga.c index 2bf43cc3..08696da3 100644 --- a/amiga.c +++ b/amiga.c @@ -1,4 +1,4 @@ -const char amiga_rcs[] = "$Id: amiga.c,v 1.12 2007/01/07 07:40:52 joergs Exp $"; +const char amiga_rcs[] = "$Id: amiga.c,v 1.13 2009/05/16 13:27:20 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/amiga.c,v $ @@ -8,7 +8,7 @@ const char amiga_rcs[] = "$Id: amiga.c,v 1.12 2007/01/07 07:40:52 joergs Exp $"; * Copyright : Written by and Copyright (C) 2001 the SourceForge * Privoxy team. http://www.privoxy.org/ * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at diff --git a/amiga.h b/amiga.h index 21b5b694..46cf2d3b 100644 --- a/amiga.h +++ b/amiga.h @@ -1,7 +1,7 @@ #ifdef AMIGA #ifndef AMIGA_H_INCLUDED #define AMIGA_H_INCLUDED -#define AMIGA_H_VERSION "$Id: amiga.h,v 1.12 2007/01/07 07:40:52 joergs Exp $" +#define AMIGA_H_VERSION "$Id: amiga.h,v 1.13 2009/05/16 13:27:20 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/amiga.h,v $ @@ -11,7 +11,7 @@ * Copyright : Written by and Copyright (C) 2001 the SourceForge * Privoxy team. http://www.privoxy.org/ * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at diff --git a/cgi.c b/cgi.c index de80ead0..f04cf158 100644 --- a/cgi.c +++ b/cgi.c @@ -1,4 +1,4 @@ -const char cgi_rcs[] = "$Id: cgi.c,v 1.142 2011/08/17 10:25:43 fabiankeil Exp $"; +const char cgi_rcs[] = "$Id: cgi.c,v 1.143 2011/08/17 10:26:47 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/cgi.c,v $ @@ -7,18 +7,18 @@ const char cgi_rcs[] = "$Id: cgi.c,v 1.142 2011/08/17 10:25:43 fabiankeil Exp $" * html or gif answers, and to compose HTTP resonses. * This only contains the framework functions, the * actual handler functions are declared elsewhere. - * + * * Functions declared include: - * + * * * Copyright : Written by and Copyright (C) 2001-2004, 2006-2008 * the SourceForge Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -85,126 +85,126 @@ static const struct cgi_dispatcher cgi_dispatchers[] = { "Privoxy main page", TRUE }, #ifdef FEATURE_GRACEFUL_TERMINATION - { "die", - cgi_die, + { "die", + cgi_die, "Shut down - Do not deploy this build in a production environment, " "this is a one click Denial Of Service attack!!!", - FALSE }, + FALSE }, #endif - { "show-status", - cgi_show_status, + { "show-status", + cgi_show_status, #ifdef FEATURE_CGI_EDIT_ACTIONS "View & change the current configuration", #else "View the current configuration", #endif - TRUE }, - { "show-version", - cgi_show_version, + TRUE }, + { "show-version", + cgi_show_version, "View the source code version numbers", - TRUE }, - { "show-request", - cgi_show_request, + TRUE }, + { "show-request", + cgi_show_request, "View the request headers", - TRUE }, + TRUE }, { "show-url-info", - cgi_show_url_info, + cgi_show_url_info, "Look up which actions apply to a URL and why", TRUE }, #ifdef FEATURE_TOGGLE { "toggle", - cgi_toggle, + cgi_toggle, "Toggle Privoxy on or off", FALSE }, #endif /* def FEATURE_TOGGLE */ #ifdef FEATURE_CGI_EDIT_ACTIONS { "edit-actions", /* Edit the actions list */ - cgi_edit_actions, + cgi_edit_actions, NULL, FALSE }, { "eaa", /* Shortcut for edit-actions-add-url-form */ - cgi_edit_actions_add_url_form, + cgi_edit_actions_add_url_form, NULL, FALSE }, { "eau", /* Shortcut for edit-actions-url-form */ - cgi_edit_actions_url_form, + cgi_edit_actions_url_form, NULL, FALSE }, { "ear", /* Shortcut for edit-actions-remove-url-form */ - cgi_edit_actions_remove_url_form, + cgi_edit_actions_remove_url_form, NULL, FALSE }, { "eal", /* Shortcut for edit-actions-list */ - cgi_edit_actions_list, + cgi_edit_actions_list, NULL, FALSE }, { "eafu", /* Shortcut for edit-actions-for-url */ - cgi_edit_actions_for_url, + cgi_edit_actions_for_url, NULL, FALSE }, { "eas", /* Shortcut for edit-actions-submit */ - cgi_edit_actions_submit, + cgi_edit_actions_submit, NULL, FALSE }, { "easa", /* Shortcut for edit-actions-section-add */ - cgi_edit_actions_section_add, + cgi_edit_actions_section_add, NULL, FALSE }, { "easr", /* Shortcut for edit-actions-section-remove */ - cgi_edit_actions_section_remove, + cgi_edit_actions_section_remove, NULL, FALSE }, { "eass", /* Shortcut for edit-actions-section-swap */ - cgi_edit_actions_section_swap, + cgi_edit_actions_section_swap, NULL, FALSE }, { "edit-actions-for-url", - cgi_edit_actions_for_url, + cgi_edit_actions_for_url, NULL, FALSE /* Edit the actions for (a) specified URL(s) */ }, { "edit-actions-list", - cgi_edit_actions_list, + cgi_edit_actions_list, NULL, TRUE /* Edit the actions list */ }, { "edit-actions-submit", - cgi_edit_actions_submit, + cgi_edit_actions_submit, NULL, FALSE /* Change the actions for (a) specified URL(s) */ }, { "edit-actions-url", - cgi_edit_actions_url, + cgi_edit_actions_url, NULL, FALSE /* Change a URL pattern in the actionsfile */ }, { "edit-actions-url-form", - cgi_edit_actions_url_form, + cgi_edit_actions_url_form, NULL, FALSE /* Form to change a URL pattern in the actionsfile */ }, { "edit-actions-add-url", - cgi_edit_actions_add_url, + cgi_edit_actions_add_url, NULL, FALSE /* Add a URL pattern to the actionsfile */ }, { "edit-actions-add-url-form", - cgi_edit_actions_add_url_form, + cgi_edit_actions_add_url_form, NULL, FALSE /* Form to add a URL pattern to the actionsfile */ }, { "edit-actions-remove-url", - cgi_edit_actions_remove_url, + cgi_edit_actions_remove_url, NULL, FALSE /* Remove a URL pattern from the actionsfile */ }, { "edit-actions-remove-url-form", - cgi_edit_actions_remove_url_form, + cgi_edit_actions_remove_url_form, NULL, FALSE /* Form to remove a URL pattern from the actionsfile */ }, { "edit-actions-section-add", - cgi_edit_actions_section_add, + cgi_edit_actions_section_add, NULL, FALSE /* Remove a section from the actionsfile */ }, { "edit-actions-section-remove", - cgi_edit_actions_section_remove, + cgi_edit_actions_section_remove, NULL, FALSE /* Remove a section from the actionsfile */ }, { "edit-actions-section-swap", - cgi_edit_actions_section_swap, + cgi_edit_actions_section_swap, NULL, FALSE /* Swap two sections in the actionsfile */ }, #endif /* def FEATURE_CGI_EDIT_ACTIONS */ - { "error-favicon.ico", - cgi_send_error_favicon, + { "error-favicon.ico", + cgi_send_error_favicon, NULL, TRUE /* Sends the favicon image for error pages. */ }, - { "favicon.ico", - cgi_send_default_favicon, + { "favicon.ico", + cgi_send_default_favicon, NULL, TRUE /* Sends the default favicon image. */ }, - { "robots.txt", - cgi_robots_txt, - NULL, TRUE /* Sends a robots.txt file to tell robots to go away. */ }, + { "robots.txt", + cgi_robots_txt, + NULL, TRUE /* Sends a robots.txt file to tell robots to go away. */ }, { "send-banner", - cgi_send_banner, + cgi_send_banner, NULL, TRUE /* Send a built-in image */ }, { "send-stylesheet", - cgi_send_stylesheet, + cgi_send_stylesheet, NULL, FALSE /* Send templates/cgi-style.css */ }, { "t", - cgi_transparent_image, + cgi_transparent_image, NULL, TRUE /* Send a transparent image (short name) */ }, { "url-info-osd.xml", - cgi_send_url_info_osd, + cgi_send_url_info_osd, NULL, TRUE /* Send templates/url-info-osd.xml */ }, { "user-manual", cgi_send_user_manual, @@ -287,7 +287,7 @@ static struct map *parse_cgi_parameters(char *argstring); /********************************************************************* - * + * * Function : dispatch_cgi * * Description : Checks if a request URL has either the magical @@ -349,7 +349,7 @@ struct http_response *dispatch_cgi(struct client_state *csp) return NULL; } - /* + /* * This is a CGI call. */ @@ -394,7 +394,7 @@ static char *grep_cgi_referrer(const struct client_state *csp) /********************************************************************* - * + * * Function : referrer_is_safe * * Description : Decides whether we trust the Referer for @@ -442,7 +442,7 @@ static int referrer_is_safe(const struct client_state *csp) } /********************************************************************* - * + * * Function : dispatch_known_cgi * * Description : Processes a CGI once dispatch_cgi has determined that @@ -480,7 +480,7 @@ static struct http_response *dispatch_known_cgi(struct client_state * csp, { query_args_start++; } - if (*query_args_start == '/') + if (*query_args_start == '/') { *query_args_start++ = '\0'; if ((param_list = new_map())) @@ -515,7 +515,7 @@ static struct http_response *dispatch_known_cgi(struct client_state * csp, return cgi_error_memory(); } - /* + /* * Find and start the right CGI function */ d = cgi_dispatchers; @@ -579,8 +579,8 @@ static struct http_response *dispatch_known_cgi(struct client_state * csp, d++; } } - - + + /********************************************************************* * * Function : parse_cgi_parameters @@ -606,7 +606,7 @@ static struct map *parse_cgi_parameters(char *argstring) return NULL; } - /* + /* * IE 5 does, of course, violate RFC 2316 Sect 4.1 and sends * the fragment identifier along with the request, so we must * cut it off here, so it won't pollute the CGI params: @@ -775,7 +775,7 @@ jb_err get_number_param(struct client_state *csp, assert(name); assert(pvalue); - *pvalue = 0; + *pvalue = 0; param = lookup(parameters, name); if (!*param) @@ -867,7 +867,7 @@ struct http_response *error_response(struct client_state *csp, if (!err) err = map(exports, "host", 1, html_encode(csp->http->host), 0); if (!err) err = map(exports, "hostport", 1, html_encode(csp->http->hostport), 0); if (!err) err = map(exports, "path", 1, html_encode_and_free_original(path), 0); - if (!err) err = map(exports, "protocol", 1, csp->http->ssl ? "https://" : "http://", 1); + if (!err) err = map(exports, "protocol", 1, csp->http->ssl ? "https://" : "http://", 1); if (!err) { err = map(exports, "host-ip", 1, html_encode(csp->http->host_ip_addr_str), 0); @@ -1098,7 +1098,7 @@ struct http_response *cgi_error_memory(void) * * Description : Almost-CGI function that is called if a template * cannot be loaded. Note this is not a true CGI, - * it takes a template name rather than a map of + * it takes a template name rather than a map of * parameters. * * Parameters : @@ -1108,7 +1108,7 @@ struct http_response *cgi_error_memory(void) * be loaded. * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_error_no_template(const struct client_state *csp, @@ -1195,7 +1195,7 @@ jb_err cgi_error_no_template(const struct client_state *csp, * 3 : error_to_report = Error code to report. * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_error_unknown(const struct client_state *csp, @@ -1259,7 +1259,7 @@ jb_err cgi_error_unknown(const struct client_state *csp, * * Description : CGI function that is called if the parameters * (query string) for a CGI were wrong. - * + * * Parameters : * 1 : csp = Current client state (buffers, headers, etc...) * 2 : rsp = http_response data structure for output @@ -1267,7 +1267,7 @@ jb_err cgi_error_unknown(const struct client_state *csp, * CGI Parameters : none * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_error_bad_param(const struct client_state *csp, @@ -1289,7 +1289,7 @@ jb_err cgi_error_bad_param(const struct client_state *csp, /********************************************************************* * - * Function : cgi_redirect + * Function : cgi_redirect * * Description : CGI support function to generate a HTTP redirect * message @@ -1301,7 +1301,7 @@ jb_err cgi_error_bad_param(const struct client_state *csp, * CGI Parameters : None * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_redirect (struct http_response * rsp, const char *target) @@ -1336,8 +1336,8 @@ jb_err cgi_redirect (struct http_response * rsp, const char *target) * FIXME: I currently only work for actions, and would * like to be generalized for other topics. * - * Parameters : - * 1 : item = item (will NOT be free()d.) + * Parameters : + * 1 : item = item (will NOT be free()d.) * It is assumed to be HTML-safe. * 2 : config = The current configuration. * @@ -1382,7 +1382,7 @@ char *add_help_link(const char *item, * HTTP header - e.g.: * "Sun, 06 Nov 1994 08:49:37 GMT" * - * Parameters : + * Parameters : * 1 : time_offset = Time returned will be current time * plus this number of seconds. * 2 : buf = Destination for result. @@ -1571,7 +1571,7 @@ struct http_response *finish_http_response(const struct client_state *csp, struc return rsp; } - /* + /* * Fill in the HTTP Status, using HTTP/1.1 * unless the client asked for HTTP/1.0. */ @@ -1580,7 +1580,7 @@ struct http_response *finish_http_response(const struct client_state *csp, struc rsp->status ? rsp->status : "200 OK"); err = enlist_first(rsp->headers, buf); - /* + /* * Set the Content-Length */ if (rsp->content_length == 0) @@ -1646,7 +1646,7 @@ struct http_response *finish_http_response(const struct client_state *csp, struc * Last-Modified: set to date/time the page was last changed. * Expires: set to date/time page next needs reloading. * Cache-Control: set to "no-cache" if applicable. - * + * * See http://www.w3.org/Protocols/rfc2068/rfc2068 */ if (rsp->is_static) @@ -1722,7 +1722,7 @@ struct http_response *finish_http_response(const struct client_state *csp, struc err = enlist_unique_header(rsp->headers, "Connection", "close"); } - /* + /* * Write the head */ if (err || (NULL == (rsp->head = list_to_text(rsp->headers)))) @@ -1802,11 +1802,11 @@ void free_http_response(struct http_response *rsp) * following an #include statament * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * JB_ERR_FILE if the template file cannot be read * *********************************************************************/ -jb_err template_load(const struct client_state *csp, char **template_ptr, +jb_err template_load(const struct client_state *csp, char **template_ptr, const char *templatename, int recursive) { jb_err err; @@ -1888,7 +1888,7 @@ jb_err template_load(const struct client_state *csp, char **template_ptr, } free(full_path); - /* + /* * Read the file, ignoring comments, and honoring #include * statements, unless we're already called recursively. * @@ -1976,7 +1976,7 @@ jb_err template_fill(char **template_ptr, const struct map *exports) file_buffer = *template_ptr; size = strlen(file_buffer) + 1; - /* + /* * Assemble pcrs joblist from exports map */ for (m = exports->first; m != NULL; m = m->next) @@ -1994,7 +1994,7 @@ jb_err template_fill(char **template_ptr, const struct map *exports) else { /* - * Treat the "replace with" text as a literal string - + * Treat the "replace with" text as a literal string - * no quoting needed, no backreferences allowed. * ("Trivial" ['T'] flag). */ @@ -2008,7 +2008,7 @@ jb_err template_fill(char **template_ptr, const struct map *exports) /* Make and run job. */ job = pcrs_compile(buf, m->value, flags, &error); - if (job == NULL) + if (job == NULL) { if (error == PCRS_ERR_NOMEM) { @@ -2035,10 +2035,10 @@ jb_err template_fill(char **template_ptr, const struct map *exports) if (error < 0) { - /* + /* * Substitution failed, keep the original buffer, * log the problem and ignore it. - * + * * The user might see some unresolved @CGI_VARIABLES@, * but returning a special CGI error page seems unreasonable * and could mask more important error messages. @@ -2090,7 +2090,7 @@ jb_err template_fill_for_cgi(const struct client_state *csp, struct http_response *rsp) { jb_err err; - + assert(csp); assert(templatename); assert(exports); @@ -2237,12 +2237,12 @@ struct map *default_exports(const struct client_state *csp, const char *caller) * "if--start.*if--end" to the given * export list. * - * Parameters : + * Parameters : * 1 : exports = map to extend * 2 : name = name of conditional block * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err map_block_killer(struct map *exports, const char *name) @@ -2266,12 +2266,12 @@ jb_err map_block_killer(struct map *exports, const char *name) * by map-block-killer, to save a few bytes. * i.e. removes "@if--start@" and "@if--end@" * - * Parameters : + * Parameters : * 1 : exports = map to extend * 2 : name = name of conditional block * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err map_block_keep(struct map *exports, const char *name) @@ -2312,13 +2312,13 @@ jb_err map_block_keep(struct map *exports, const char *name) * The control structure and one of the alternatives * will be hidden. * - * Parameters : + * Parameters : * 1 : exports = map to extend * 2 : name = name of conditional block * 3 : choose_first = nonzero for first, zero for second. * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err map_conditional(struct map *exports, const char *name, int choose_first) @@ -2350,7 +2350,7 @@ jb_err map_conditional(struct map *exports, const char *name, int choose_first) * * Function : make_menu * - * Description : Returns an HTML-formatted menu of the available + * Description : Returns an HTML-formatted menu of the available * unhidden CGIs, excluding the one given in * and the toggle CGI if toggling is disabled. * @@ -2358,7 +2358,7 @@ jb_err map_conditional(struct map *exports, const char *name, int choose_first) * 1 : self = name of CGI to leave out, can be NULL for * complete listing. * 2 : feature_flags = feature bitmap from csp->config - * + * * * Returns : menu string, or NULL on out-of-memory error. * @@ -2399,7 +2399,7 @@ char *make_menu(const char *self, const unsigned feature_flags) html_encoded_prefix = html_encode(CGI_PREFIX); if (html_encoded_prefix == NULL) { - return NULL; + return NULL; } else { diff --git a/cgi.h b/cgi.h index d9fe6a7e..a7deedee 100644 --- a/cgi.h +++ b/cgi.h @@ -1,24 +1,24 @@ #ifndef CGI_H_INCLUDED #define CGI_H_INCLUDED -#define CGI_H_VERSION "$Id: cgi.h,v 1.39 2011/07/03 17:55:23 fabiankeil Exp $" +#define CGI_H_VERSION "$Id: cgi.h,v 1.40 2011/07/08 13:27:31 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/cgi.h,v $ * * Purpose : Declares functions to intercept request, generate * html or gif answers, and to compose HTTP resonses. - * + * * Functions declared include: - * + * * * Copyright : Written by and Copyright (C) 2001-2009 the * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -69,7 +69,7 @@ extern jb_err map_block_killer (struct map *exports, const char *name); extern jb_err map_block_keep (struct map *exports, const char *name); extern jb_err map_conditional (struct map *exports, const char *name, int choose_first); -extern jb_err template_load(const struct client_state *csp, char ** template_ptr, +extern jb_err template_load(const struct client_state *csp, char ** template_ptr, const char *templatename, int recursive); extern jb_err template_fill(char ** template_ptr, const struct map *exports); extern jb_err template_fill_for_cgi(const struct client_state *csp, diff --git a/cgiedit.c b/cgiedit.c index 946a3e45..345977e6 100644 --- a/cgiedit.c +++ b/cgiedit.c @@ -1,4 +1,4 @@ -const char cgiedit_rcs[] = "$Id: cgiedit.c,v 1.68 2011/01/22 12:30:22 fabiankeil Exp $"; +const char cgiedit_rcs[] = "$Id: cgiedit.c,v 1.69 2011/04/19 13:00:47 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/cgiedit.c,v $ @@ -85,10 +85,10 @@ struct file_line { /** Next entry in the linked list */ struct file_line * next; - + /** The raw data, to write out if this line is unmodified. */ char * raw; - + /** Comments and/or whitespace to put before this line if it's modified and then written out. */ char * prefix; @@ -97,7 +97,7 @@ struct file_line are performed on the data read from file before it's stored here, so it will be a single line of data. */ char * unprocessed; - + /** The type of data on this line. One of the FILE_LINE_xxx constants. */ int type; @@ -327,9 +327,9 @@ static jb_err map_copy_parameter_url(struct map *out, const char *name); #endif /* unused function */ -static jb_err get_file_name_param(struct client_state *csp, - const struct map *parameters, - const char *param_name, +static jb_err get_file_name_param(struct client_state *csp, + const struct map *parameters, + const char *param_name, const char **pfilename); /* Internal convenience functions */ @@ -707,7 +707,7 @@ jb_err cgi_edit_actions_remove_url_form(struct client_state *csp, if (cur_line->type == FILE_LINE_ACTION) { section_start_line_number = line_number; - } + } cur_line = cur_line->next; } @@ -3415,7 +3415,7 @@ jb_err cgi_edit_actions_url(struct client_state *csp, if (cur_line->type == FILE_LINE_ACTION) { section_start_line_number = line_number; - } + } cur_line = cur_line->next; line_number++; } @@ -4183,7 +4183,7 @@ jb_err cgi_edit_actions_section_swap(struct client_state *csp, * * Description : Converts a string into a form JavaScript will like. * - * Netscape 4's JavaScript sucks - it doesn't use + * Netscape 4's JavaScript sucks - it doesn't use * "id" parameters, so you have to set the "name" * used to submit a form element to something JavaScript * will like. (Or access the elements by index in an diff --git a/cgiedit.h b/cgiedit.h index dd051664..287bd479 100644 --- a/cgiedit.h +++ b/cgiedit.h @@ -1,23 +1,23 @@ #ifndef CGIEDIT_H_INCLUDED #define CGIEDIT_H_INCLUDED -#define CGIEDIT_H_VERSION "$Id: cgiedit.h,v 1.10 2008/08/31 15:59:03 fabiankeil Exp $" +#define CGIEDIT_H_VERSION "$Id: cgiedit.h,v 1.11 2009/05/16 13:27:20 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/cgiedit.h,v $ * * Purpose : CGI-based actionsfile editor. - * + * * Functions declared include: - * + * * * Copyright : Written by and Copyright (C) 2001 the SourceForge * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at diff --git a/cgisimple.c b/cgisimple.c index 3ab3428e..0e9ce70d 100644 --- a/cgisimple.c +++ b/cgisimple.c @@ -1,22 +1,22 @@ -const char cgisimple_rcs[] = "$Id: cgisimple.c,v 1.109 2011/04/19 13:00:47 fabiankeil Exp $"; +const char cgisimple_rcs[] = "$Id: cgisimple.c,v 1.110 2011/06/23 14:01:39 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/cgisimple.c,v $ * * Purpose : Simple CGIs to get information about Privoxy's * status. - * + * * Functions declared include: - * + * * * Copyright : Written by and Copyright (C) 2001-2011 the * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -80,7 +80,7 @@ static jb_err load_file(const char *filename, char **buffer, size_t *length); * Description : CGI function that is called for the CGI_SITE_1_HOST * and CGI_SITE_2_HOST/CGI_SITE_2_PATH base URLs. * Boring - only exports the default exports. - * + * * Parameters : * 1 : csp = Current client state (buffers, headers, etc...) * 2 : rsp = http_response data structure for output @@ -118,7 +118,7 @@ jb_err cgi_default(struct client_state *csp, * * Description : CGI function that is called if an unknown action was * given. - * + * * Parameters : * 1 : csp = Current client state (buffers, headers, etc...) * 2 : rsp = http_response data structure for output @@ -127,7 +127,7 @@ jb_err cgi_default(struct client_state *csp, * CGI Parameters : none * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_error_404(struct client_state *csp, @@ -165,7 +165,7 @@ jb_err cgi_error_404(struct client_state *csp, * NOTE: Turning this on in a production build * would be a BAD idea. An EXTREMELY BAD idea. * In short, don't do it. - * + * * Parameters : * 1 : csp = Current client state (buffers, headers, etc...) * 2 : rsp = http_response data structure for output @@ -174,7 +174,7 @@ jb_err cgi_error_404(struct client_state *csp, * CGI Parameters : none * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_die (struct client_state *csp, @@ -227,7 +227,7 @@ jb_err cgi_die (struct client_state *csp, * * Description : Show the client's request and what sed() would have * made of it. - * + * * Parameters : * 1 : csp = Current client state (buffers, headers, etc...) * 2 : rsp = http_response data structure for output @@ -236,7 +236,7 @@ jb_err cgi_die (struct client_state *csp, * CGI Parameters : none * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_show_request(struct client_state *csp, @@ -254,7 +254,7 @@ jb_err cgi_show_request(struct client_state *csp, { return JB_ERR_MEMORY; } - + /* * Repair the damage done to the IOB by get_header() */ @@ -289,7 +289,7 @@ jb_err cgi_show_request(struct client_state *csp, * * Function : cgi_send_banner * - * Description : CGI function that returns a banner. + * Description : CGI function that returns a banner. * * Parameters : * 1 : csp = Current client state (buffers, headers, etc...) @@ -304,7 +304,7 @@ jb_err cgi_show_request(struct client_state *csp, * equivalent). * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_send_banner(struct client_state *csp, @@ -317,7 +317,7 @@ jb_err cgi_send_banner(struct client_state *csp, * If type is auto, then determine the right thing * to do from the set-image-blocker action */ - if (imagetype == 'a') + if (imagetype == 'a') { /* * Default to pattern @@ -368,14 +368,14 @@ jb_err cgi_send_banner(struct client_state *csp, } #endif /* def FEATURE_IMAGE_BLOCKING */ } - + /* * Now imagetype is either the non-auto type we were called with, * or it was auto and has since been determined. In any case, we * can proceed to actually answering the request by sending a redirect * or an image as appropriate: */ - if (imagetype == 'r') + if (imagetype == 'r') { rsp->status = strdup("302 Local Redirect from Privoxy"); if (rsp->status == NULL) @@ -390,7 +390,7 @@ jb_err cgi_send_banner(struct client_state *csp, } else { - if ((imagetype == 'b') || (imagetype == 't')) + if ((imagetype == 'b') || (imagetype == 't')) { rsp->body = bindup(image_blank_data, image_blank_length); rsp->content_length = image_blank_length; @@ -432,7 +432,7 @@ jb_err cgi_send_banner(struct client_state *csp, * CGI Parameters : None * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_transparent_image(struct client_state *csp, @@ -476,7 +476,7 @@ jb_err cgi_transparent_image(struct client_state *csp, * CGI Parameters : None * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_send_default_favicon(struct client_state *csp, @@ -537,7 +537,7 @@ jb_err cgi_send_default_favicon(struct client_state *csp, * CGI Parameters : None * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_send_error_favicon(struct client_state *csp, @@ -599,7 +599,7 @@ jb_err cgi_send_error_favicon(struct client_state *csp, * CGI Parameters : None * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_send_stylesheet(struct client_state *csp, @@ -607,7 +607,7 @@ jb_err cgi_send_stylesheet(struct client_state *csp, const struct map *parameters) { jb_err err; - + assert(csp); assert(rsp); @@ -653,7 +653,7 @@ jb_err cgi_send_stylesheet(struct client_state *csp, * CGI Parameters : None * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_send_url_info_osd(struct client_state *csp, @@ -739,7 +739,7 @@ static const char *get_content_type(const char *filename) * (relative to user-manual from config) * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_send_user_manual(struct client_state *csp, @@ -829,7 +829,7 @@ jb_err cgi_send_user_manual(struct client_state *csp, * CGI Parameters : none * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_show_version(struct client_state *csp, @@ -878,7 +878,7 @@ jb_err cgi_show_version(struct client_state *csp, * Default is to show menu and other information. * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_show_status(struct client_state *csp, @@ -924,7 +924,7 @@ jb_err cgi_show_status(struct client_state *csp, if (!err) err = map(exports, "options", 1, csp->config->proxy_args, 1); if (!err) err = show_defines(exports); - if (err) + if (err) { free_map(exports); return JB_ERR_MEMORY; @@ -968,8 +968,8 @@ jb_err cgi_show_status(struct client_state *csp, #else /* ndef FEATURE_STATISTICS */ err = err || map_block_killer(exports, "statistics"); #endif /* ndef FEATURE_STATISTICS */ - - /* + + /* * List all action files in use, together with view and edit links, * except for standard.action, which should only be viewable. (Not * enforced in the editor itself) @@ -1010,7 +1010,7 @@ jb_err cgi_show_status(struct client_state *csp, if (!err) err = string_append(&s, "\n"); } } - if (*s != '\0') + if (*s != '\0') { if (!err) err = map(exports, "actions-filenames", 1, s, 0); } @@ -1019,7 +1019,7 @@ jb_err cgi_show_status(struct client_state *csp, if (!err) err = map(exports, "actions-filenames", 1, "None specified", 1); } - /* + /* * List all re_filterfiles in use, together with view options. * FIXME: Shouldn't include hardwired HTML here, use line template instead! */ @@ -1036,7 +1036,7 @@ jb_err cgi_show_status(struct client_state *csp, if (!err) err = string_append(&s, "\n"); } } - if (*s != '\0') + if (*s != '\0') { if (!err) err = map(exports, "re-filter-filenames", 1, s, 0); } @@ -1076,7 +1076,7 @@ jb_err cgi_show_status(struct client_state *csp, return template_fill_for_cgi(csp, "show-status", exports, rsp); } - + /********************************************************************* * * Function : cgi_show_url_info @@ -1097,7 +1097,7 @@ jb_err cgi_show_status(struct client_state *csp, * the template. * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_show_url_info(struct client_state *csp, @@ -1215,7 +1215,7 @@ jb_err cgi_show_url_info(struct client_state *csp, struct http_request url_to_query[1]; struct current_action_spec action[1]; int i; - + if (map(exports, "url", 1, html_encode(url_param), 0)) { free(url_param); @@ -1503,7 +1503,7 @@ jb_err cgi_show_url_info(struct client_state *csp, * CGI Parameters : None * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ jb_err cgi_robots_txt(struct client_state *csp, @@ -1551,7 +1551,7 @@ jb_err cgi_robots_txt(struct client_state *csp, * 1 : exports = map to extend * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ static jb_err show_defines(struct map *exports) @@ -1801,7 +1801,7 @@ static char *show_rcs(void) * Default is to show menu and other information. * * Returns : JB_ERR_OK on success - * JB_ERR_MEMORY on out-of-memory error. + * JB_ERR_MEMORY on out-of-memory error. * *********************************************************************/ static jb_err cgi_show_file(struct client_state *csp, @@ -1895,7 +1895,7 @@ static jb_err cgi_show_file(struct client_state *csp, return JB_ERR_CGI_PARAMS; } - + /********************************************************************* * * Function : load_file diff --git a/cgisimple.h b/cgisimple.h index b7a98a07..f51d347a 100644 --- a/cgisimple.h +++ b/cgisimple.h @@ -1,24 +1,24 @@ #ifndef CGISIMPLE_H_INCLUDED #define CGISIMPLE_H_INCLUDED -#define CGISIMPLE_H_VERSION "$Id: cgisimple.h,v 1.16 2008/05/26 17:30:55 fabiankeil Exp $" +#define CGISIMPLE_H_VERSION "$Id: cgisimple.h,v 1.17 2009/05/16 13:27:20 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/cgisimple.h,v $ * * Purpose : Declares functions to intercept request, generate * html or gif answers, and to compose HTTP resonses. - * + * * Functions declared include: - * + * * * Copyright : Written by and Copyright (C) 2001-2007 the SourceForge * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at diff --git a/configure.in b/configure.in index 3f4693f4..d072ec2d 100644 --- a/configure.in +++ b/configure.in @@ -1,38 +1,38 @@ dnl Process this file with autoconf to produce a configure script. -dnl -dnl $Id: configure.in,v 1.158 2011/06/23 14:01:01 fabiankeil Exp $ -dnl +dnl +dnl $Id: configure.in,v 1.159 2011/07/03 17:53:00 fabiankeil Exp $ +dnl dnl Written by and Copyright (C) 2001-2010 the dnl Privoxy team. http://www.privoxy.org/ dnl dnl Based on the Internet Junkbuster originally written -dnl by and Copyright (C) 1997 Anonymous Coders and +dnl by and Copyright (C) 1997 Anonymous Coders and dnl Junkbusters Corporation. http://www.junkbusters.com dnl -dnl This program is free software; you can redistribute it +dnl This program is free software; you can redistribute it dnl and/or modify it under the terms of the GNU General dnl Public License as published by the Free Software dnl Foundation; either version 2 of the License, or (at dnl your option) any later version. -dnl +dnl dnl This program is distributed in the hope that it will dnl be useful, but WITHOUT ANY WARRANTY; without even the dnl implied warranty of MERCHANTABILITY or FITNESS FOR A dnl PARTICULAR PURPOSE. See the GNU General Public dnl License for more details. -dnl +dnl dnl The GNU General Public License should be included with dnl this file. If not, you can view it at dnl http://www.gnu.org/copyleft/gpl.html dnl or write to the Free Software Foundation, Inc., 59 dnl Temple Place - Suite 330, Boston, MA 02111-1307, USA. -dnl +dnl dnl ================================================================= dnl AutoConf Initialization dnl ================================================================= -AC_REVISION($Revision: 1.158 $) +AC_REVISION($Revision: 1.159 $) AC_INIT(jcc.c) if test ! -f config.h.in; then @@ -44,7 +44,7 @@ if test ! -f config.h.in; then else autoheader fi -fi +fi AC_CONFIG_HEADER([config.h]) AC_CANONICAL_HOST @@ -52,13 +52,13 @@ AC_CANONICAL_HOST dodk=auto DKPREFIX=none AC_ARG_WITH(docbook, dnl - --with-docbook=[[yes|no|directory]] - Enable docbook documentation creation + --with-docbook=[[yes|no|directory]] + Enable docbook documentation creation (default = yes, for gnu and linux),[dnl case "$with_docbook" in yes) dodk=yes;; no) dodk=no;; -*) +*) dodk=yes DKPREFIX=$withval ;; @@ -124,7 +124,7 @@ AC_SUBST(ID) AC_SUBST(BGROUPS) dnl ================================================================= -dnl debug, gcc and gdb support +dnl debug, gcc and gdb support dnl ================================================================= AC_ARG_WITH(debug, @@ -202,7 +202,7 @@ else AC_MSG_CHECKING([for group]) AC_ARG_WITH(group, [ --with-group=privoxy Set group for privoxy], - [ + [ if test "x$withval" != "xyes"; then if test $BGROUPS = no ; then AC_MSG_ERROR(There is no 'groups' program on this system) @@ -241,7 +241,7 @@ fi dnl ================================================================= dnl additional gcc flags dnl ================================================================= -dnl +dnl if test "$GCC"; then if test "$host" != "powerpc-unknown-amigaos"; then CFLAGS="-pipe $CFLAGS" @@ -259,7 +259,7 @@ dnl Reason: This sets CFLAGS in order to switch the Cygwin compiler dnl into Cygwin or MinGW32 modes. Depending on the mode selected, dnl the compiler will use completely different sets of library dnl and include files. -dnl +dnl dnl ================================================================= AC_MINGW32 @@ -323,7 +323,7 @@ if test $dodk != no; then fi if test $DB2HTML = false; then dnl We need to clean the variable, otherwise AC_CHECK_PROGS - dnl will fail + dnl will fail DB2HTML="" AC_CHECK_PROGS(DB2HTML,db2html docbook2html,false) fi @@ -429,7 +429,7 @@ AC_ARG_ENABLE(pthread, [if test $enableval = no; then # Disable pthreads if test $have_pthread = yes; then - AC_MSG_WARN([pthreads seem to be available but you are using --disable-pthread.]) + AC_MSG_WARN([pthreads seem to be available but you are using --disable-pthread.]) AC_MSG_WARN([This is almost always a mistake and can render Privoxy unacceptable slow.]) fi have_pthread=no @@ -647,10 +647,10 @@ AC_SUBST(SOCKET_LIB) dnl ================================================================= dnl Mac OSX specific dnl ================================================================= - + case "$host" in *-apple-darwin*) SPECIAL_CFLAGS="-Dunix" -;; +;; esac dnl ================================================================= @@ -773,7 +773,7 @@ AC_CHECK_LIB(pcre, pcre_compile, [ ], [have_pcre=no]) ]) ], [have_pcre=no]) - + AC_CHECK_LIB(pcreposix, regcomp, [ AC_CHECK_HEADER(pcreposix.h, [ AC_EGREP_HEADER(pcreposix_regerror, pcreposix.h, [AC_MSG_WARN([[pcreposix old version installed]]); have_pcreposix=no], [have_pcreposix=yes]) @@ -782,7 +782,7 @@ AC_CHECK_LIB(pcreposix, regcomp, [ AC_EGREP_HEADER(pcreposix_regerror, pcre/pcreposix.h, [AC_MSG_WARN([[pcreposix old version installed]]); have_pcreposix=no], [have_pcreposix=yes]; [AC_DEFINE(PCREPOSIX_H_IN_SUBDIR)]) ], [have_pcreposix=no]) ]) -], [have_pcreposix=no], -lpcre) +], [have_pcreposix=no], -lpcre) dnl ================================================================ dnl libpcrs is temporarily disabled. @@ -837,7 +837,7 @@ AC_ARG_ENABLE(ie-images, fi],) AC_ARG_ENABLE(image-blocking, -[ --disable-image-blocking Don't try to figure out whether a request is +[ --disable-image-blocking Don't try to figure out whether a request is for an image or HTML - assume HTML.], [if test $enableval = yes; then AC_DEFINE(FEATURE_IMAGE_BLOCKING) @@ -932,7 +932,7 @@ if test $enableval2 = yes; then AC_MSG_WARN([No zlib found. Privoxy will not be able to filter compressed content. This may become a fatal error in the future.]) - fi + fi fi AC_ARG_ENABLE(compression, diff --git a/cygwin.h b/cygwin.h index c9270999..9e84e827 100644 --- a/cygwin.h +++ b/cygwin.h @@ -1,6 +1,6 @@ #ifndef CYGWIN_H_INCLUDED #define CYGWIN_H_INCLUDED -#define CYGWIN_H_VERSION "$Id: cygwin.h,v 1.6 2006/07/18 14:48:45 david__schmidt Exp $" +#define CYGWIN_H_VERSION "$Id: cygwin.h,v 1.7 2009/05/16 13:27:20 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/cygwin.h,v $ @@ -13,10 +13,10 @@ * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at diff --git a/deanimate.c b/deanimate.c index 3ad4e2be..d583bc68 100644 --- a/deanimate.c +++ b/deanimate.c @@ -1,4 +1,4 @@ -const char deanimate_rcs[] = "$Id: deanimate.c,v 1.19 2008/05/21 15:29:35 fabiankeil Exp $"; +const char deanimate_rcs[] = "$Id: deanimate.c,v 1.20 2009/05/16 13:27:20 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/deanimate.c,v $ @@ -6,7 +6,7 @@ const char deanimate_rcs[] = "$Id: deanimate.c,v 1.19 2008/05/21 15:29:35 fabian * Purpose : Declares functions to manipulate binary images on the * fly. High-level functions include: * - Deanimation of GIF images - * + * * Functions declared include: gif_deanimate, buf_free, * buf_copy, buf_getbyte, gif_skip_data_block * and gif_extract_image @@ -19,7 +19,7 @@ const char deanimate_rcs[] = "$Id: deanimate.c,v 1.19 2008/05/21 15:29:35 fabian * and ideas from the Image::DeAnim Perl module by * Ken MacFarlane, * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -53,7 +53,7 @@ const char deanimate_rcs[] = "$Id: deanimate.c,v 1.19 2008/05/21 15:29:35 fabian const char deanimate_h_rcs[] = DEANIMATE_H_VERSION; /********************************************************************* - * + * * Function : buf_free * * Description : Safely frees a struct binbuffer @@ -79,7 +79,7 @@ void buf_free(struct binbuffer *buf) /********************************************************************* - * + * * Function : buf_extend * * Description : Ensure that a given binbuffer can hold a given amount @@ -90,7 +90,7 @@ void buf_free(struct binbuffer *buf) * Parameters : * 1 : buf = Pointer to the binbuffer * 2 : length = Desired minimum size - * + * * * Returns : 0 on success, 1 on failure. * @@ -121,7 +121,7 @@ static int buf_extend(struct binbuffer *buf, size_t length) /********************************************************************* - * + * * Function : buf_copy * * Description : Safely copies a given amount of bytes from one @@ -142,7 +142,7 @@ static int buf_copy(struct binbuffer *src, struct binbuffer *dst, size_t length) /* * Sanity check: Can't copy more data than we have */ - if (src->offset + length > src->size) + if (src->offset + length > src->size) { return 1; } @@ -150,7 +150,7 @@ static int buf_copy(struct binbuffer *src, struct binbuffer *dst, size_t length) /* * Ensure that dst can hold the new data */ - if (buf_extend(dst, length)) + if (buf_extend(dst, length)) { return 1; } @@ -169,7 +169,7 @@ static int buf_copy(struct binbuffer *src, struct binbuffer *dst, size_t length) /********************************************************************* - * + * * Function : buf_getbyte * * Description : Safely gets a byte from a given binbuffer at a @@ -197,7 +197,7 @@ static unsigned char buf_getbyte(const struct binbuffer *src, size_t offset) /********************************************************************* - * + * * Function : gif_skip_data_block * * Description : Safely advances the offset of a given struct binbuffer @@ -215,7 +215,7 @@ static int gif_skip_data_block(struct binbuffer *buf) { unsigned char c; - /* + /* * Data blocks are sequences of chunks, which are headed * by a one-byte length field, with the last chunk having * zero length. @@ -236,12 +236,12 @@ static int gif_skip_data_block(struct binbuffer *buf) /********************************************************************* - * + * * Function : gif_extract_image * * Description : Safely extracts an image data block from a given * struct binbuffer that contains a GIF image and whose - * offset is positioned at the start of a data block + * offset is positioned at the start of a data block * into a given destination binbuffer. * * Parameters : @@ -279,7 +279,7 @@ static int gif_extract_image(struct binbuffer *src, struct binbuffer *dst) if (buf_copy(src, dst, (size_t)map_length)) { return 1; - } + } } if (buf_copy(src, dst, 1)) return 1; @@ -304,7 +304,7 @@ static int gif_extract_image(struct binbuffer *src, struct binbuffer *dst) } /********************************************************************* - * + * * Function : gif_deanimate * * Description : Deanimate a given GIF image, i.e. given a GIF with @@ -336,9 +336,9 @@ int gif_deanimate(struct binbuffer *src, struct binbuffer *dst, int get_first_im c = buf_getbyte(src, 10); /* - * Check & copy GIF header + * Check & copy GIF header */ - if (strncmp(src->buffer, "GIF89a", 6) && strncmp(src->buffer, "GIF87a", 6)) + if (strncmp(src->buffer, "GIF89a", 6) && strncmp(src->buffer, "GIF87a", 6)) { return 1; } @@ -390,7 +390,7 @@ int gif_deanimate(struct binbuffer *src, struct binbuffer *dst, int get_first_im case 0x3b: goto write; - /* + /* * Image block: Extract to current image buffer. */ case 0x2c: @@ -450,13 +450,13 @@ int gif_deanimate(struct binbuffer *src, struct binbuffer *dst, int get_first_im */ default: goto failed; - + } } /* -END- while src */ /* * Either we got here by goto, or because the GIF is - * bogus and EOF was reached before an end-of-gif marker + * bogus and EOF was reached before an end-of-gif marker * was found. */ diff --git a/deanimate.h b/deanimate.h index b785cd33..c5f1cad5 100644 --- a/deanimate.h +++ b/deanimate.h @@ -1,6 +1,6 @@ #ifndef DEANIMATE_H_INCLUDED #define DEANIMATE_H_INCLUDED -#define DEANIMATE_H_VERSION "$Id: deanimate.h,v 1.12 2008/03/28 15:13:39 fabiankeil Exp $" +#define DEANIMATE_H_VERSION "$Id: deanimate.h,v 1.13 2009/05/16 13:27:20 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/deanimate.h,v $ @@ -8,9 +8,9 @@ * Purpose : Declares functions to manipulate binary images on the * fly. High-level functions include: * - Deanimation of GIF images - * + * * Functions declared include: gif_deanimate and buf_free. - * + * * * Copyright : Written by and Copyright (C) 2001 - 2004 by the the * SourceForge Privoxy team. http://www.privoxy.org/ @@ -19,10 +19,10 @@ * Ken MacFarlane, * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -64,7 +64,7 @@ struct binbuffer extern int gif_deanimate(struct binbuffer *src, struct binbuffer *dst, int get_first_image); extern void buf_free(struct binbuffer *buf); -/* +/* * Revision control strings from this header and associated .c file */ extern const char deanimate_rcs[]; diff --git a/doc/source/authors.sgml b/doc/source/authors.sgml index 3e7379db..1589d03d 100644 --- a/doc/source/authors.sgml +++ b/doc/source/authors.sgml @@ -2,29 +2,29 @@ File : $Source: /cvsroot/ijbswa/current/doc/source/authors.sgml,v $ Purpose : AUTHORS file for Privoxy - - $Id: authors.sgml,v 2.17 2010/11/06 12:55:48 fabiankeil Exp $ - + $Id: authors.sgml,v 2.18 2011/08/17 10:40:07 fabiankeil Exp $ + + Copyright (C) 2001-2009 Privoxy Developers http://www.privoxy.org/ See LICENSE. ======================================================================== - NOTE: Please read developer-manual/documentation.html before touching + NOTE: Please read developer-manual/documentation.html before touching anything in this, or other Privoxy documentation. You have been warned! - Failure to abide by this rule will result in the revocation of your license + Failure to abide by this rule will result in the revocation of your license to live a peaceful existence! ======================================================================== =================================================================== - READ: Document Note: This file generates the AUTHORS file in the + READ: Document Note: This file generates the AUTHORS file in the top level source directory. See p-authors.sgml for list of developers and contributors, etc. They were split from here for use in man page. =================================================================== --> + diff --git a/doc/source/buildsource.sgml b/doc/source/buildsource.sgml index f7ac862d..afc2c6b9 100644 --- a/doc/source/buildsource.sgml +++ b/doc/source/buildsource.sgml @@ -2,8 +2,8 @@ File : $Source: /cvsroot/ijbswa/current/doc/source/buildsource.sgml,v $ Purpose : Entity included in other project documents. - - $Id: buildsource.sgml,v 2.17 2009/02/21 13:27:58 hal9 Exp $ + + $Id: buildsource.sgml,v 2.18 2009/02/23 09:03:12 fabiankeil Exp $ Copyright (C) 2001-2009 Privoxy Developers http://www.privoxy.org/ See LICENSE. @@ -12,7 +12,7 @@ This file used for inclusion with other documents only. ====================================================================== - If you make changes to this file, please verify the finished + If you make changes to this file, please verify the finished docs all display as intended. This file is included into: @@ -22,7 +22,7 @@ --> - To build Privoxy from source, + To build Privoxy from source, autoconf, GNU make @@ -32,12 +32,12 @@ When building from a source tarball, - first unpack the source: + tarball), +--> first unpack the source: @@ -63,7 +63,7 @@ - This will create a directory named current/, which will + This will create a directory named current/, which will contain the source tree. @@ -81,7 +81,7 @@ and group just for this purpose. See your local documentation for the correct command line to do add new users and groups (something like adduser, but the command syntax may vary from platform - to platform). + to platform). @@ -113,7 +113,7 @@ autoheader autoconf ./configure # (--help to see options) - make # (the make from GNU, sometimes called gmake) + make # (the make from GNU, sometimes called gmake) su # Possibly required make -n install # (to see where all the files will go) make -s install # (to really install, -s to silence output) @@ -135,14 +135,14 @@ - To build an executable with security enhanced features so that + To build an executable with security enhanced features so that users cannot easily bypass the proxy (e.g. Go There Anyway), or alter their own configurations, configure like this: ./configure --disable-toggle --disable-editor --disable-force - + Then build as above. In Privoxy 3.0.7 and later, all of these options can also be disabled through the configuration file. @@ -177,9 +177,9 @@ can also be disabled through the configuration file. - The default installation path for make install is - /usr/local. This may of course be customized with - the various ./configure path options. If you are doing + The default installation path for make install is + /usr/local. This may of course be customized with + the various ./configure path options. If you are doing an install to anywhere besides /usr/local, be sure to set the appropriate paths with the correct configure options (./configure --help). Non-privileged users must of course @@ -209,15 +209,15 @@ can also be disabled through the configuration file. localstatedir (ie: var/) will default to /var instead of $prefix/var so the logs will go to /var/log/privoxy/, and the pid file - will be created in /var/run/privoxy.pid. + will be created in /var/run/privoxy.pid. - make install will attempt to set the correct values - in config (main configuration file). You should + make install will attempt to set the correct values + in config (main configuration file). You should check this to make sure all values are correct. If appropriate, - an init script will be installed, but it is up to the user to determine - how and where to start Privoxy. The init + an init script will be installed, but it is up to the user to determine + how and where to start Privoxy. The init script should be checked for correct paths and values, if anything other than a default install is done. @@ -248,9 +248,9 @@ can also be disabled through the configuration file. - The simplest command line to start Privoxy is - $path/privoxy --user=privoxy $path/etc/privoxy/config. - See privoxy --usage, or the man page, for other options, + The simplest command line to start Privoxy is + $path/privoxy --user=privoxy $path/etc/privoxy/config. + See privoxy --usage, or the man page, for other options, and configuration. ]]> diff --git a/doc/source/config.sgml b/doc/source/config.sgml index 34e8e876..adf9be6c 100644 --- a/doc/source/config.sgml +++ b/doc/source/config.sgml @@ -1,5 +1,5 @@ + @@ -12,19 +12,19 @@ File : $Source: /cvsroot/ijbswa/current/doc/source/config.sgml,v $ Purpose : config file generation - - $Id: config.sgml,v 2.18 2010/11/06 12:55:48 fabiankeil Exp $ + + $Id: config.sgml,v 2.19 2011/08/17 10:40:07 fabiankeil Exp $ Copyright (C) 2001-2009 Privoxy Developers http://www.privoxy.org/ See LICENSE. ======================================================================== - NOTE: Please read developer-manual/documentation.html before touching - anything in this, or other Privoxy documentation. + NOTE: Please read developer-manual/documentation.html before touching + anything in this, or other Privoxy documentation. ======================================================================== - This file is used to generate the main Privoxy config file. It is mostly - content included from p-config.sgml (where all the data is). See that + This file is used to generate the main Privoxy config file. It is mostly + content included from p-config.sgml (where all the data is). See that file for more comments. --> diff --git a/doc/source/contacting.sgml b/doc/source/contacting.sgml index 50109f30..70a8c152 100644 --- a/doc/source/contacting.sgml +++ b/doc/source/contacting.sgml @@ -2,8 +2,8 @@ File : $Source: /cvsroot/ijbswa/current/doc/source/contacting.sgml,v $ Purpose : Entity included in other project documents. - - $Id: contacting.sgml,v 2.24 2011/05/03 10:13:21 fabiankeil Exp $ + + $Id: contacting.sgml,v 2.25 2011/08/18 11:42:50 fabiankeil Exp $ Copyright (C) 2001-2011 Privoxy Developers http://www.privoxy.org/ See LICENSE. @@ -29,13 +29,13 @@ We value your feedback. In fact, we rely on it to improve Privoxy and its configuration. - However, please note the following hints, so we can + However, please note the following hints, so we can provide you with the best support: Get Support - For casual users, our + For casual users, our support forum at SourceForge is probably best suited: http://sourceforge.net/tracker/?group_id=11118&atid=211118 @@ -86,30 +86,30 @@ - Configuration issues, such as ads that slip through, or sites that - don't function properly due to one Privoxy + Configuration issues, such as ads that slip through, or sites that + don't function properly due to one Privoxy action or another being turned on. - + - Bugs in the programming code that makes up + Bugs in the programming code that makes up Privoxy, such as that might cause a crash. - + Reporting Ads or Other Configuration Problems Please send feedback on ads that slipped through, innocent images that were - blocked, sites that don't work properly, and other configuration related problem of - default.action file, to + blocked, sites that don't work properly, and other configuration related problem of + default.action file, to http://sourceforge.net/tracker/?group_id=11118&atid=460288, the Actions File Tracker. - + New, improved default.action files may occasionally be made @@ -124,15 +124,15 @@ Reporting Bugs - Please report all bugs through our bug tracker: - http://sourceforge.net/tracker/?group_id=11118&atid=111118. + Please report all bugs through our bug tracker: + http://sourceforge.net/tracker/?group_id=11118&atid=111118. Before doing so, please make sure that the bug has not already been submitted and observe the additional hints at the top of the submit - form. If already submitted, please feel free to add any info to the + form. If already submitted, please feel free to add any info to the original report that might help to solve the issue. @@ -170,7 +170,7 @@ Please be sure to provide the following information: (if you got the source from CVS, please also provide the source code revisions as shown in http://config.privoxy.org/show-version). - + @@ -180,11 +180,11 @@ Please be sure to provide the following information: sending the output of uname -a should do, in case of GNU/Linux, please also name the distribution. - + - The name, platform, and version of the browser + The name, platform, and version of the browser you were using (e.g. Internet Explorer v5.5 for Mac). @@ -192,9 +192,9 @@ Please be sure to provide the following information: The URL where the problem occurred, or some way for us to duplicate the - problem (e.g. http://somesite.example.com/?somethingelse=123). + problem (e.g. http://somesite.example.com/?somethingelse=123). - + @@ -202,22 +202,22 @@ Please be sure to provide the following information: by the Privoxy developers via SourceForge, or if you got your copy somewhere else. - + - Whether you are using Privoxy in tandem with + Whether you are using Privoxy in tandem with another proxy such as Tor. If so, please temporary disable the other proxy to see if the symptoms change. - + - Whether you are using a personal firewall product. If so, does + Whether you are using a personal firewall product. If so, does Privoxy work without it? - + @@ -246,7 +246,7 @@ debug 8192 # Non-fatal errors submit any logfiles you didn't read first. You can mask sensitive information as long as it's clear that you removed something. - + @@ -273,8 +273,8 @@ debug 8192 # Non-fatal errors The appendix - of the Privoxy User Manual also has helpful information - on understanding actions, and action debugging. + of the Privoxy User Manual also has helpful information + on understanding actions, and action debugging. diff --git a/doc/source/copyright.sgml b/doc/source/copyright.sgml index 42a373bf..de128d2a 100644 --- a/doc/source/copyright.sgml +++ b/doc/source/copyright.sgml @@ -2,8 +2,8 @@ File : $Source: /cvsroot/ijbswa/current/doc/source/copyright.sgml,v $ Purpose : Entity included in other project documents. - - $Id: copyright.sgml,v 2.12 2011/03/27 13:50:38 fabiankeil Exp $ + + $Id: copyright.sgml,v 2.13 2011/08/18 11:42:50 fabiankeil Exp $ Copyright (C) 2001-2011 Privoxy Developers http://www.privoxy.org/ See LICENSE. @@ -12,7 +12,7 @@ This file used for inclusion with other documents only. ====================================================================== - If you make changes to this file, please verify the finished + If you make changes to this file, please verify the finished docs all display as intended. This file is included into: @@ -23,8 +23,8 @@ faq ************************************************************** - NOTE: the &my-copy entity must be defined in any file that will - include this file. (This is a workaround for docbook2man not + NOTE: the &my-copy entity must be defined in any file that will + include this file. (This is a workaround for docbook2man not handling the standard © entity in the man page processing.) ************************************************************** diff --git a/doc/source/developer-manual.sgml b/doc/source/developer-manual.sgml index c5723955..c805d541 100644 --- a/doc/source/developer-manual.sgml +++ b/doc/source/developer-manual.sgml @@ -1,5 +1,5 @@ + @@ -23,16 +23,16 @@ Purpose : developer manual This file belongs into ijbswa.sourceforge.net:/home/groups/i/ij/ijbswa/htdocs/ - - $Id: developer-manual.sgml,v 2.34 2010/11/06 12:55:48 fabiankeil Exp $ + + $Id: developer-manual.sgml,v 2.35 2011/08/17 10:40:07 fabiankeil Exp $ Copyright (C) 2001-2009 Privoxy Developers http://www.privoxy.org/ See LICENSE. ======================================================================== - NOTE: Please read developer-manual/documentation.html before touching + NOTE: Please read developer-manual/documentation.html before touching anything in this, or other Privoxy documentation. You have been warned! - Failure to abide by this rule will result in the revocation of your license + Failure to abide by this rule will result in the revocation of your license to live a peaceful existence! ======================================================================== @@ -45,24 +45,24 @@ - Copyright &my-copy; 2001-2009 by + Copyright &my-copy; 2001-2009 by Privoxy Developers - $Id: developer-manual.sgml,v 2.34 2010/11/06 12:55:48 fabiankeil Exp $ + $Id: developer-manual.sgml,v 2.35 2011/08/17 10:40:07 fabiankeil Exp $ @@ -118,16 +118,16 @@ Hal. I don't like seeing blank space :) So added *something* here. - --> + --> Privoxy, as an heir to - Junkbuster, is a Free Software project + Junkbuster, is a Free Software project and the code is licensed under the GNU General Public License version 2. As such, Privoxy development is potentially open to anyone who has the time, knowledge, and desire to contribute in any capacity. Our goals are simply to continue the mission, to improve Privoxy, and - to make it available to as wide an audience as possible. + to make it available to as wide an audience as possible. One does not have to be a programmer to contribute. Packaging, testing, @@ -139,19 +139,19 @@ Hal. The first step is to join the developer's mailing list. - You can submit your ideas, or even better patches. Patches are best - submitted to the Sourceforge tracker set up for this purpose, but + You can submit your ideas, or even better patches. Patches are best + submitted to the Sourceforge tracker set up for this purpose, but can be sent to the list for review too. - You will also need to have a cvs package installed, which will + You will also need to have a cvs package installed, which will entail having ssh installed as well (which seems to be a requirement of SourceForge), in order to access the cvs repository. Having the GNU build tools is also going to be important (particularly, autoconf and gmake). - For the time being (read, this section is under construction), you can - also refer to the extensive comments in the source code. In fact, + For the time being (read, this section is under construction), you can + also refer to the extensive comments in the source code. In fact, reading the code is recommended in any case. @@ -161,7 +161,7 @@ Hal. The CVS Repository If you become part of the active development team, you will eventually - need write access to our holy grail, the CVS repository. One of the + need write access to our holy grail, the CVS repository. One of the team members will need to set this up for you. Please read this chapter completely before accessing via CVS. @@ -206,21 +206,21 @@ Hal. At one time there were two distinct branches: stable and unstable. The - more drastic changes were to be in the unstable branch. These branches - have now been merged to minimize time and effort of maintaining two + more drastic changes were to be in the unstable branch. These branches + have now been merged to minimize time and effort of maintaining two branches. - + --> CVS Commit Guidelines @@ -231,16 +231,16 @@ Hal. main development trunk, and we ask anyone with CVS access to strictly adhere to the following guidelines: - + Basic Guidelines, for all branches: - Please don't commit even + Please don't commit even a small change without testing it thoroughly first. When we're - close to a public release, ask a fellow developer to review your + close to a public release, ask a fellow developer to review your changes. @@ -269,18 +269,18 @@ Hal. url="http://sourceforge.net/tracker/?atid=311118&group_id=11118&func=browse">patch tracker instead. - + - + - + Documentation Guidelines All formal documents are maintained in Docbook SGML and located in the doc/source/* directory. You will need - Docbook, the Docbook + Docbook, the Docbook DTD's and the Docbook modular stylesheets (or comparable alternatives), and either jade or openjade (recommended) installed in order to @@ -337,20 +337,20 @@ Hal. privoxy.1 (man page), and config files are also now maintained as Docbook SGML. These files, when built, in the top-level source directory are - generated files! Also, the Privoxy index.html (and a - variation on this file, privoxy-index.html, + generated files! Also, the Privoxy index.html (and a + variation on this file, privoxy-index.html, meant for inclusion with doc packages), are maintained as SGML as well. DO NOT edit these directly. Edit the SGML source, or contact someone involved in the documentation. - + config requires some special handling. The reason it is maintained this way is so that the extensive comments in the file - mirror those in user-manual. But the conversion - process requires going from SGML to HTML to text to special formatting + mirror those in user-manual. But the conversion + process requires going from SGML to HTML to text to special formatting required for the embedded comments. Some of this does not survive so well. Especially some of the examples that are longer than 80 characters. - The build process for this file outputs to config.new, + The build process for this file outputs to config.new, which should be reviewed for errors and mis-formatting. Once satisfied that it is correct, then it should be hand copied to config. @@ -362,8 +362,8 @@ Hal. Packagers are encouraged to include this documentation. For those without the ability to build the docs locally, text versions of each are kept in - CVS. HTML versions are also being kept in CVS under - doc/webserver/*. And PDF version are kept in + CVS. HTML versions are also being kept in CVS under + doc/webserver/*. And PDF version are kept in doc/pdf/*. @@ -381,7 +381,7 @@ Hal. How do you update the webserver (i.e. the pages on privoxy.org)? - + First, build the docs by running make @@ -399,7 +399,7 @@ Hal. Finished docs should be occasionally submitted to CVS - (doc/webserver/*/*.html) so that those without + (doc/webserver/*/*.html) so that those without the ability to build them locally, have access to them if needed. This is especially important just prior to a new release! Please do this after the $VERSION and @@ -411,14 +411,14 @@ Hal. Quickstart to Docbook and SGML - If you are not familiar with SGML, it is a markup language similar to HTML. - Actually, not a mark up language per se, but a language used to define + If you are not familiar with SGML, it is a markup language similar to HTML. + Actually, not a mark up language per se, but a language used to define markup languages. In fact, HTML is an SGML application. Both will use tags to format text and other content. SGML tags can be much more varied, and flexible, but do much of the same kinds of things. The tags, or elements, are definable in SGML. There is no set standards. Since we are using - Docbook, our tags are those that are defined by + Docbook, our tags are those that are defined by Docbook. Much of how the finish document is rendered is determined by the stylesheets. The stylesheets determine how each tag gets translated to HTML, or other @@ -435,26 +435,26 @@ Hal. Our documents use sections for the most part. Sections - will be processed into HTML headers (e.g. h1 for + will be processed into HTML headers (e.g. h1 for sect1). The Docbook stylesheets - will use these to also generate the Table of Contents for each doc. Our - TOC's are set to a depth of three. Meaning sect1, - sect2, and sect3 will have TOC - entries, but sect4 will not. Each section requires - a <title> element, and at least one - <para>. There is a limit of five section - levels in Docbook, but generally three should be sufficient for our + will use these to also generate the Table of Contents for each doc. Our + TOC's are set to a depth of three. Meaning sect1, + sect2, and sect3 will have TOC + entries, but sect4 will not. Each section requires + a <title> element, and at least one + <para>. There is a limit of five section + levels in Docbook, but generally three should be sufficient for our purposes. - Some common elements that you likely will use: + Some common elements that you likely will use: - <para></para>, paragraph delimiter. Most + <para></para>, paragraph delimiter. Most text needs to be within paragraph elements (there are some exceptions). @@ -468,7 +468,7 @@ Hal. <command></command>, command examples. - <literallayout></literallayout>, like + <literallayout></literallayout>, like <pre>, more or less. @@ -478,15 +478,15 @@ Hal. <listitem></listitem>, member of the above. - <screen></screen>, screen output, implies + <screen></screen>, screen output, implies <literallayout>. - <ulink url="example.com"></ulink>, like + <ulink url="example.com"></ulink>, like HTML <a> tag. - <quote></quote>, for, doh, quoting text. + <quote></quote>, for, doh, quoting text. @@ -506,8 +506,8 @@ Hal. <application>Privoxy</application> Documentation Style - It will be easier if everyone follows a similar writing style. This - just makes it easier to read what someone else has written if it + It will be easier if everyone follows a similar writing style. This + just makes it easier to read what someone else has written if it is all done in a similar fashion. @@ -519,7 +519,7 @@ Hal. All tags should be lower case. - + Tags delimiting a block of text (even small @@ -534,11 +534,11 @@ Hal. Just to <emphasis>emphasize</emphasis>, some text goes here. - + Tags should be nested and step indented for block text like: (except - in-line tags) + in-line tags) <para> <itemizedlist> @@ -552,48 +552,48 @@ Hal. This makes it easier to find the text amongst the tags ;-) - + - Use white space to separate logical divisions within a document, - like between sections. Running everything together consistently + Use white space to separate logical divisions within a document, + like between sections. Running everything together consistently makes it harder to read and work on. - + - Do not hesitate to make comments. Comments can either use the - <comment> element, or the <!-- --> style comment - familiar from HTML. (Note in Docbook v4.x <comment> is + Do not hesitate to make comments. Comments can either use the + <comment> element, or the <!-- --> style comment + familiar from HTML. (Note in Docbook v4.x <comment> is replaced by <remark>.) - + - We have an international audience. Refrain from slang, or English - idiosyncrasies (too many to list :). Humor also does not translate + We have an international audience. Refrain from slang, or English + idiosyncrasies (too many to list :). Humor also does not translate well sometimes. - + Try to keep overall line lengths in source files to 80 characters or less for obvious reasons. This is not always possible, with lengthy URLs for instance. - + - Our documents are available in differing formats. Right now, they - are just plain text, HTML, and PDF, but others are always a - future possibility. Be careful with URLs (<ulink>), and avoid + Our documents are available in differing formats. Right now, they + are just plain text, HTML, and PDF, but others are always a + future possibility. Be careful with URLs (<ulink>), and avoid this mistake: My favorite site is <ulink url="http://example.com">here</ulink>. - This will render as My favorite site is here, which is + This will render as My favorite site is here, which is not real helpful in a text doc. Better like this: @@ -607,37 +607,37 @@ Hal. -H option. (ispell I think too.) - + - - + + - + Privoxy Custom Entities - Privoxy documentation is using - a number of customized entities to facilitate - documentation maintenance. + Privoxy documentation is using + a number of customized entities to facilitate + documentation maintenance. We are using a set of boilerplate files with generic text, that is used by multiple docs. This way we can write something once, and use it repeatedly without having to re-write the same content over and over again. If editing such a file, keep in mind that it should be - generic. That is the purpose; so it can be used in varying + generic. That is the purpose; so it can be used in varying contexts without additional modifications. - We are also using what Docbook calls - internal entities. These are like variables in + We are also using what Docbook calls + internal entities. These are like variables in programming. Well, sort of. For instance, we have the - p-version entity that contains the current - Privoxy version string. You are strongly - encouraged to use these where possible. Some of these obviously + p-version entity that contains the current + Privoxy version string. You are strongly + encouraged to use these where possible. Some of these obviously require re-setting with each release (done by the Makefile). A sampling of custom entities are listed below. See any of the main docs for examples. @@ -653,28 +653,28 @@ Hal. In this example, the contents of the file, - supported.sgml is available for inclusion anywhere - in the doc. To make this happen, just reference the now defined - entity: &supported; (starts with an ampersand - and ends with a semi-colon), and the contents will be dumped into + supported.sgml is available for inclusion anywhere + in the doc. To make this happen, just reference the now defined + entity: &supported; (starts with an ampersand + and ends with a semi-colon), and the contents will be dumped into the finished doc at that point. - + Commonly used internal entities: - p-version: the Privoxy + p-version: the Privoxy version string, e.g. &p-version;. - p-status: the project status, either + p-status: the project status, either alpha, beta, or stable. - p-not-stable: use to conditionally include + p-not-stable: use to conditionally include text in not stable releases (e.g. beta). @@ -684,16 +684,16 @@ Hal. p-text: this doc is only generated as text. - + - + - There are others in various places that are defined for a specific + There are others in various places that are defined for a specific purpose. Read the source! - + - + @@ -718,7 +718,7 @@ Hal. Using Comments - + Comment, Comment, Comment @@ -757,7 +757,7 @@ is actually being done. - + Use blocks for comments @@ -798,9 +798,9 @@ if ( this_variable == that_variable ) /* this may not either */ wish to "disrupt" the flow of the code, feel free to use a 1 line comment which is NOT on the same line as the code. - + - + Keep Comments on their own line @@ -853,7 +853,7 @@ short do_something_very_important( } /* -END- do_something_very_important */ - + Comment each logical step @@ -871,9 +871,9 @@ short do_something_very_important( comment. After all, these are usually major logic containers. - + - + Comment All Functions Thoroughly @@ -892,9 +892,9 @@ short do_something_very_important( functions should contain the information presented in the addendum section of this document. - + - + Comment at the end of braces if the content is more than one screen length @@ -930,12 +930,12 @@ if ( 1 == X ) } /* -END- if ( 1 == X ) */ - + Naming Conventions - + Variable Names @@ -960,9 +960,9 @@ int msiis5hack = 0; int msIis5Hack = 0; - - + + Function Names @@ -988,9 +988,9 @@ int loadSomeFile( struct client_state *csp ) - + - + Header file prototypes @@ -1007,15 +1007,15 @@ int loadSomeFile( struct client_state *csp ) Instead of: -(.h) extern int load_aclfile( struct client_state * ); or -(.h) extern int load_aclfile(); +(.h) extern int load_aclfile( struct client_state * ); or +(.h) extern int load_aclfile(); (.c) int load_aclfile( struct client_state *csp ) - + - + Enumerations, and #defines @@ -1043,7 +1043,7 @@ int loadSomeFile( struct client_state *csp ) #endif /* def FEATURE_FORCE */ - + Constants @@ -1065,23 +1065,23 @@ int loadSomeFile( struct client_state *csp ) -#define USE_IMG_LST 1 or +#define USE_IMG_LST 1 or #define _USE_IMAGE_LIST 1 or -#define USE_IMAGE_LIST_ 1 or +#define USE_IMAGE_LIST_ 1 or #define use_image_list 1 or #define UseImageList 1 - + - + Using Space - + Put braces on a line by themselves. @@ -1127,7 +1127,7 @@ while ( more lines are read ) } - + ALL control statements should have a block @@ -1160,9 +1160,9 @@ if ( this == that ) "feature". The "explanation" and "exception" from the point above also applies. - + - + Do not belabor/blow-up boolean expressions @@ -1181,9 +1181,9 @@ structure->flag = ( condition ); to the project has at least a "good" knowledge of C/C++. (Hope I do not offend by that last comment ... 8-) - + - + Use white space freely because it is free @@ -1205,7 +1205,7 @@ if ( this_variable == this_variable ) first_value = old_value + ( ( some_value - another_value ) - whatever ) - + Don't use white space around structure operators @@ -1229,9 +1229,9 @@ function_name(); Instead of: a_struct -> a_member; a_struct . a_member; function_name (); - + - + Make the last brace of a function stand out @@ -1267,9 +1267,9 @@ int function2( ... ) Status: developer-discretion on the number of blank lines. Enforced is the end of function comments. - + - + Use 3 character indentions @@ -1306,11 +1306,11 @@ int function1( ... ) - + Initializing - + Initialize all variables @@ -1337,11 +1337,11 @@ struct *ptr = NULL; - + Functions - + Name functions that return a boolean as a question. @@ -1358,7 +1358,7 @@ contains_an_image(); is_web_page_blank(); - + Always specify a return type for a function. @@ -1370,9 +1370,9 @@ is_web_page_blank(); purpose, and create a void return type if the function does not need to return anything. - + - + Minimize function calls when iterating by using variables @@ -1416,9 +1416,9 @@ for ( size_t cnt = 0; cnt < len; cnt++ ) *may* change or could *potentially* change, then you must code the function call in the for/while loop. - + - + Pass and Return by Const Reference @@ -1437,9 +1437,9 @@ for ( size_t cnt = 0; cnt < len; cnt++ ) Both these pointers are *const*! If the c runtime library maintainers do it, we should too. - + - + Pass and Return by Value @@ -1453,9 +1453,9 @@ for ( size_t cnt = 0; cnt < len; cnt++ ) prototypes with "pass by value": int load_aclfile( struct client_state *csp ) - + - + Names of include files @@ -1478,7 +1478,7 @@ for ( size_t cnt = 0; cnt < len; cnt++ ) -/* This is not a local include, but requires a path element. */ +/* This is not a local include, but requires a path element. */ #include <sys/fileName.h> @@ -1487,9 +1487,9 @@ for ( size_t cnt = 0; cnt < len; cnt++ ) without a _very_ good reason. This duplicates the #include "file.h" behavior. - + - + Provide multiple inclusion protection @@ -1512,7 +1512,7 @@ for ( size_t cnt = 0; cnt < len; cnt++ ) #endif /* ndef PROJECT_H_INCLUDED */ - + Use `extern "C"` when appropriate @@ -1536,7 +1536,7 @@ extern "C" #endif /* def __cplusplus */ - + Where Possible, Use Forward Struct Declaration Instead of Includes @@ -1562,13 +1562,13 @@ extern file_list *xyz; Status: Use with discretion. - + General Coding Practices - + Turn on warnings @@ -1578,9 +1578,9 @@ extern file_list *xyz; should turn on as many as possible. With GCC, the switch is "-Wall". Try and fix as many warnings as possible. - + - + Provide a default case for all switch statements @@ -1623,9 +1623,9 @@ switch( hash_string( cmd ) ) Status: Programmer discretion is advised. - + - + Try to avoid falling through cases in a switch statement. @@ -1648,9 +1648,9 @@ switch( hash_string( cmd ) ) the fact of the fall through and reason why you felt it was necessary. - + - + Use 'long' or 'short' Instead of 'int' @@ -1666,9 +1666,9 @@ switch( hash_string( cmd ) ) now). Should we add these to IJB now that we have a "configure" script? - + - + Don't mix size_t and other types @@ -1680,9 +1680,9 @@ switch( hash_string( cmd ) ) variable of a different type (or even against a constant) without casting one of the values. - + - + Declare each variable and struct on its own line. @@ -1715,9 +1715,9 @@ long c = 0; Status: developer-discretion. - + - + Use malloc/zalloc sparingly @@ -1735,7 +1735,7 @@ If a function creates a struct and stores a pointer to it in a list, then it should definitely be allocated via `malloc'. - + The Programmer Who Uses 'malloc' is Responsible for Ensuring 'free' @@ -1765,9 +1765,9 @@ static void unload_re_filterfile( void *f ) { ... } standard is for allocating and freeing data structures (complex or nested). - + - + Add loaders to the `file_list' structure and in order @@ -1783,9 +1783,9 @@ static void unload_re_filterfile( void *f ) { ... } POPUPs can also be referred to as KILLPOPUPs, it is clear that it should come first. - + - + "Uncertain" new code and/or changes to existing code, use FIXME or XXX @@ -1815,7 +1815,7 @@ static void unload_re_filterfile( void *f ) { ... } include in the project (or conversely exclude from the project). - + @@ -1850,7 +1850,7 @@ const char FILENAME_rcs[] = "$Id$"; * The GNU General Public License should be included with * this file. If not, you can view it at * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html - * or write to the Free Software Foundation, Inc., + * or write to the Free Software Foundation, Inc., * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 , * USA * @@ -1904,7 +1904,7 @@ const char FILENAME_h_rcs[] = FILENAME_H_VERSION; * The GNU General Public License should be included with * this file. If not, you can view it at * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html - * or write to the Free Software Foundation, Inc., + * or write to the Free Software Foundation, Inc., * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 , * USA * @@ -2011,7 +2011,7 @@ Install the rpm. Any error messages? Please submit test reports only with the test form at sourceforge. Three simple steps: - + Select category: the distribution you test on. Select group: the version of Privoxy that we are about to release. Fill the Summary and Detailed Description with something @@ -2021,7 +2021,7 @@ at sourceforge. Three simple steps: Do not mail to the mailing list (we cannot keep track on issues there). - + @@ -2049,7 +2049,7 @@ at sourceforge. Three simple steps: Version numbers - First you need to determine which version number the release will have. + First you need to determine which version number the release will have. Privoxy version numbers consist of three numbers, separated by dots, like in X.Y.Z (e.g. 3.0.0), where: @@ -2057,7 +2057,7 @@ at sourceforge. Three simple steps: X, the version major, is rarely ever changed. It is increased by one if turning a development branch into stable substantially changes the functionality, - user interface or configuration syntax. Majors 1 and 2 were + user interface or configuration syntax. Majors 1 and 2 were Junkbuster, and 3 will be the first stable Privoxy release. @@ -2081,7 +2081,7 @@ at sourceforge. Three simple steps: Z, the point or sub version, represents a release of the software within a branch. - It is therefore incremented immediately before each code freeze. + It is therefore incremented immediately before each code freeze. In development branches, only the even point versions correspond to actual releases, while the odd ones denote the evolving state of the sources on CVS in between. It follows that Z is odd on CVS in development branches most of the time. There, it gets @@ -2094,11 +2094,11 @@ at sourceforge. Three simple steps: Stable branches work a little differently, since there should be little to no development happening in such branches. Remember, only bugfixes, which presumably should have had some testing - before being committed. Stable branches will then have their - version reported as 0.0.0, during that period - between releases when changes are being added. This is to denote - that this code is not for release. Then - as the release nears, the version is bumped according: e.g. + before being committed. Stable branches will then have their + version reported as 0.0.0, during that period + between releases when changes are being added. This is to denote + that this code is not for release. Then + as the release nears, the version is bumped according: e.g. 3.0.1 -> 0.0.0 -> 3.0.2. @@ -2120,16 +2120,16 @@ at sourceforge. Three simple steps: before committing to a stable branch! - Developers should remember too that if they commit a bugfix to the stable - branch, this will more than likely require a separate submission to the - main trunk, since these are separate development trees within CVS. If you + Developers should remember too that if they commit a bugfix to the stable + branch, this will more than likely require a separate submission to the + main trunk, since these are separate development trees within CVS. If you are working on both, then this would require at least two separate check outs (i.e main trunk, and the stable release branch, which is v_3_0_branch at the moment). - + Before the Release: Freeze @@ -2145,26 +2145,26 @@ at sourceforge. Three simple steps: they have pending changes/fixes in their pipelines. Announce the freeze so that nobody will interfere with last minute changes. - + Increment the version number (point from odd to even in development - branches!) in configure.in. (RPM spec files + branches!) in configure.in. (RPM spec files will need to be incremented as well.) - + If default.action has changed since last release (i.e. software release or standalone actions file release), bump up its version info to A.B in this line: - + {+add-header{X-Actions-File-Version: A.B} -filter -no-popups} - + Then change the version info in doc/webserver/actions/index.php, line: '$required_actions_file_version = "A.B";' @@ -2172,36 +2172,36 @@ at sourceforge. Three simple steps: All documentation should be rebuild after the version bump. - Finished docs should be then be committed to CVS (for those - without the ability to build these). Some docs may require + Finished docs should be then be committed to CVS (for those + without the ability to build these). Some docs may require rather obscure processing tools. config, the man page (and the html version of the man page), and the PDF docs fall in this category. REAMDE, the man page, AUTHORS, and config - should all also be committed to CVS for other packagers. The + should all also be committed to CVS for other packagers. The formal docs should be uploaded to the webserver. See the Section "Updating the webserver" in this manual for details. - + - The User Manual is also used for context + The User Manual is also used for context sensitive help for the CGI editor. This is version sensitive, so that - the user will get appropriate help for his/her release. So with + the user will get appropriate help for his/her release. So with each release a fresh version should be uploaded to the webserver (this is in addition to the main User Manual - link from the main page since we need to keep manuals for various - versions available). The CGI pages will link to something like + link from the main page since we need to keep manuals for various + versions available). The CGI pages will link to something like http://privoxy.org/$(VERSION)/user-manual/. This will need to be updated for each new release. There is no Makefile target for this at this time!!! It needs to be done manually. - + All developers should look at the ChangeLog and make sure noteworthy changes are referenced. - + Commit all files that were changed in the above steps! @@ -2213,14 +2213,14 @@ at sourceforge. Three simple steps: cvs tag v_X_Y_Z. Don't use vX_Y_Z, ver_X_Y_Z, v_X.Y.Z (won't work) etc. - + If the release was in a development branch, increase the point version from even to odd (X.Y.(Z+1)) again in configure.in and commit your change. - + On the webserver, copy the user manual to a new top-level directory @@ -2228,27 +2228,27 @@ at sourceforge. Three simple steps: pages, which have the version as a prefix, will go into the right version of the manual. If this is a development branch release, also symlink X.Y.(Z-1) to X.Y.Z and X.Y.(Z+1) to - . (i.e. dot). + . (i.e. dot). - + - + - + Building and Releasing the Packages Now the individual packages can be built and released. Note that for GPL reasons the first package to be released is always the source tarball. - + For all types of packages, including the source tarball, you must make sure that you build from clean sources by exporting the right version from CVS into an empty directory (just press return when asked for a password): - + mkdir dist # delete or choose different name if it already exists @@ -2257,20 +2257,20 @@ at sourceforge. Three simple steps: cvs -z3 -d:pserver:anonymous@ijbswa.cvs.sourceforge.net:/cvsroot/ijbswa export -r v_X_Y_Z current - + Do NOT change a single bit, including, but not limited to version information after export from CVS. This is to make sure that all release packages, and with them, all future bug reports, are based on exactly the same code. - + - Every significant release of Privoxy has included at least one - package that either had incorrect versions of files, missing files, - or incidental leftovers from a previous build process that gave - unknown numbers of users headaches to try to figure out what was + Every significant release of Privoxy has included at least one + package that either had incorrect versions of files, missing files, + or incidental leftovers from a previous build process that gave + unknown numbers of users headaches to try to figure out what was wrong. PLEASE, make sure you are using pristene sources, and are following the prescribed process! @@ -2278,14 +2278,14 @@ at sourceforge. Three simple steps: Please find additional instructions for the source tarball and the - individual platform dependent binary packages below. And details + individual platform dependent binary packages below. And details on the Sourceforge release process below that. Note on Privoxy Packaging - Please keep these general guidelines in mind when putting together + Please keep these general guidelines in mind when putting together your package. These apply to all platforms! @@ -2293,11 +2293,11 @@ at sourceforge. Three simple steps: Privoxy requires - write access to: all *.action files, all - logfiles, and the trust file. You will + write access to: all *.action files, all + logfiles, and the trust file. You will need to determine the best way to do this for your platform. - + Please include up to date documentation. At a bare minimum: @@ -2343,11 +2343,11 @@ at sourceforge. Three simple steps: The documentation has been designed such that the manuals are linked - to each other from parallel directories, and should be packaged + to each other from parallel directories, and should be packaged that way. privoxy-index.html can also be included and can serve as a focal point for docs and other links of interest (and possibly renamed to index.html). - This should be one level up from the manuals. There is a link also + This should be one level up from the manuals. There is a link also on this page to an HTMLized version of the man page. To avoid 404 for this, it is in CVS as doc/webserver/man-page/privoxy-man-page.html, @@ -2357,16 +2357,16 @@ at sourceforge. Three simple steps: with privoxy-index.html, (i.e. one level up from the manual directories). - + user.action and user.filter are designed for local preferences. Make sure these do not get overwritten! - config should not be overwritten either. This + config should not be overwritten either. This has especially important configuration data in it. trust should be left in tact as well. - + Other configuration files (default.action and @@ -2376,29 +2376,29 @@ at sourceforge. Three simple steps: likely to change between releases and contain important new features and bug fixes. - + - Please check platform specific notes in this doc, if you haven't - done Privoxy packaging before for other platform - specific issues. Conversely, please add any notes that you know - are important for your platform (or contact one of the doc + Please check platform specific notes in this doc, if you haven't + done Privoxy packaging before for other platform + specific issues. Conversely, please add any notes that you know + are important for your platform (or contact one of the doc maintainers to do this if you can't). - + - Packagers should do a clean install of their - package after building it. So any previous installs should be - removed first to ensure the integrity of the newly built package. - Then run the package for a while to make sure there are no + Packagers should do a clean install of their + package after building it. So any previous installs should be + removed first to ensure the integrity of the newly built package. + Then run the package for a while to make sure there are no obvious problems, before uploading. - + - - + + Source Tarball @@ -2444,7 +2444,7 @@ at sourceforge. Three simple steps: First, make sure that you have freshly exported the right version into an empty directory. (See "Building and releasing - packages" above). + packages" above). As the only exception to not changing anything after export from CVS, @@ -2515,7 +2515,7 @@ at sourceforge. Three simple steps: Change directory to the os2setup directory. Edit the os2build.cmd file to set the final executable filename. - For example, + For example, @@ -2635,7 +2635,7 @@ at sourceforge. Three simple steps: - Then, run: + Then, run: @@ -2693,7 +2693,7 @@ at sourceforge. Three simple steps: - You can then upload privoxyosx_setup_x.y.z.zip anonymously to + You can then upload privoxyosx_setup_x.y.z.zip anonymously to uploads.sourceforge.net/incoming, create a release for it, and you're done. Use the release notes and Change Log from the source tarball package. @@ -2814,7 +2814,7 @@ at sourceforge. Three simple steps: Uploading and Releasing Your Package - After the package is ready, it is time to upload it + After the package is ready, it is time to upload it to SourceForge, and go through the release steps. The upload is done via FTP: @@ -2824,47 +2824,47 @@ at sourceforge. Three simple steps: Upload to: ftp://upload.sourceforge.net/incoming - + user: anonymous - + password: ijbswa-developers@lists.sourceforge.net - + - + Or use the make targets as described above. Once this done go to https://sourceforge.net/project/admin/editpackages.php?group_id=11118, - making sure you are logged in. Find your target platform in the - second column, and click Add Release. You will - then need to create a new release for your package, using the format + >https://sourceforge.net/project/admin/editpackages.php?group_id=11118, + making sure you are logged in. Find your target platform in the + second column, and click Add Release. You will + then need to create a new release for your package, using the format of $VERSION ($CODE_STATUS), e.g. &p-version; (beta). Now just follow the prompts. Be sure to add any appropriate Release - notes. You should see your freshly uploaded packages in - Step 2. Add Files To This Release. Check the - appropriate box(es). Remember at each step to hit the - Refresh/Submit buttons! You should now see your - file(s) listed in Step 3. Fill out the forms with the appropriate + notes. You should see your freshly uploaded packages in + Step 2. Add Files To This Release. Check the + appropriate box(es). Remember at each step to hit the + Refresh/Submit buttons! You should now see your + file(s) listed in Step 3. Fill out the forms with the appropriate information for your platform, being sure to hit Update - for each file. If anyone is monitoring your platform, check the - email box at the very bottom to notify them of + for each file. If anyone is monitoring your platform, check the + email box at the very bottom to notify them of the new package. This should do it! - If you have made errors, or need to make changes, you can go through - essentially the same steps, but select Edit Release, + If you have made errors, or need to make changes, you can go through + essentially the same steps, but select Edit Release, instead of Add Release. @@ -2878,20 +2878,20 @@ at sourceforge. Three simple steps: include the download location, the release notes and the Changelog. Also, post an - updated News item on the project page Sourceforge, and update the Home + updated News item on the project page Sourceforge, and update the Home page and docs linked from the Home page (see below). Other news sites and release oriented sites, such as Freshmeat, should also be notified. - + Update the Webserver The webserver should be updated at least with each stable release. When updating, please follow these steps to make sure that no broken links, - inconsistent contents or permission problems will occur (as it has many + inconsistent contents or permission problems will occur (as it has many times in the past!): @@ -2906,7 +2906,7 @@ at sourceforge. Three simple steps: That will generate doc/webserver/user-manual, doc/webserver/developer-manual, - doc/webserver/faq, + doc/webserver/faq, doc/pdf/*.pdf and doc/webserver/index.html automatically. @@ -2923,7 +2923,7 @@ at sourceforge. Three simple steps: create new directories under doc/webserver). - Next, commit any changes from the above steps to CVS. All set? + Next, commit any changes from the above steps to CVS. All set? If these are docs in the stable branch, then do: @@ -2950,7 +2950,7 @@ at sourceforge. Three simple steps: &contacting; - + Privoxy Copyright, License and History @@ -2975,7 +2975,7 @@ at sourceforge. Three simple steps: - + See also @@ -2986,7 +2986,7 @@ at sourceforge. Three simple steps: +--> @@ -137,7 +137,7 @@ Hal. You can find the latest version of the document at http://www.privoxy.org/faq/. Please see the Contact section if you want to - contact the developers. + contact the developers. @@ -152,7 +152,7 @@ Hal. General Information Who should give &my-app; a try? - Anyone who is interested in security, privacy, or in + Anyone who is interested in security, privacy, or in finer-grained control over their web and Internet experience. @@ -160,7 +160,7 @@ Hal. Is Privoxy the best choice for me? - &my-app; is certainly a good choice, especially for those who want more + &my-app; is certainly a good choice, especially for those who want more control and security. Those with the willingness to read the documentation and the ability to fine-tune their installation will benefit the most. @@ -170,19 +170,19 @@ me? completely personalize your installation. Being familiar with, or at least having an interest in learning about HTTP and other networking - protocols, HTML, and + protocols, HTML, and Regular Expressions - will be a big plus and will help you get the most out of &my-app;. - A new installation just includes a very basic configuration. The user - should take this as a starting point only, and enhance it as he or she - sees fit. In fact, the user is encouraged, and expected to, fine-tune the + will be a big plus and will help you get the most out of &my-app;. + A new installation just includes a very basic configuration. The user + should take this as a starting point only, and enhance it as he or she + sees fit. In fact, the user is encouraged, and expected to, fine-tune the configuration. - Much of Privoxy's configuration can be done + Much of Privoxy's configuration can be done with a Web browser. - But there are areas where configuration is done using a + But there are areas where configuration is done using a text editor to edit configuration files. Also note that the web-based action editor doesn't use authentication and should only be enabled in environments @@ -220,13 +220,13 @@ Privoxy work? Does Privoxy do anything more than ad blocking? - - Yes, ad blocking is but one possible use. There are many, many ways &my-app; - can be used to sanitize and customize web browsing. + + Yes, ad blocking is but one possible use. There are many, many ways &my-app; + can be used to sanitize and customize web browsing. -What is this new version of +<sect2 renderas="sect3" id="newjb"><title>What is this new version of <quote><citetitle>Junkbuster</citetitle></quote>? @@ -247,20 +247,20 @@ Junkbuster at all? led to confusion. - There are also potential legal complications from our use of the - Junkbuster name, which is a registered trademark of + There are also potential legal complications from our use of the + Junkbuster name, which is a registered trademark of Junkbusters Corporation. - There are, however, no objections from Junkbusters Corporation to the + There are, however, no objections from Junkbusters Corporation to the Privoxy project itself, and they, in fact, still share our ideals and goals. - The developers also believed that there are so many improvements over the original - code, that it was time to make a clean break from the past and make + The developers also believed that there are so many improvements over the original + code, that it was time to make a clean break from the past and make a name in their own right. - Privoxy is the + Privoxy is the Privacy Enhancing Proxy. Also, its content modification and junk suppression gives you, the user, more control, more freedom, and allows you to browse your personal and @@ -269,7 +269,7 @@ Junkbuster at all? How does Privoxy differ -from the old Junkbuster? +from the old Junkbuster? Privoxy picks up where Junkbuster left off. @@ -283,7 +283,7 @@ from the old Junkbuster? Privoxy's new features include: - + &newfeatures; @@ -302,7 +302,7 @@ an ad, and what is not? and the host (blocking the big banner hosting services like doublecklick.net already helps a lot). Privoxy takes advantage of this fact by using URL - patterns to sort out and block the requests for things that sound + patterns to sort out and block the requests for things that sound like they would be ads or banners. @@ -320,7 +320,7 @@ an ad, and what is not? -Can Privoxy make mistakes? +<title id="mistakes">Can Privoxy make mistakes? This does not sound very scientific. Actually, it's a black art ;-) And yes, it is always possible to have a broad @@ -347,12 +347,12 @@ This does not sound very scientific. The default installation should give you a good starting point, and block most ads and unwanted content, but many of the more advanced features are off by default, and require - you to activate them. + you to activate them. You do have to set up your browser to use Privoxy (see the Installation section below). + linkend="firststep">Installation section below). And you will certainly run into situations where there are false positives, @@ -367,7 +367,7 @@ This does not sound very scientific. Can Privoxy run as a server on a network? - + Yes, &my-app; runs as a server already, and can easily be configured to serve more than one client. See How can I set up Privoxy to act as a proxy for my LAN below. @@ -384,8 +384,8 @@ Privoxy. Why should I use Privoxy at all? your browser just can't. - In addition, a proxy is good choice if you use multiple browsers, or - have a LAN with multiple computers since &my-app; can run as a server + In addition, a proxy is good choice if you use multiple browsers, or + have a LAN with multiple computers since &my-app; can run as a server application. This way all the configuration is in one place, and you don't have to maintain a similar configuration for possibly many browsers or users. @@ -404,8 +404,8 @@ Privoxy. Why should I use Privoxy at all? The most important reason is because you have access to everything, and you can control everything. You can check every line of every configuration file yourself. You can check every - last bit of source code should you desire. And even if you can't read code, - there should be some comfort in knowing that other people can, + last bit of source code should you desire. And even if you can't read code, + there should be some comfort in knowing that other people can, and do read it. You can build the software from scratch, if you want, so that you know the executable is clean, and that it is yours. In fact, we encourage this level of scrutiny. It @@ -413,14 +413,14 @@ Privoxy. Why should I use Privoxy at all? -Is there is a license or fee? What about a +<sect2 renderas="sect3" id="license"><title>Is there is a license or fee? What about a warranty? Registration? Privoxy is free software and licensed under the GNU General Public License (GPL) version 2. It is free to use, copy, modify or distribute as you wish under the terms of this license. Please see the Copyright section for more - information on the license and copyright. Or the LICENSE file + information on the license and copyright. Or the LICENSE file that should be included. @@ -552,10 +552,10 @@ warranty? Registration? Which browsers are supported by Privoxy? - Any browser that can be configured to use a proxy, which + Any browser that can be configured to use a proxy, which should be virtually all browsers, including Firefox, Internet - Explorer, Opera, and + Explorer, Opera, and Safari among others. Direct browser support is not an absolute requirement since Privoxy runs as a separate application and talks @@ -581,7 +581,7 @@ Include supported.sgml here: dealing with some of the common abuses of HTML in email. See How can I configure Privoxy with Outlook? below for more on - this. + this. Be aware that HTML email presents a number of unique security and privacy @@ -592,11 +592,11 @@ Include supported.sgml here: -I just installed Privoxy. Is there anything +<title>I just installed Privoxy. Is there anything special I have to do now? - All browsers should be told to use Privoxy - as a proxy by specifying the correct proxy address and port number + All browsers should be told to use Privoxy + as a proxy by specifying the correct proxy address and port number in the appropriate configuration area for the browser. It's possible to combine &my-app; with a packet filter to intercept HTTP requests even if the client isn't explicitly configured to use &my-app;, - but where possible, configuring the client is recommended. See + but where possible, configuring the client is recommended. See the User Manual for more details. You should also flush your browser's memory and disk - cache to get rid of any cached junk items, and remove any stored + cache to get rid of any cached junk items, and remove any stored cookies. @@ -636,7 +636,7 @@ special I have to do now? If you set up the Privoxy to run on the computer you browse from (rather than your ISP's server or some - networked computer on a LAN), the proxy will be on 127.0.0.1 + networked computer on a LAN), the proxy will be on 127.0.0.1 (sometimes referred to as localhost, which is the special name used by every computer on the Internet to refer to itself) and the port will be 8118 (unless you used the When configuring your browser's proxy settings you typically enter the word localhost or the IP address 127.0.0.1 in the boxes next to HTTP and Secure (HTTPS) and - then the number 8118 for port. + then the number 8118 for port. This tells your browser to send all web requests to Privoxy instead of directly to the Internet. - Privoxy can also be used to proxy for - a Local Area Network. In this case, your would enter either the IP - address of the LAN host where Privoxy + Privoxy can also be used to proxy for + a Local Area Network. In this case, your would enter either the IP + address of the LAN host where Privoxy is running, or the equivalent hostname, e.g. 192.168.1.1. Port assignment would be same as above. Note that Privoxy doesn't listen on any LAN interfaces by @@ -672,17 +672,17 @@ special I have to do now? All the ads are there. What's wrong? - Did you configure your browser to use Privoxy + Did you configure your browser to use Privoxy as a proxy? It does not sound like it. See above. You might also try flushing - the browser's caches to force a full re-reading of pages. You can verify - that Privoxy is running, and your browser - is correctly configured by entering the special URL: - http://p.p/. + the browser's caches to force a full re-reading of pages. You can verify + that Privoxy is running, and your browser + is correctly configured by entering the special URL: + http://p.p/. This should take you to a page titled This is Privoxy.. with access to Privoxy's internal configuration. - If you see this, then you are good to go. If you receive a page saying + If you see this, then you are good to go. If you receive a page saying Privoxy is not running, then the browser is not set up to use your Privoxy installation. If you receive anything else (probably nothing at all), it could either @@ -721,7 +721,7 @@ Privoxy is running and being used. The procedure for clearing the cache varies from browser to browser. For - example, Mozilla/Netscape users would click + example, Mozilla/Netscape users would click Edit --> Preferences --> Advanced --> Cache and then click both Clear Memory Cache @@ -745,7 +745,7 @@ Privoxy is running and being used. &my-app; utilizes the concept of - actions + actions that are used to manipulate and control web page data. Actions files are where these actions @@ -755,7 +755,7 @@ Privoxy is running and being used. There is a wide array of actions available that give the user a high degree of control and flexibility on how to process each and every web page. - + Actions can be defined on a URL pattern basis, i.e. @@ -771,7 +771,7 @@ Privoxy is running and being used. -The <quote>actions</quote> concept confuses me. Please list +<title>The <quote>actions</quote> concept confuses me. Please list some of these <quote>actions</quote>. For a comprehensive discussion of the actions concept, please refer @@ -787,7 +787,7 @@ some of these actions. How are actions files configured? What is the easiest -way to do this? +way to do this? Actions files are just text files in a special syntax and can be edited @@ -796,8 +796,8 @@ way to do this? at http://config.privoxy.org/ (Shortcut: http://p.p/) and then select View & - change the current configuration from the menu. Note - that this feature must be explicitly enabled in the main config file + change the current configuration from the menu. Note + that this feature must be explicitly enabled in the main config file (see enable-edit-actions). @@ -816,7 +816,7 @@ the differences? Where can I get updated Actions Files? - Based on your feedback and the continuing development, updates of + Based on your feedback and the continuing development, updates of default.action will be made available from time to time on the files section of @@ -845,21 +845,21 @@ the differences? Why is the configuration so complicated? - Complicated is in the eye of the beholder. Those that are + Complicated is in the eye of the beholder. Those that are familiar with some of the underlying concepts, such as regular expression syntax, take to it like a fish takes to water. Also, software that tries hard to be user friendly, often lacks sophistication and flexibility. There is always that trade-off there between power vs. easy-of-use. Furthermore, anyone is welcome to contribute ideas and - implementations to enhance &my-app;. + implementations to enhance &my-app;. How can I make my Yahoo/Hotmail/Gmail account work? The default configuration shouldn't impact the usability of any of these services. - It may, however, make all cookies + It may, however, make all cookies temporary, so that your browser will forget your login credentials in between browser sessions. If you would like not to have to log in manually each time you access those websites, simply turn off all cookie handling @@ -873,9 +873,9 @@ the differences? .login.yahoo.com - These kinds of sites are often quite complex and heavy with - Javascript and - thus fragile. So if still a problem, + These kinds of sites are often quite complex and heavy with + Javascript and + thus fragile. So if still a problem, we have an alias just for such sticky situations: @@ -893,8 +893,8 @@ the differences? Make sure the domain, host and path are appropriate as well. Your browser can - tell you where you are specifically and you should use that information for - your configuration settings. Note that above it is not referenced as + tell you where you are specifically and you should use that information for + your configuration settings. Note that above it is not referenced as gmail.com, which is a valid domain name. @@ -908,7 +908,7 @@ the differences? profiles in the web based actions file editor at http://config.privoxy.org/show-status. See the User - Manual for a list of actions, and how the default + Manual for a list of actions, and how the default profiles are set. @@ -916,23 +916,23 @@ the differences? Where the defaults are likely to break some sites, exceptions for known popular problem sites are included, but in general, the more aggressive your default settings are, the more exceptions - you will have to make later. New users are best to start off in - Cautious setting. This is safest and will have the fewest + you will have to make later. New users are best to start off in + Cautious setting. This is safest and will have the fewest problems. See the User Manual for a more detailed discussion. - It should be noted that the Advanced profile (formerly known + It should be noted that the Advanced profile (formerly known as the Adventuresome profile) is more - aggressive, and will make use of some of + aggressive, and will make use of some of Privoxy's advanced features. Use at your own risk! - Why can I change the configuration +<sect2 renderas="sect3" id="browseconfig"> <title>Why can I change the configuration with a browser? Does that not raise security issues? It may seem strange that regular users can edit the config files with their @@ -990,21 +990,21 @@ with a browser? Does that not raise security issues? - If you are familiar with regular expressions, and HTML, you can look at + If you are familiar with regular expressions, and HTML, you can look at the provided default.filter with a text editor and define your own filters. This is potentially a very powerful feature, but - requires some expertise in both regular expressions and HTML/HTTP. - user.filter, so they won't - be overwritten during upgrades. - The ability to define multiple filter files + requires some expertise in both regular expressions and HTML/HTTP. + user.filter, so they won't + be overwritten during upgrades. + The ability to define multiple filter files in config is a new feature as of v. 3.0.5.]]> - There is no GUI editor option for this part of the configuration, - but you can disable/enable the various pre-defined filters of the included + There is no GUI editor option for this part of the configuration, + but you can disable/enable the various pre-defined filters of the included default.filter file with the web-based actions file editor. Note that the custom actions editor must be explicitly enabled in @@ -1021,10 +1021,10 @@ with a browser? Does that not raise security issues? -How can I set up Privoxy to act as a proxy for my +<title>How can I set up Privoxy to act as a proxy for my LAN? - By default, Privoxy only responds to requests + By default, Privoxy only responds to requests from 127.0.0.1 (localhost). To have it act as a server for a network, this needs to be changed in the main configuration file. Look for @@ -1043,12 +1043,12 @@ with a browser? Does that not raise security issues? - Save the file, and restart Privoxy. Configure + Save the file, and restart Privoxy. Configure all browsers on the network then to use this address and port number. - Alternately, you can have Privoxy listen on + Alternately, you can have Privoxy listen on all available interfaces: @@ -1058,10 +1058,10 @@ with a browser? Does that not raise security issues? - And then use Privoxy's + And then use Privoxy's permit-access - feature to limit connections. A firewall in this situation is recommended + url="../user-manual/config.html#PERMIT-ACCESS">permit-access + feature to limit connections. A firewall in this situation is recommended as well. @@ -1096,7 +1096,7 @@ with a browser? Does that not raise security issues? If you want to see nothing, then change the set-image-blocker - action to blank. This can be done by editing the + action to blank. This can be done by editing the user.action file, or through the web-based actions file editor. @@ -1111,7 +1111,7 @@ with a browser? Does that not raise security issues? is rather smart, it will make occasional mistakes. The checkerboard image is visually decent, and it shows you where images have been blocked, which can be very helpful in case some navigation aid or otherwise innocent image was - erroneously blocked. It is recommended for new users so they can + erroneously blocked. It is recommended for new users so they can see what is happening. Some people might also enjoy seeing how many banners they don't have to see. @@ -1127,7 +1127,7 @@ instead of the checkerboard image. Why and how do I get rid of this? or (i)layers, and these external HTML documents are blocked. Being non-images they get replaced by a substitute HTML page rather than a substitute image, which wouldn't work out technically, since the browser expects and accepts - only HTML when it has requested an HTML document. + only HTML when it has requested an HTML document. The substitute page adapts to the available space and shows itself as a @@ -1146,15 +1146,15 @@ instead of the checkerboard image. Why and how do I get rid of this? -Can Privoxy run as a service +<title>Can Privoxy run as a service on Win2K/NT/XP? Windows service functionality. See - the User Manual for details on how to install and configure + the User Manual for details on how to install and configure Privoxy as a service. - + Earlier ]]>3.x versions could run as a system service using srvany.exe. See the discussion at and thus avoid individual browser configuration? - No, its more complicated than that. This only works with special kinds + No, its more complicated than that. This only works with special kinds of proxies known as intercepting proxies (see below). @@ -1215,7 +1215,7 @@ and thus avoid individual browser configuration? but it can handle requests that where intercepted and redirected with a packet filter (like PF or iptables), as long as the Host - header is present. + header is present. As the Host header is required by HTTP/1.1 and as most @@ -1256,14 +1256,14 @@ and thus avoid individual browser configuration? of knowing which particular application makes a request, so there is no way to distinguish between web pages and HTML mail. Privoxy just blindly proxies all requests. In the - case of Outlook Express (see above), OE uses - IE anyway, and there is no way for Privoxy to ever + case of Outlook Express (see above), OE uses + IE anyway, and there is no way for Privoxy to ever be able to distinguish between them (nor could any other proxy type application for that matter). - For a good discussion of some of the issues involved (including privacy and - security issues), see + For a good discussion of some of the issues involved (including privacy and + security issues), see http://sourceforge.net/tracker/?func=detail&atid=211118&aid=629518&group_id=11118. @@ -1272,12 +1272,12 @@ and thus avoid individual browser configuration? I sometimes notice cookies sneaking through. How? Cookies can be - set in several ways. The classic method is via the + url="http://en.wikipedia.org/wiki/Browser_cookie">Cookies can be + set in several ways. The classic method is via the Set-Cookie HTTP header. This is straightforward, and an - easy one to manipulate, such as the &my-app; concept of + easy one to manipulate, such as the &my-app; concept of session-cookies-only. - There is also the possibility of using + There is also the possibility of using Javascript to set cookies (&my-app; calls these content-cookies). This is trickier because the syntax can vary widely, and thus requires a certain @@ -1296,20 +1296,20 @@ and thus avoid individual browser configuration? Are all cookies bad? Why? - No, in fact there are many beneficial uses of + No, in fact there are many beneficial uses of cookies. Cookies are just a method that browsers can use to store data between pages, or between browser sessions. Sometimes there is a good reason for this, and the user's life is a bit easier as a result. But there is a long history of some websites taking - advantage of this layer of trust, and using the data they glean from you and + advantage of this layer of trust, and using the data they glean from you and your browsing habits for their own purposes, and maybe to your potential detriment. Such sites are using you and storing their data on your system. That is why the privacy conscious watch from whom those cookies come, and why they really need to be there. - See the + See the Wikipedia cookie definition for more. @@ -1319,14 +1319,14 @@ and thus avoid individual browser configuration? How can I allow permanent cookies for my trusted sites? - There are several actions that relate to cookies. The default behavior is to + There are several actions that relate to cookies. The default behavior is to allow only session cookies, which means the cookies only last - for the current browser session. This eliminates most kinds of abuse related + for the current browser session. This eliminates most kinds of abuse related to cookies. But there may be cases where you want cookies to last. To disable all cookie actions, so that cookies are allowed unrestricted, - both in and out, for example.com: + both in and out, for example.com: @@ -1347,14 +1347,14 @@ and thus avoid individual browser configuration? Each instance of Privoxy has its own configuration, including such attributes as the TCP port that it listens on. - What you can do is run multiple instances of Privoxy, each with - a unique + What you can do is run multiple instances of Privoxy, each with + a unique listen-address configuration setting, and configuration path, and then each of these can have their own configurations. Think of it as per-port configuration. - + Simple enough for a few users, but for large installations, consider having groups of users that might share like configurations. @@ -1373,7 +1373,7 @@ and thus avoid individual browser configuration? ############################################################ { +block } / # Block *all* URLs - + ############################################################ # Whitelist ############################################################ @@ -1382,12 +1382,12 @@ and thus avoid individual browser configuration? toys.example.com games.example.com - This allows access to only those three sites by first blocking all URLs, and + This allows access to only those three sites by first blocking all URLs, and then subsequently allowing three specific exceptions. - Another approach is Privoxy's - trustfile concept, which incorporates the notion of + Another approach is Privoxy's + trustfile concept, which incorporates the notion of trusted referrers. See the Trust documentation for details. @@ -1404,14 +1404,14 @@ and thus avoid individual browser configuration? How can I turn off ad-blocking? - Ad blocking is achieved through a complex application of various &my-app; - actions. These - actions are deployed against simple images, banners, flash animations, + Ad blocking is achieved through a complex application of various &my-app; + actions. These + actions are deployed against simple images, banners, flash animations, text pages, JavaScript, pop-ups and pop-unders, etc., so its not as simple as just turning one or two actions off. The various actions that make up &my-app; ad blocking are hard-coded into the default configuration files. It has been assumed that everyone using &my-app; is interested in this - particular feature. + particular feature. If you want to do without this, there are several approaches you can take: @@ -1421,7 +1421,7 @@ and thus avoid individual browser configuration? blocking rules, and corresponding exceptions. Or lastly, if you are not concerned about the additional blocks that are done for privacy reasons, you can very easily over-ride all blocking with the - following very simple rule in your user.action: + following very simple rule in your user.action: @@ -1429,7 +1429,7 @@ and thus avoid individual browser configuration? { -block } / # UN-Block *all* URLs - + Or even a more comprehensive reversing of various ad related actions: @@ -1451,7 +1451,7 @@ and thus avoid individual browser configuration? -How can I have custom template pages, like the +<title>How can I have custom template pages, like the <emphasis>BLOCKED</emphasis> page? &my-app; templates are specialized text files utilized by @@ -1465,12 +1465,12 @@ and thus avoid individual browser configuration? during upgrades. You can, however, create completely new templates, place them in another directory and specify the alternate path in the main config. For details, have a look at the templdir option. + url="../user-manual/config.html#templdir">templdir option. -How can I remove the <quote>Go There Anyway</quote> link from +<title>How can I remove the <quote>Go There Anyway</quote> link from the <emphasis>BLOCKED</emphasis> page? There is more than one way to do it (although Perl is not involved). @@ -1479,7 +1479,7 @@ the BLOCKED page? Editing the BLOCKED template page (see above) may dissuade some users, but this method is easily circumvented. Where you need this level of control, you might want to build &my-app; from source, and disable various features that are - available as compile-time options. You should + available as compile-time options. You should configure the sources as follows: @@ -1509,15 +1509,15 @@ the BLOCKED page? Miscellaneous -How much does Privoxy slow my browsing down? This +<title id="slowsme">How much does Privoxy slow my browsing down? This has to add extra time to browsing. How much of an impact depends on many things, including the CPU of the host - system, how aggressive the configuration is, which specific actions are being triggered, + system, how aggressive the configuration is, which specific actions are being triggered, the size of the page, the bandwidth of the connection, etc. - Overall, it should not slow you down any in real terms, and may actually help + Overall, it should not slow you down any in real terms, and may actually help speed things up since ads, banners and other junk are not typically being retrieved and displayed. The actual processing time required by Privoxy itself for each page, is relatively small @@ -1555,7 +1555,7 @@ delays in page requests. What's wrong? url="../user-manual/actions-file.html#FILTER">filter action, such as filtering banners by size, web-bugs etc, or the deanimate-gifs - action, the entire document must be loaded into memory in order for the filtering + action, the entire document must be loaded into memory in order for the filtering mechanism to work, and nothing is sent to the browser during this time. @@ -1569,7 +1569,7 @@ delays in page requests. What's wrong? anti-virus software). - Filtering is automatically disabled for inappropriate MIME types. But note + Filtering is automatically disabled for inappropriate MIME types. But note that if the web server mis-reports the MIME type, then content that should not be filtered, could be. Privoxy only knows how to differentiate filterable content because of the MIME type as reported by @@ -1582,11 +1582,11 @@ delays in page requests. What's wrong? "http://p.p/"? http://config.privoxy.org/ is the - address of Privoxy's built-in user interface, and + address of Privoxy's built-in user interface, and http://p.p/ is a shortcut for it. - Since Privoxy sits between your web browser and the Internet, + Since Privoxy sits between your web browser and the Internet, it can simply intercept requests for these addresses and answer them with its built-in web server. @@ -1607,7 +1607,7 @@ delays in page requests. What's wrong? Do you still maintain the blocklists? No. The patterns for blocking now reside (among other things) in the actions files, which are + url="../user-manual/actions-file.html">actions files, which are actively maintained instead. See next question ... @@ -1621,25 +1621,25 @@ various ways to interact with the developers. -If I do submit missed ads, will +<sect2 renderas="sect3" id="newads2"><title>If I do submit missed ads, will they be included in future updates? Whether such submissions are eventually included in the - default.action configuration file depends on how - significant the issue is. We of course want to address any potential - problem with major, high-profile sites such as Google, - Yahoo, etc. Any site with global or regional reach, + default.action configuration file depends on how + significant the issue is. We of course want to address any potential + problem with major, high-profile sites such as Google, + Yahoo, etc. Any site with global or regional reach, has a good chance of being a candidate. But at the other end of the spectrum are any number of smaller, low-profile sites such as for local clubs or schools. Since their reach and impact are much less, they are best handled by inclusion in the user's user.action, and thus would be - unlikely to be included. + unlikely to be included. -Why doesn't anyone answer my support +<sect2 renderas="sect3" id="noonecares"><title>Why doesn't anyone answer my support request? Rest assured that it has been read and considered. Why it is not answered, @@ -1657,7 +1657,7 @@ us help you. Your efforts are not wasted, and we do appreciate them. If you run both the browser and &my-app; locally, you cannot hide your IP address with Privoxy or ultimately any other software alone. The server needs to know your IP address so that it knows - where to send the responses back. + where to send the responses back. There are many publicly usable "anonymous" proxies out there, which @@ -1693,8 +1693,8 @@ us help you. Your efforts are not wasted, and we do appreciate them. Privoxy can remove various information about you, - and allows you more freedom to decide which sites - you can trust, and what details you want to reveal. But it neither + and allows you more freedom to decide which sites + you can trust, and what details you want to reveal. But it neither hides your IP address, nor can it guarantee that the rest of the system behaves correctly. There are several possibilities how a web sites can find out who you are, even if you are using a strict Privoxy @@ -1744,7 +1744,7 @@ us help you. Your efforts are not wasted, and we do appreciate them. 5. Startup to make sure Privoxy itself is setup correctly. - + If it is, refer to Tor's extensive documentation to learn how to install Tor, and make sure Tor's logfile says that @@ -1838,7 +1838,7 @@ us help you. Your efforts are not wasted, and we do appreciate them. content is being altered? - Definitely. It is common for sites to use browser type, browser version, + Definitely. It is common for sites to use browser type, browser version, HTTP header content, and various other techniques in order to dynamically decide what to display and how to display it. What you see, and what I see, might be very different. There are many, many ways that this can be handled, @@ -1864,8 +1864,8 @@ content is being altered? many other ways things can go wrong when trying to fool a web server. The results of which could inadvertently cause pages to load incorrectly, partially, or even not at all. And there may be no obvious clues as to just - what went wrong, or why. Nowhere will there be a message that says - Turn off fast-redirects or else! + what went wrong, or why. Nowhere will there be a message that says + Turn off fast-redirects or else! @@ -1875,8 +1875,8 @@ content is being altered? - If you have problems with a site, you will have to adjust your configuration - accordingly. Cookies are probably the most likely adjustment that may + If you have problems with a site, you will have to adjust your configuration + accordingly. Cookies are probably the most likely adjustment that may be required, but by no means the only one. @@ -1884,13 +1884,13 @@ content is being altered? -Can Privoxy act as a <quote>caching</quote> proxy to +<title id="caching">Can Privoxy act as a <quote>caching</quote> proxy to speed up web browsing? - No, it does not have this ability at all. You want something like + No, it does not have this ability at all. You want something like Squid or Polipo for this. - And, yes, before you ask, Privoxy can co-exist + And, yes, before you ask, Privoxy can co-exist with other kinds of proxies like Squid. See the forwarding chapter in the user @@ -1901,7 +1901,7 @@ speed up web browsing? What about as a firewall? Can Privoxy protect me? - Not in the way you mean, or in the way some firewall vendors claim they can. + Not in the way you mean, or in the way some firewall vendors claim they can. Privoxy can help protect your privacy, but can't protect your system from intrusion attempts. It is, of course, perfectly possible to use both. @@ -1913,10 +1913,10 @@ speed up web browsing? ads used to be. Why? It is technically possible to eliminate banners and ads in a way that frees - their allocated page space. This could easily be done by blocking with + their allocated page space. This could easily be done by blocking with Privoxy's filters, and eliminating the entire image references from the - HTML page source. + HTML page source. But, this would consume considerably more CPU resources (IOW, slow things @@ -1955,35 +1955,35 @@ ads used to be. Why? As far as ad blocking is concerned, this is less of a restriction than it may seem, since ad sources are often identifiable by the host name, and often the banners to be placed in an encrypted page come unencrypted nonetheless - for efficiency reasons, which exposes them to the full power of + for efficiency reasons, which exposes them to the full power of Privoxy's ad blocking. Content cookies (those that are embedded in the actual HTML or JS page content, see filter{content-cookies}), - in an SSL transaction will be impossible to block under these conditions. - Fortunately, this does not seem to be a very common scenario since most + url="../user-manual/actions-file.html#FILTER-CONTENT-COOKIES">filter{content-cookies}), + in an SSL transaction will be impossible to block under these conditions. + Fortunately, this does not seem to be a very common scenario since most cookies come by traditional means. -Privoxy runs as a <quote>server</quote>. How +<title id="secure">Privoxy runs as a <quote>server</quote>. How secure is it? Do I need to take any special precautions? - On Unix-like systems, Privoxy can run as a non-privileged + On Unix-like systems, Privoxy can run as a non-privileged user, which is how we recommend it be run. Also, by default Privoxy listens to requests from localhost only. - The server aspect of Privoxy is not itself directly + The server aspect of Privoxy is not itself directly exposed to the Internet in this configuration. If you want to have Privoxy serve as a LAN proxy, this will have to be opened up to allow for LAN requests. In this case, we'd recommend - you specify only the LAN gateway address, e.g. 192.168.1.1, in the main + you specify only the LAN gateway address, e.g. 192.168.1.1, in the main Privoxy configuration file and check all access control and security options. All LAN hosts can then use this as their proxy address @@ -2006,23 +2006,23 @@ secure is it? Do I need to take any special precautions? url="http://config.privoxy.org/toggle">http://config.privoxy.org/toggle. - See the Bookmarklets section - of the User Manual for an easy way to access this - feature. Note that this is a feature that may need to be enabled in the main + See the Bookmarklets section + of the User Manual for an easy way to access this + feature. Note that this is a feature that may need to be enabled in the main config file. -When <quote>disabled</quote> is Privoxy totally +<title>When <quote>disabled</quote> is Privoxy totally out of the picture? No, this just means all optional filtering and actions are disabled. - Privoxy is still acting as a proxy, but just + Privoxy is still acting as a proxy, but just doing less of the things that Privoxy would - normally be expected to do. It is still a middle-man in - the interaction between your browser and web sites. See below to bypass + normally be expected to do. It is still a middle-man in + the interaction between your browser and web sites. See below to bypass the proxy. @@ -2038,10 +2038,10 @@ out of the picture? -My logs show Privoxy <quote>crunches</quote> +<title>My logs show Privoxy <quote>crunches</quote> ads, but also its own internal CGI pages. What is a <quote>crunch</quote>? - A crunch simply means Privoxy intercepted + A crunch simply means Privoxy intercepted something, nothing more. Often this is indeed ads or banners, but Privoxy uses the same mechanism for trapping requests for its own internal pages. For instance, a request for @@ -2065,7 +2065,7 @@ from a webserver? FTP server? viewing a document (i.e. a page), and downloading a file. The same is true of Privoxy. If there is a match for a block pattern, - it will still be blocked, and of course this is obvious. + it will still be blocked, and of course this is obvious. Filtering is potentially more of a concern since the results are not always @@ -2092,7 +2092,7 @@ from a webserver? FTP server? altered by filtering, will be saved too, for these (probably rare) cases. - Note that versions later than 3.0.2 do NOT filter document types reported as + Note that versions later than 3.0.2 do NOT filter document types reported as text/plain. Prior to this, Privoxy did filter this document type. @@ -2114,7 +2114,7 @@ from a webserver? FTP server? all to the content is to be avoided. - Privoxy does not do FTP at all, only HTTP + Privoxy does not do FTP at all, only HTTP and HTTPS (SSL) protocols. @@ -2131,18 +2131,18 @@ altered it! Yikes, what is wrong! Should I continue to use a <quote>HOSTS</quote> file for ad-blocking? One time-tested technique to defeat common ads is to trick the local DNS - system by giving a phony IP address for the ad generator in the local - HOSTS file, typically using 127.0.0.1, aka + system by giving a phony IP address for the ad generator in the local + HOSTS file, typically using 127.0.0.1, aka localhost. This effectively blocks the ad. - There is no reason to use this technique in conjunction with + There is no reason to use this technique in conjunction with Privoxy. Privoxy - does essentially the same thing, much more elegantly and with much more + does essentially the same thing, much more elegantly and with much more flexibility. A large HOSTS file, in fact, not only duplicates effort, but may get in the way and seriously slow down your system. - It is recommended to remove such entries from your HOSTS file. If you think - your hosts list is neglected by Privoxy's + It is recommended to remove such entries from your HOSTS file. If you think + your hosts list is neglected by Privoxy's configuration, consider adding your list to your user.action file: @@ -2164,15 +2164,15 @@ and related issues? -I've noticed that Privoxy changes <quote>Microsoft</quote> to +<title>I've noticed that Privoxy changes <quote>Microsoft</quote> to <quote>MicroSuck</quote>! Why are you manipulating my browsing? @@ -2193,7 +2193,7 @@ and related issues? Privoxy generates HTML in both its own templates, and possibly whenever there are text substitutions via a &my-app; filter. While this should always conform to the HTML 4.01 specifications, it has not been - validated against this or any other standard. + validated against this or any other standard. @@ -2251,7 +2251,7 @@ and related issues? -Privoxy is not running. Solution: verify +Privoxy is not running. Solution: verify that &my-app; is installed correctly, has not crashed, and is indeed running. Turn on Privoxy's logging, and look at the logs to see what they say. @@ -2264,7 +2264,7 @@ and related issues? configuration and take the forwarders out of the equation. - Or you have a firewall that is interfering and blocking you. Solution: + Or you have a firewall that is interfering and blocking you. Solution: try disabling or removing the firewall as a simple test. @@ -2285,7 +2285,7 @@ and related issues? -I just added a new rule, but the steenkin ad is +<title id="flushit">I just added a new rule, but the steenkin ad is still getting through. How? If the ad had been displayed before you added its URL, it will probably be @@ -2299,16 +2299,16 @@ still getting through. How? applied. Try pasting the full URL of the offending ad into http://config.privoxy.org/show-url-info and see if it really matches your new rule. Blocking ads is like blocking - spam: a lot of tinkering is required to stay ahead of the game. And - remember you need to block the URL of the ad in question, which may be + spam: a lot of tinkering is required to stay ahead of the game. And + remember you need to block the URL of the ad in question, which may be entirely different from the site URL itself. Most ads are hosted on different servers than the main site itself. If you right-click on the ad, you should - be able to get all the relevant information you need. Alternately, you can + be able to get all the relevant information you need. Alternately, you can find the correct URL by looking at Privoxy's logs (you may need to enable logging in the main config file if its disabled). - Below is a slightly modified real-life log snippet that originates with one + Below is a slightly modified real-life log snippet that originates with one requested URL: www.example.com (name of site was changed for this example, the number of requests is real). You can see in this the complexity of what goes into making up this one page. There @@ -2318,8 +2318,8 @@ still getting through. How? content is obviously good or bad, but not all. Many of the more questionable looking requests, are going to outside domains that seem to be identifying themselves with suspicious looking names, making - our job a little easier. &my-app; has crunched (meaning caught - and BLOCKED) quite a few items in this example, but perhaps missed a few as well. + our job a little easier. &my-app; has crunched (meaning caught + and BLOCKED) quite a few items in this example, but perhaps missed a few as well. @@ -2372,7 +2372,7 @@ Request: 66.70.21.80/scripts/click.php?hid=a71b9f6504b0c5681fa5&si=Ua What can I do? - First verify that it is indeed a Privoxy problem, + First verify that it is indeed a Privoxy problem, by toggling off Privoxy through http://config.privoxy.org/toggle (the toggle feature may need to be enabled in the main @@ -2408,13 +2408,13 @@ What can I do? on again. Remember to flush your browser's caches in between any such changes! - Alternately, if you are comfortable with a text editor, you can accomplish - the same thing by editing the appropriate actions file. Probably the easiest + Alternately, if you are comfortable with a text editor, you can accomplish + the same thing by editing the appropriate actions file. Probably the easiest way to deal with such problems when editing by hand is to add your site to a { fragile } section in user.action, which is an alias that turns off most dangerous actions, but is also likely to turn off more actions then needed, and thus lower - your privacy and protection more than necessary, + your privacy and protection more than necessary, Troubleshooting actions is discussed in more detail in the with general configuration information and examples. - As a last resort, you can always see if your browser has a setting that will + As a last resort, you can always see if your browser has a setting that will bypass the proxy setting for selective sites. Modern browsers can do this. @@ -2472,7 +2472,7 @@ every time I start IE. What gives? set-up DUN connection and each LAN connection in IE store the settings for each user individually. As such this enforces individual configurations rather than common ones. Hence the first time you use a DUN connection after - re-booting your system it may not perform as you expect, and prompt you for + re-booting your system it may not perform as you expect, and prompt you for the password. Just set and save the password again and all should be OK. @@ -2487,16 +2487,16 @@ every time I start IE. What gives? I cannot connect to any FTP sites. Privoxy is blocking me. - Privoxy cannot act as a proxy for FTP traffic, + Privoxy cannot act as a proxy for FTP traffic, so do not configure your browser to use Privoxy as an FTP proxy. The same is true for any protocol other than HTTP - or HTTPS (SSL). + or HTTPS (SSL). Most browsers understand FTP as well as HTTP. If you connect to a site, with a URL like ftp://ftp.example.com, your browser is making - an FTP connection, and not a HTTP connection. So while your browser may - speak FTP, Privoxy does not, and cannot proxy + an FTP connection, and not a HTTP connection. So while your browser may + speak FTP, Privoxy does not, and cannot proxy such traffic. @@ -2506,7 +2506,7 @@ every time I start IE. What gives? accidentally enable FTP proxying in these cases. And of course, if this happens, Privoxy will indeed cause problems since it does not know FTP. Just disable the FTP setting + message if a FTP connection is attempted.]]> Just disable the FTP setting and all will be well again. @@ -2518,14 +2518,14 @@ every time I start IE. What gives? -In Mac OS X, I can't configure Microsoft Internet Explorer to use +<title>In Mac OS X, I can't configure Microsoft Internet Explorer to use Privoxy as the HTTP proxy. Microsoft Internet Explorer (in versions like 5.1) respects system-wide network settings. In order to change the HTTP proxy, open System Preferences, and click on the Network icon. In the settings pane that - comes up, click on the Proxies tab. Ensure the "Web Proxy (HTTP)" checkbox - is checked and enter 127.0.0.1 in the entry field. + comes up, click on the Proxies tab. Ensure the "Web Proxy (HTTP)" checkbox + is checked and enter 127.0.0.1 in the entry field. Enter 8118 in the Port field. The next time you start IE, it should reflect these values. @@ -2533,12 +2533,12 @@ every time I start IE. What gives? -In Mac OS X, I dragged the Privoxy folder to the trash in order to +<title>In Mac OS X, I dragged the Privoxy folder to the trash in order to uninstall it. Now the finder tells me I don't have sufficient privileges to empty the trash. Note: This ONLY applies to privoxy 3.0.6 and earlier. - + Just dragging the Privoxy folder to the trash is not enough to delete it. Privoxy supplies an @@ -2546,9 +2546,9 @@ every time I start IE. What gives? these details. Open the trash, drag the uninstall.command file out of the trash and double-click on it. You will be prompted for confirmation and the administration password. - + - The trash may still appear full after this command; emptying the trash + The trash may still appear full after this command; emptying the trash from the desktop should make it appear empty again. @@ -2561,7 +2561,7 @@ every time I start IE. What gives? localhost as my browser's proxy setting. We believe this is due to an IPv6-related bug in Mac OS X, but don't fully - understand the issue yet. In any case, changing the proxy setting to + understand the issue yet. In any case, changing the proxy setting to 127.0.0.1 instead of localhost works around the problem. @@ -2586,9 +2586,9 @@ every time I start IE. What gives? user.action: - # Make exceptions for ill-behaved sites: - # - {-prevent-compression} + # Make exceptions for ill-behaved sites: + # + {-prevent-compression} .example.com If that works, you may also want to report the problem to the @@ -2606,7 +2606,7 @@ Why? its running on from the IP address of the system interface it is bound to (from the config file listen-address setting). If the system cannot supply - this information, Privoxy logs this condition. + this information, Privoxy logs this condition. Typically, this would be considered a minor system configuration error. It is @@ -2627,11 +2627,11 @@ Why? -When I try to launch Privoxy, I get an +<title>When I try to launch Privoxy, I get an error message <quote>port 8118 is already in use</quote> (or similar wording). Why? - Port 8118 is Privoxy's default TCP + Port 8118 is Privoxy's default TCP listening port. Typically this message would mean that there is already one instance of Privoxy running, and your system is actually trying to start a second @@ -2661,8 +2661,8 @@ Why? is used? - This may also be caused by the demoronizer filter, - in conjunction with a web server that is misreporting the content type. Binary + This may also be caused by the demoronizer filter, + in conjunction with a web server that is misreporting the content type. Binary files are exempted from Privoxy's filtering (unless the web server by mistake says the file is something else). Either upgrade Privoxy, or go to the most recent @@ -2676,26 +2676,26 @@ Why? What is the demoronizer and why is it there? - The original demoronizer was a Perl script that cleaned up HTML pages which - were created with certain Microsoft products. MS has used proprietary extensions + The original demoronizer was a Perl script that cleaned up HTML pages which + were created with certain Microsoft products. MS has used proprietary extensions to standardized font encodings (ISO 8859-1), which has caused problems for pages that are viewed with non-Microsoft products (and are expecting to see a standard set of fonts). The demoronizer corrected these errors so the pages displayed correctly. Privoxy borrowed from this script, introducing a filter based on the original demoronizer, which in turn could - correct these errors on the fly. + correct these errors on the fly. - But this is only needed in some situations, and will cause serious problems in some + But this is only needed in some situations, and will cause serious problems in some other situations. - If you are using Microsoft products, you do not need it. If you need to view - pages with UTF-8 characters (such as Cyrillic or Chinese), then it will + If you are using Microsoft products, you do not need it. If you need to view + pages with UTF-8 characters (such as Cyrillic or Chinese), then it will cause corruption of the fonts, and thus should not be on. - On the other hand, if you use non-Microsoft products, and you occasionally + On the other hand, if you use non-Microsoft products, and you occasionally notice weird characters on pages, you might want to try it. @@ -2705,16 +2705,16 @@ Why? Why do I keep seeing PrivoxyWindowOpen() in raw source code? - Privoxy is attempting to disable malicious - Javascript + Privoxy is attempting to disable malicious + Javascript in this case, with the unsolicited-popups - filter. Privoxy cannot tell very well + filter. Privoxy cannot tell very well good code snippets from bad code snippets. - If you see this in HTML source, and the page displays without problems, then - this is good, and likely some pop-up window was disabled. If you see this - where it is causing a problem, such as a downloaded program source code file, + If you see this in HTML source, and the page displays without problems, then + this is good, and likely some pop-up window was disabled. If you see this + where it is causing a problem, such as a downloaded program source code file, then you should set an exception for this site or page such that the integrity of the page stays in tact by disabling all filtering. @@ -2752,13 +2752,13 @@ Why? - At one site Privoxy just hangs, and starts taking + At one site Privoxy just hangs, and starts taking all CPU. Why is this? This is probably a manifestation of the 100% cpu problem that - occurs on pages containing many (thousands upon thousands) of blank lines. The blank lines - are in the raw HTML source of the page, and the browser just ignores them. But the + occurs on pages containing many (thousands upon thousands) of blank lines. The blank lines + are in the raw HTML source of the page, and the browser just ignores them. But the pattern matching in Privoxy's page filtering mechanism is trying to match against absurdly long strings and this becomes very CPU-intensive, taking a long, long time to complete. @@ -2886,7 +2886,7 @@ browsing has slowed to a crawl. What gives? If you compiled &my-app; with threading support (on POSIX-based systems), the Conditional #defines section on http://config.privoxy.org/show-status - will list FEATURE_PTHREAD as enabled. + will list FEATURE_PTHREAD as enabled. @@ -2899,18 +2899,18 @@ browsing has slowed to a crawl. What gives? &contacting; - + Privoxy Copyright, License and History ©right; - + Portions of this document are borrowed from the original - Junkbuster (tm) FAQ, and modified as + Junkbuster (tm) FAQ, and modified as appropriate for Privoxy. @@ -2931,8 +2931,8 @@ browsing has slowed to a crawl. What gives? - - + + diff --git a/doc/source/install.sgml b/doc/source/install.sgml index 9a610f06..3b168d52 100644 --- a/doc/source/install.sgml +++ b/doc/source/install.sgml @@ -1,5 +1,5 @@ + @@ -15,16 +15,16 @@ File : $Source: /cvsroot/ijbswa/current/doc/source/install.sgml,v $ Purpose : INSTALL file for Privoxy - - $Id: install.sgml,v 2.17 2010/11/06 12:55:48 fabiankeil Exp $ + + $Id: install.sgml,v 2.18 2011/08/17 10:40:07 fabiankeil Exp $ Copyright (C) 2001-2009 Privoxy Developers http://www.privoxy.org/ See LICENSE. ======================================================================== - NOTE: Please read developer-manual/documentation.html before touching + NOTE: Please read developer-manual/documentation.html before touching anything in this, or other Privoxy documentation. You have been warned! - Failure to abide by this rule will result in the revocation of your license + Failure to abide by this rule will result in the revocation of your license to live a peaceful existence! ======================================================================== @@ -62,10 +62,10 @@ * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -80,8 +80,8 @@ * The GNU General Public License should be included with * this file. If not, you can view it at * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html - * or write to the Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, + * or write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, * USA * *********************************************************************/ diff --git a/doc/source/license.sgml b/doc/source/license.sgml index be1b0c25..c62c675a 100644 --- a/doc/source/license.sgml +++ b/doc/source/license.sgml @@ -2,17 +2,17 @@ File : $Source: /cvsroot/ijbswa/current/doc/source/license.sgml,v $ Purpose : Entity included in other project documents. - - $Id: license.sgml,v 2.5 2006/09/22 01:27:55 hal9 Exp $ + + $Id: license.sgml,v 2.6 2008/05/23 15:09:48 fabiankeil Exp $ Copyright (C) 2001-2008 Privoxy Developers http://www.privoxy.org/ See LICENSE. - + ====================================================================== This file used for inclusion with other documents only. ====================================================================== - If you make changes to this file, please verify the finished + If you make changes to this file, please verify the finished docs all display as intended. This file is included into: @@ -27,7 +27,7 @@ Privoxy is free software; you can - redistribute it and/or modify it under the terms of the + redistribute it and/or modify it under the terms of the GNU General Public License, version 2, as published by the Free Software Foundation. diff --git a/doc/source/p-authors.sgml b/doc/source/p-authors.sgml index 2b45c808..6b35ebaf 100644 --- a/doc/source/p-authors.sgml +++ b/doc/source/p-authors.sgml @@ -2,8 +2,8 @@ File : $Source: /cvsroot/ijbswa/current/doc/source/p-authors.sgml,v $ Purpose : Entity included in other project documents. - - $Id: p-authors.sgml,v 2.40 2009/10/24 12:28:02 fabiankeil Exp $ + + $Id: p-authors.sgml,v 2.41 2009/12/16 08:28:11 fabiankeil Exp $ Copyright (C) 2001-2009 Privoxy Developers http://www.privoxy.org/ See LICENSE. @@ -12,7 +12,7 @@ This file used for inclusion with other documents only. ====================================================================== - If you make changes to this file, please verify the finished + If you make changes to this file, please verify the finished docs all display as intended. This file is included into: diff --git a/doc/source/p-config.sgml b/doc/source/p-config.sgml index 1d9b0176..e4416f72 100644 --- a/doc/source/p-config.sgml +++ b/doc/source/p-config.sgml @@ -3,39 +3,39 @@ Purpose : Used with other docs and files only. - $Id: p-config.sgml,v 2.77 2011/08/17 10:30:36 fabiankeil Exp $ + $Id: p-config.sgml,v 2.78 2011/08/18 11:42:50 fabiankeil Exp $ Copyright (C) 2001-2011 Privoxy Developers http://www.privoxy.org/ See LICENSE. ======================================================================== - NOTE: Please read developer-manual/documentation.html before touching + NOTE: Please read developer-manual/documentation.html before touching anything in this, or other Privoxy documentation. ======================================================================== - - This file contains all the config file comments and options. It used to + + This file contains all the config file comments and options. It used to build both the user-manual config sections, and all of config (yes, the main config file) itself. - Rationale: This is broken up into two files since a file with a prolog + Rationale: This is broken up into two files since a file with a prolog (DTD, etc) cannot be sourced as a secondary file. config.sgml is basically a wrapper for this file. IMPORTANT: - OPTIONS: The actual options are included in this file and prefixed with - '@@', and processed by the Makefile to strip the '@@'. Default options - that should appear commented out should be listed as: '@@#OPTION'. + OPTIONS: The actual options are included in this file and prefixed with + '@@', and processed by the Makefile to strip the '@@'. Default options + that should appear commented out should be listed as: '@@#OPTION'. Otherwise, as '@@OPTION'. Example: @@listen-address 127.0.0.1:8118 - The Makefile does significant other processing too. The final results - should be checked to make sure that the perl processing does not + The Makefile does significant other processing too. The final results + should be checked to make sure that the perl processing does not fubar something!!! Makefile processing requires w3m, fmt (shell line formatter), and perl. - + This file is included into: @@ -59,11 +59,11 @@ - + confdir /etc/privoxy - + @@ -97,7 +97,7 @@ Sample Configuration File for Privoxy v&p-version; - $Id: p-config.sgml,v 2.77 2011/08/17 10:30:36 fabiankeil Exp $ + $Id: p-config.sgml,v 2.78 2011/08/18 11:42:50 fabiankeil Exp $ Copyright (C) 2001-2011 Privoxy Developers http://www.privoxy.org/ @@ -167,7 +167,7 @@ II. FORMAT OF THE CONFIGURATION FILE Thus, by placing a # at the start of an existing configuration line, - you can make it a comment and it will be treated as if it weren't there. + you can make it a comment and it will be treated as if it weren't there. This is called "commenting out" an option and can be useful. Removing the # again is called "uncommenting". @@ -237,11 +237,11 @@ II. FORMAT OF THE CONFIGURATION FILE Notes: - The User Manual URI is the single best source of information on + The User Manual URI is the single best source of information on Privoxy, and is used for help links from some of the internal CGI pages. The manual itself is normally packaged with the binary distributions, so you probably want to set this to a locally - installed copy. + installed copy. Examples: @@ -265,7 +265,7 @@ II. FORMAT OF THE CONFIGURATION FILE   user-manual  file://///some-server/some-path/privoxy-&p-version;/user-manual/ - --> + --> The best all purpose solution is simply to put the full local PATH to where the User Manual is @@ -281,7 +281,7 @@ II. FORMAT OF THE CONFIGURATION FILE (or the shortcut: http://p.p/user-manual/). - If the documentation is not on the local system, it can be accessed + If the documentation is not on the local system, it can be accessed from a remote server, as: @@ -295,7 +295,7 @@ II. FORMAT OF THE CONFIGURATION FILE file, because it is used while the config file is being read on start-up. - + ]]>
- + If set, this option should be the first option in the config file, because it is used while the config file is being read. @@ -327,7 +327,7 @@ II. FORMAT OF THE CONFIGURATION FILE Specifies: - A URL to be displayed in the error page that users will see if access to an untrusted page is denied. + A URL to be displayed in the error page that users will see if access to an untrusted page is denied. @@ -415,7 +415,7 @@ II. FORMAT OF THE CONFIGURATION FILE If both admin-address and proxy-info-url are unset, the whole "Local Privoxy Support" box on all generated pages will not be shown. - + @@ -464,10 +464,10 @@ II. FORMAT OF THE CONFIGURATION FILE If both admin-address and proxy-info-url are unset, the whole "Local Privoxy Support" box on all generated pages will not be shown. - + This URL shouldn't be blocked ;-) - + @@ -489,7 +489,7 @@ II. FORMAT OF THE CONFIGURATION FILE Privoxy can (and normally does) use a number of other files for additional configuration, help and logging. This section of the configuration file tells Privoxy - where to find those other files. + where to find those other files. @@ -533,16 +533,16 @@ II. FORMAT OF THE CONFIGURATION FILE No trailing /, please. - + --> @@ -685,7 +685,7 @@ actionsfile Effect if unset: - No actions are taken at all. More or less neutral proxying. + No actions are taken at all. More or less neutral proxying. @@ -695,15 +695,15 @@ actionsfile Multiple actionsfile lines are permitted, and are in fact recommended! - + The default values are default.action, which is the main actions file maintained by the developers, and user.action, where you can make your personal additions. - - Actions files contain all the per site and per URL configuration for + + Actions files contain all the per site and per URL configuration for ad blocking, cookie management, privacy considerations, etc. - There is no point in using Privoxy without at + There is no point in using Privoxy without at least one actions file. @@ -772,7 +772,7 @@ actionsfile rules that use regular expressions. These rules permit powerful changes on the content of Web pages, and optionally the headers as well, e.g., you could try to disable your favorite JavaScript annoyances, - re-write the actual displayed text, or just have some fun + re-write the actual displayed text, or just have some fun playing buzzword bingo with web pages. @@ -858,7 +858,7 @@ actionsfile periodically remove it. On Unix systems, you can do this with a cron job (see man cron). For Red Hat based Linux distributions, a logrotate script has been included. - + Any log files must be writable by whatever user Privoxy is being run as (on Unix, default user id is privoxy). @@ -911,14 +911,14 @@ actionsfile If you specify a trust file, Privoxy will only allow - access to sites that are specified in the trustfile. Sites can be listed + access to sites that are specified in the trustfile. Sites can be listed in one of two ways: - Prepending a ~ character limits access to this site - only (and any sub-paths within this site), e.g. + Prepending a ~ character limits access to this site + only (and any sub-paths within this site), e.g. ~www.example.com allows access to - ~www.example.com/features/news.html, etc. + ~www.example.com/features/news.html, etc. Or, you can designate sites as trusted referrers, by @@ -932,7 +932,7 @@ actionsfile made. - If you use the + operator in the trust file, it may grow + If you use the + operator in the trust file, it may grow considerably over time. @@ -944,7 +944,7 @@ actionsfile Possible applications include limiting Internet access for children. - + @@ -1449,7 +1449,7 @@ actionsfile Note that you must have compiled Privoxy with - support for this feature, otherwise this option has no effect. + support for this feature, otherwise this option has no effect. @@ -1572,7 +1572,7 @@ actionsfile Note that you must have compiled Privoxy with - support for this feature, otherwise this option has no effect. + support for this feature, otherwise this option has no effect. @@ -1679,7 +1679,7 @@ ACLs: permit-access and deny-access [dst_addr[:port][/dst_masklen]] - Where src_addr and + Where src_addr and dst_addr are IPv4 addresses in dotted decimal notation or valid DNS names, port is a port number, and src_masklen and @@ -1726,11 +1726,11 @@ ACLs: permit-access and deny-access Access controls are included at the request of ISPs and systems administrators, and are not usually needed by individual users. - For a typical home user, it will normally suffice to ensure that + For a typical home user, it will normally suffice to ensure that Privoxy only listens on the localhost (127.0.0.1) or internal (home) network address by means of the listen-address - option. + option. Please see the warnings in the FAQ that Privoxy @@ -1867,7 +1867,7 @@ ACLs: permit-access and deny-access For content filtering, i.e. the +filter and - +deanimate-gif actions, it is necessary that + +deanimate-gif actions, it is necessary that Privoxy buffers the entire document body. This can be potentially dangerous, since a server could just keep sending data indefinitely and wait for your RAM to exhaust -- with nasty consequences. @@ -1940,7 +1940,7 @@ ACLs: permit-access and deny-access http_parent[:port] - where target_pattern is a URL pattern + where target_pattern is a URL pattern that specifies to which requests (i.e. URLs) this forward rule shall apply. Use / to denote all URLs. http_parent[:port] @@ -2063,7 +2063,7 @@ forward-socks4, forward-socks4a and forward-socks5 and socks_proxy are IP addresses in dotted decimal notation or valid DNS names (http_parent - may be . to denote no HTTP forwarding), and the optional + may be . to denote no HTTP forwarding), and the optional port parameters are TCP ports, i.e. integer values from 1 to 65535 @@ -2138,9 +2138,9 @@ forward-socks4, forward-socks4a and forward-socks5 forward-socks4 / socks-gw.example.com:1080 . - + - To chain Privoxy and Tor, both running on the same system, you would use + To chain Privoxy and Tor, both running on the same system, you would use something like: @@ -2189,7 +2189,7 @@ forward-socks4, forward-socks4a and forward-socks5 Advanced Forwarding Examples - If you have links to multiple ISPs that provide various special content + If you have links to multiple ISPs that provide various special content only to their subscribers, you can configure multiple Privoxies which have connections to the respective ISPs to act as forwarders to each other, so that your users can see the internal content of all ISPs. @@ -2230,9 +2230,9 @@ forward-socks4, forward-socks4a and forward-socks5 - If you intend to chain Privoxy and - squid locally, then chaining as - browser -> squid -> privoxy is the recommended way. + If you intend to chain Privoxy and + squid locally, then chaining as + browser -> squid -> privoxy is the recommended way. @@ -2242,14 +2242,14 @@ forward-socks4, forward-socks4a and forward-socks5 - # Define Privoxy as parent proxy (without ICP) - cache_peer 127.0.0.1 parent 8118 7 no-query + # Define Privoxy as parent proxy (without ICP) + cache_peer 127.0.0.1 parent 8118 7 no-query - # Define ACL for protocol FTP - acl ftp proto FTP + # Define ACL for protocol FTP + acl ftp proto FTP # Do not forward FTP requests to Privoxy - always_direct allow ftp + always_direct allow ftp # Forward all the rest to Privoxy never_direct allow all @@ -2269,7 +2269,7 @@ forward-socks4, forward-socks4a and forward-socks5 forward / . - forward /.*\.(exe|com|dll|zip)$ antivir.example.com:8010 + forward /.*\.(exe|com|dll|zip)$ antivir.example.com:8010 @@ -2281,7 +2281,7 @@ forward-socks4, forward-socks4a and forward-socks5 Specifies: - How often Privoxy retries if a forwarded connection request fails. + How often Privoxy retries if a forwarded connection request fails. @@ -2384,7 +2384,7 @@ forward-socks4, forward-socks4a and forward-socks5 If you don't trust your clients and want to force them to use Privoxy, enable this option and configure your packet filter to redirect outgoing - HTTP connections into Privoxy. + HTTP connections into Privoxy. Make sure that Privoxy's own requests @@ -3152,11 +3152,11 @@ forward-socks4, forward-socks4a and forward-socks5 - + activity-animation 1 - + ]]> @@ -3173,18 +3173,18 @@ forward-socks4, forward-socks4a and forward-socks5 - + log-messages 1 - + ]]> @@]]> - + If log-buffer-size is set to 1, the size of the log buffer, i.e. the amount of memory used for the log messages displayed in the console window, will be limited to log-max-lines (see below). @@ -3199,11 +3199,11 @@ forward-socks4, forward-socks4a and forward-socks5 - + log-buffer-size 1 - + ]]> @@ -3219,11 +3219,11 @@ forward-socks4, forward-socks4a and forward-socks5 - + log-max-lines 200 - + ]]> @@ -3240,11 +3240,11 @@ forward-socks4, forward-socks4a and forward-socks5 - + log-highlight-messages 1 - + ]]> @@ -3259,11 +3259,11 @@ forward-socks4, forward-socks4a and forward-socks5 - + log-font-name Comic Sans MS - + ]]> @@ -3278,18 +3278,18 @@ forward-socks4, forward-socks4a and forward-socks5 - + log-font-size 8 - + ]]> @@]]> - + show-on-task-bar controls whether or not Privoxy will appear as a button on the Task bar when minimized: @@ -3299,11 +3299,11 @@ forward-socks4, forward-socks4a and forward-socks5 - + show-on-task-bar 0 - + ]]> @@ -3320,11 +3320,11 @@ forward-socks4, forward-socks4a and forward-socks5 - + close-button-minimizes 1 - + ]]> @@ -3342,11 +3342,11 @@ forward-socks4, forward-socks4a and forward-socks5 - + #hide-console - + ]]> diff --git a/doc/source/privoxy-man-page.sgml b/doc/source/privoxy-man-page.sgml index 525a08f0..0d24c78a 100644 --- a/doc/source/privoxy-man-page.sgml +++ b/doc/source/privoxy-man-page.sgml @@ -4,22 +4,22 @@ Purpose : Manual Page This file belongs into ijbswa.sourceforge.net:/home/groups/i/ij/ijbswa/htdocs/ - - $Id: privoxy-man-page.sgml,v 2.36 2010/11/06 12:55:48 fabiankeil Exp $ + + $Id: privoxy-man-page.sgml,v 2.37 2011/08/17 10:40:07 fabiankeil Exp $ Copyright (C) 2001-2009 Privoxy Developers http://www.privoxy.org/ See LICENSE. ======================================================================== - NOTE: Please read developer-manual/documentation.html before touching - anything in this, or other Privoxy documentation. + NOTE: Please read developer-manual/documentation.html before touching + anything in this, or other Privoxy documentation. ======================================================================== Doc NOTES: This is some tricky markup! There are some quirks to how this markup is handled. It is not always so co-operative. - Please don't change the markup unless you can verify the changes - will improve finished output! - + Please don't change the markup unless you can verify the changes + will improve finished output! + literallayout tags are particularly sensitive to where they are placed. The 'replaceable' and 'command' tags are used here somewhat unconventionally, since it seems to generate the proper formatting (at least for me :). @@ -28,15 +28,15 @@ Requires docbook2man (short perl script), see CVS http://sources.redhat.com/docbook-tools/. Also requires openjade and SGMLSpm - perl module. - + perl module. + For man page references, see: http://www.linuxdoc.org/HOWTO/mini/DocBook-Install/using.html http://docbook.org/tdg/en/html/ch02.html#making-refentry --> + @@ -57,7 +57,7 @@ 2009-02-15 - privoxy + privoxy 1 Privoxy &p-version; @@ -70,16 +70,16 @@ - + privoxy - pidfile - user[.group] + pidfile + user[.group] - hostname - configfile + hostname + configfile @@ -92,7 +92,7 @@ options: - + --help @@ -157,7 +157,7 @@ Privoxy process that the directory tree starts there. If set up carefully, this can limit the impact of possible vulnerabilities in Privoxy to the files contained in - that hierarchy. + that hierarchy. @@ -177,7 +177,7 @@ If the configfile is not specified on the command line, Privoxy will look for a file named config in the current directory. If no - configfile is found, Privoxy will + configfile is found, Privoxy will fail to start. @@ -201,21 +201,21 @@ filter to build an intercepting proxy (see config). The default setting is for localhost, on port 8118 (configurable in the main config file). To set the - HTTP proxy in Firefox, go through: Tools; + HTTP proxy in Firefox, go through: Tools; Options; General; Connection Settings; - Manual Proxy Configuration. + Manual Proxy Configuration. - For Internet Explorer, go through: Tools; + For Internet Explorer, go through: Tools; Internet Properties; Connections; - LAN Settings. + LAN Settings. The Secure (SSL) Proxy should also be set to the same values, otherwise https: URLs will not be proxied. Note: Privoxy can only proxy HTTP and HTTPS traffic. Do not try it with FTP or other protocols. - HTTPS presents some limitations, and not all features will work with HTTPS + HTTPS presents some limitations, and not all features will work with HTTPS connections. @@ -231,25 +231,25 @@ Privoxy can be configured with the various configuration files. The default configuration files are: config, default.filter, default.action and - default.action. user.action should + default.action. user.action should be used for locally defined exceptions to the default rules in match-all.action and default.action, and user.filter for locally defined filters. These are well commented. On Unix and Unix-like systems, these are located in - /etc/privoxy/ by default. + /etc/privoxy/ by default. - - Privoxy uses the concept of actions + + Privoxy uses the concept of actions in order to manipulate the data stream between the browser and remote sites. - There are various actions available with specific functions for such things + There are various actions available with specific functions for such things as blocking web sites, managing cookies, etc. These actions can be invoked - individually or combined, and used against individual URLs, or groups of URLs + individually or combined, and used against individual URLs, or groups of URLs that can be defined using wildcards and regular expressions. The result is that the user has greatly enhanced control and freedom. The actions list (ad blocks, etc) can also be configured with your - web browser at http://config.privoxy.org/ + web browser at http://config.privoxy.org/ (assuming the configuration allows it). Privoxy's configuration parameters can also be viewed at the same page. In addition, Privoxy can be toggled on/off. @@ -268,7 +268,7 @@ Files - + /usr/sbin/privoxy /etc/privoxy/config /etc/privoxy/match-all.action @@ -296,11 +296,11 @@ Privoxy terminates on the SIGINT, SIGTERM and SIGABRT signals. Log - rotation scripts may cause a re-opening of the logfile by sending a + rotation scripts may cause a re-opening of the logfile by sending a SIGHUP to Privoxy. Note that unlike other daemons, Privoxy does not need to be made aware of config file changes by SIGHUP -- it will detect them - automatically. + automatically. diff --git a/doc/source/privoxy.sgml b/doc/source/privoxy.sgml index 2c97d242..0d483691 100644 --- a/doc/source/privoxy.sgml +++ b/doc/source/privoxy.sgml @@ -2,8 +2,8 @@ File : $Source: /cvsroot/ijbswa/current/doc/source/privoxy.sgml,v $ Purpose : Entity included in other project documents. - - $Id: privoxy.sgml,v 2.10 2010/02/19 16:44:42 fabiankeil Exp $ + + $Id: privoxy.sgml,v 2.11 2011/08/18 11:42:50 fabiankeil Exp $ Copyright (C) 2001-2011 Privoxy Developers http://www.privoxy.org/ See LICENSE. @@ -12,7 +12,7 @@ This file used for inclusion with other documents only. ====================================================================== - If you make changes to this file, please verify the finished + If you make changes to this file, please verify the finished docs all display as intended. This file is included into: diff --git a/doc/source/readme.sgml b/doc/source/readme.sgml index e6b664f9..3e563ee8 100644 --- a/doc/source/readme.sgml +++ b/doc/source/readme.sgml @@ -1,5 +1,5 @@ + @@ -16,23 +16,23 @@ File : $Source: /cvsroot/ijbswa/current/doc/source/readme.sgml,v $ Purpose : README for Privoxy - - $Id: readme.sgml,v 2.44 2011/08/17 10:40:07 fabiankeil Exp $ + + $Id: readme.sgml,v 2.45 2011/08/18 11:42:50 fabiankeil Exp $ Copyright (C) 2001-2011 Privoxy Developers http://www.privoxy.org/ See LICENSE. ======================================================================== - NOTE: Please read developer-manual/documentation.html before touching + NOTE: Please read developer-manual/documentation.html before touching anything in this, or other Privoxy documentation. You have been warned! - Failure to abide by this rule will result in the revocation of your license + Failure to abide by this rule will result in the revocation of your license to live a peaceful existence! ======================================================================== =================================================================== - READ: Document Note: This file generates the README in the top level - source directory. It is generated as only a plain text file. The - current markup is not suitable for other formats. Build from + READ: Document Note: This file generates the README in the top level + source directory. It is generated as only a plain text file. The + current markup is not suitable for other formats. Build from Makefile with 'make dok-readme'. =================================================================== @@ -40,21 +40,21 @@ ====================================================================== NOTE: The left margin spacing is *important* when using 'literallayout' - WYSISWYG!!! Don't mess this up!!! Careful with linebreaks too, ie + WYSISWYG!!! Don't mess this up!!! Careful with linebreaks too, ie the para tag forces a linebreak. Tags need to be carefully placed as a result - to avoid extra blank lines, etc. + to avoid extra blank lines, etc. ====================================================================== - For stable releases, change - - entity % p-not-stable "INCLUDE" - - to - - entity % p-not-stable "IGNORE" - + For stable releases, change + + entity % p-not-stable "INCLUDE" + + to + + entity % p-not-stable "IGNORE" + in the DTD at the top. This will toggle various text 'off'. BOTH - MUST be toggled in this case or you will get both text referencing + MUST be toggled in this case or you will get both text referencing stable and unstable versions. You only want one or the other! --> @@ -84,10 +84,10 @@ * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -102,8 +102,8 @@ * The GNU General Public License should be included with * this file. If not, you can view it at * http://www.gnu.org/copyleft/gpl.html - * or write to the Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, + * or write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, * USA * *********************************************************************/ @@ -149,10 +149,10 @@ INSTALL - + See the INSTALL file in this directory, for installing from raw source, and the User Manual, for all other - installation types. + installation types. @@ -164,7 +164,7 @@ HOSTNAME ][config_file] - See the man page or User Manual for an explanation of each option, and + See the man page or User Manual for an explanation of each option, and other configuration and usage issues. @@ -209,10 +209,10 @@ DOCUMENTATION There should be documentation in the 'doc' subdirectory. In particular, see the + may not be completed at this point]]>. In particular, see the User Manual there, the FAQ, and those interested in Privoxy development, should look at - developer-manual. + developer-manual. The source and configuration files are all well commented. The main configuration files are: 'config', 'default.action', and - 'default.filter'. + 'default.filter'. - Included documentation may vary according to platform and packager. All - documentation is posted on http://www.privoxy.org, in case you don't have it, + Included documentation may vary according to platform and packager. All + documentation is posted on http://www.privoxy.org, in case you don't have it, or can't find it. @@ -244,7 +244,7 @@ - + diff --git a/doc/source/seealso.sgml b/doc/source/seealso.sgml index 73afbeb9..5b61d009 100644 --- a/doc/source/seealso.sgml +++ b/doc/source/seealso.sgml @@ -2,8 +2,8 @@ File : $Source: /cvsroot/ijbswa/current/doc/source/seealso.sgml,v $ Purpose : Entity included in other project documents. - - $Id: seealso.sgml,v 2.11 2009/02/19 02:20:22 hal9 Exp $ + + $Id: seealso.sgml,v 2.12 2009/02/23 10:42:58 fabiankeil Exp $ Copyright (C) 2001-2009 Privoxy Developers http://www.privoxy.org/ See LICENSE. @@ -12,7 +12,7 @@ This file used for inclusion with other documents only. ====================================================================== - If you make changes to this file, please verify the finished + If you make changes to this file, please verify the finished docs all display as intended. This file is included into: @@ -22,7 +22,7 @@ faq developer-manual - NOTE: 04/05/02, HB Removed   tags. They were causing docbook2man + NOTE: 04/05/02, HB Removed   tags. They were causing docbook2man to barf. --> @@ -36,28 +36,28 @@ http://www.privoxy.org/, - the Privoxy Home page. + url="http://www.privoxy.org/">http://www.privoxy.org/, + the Privoxy Home page. http://www.privoxy.org/faq/, - the Privoxy FAQ. + url="http://www.privoxy.org/faq/">http://www.privoxy.org/faq/, + the Privoxy FAQ. http://www.privoxy.org/developer-manual/, - the Privoxy developer manual. + url="http://www.privoxy.org/developer-manual/">http://www.privoxy.org/developer-manual/, + the Privoxy developer manual. - https://sourceforge.net/projects/ijbswa/, - the Project Page for Privoxy on + https://sourceforge.net/projects/ijbswa/, + the Project Page for Privoxy on SourceForge. @@ -71,7 +71,7 @@ https://sourceforge.net/tracker/?group_id=11118&atid=460288, to submit misses and other - configuration related suggestions to the developers. + configuration related suggestions to the developers. - https://www.torproject.org/, - Tor can help anonymize web browsing, + https://www.torproject.org/, + Tor can help anonymize web browsing, web publishing, instant messaging, IRC, SSH, and other applications. diff --git a/doc/source/supported.sgml b/doc/source/supported.sgml index 274091f7..728e70ee 100644 --- a/doc/source/supported.sgml +++ b/doc/source/supported.sgml @@ -2,8 +2,8 @@ File : $Source: /cvsroot/ijbswa/current/doc/source/supported.sgml,v $ Purpose : Entity included in other project documents. - - $Id: supported.sgml,v 2.8 2007/10/30 17:49:04 fabiankeil Exp $ + + $Id: supported.sgml,v 2.9 2008/01/17 01:49:51 hal9 Exp $ Copyright (C) 2001-2008 Privoxy Developers http://www.privoxy.org/ See LICENSE. @@ -12,7 +12,7 @@ This file used for inclusion with other documents only. ====================================================================== - If you make changes to this file, please verify the finished + If you make changes to this file, please verify the finished docs all display as intended. This file is included into: @@ -34,13 +34,13 @@ But any operating system that runs TCP/IP, can conceivably take advantage of Privoxy in a networked situation where - Privoxy would run as a server on a LAN gateway. + Privoxy would run as a server on a LAN gateway. Then only the gateway needs to be running one of the above operating systems. - Source code is freely available, so porting to other operating systems + Source code is freely available, so porting to other operating systems is always a possibility. ]]> diff --git a/doc/source/user-manual.sgml b/doc/source/user-manual.sgml index 1242d1e1..408a6128 100644 --- a/doc/source/user-manual.sgml +++ b/doc/source/user-manual.sgml @@ -1,5 +1,5 @@ + @@ -34,13 +34,13 @@ This file belongs into ijbswa.sourceforge.net:/home/groups/i/ij/ijbswa/htdocs/ - $Id: user-manual.sgml,v 2.133 2011/08/18 11:42:50 fabiankeil Exp $ + $Id: user-manual.sgml,v 2.134 2011/08/18 11:45:02 fabiankeil Exp $ Copyright (C) 2001-2011 Privoxy Developers http://www.privoxy.org/ See LICENSE. ======================================================================== - NOTE: Please read developer-manual/documentation.html before touching + NOTE: Please read developer-manual/documentation.html before touching anything in this, or other Privoxy documentation. ======================================================================== @@ -60,7 +60,7 @@ -$Id: user-manual.sgml,v 2.133 2011/08/18 11:42:50 fabiankeil Exp $ +$Id: user-manual.sgml,v 2.134 2011/08/18 11:45:02 fabiankeil Exp $ Features - In addition to the core - features of ad blocking and + In addition to the core + features of ad blocking and cookie management, Privoxy provides many supplemental - features, + features, that give the end-user more control, more privacy and more freedom: @@ -165,14 +165,14 @@ Hal. - Note: - On some platforms, the installer may remove previously installed versions, if + Note: + On some platforms, the installer may remove previously installed versions, if found. (See below for your platform). In any case be sure to backup your old configuration if it is valuable to you. See the note to upgraders section below. - + Binary Packages How to install the binary packages depends on your operating system: @@ -185,7 +185,7 @@ How to install the binary packages depends on your operating system: RPMs can be installed with rpm -Uvh privoxy-&p-version;-1.rpm, - and will use /etc/privoxy for the location + and will use /etc/privoxy for the location of configuration files. @@ -193,13 +193,13 @@ How to install the binary packages depends on your operating system: Note that on Red Hat, Privoxy will not be automatically started on system boot. You will need to enable that using chkconfig, - ntsysv, or similar methods. + ntsysv, or similar methods. - If you have problems with failed dependencies, try rebuilding the SRC RPM: - rpm --rebuild privoxy-&p-version;-1.src.rpm. This - will use your locally installed libraries and RPM version. + If you have problems with failed dependencies, try rebuilding the SRC RPM: + rpm --rebuild privoxy-&p-version;-1.src.rpm. This + will use your locally installed libraries and RPM version. @@ -214,7 +214,7 @@ How to install the binary packages depends on your operating system: Debian and Ubuntu DEBs can be installed with apt-get install privoxy, - and will use /etc/privoxy for the location of + and will use /etc/privoxy for the location of configuration files. @@ -225,7 +225,7 @@ How to install the binary packages depends on your operating system: Just double-click the installer, which will guide you through the installation process. You will find the configuration files - in the same directory as you installed Privoxy in. + in the same directory as you installed Privoxy in. Version 3.0.5 beta introduced full Windows service @@ -256,7 +256,7 @@ How to install the binary packages depends on your operating system: command: services.msc. If you do not take the manual step of modifying Privoxy's service settings, it will not start. Note too that you will need to give Privoxy a user account that - actually exists, or it will not be permitted to + actually exists, or it will not be permitted to write to its log and configuration files. @@ -277,7 +277,7 @@ How to install the binary packages depends on your operating system: First, make sure that no previous installations of - Junkbuster and / or + Junkbuster and / or Privoxy are left on your system. Check that no Junkbuster or Privoxy objects are in @@ -311,7 +311,7 @@ How to install the binary packages depends on your operating system: installation (in addition to every time your computer starts up). To prevent the privoxy service from automatically starting when your computer starts up, remove or rename the folder named - /Library/StartupItems/Privoxy. + /Library/StartupItems/Privoxy. To manually start or stop the privoxy service, use the Privoxy Utility @@ -323,9 +323,9 @@ How to install the binary packages depends on your operating system: AmigaOS - Copy and then unpack the lha archive to a suitable location. + Copy and then unpack the lha archive to a suitable location. All necessary files will be installed into Privoxy - directory, including all configuration and log files. To uninstall, just + directory, including all configuration and log files. To uninstall, just remove this directory. @@ -352,19 +352,19 @@ How to install the binary packages depends on your operating system: Gentoo - Gentoo source packages (Ebuilds) for Privoxy are - contained in the Gentoo Portage Tree (they are not on the download page, - but there is a Gentoo section, where you can see when a new + Gentoo source packages (Ebuilds) for Privoxy are + contained in the Gentoo Portage Tree (they are not on the download page, + but there is a Gentoo section, where you can see when a new Privoxy Version is added to the Portage Tree). - Before installing Privoxy under Gentoo just do - first emerge --sync to get the latest changes from the - Portage tree. With emerge privoxy you install the latest + Before installing Privoxy under Gentoo just do + first emerge --sync to get the latest changes from the + Portage tree. With emerge privoxy you install the latest version. - Configuration files are in /etc/privoxy, the + Configuration files are in /etc/privoxy, the documentation is in /usr/share/doc/privoxy-&p-version; and the Log directory is in /var/log/privoxy. @@ -377,7 +377,7 @@ How to install the binary packages depends on your operating system: The most convenient way to obtain the Privoxy sources - is to download the source tarball from our + is to download the source tarball from our project download page. @@ -386,8 +386,8 @@ How to install the binary packages depends on your operating system: If you like to live on the bleeding edge and are not afraid of using possibly unstable development versions, you can check out the up-to-the-minute version directly from the - CVS repository. - - + Keeping your Installation Up-to-Date As user feedback comes in and development continues, we will make updated versions @@ -420,7 +420,7 @@ How to install the binary packages depends on your operating system: In order not to lose your personal changes and adjustments when updating to the latest default.action file we strongly - recommend that you use user.action and + recommend that you use user.action and user.filter for your local customizations of Privoxy. See the Chapter on actions files for details. @@ -959,7 +959,7 @@ How to install the binary packages depends on your operating system: Note to Upgraders - A quick list of things to be aware of before upgrading from earlier + A quick list of things to be aware of before upgrading from earlier versions of Privoxy: @@ -968,7 +968,7 @@ How to install the binary packages depends on your operating system: - The recommended way to upgrade &my-app; is to backup your old + The recommended way to upgrade &my-app; is to backup your old configuration files, install the new ones, verify that &my-app; is working correctly and finally merge back your changes using diff and maybe patch. @@ -982,20 +982,20 @@ How to install the binary packages depends on your operating system: - + Note that some installers remove earlier versions completely, including configuration files, therefore you should really save any important configuration files! - - On the other hand, other installers don't overwrite existing configuration + + On the other hand, other installers don't overwrite existing configuration files, thinking you will want to do that yourself. - + standard.action has been merged into the default.action file. @@ -1012,21 +1012,21 @@ How to install the binary packages depends on your operating system: - Three other config file settings are now off by default: + Three other config file settings are now off by default: enable-remote-toggle, enable-remote-http-toggle, - and enable-edit-actions. + and enable-edit-actions. If you use or want these, you will need to explicitly enable them, and - be aware of the security issues involved. + be aware of the security issues involved. @@ -1100,19 +1100,19 @@ How to install the binary packages depends on your operating system: Install Privoxy. See the Installation Section below for platform specific - information. + information. - + Advanced users and those who want to offer Privoxy service to more than just their local machine should check the main config file, especially the security-relevant options. These are + linkend="access-control">security-relevant options. These are off by default. - + @@ -1128,26 +1128,26 @@ How to install the binary packages depends on your operating system: HTTPS (SSL) proxy by setting the proxy configuration for address of 127.0.0.1 and port 8118. - DO NOT activate proxying for FTP or + DO NOT activate proxying for FTP or any protocols besides HTTP and HTTPS (SSL) unless you intend to prevent your browser from using these protocols. - + Flush your browser's disk and memory caches, to remove any cached ad images. - If using Privoxy to manage + If using Privoxy to manage cookies, you should remove any currently stored cookies too. - + - A default installation should provide a reasonable starting point for + A default installation should provide a reasonable starting point for most. There will undoubtedly be occasions where you will want to adjust the - configuration, but that can be dealt with as the need arises. Little + configuration, but that can be dealt with as the need arises. Little to no initial configuration is required in most cases, you may want to enable the web-based action editor though. @@ -1161,7 +1161,7 @@ How to install the binary packages depends on your operating system: introduction to how Privoxy blocks ads and banners. - + @@ -1176,7 +1176,7 @@ How to install the binary packages depends on your operating system: Action has hints on how to understand and debug actions that misbehave. - + Please see the section Contacting the Developers on how to report bugs, problems with websites or to get - help. + help. - + Now enjoy surfing with enhanced control, comfort and privacy! - + @@ -1213,35 +1213,35 @@ How to install the binary packages depends on your operating system: Quickstart to Ad Blocking Ad blocking is but one of Privoxy's - array of features. Many of these features are for the technically minded advanced + array of features. Many of these features are for the technically minded advanced user. But, ad and banner blocking is surely common ground for everybody. - - This section will provide a quick summary of ad blocking so + + This section will provide a quick summary of ad blocking so you can get up to speed quickly without having to read the more extensive information provided below, though this is highly recommended. First a bit of a warning ... blocking ads is much like blocking SPAM: the - more aggressive you are about it, the more likely you are to block - things that were not intended. And the more likely that some things + more aggressive you are about it, the more likely you are to block + things that were not intended. And the more likely that some things may not work as intended. So there is a trade off here. If you want extreme ad free browsing, be prepared to deal with more problem sites, and to spend more time adjusting the - configuration to solve these unintended consequences. In short, there is - not an easy way to eliminate all ads. Either take + configuration to solve these unintended consequences. In short, there is + not an easy way to eliminate all ads. Either take the easy way and settle for most ads blocked with the default configuration, or jump in and tweak it for your personal surfing habits and preferences. Secondly, a brief explanation of Privoxy's - actions. Actions in this context, are + actions. Actions in this context, are the directives we use to tell Privoxy to perform some task relating to HTTP transactions (i.e. web browsing). We tell Privoxy to take some action. Each @@ -1253,7 +1253,7 @@ How to install the binary packages depends on your operating system: Actions are specified in Privoxy's configuration, - followed by one or more URLs to which the action should apply. URLs + followed by one or more URLs to which the action should apply. URLs can actually be URL type patterns that use wildcards so they can apply potentially to a range of similar URLs. The actions, together with the URL patterns are called a section. @@ -1276,7 +1276,7 @@ How to install the binary packages depends on your operating system: The most important actions for basic ad blocking are: block, handle-as-image, + linkend="handle-as-image">handle-as-image, handle-as-empty-document,and set-image-blocker: @@ -1284,10 +1284,10 @@ How to install the binary packages depends on your operating system: - + - block - this is perhaps + block - this is perhaps the single most used action, and is particularly important for ad blocking. This action stops any contact between your browser and any URL patterns that match this action's configuration. It can be used for blocking ads, @@ -1296,32 +1296,32 @@ How to install the binary packages depends on your operating system: Privoxy's own built-in BLOCKED page instead to let you now what has happened (with some exceptions, see below). - + - handle-as-image - + handle-as-image - tells Privoxy to treat this URL as an image. Privoxy's default configuration already does this for all common image types (e.g. GIF), but there are many situations where this is not so easy to determine. So we'll force it in these cases. This is particularly important for ad blocking, since only if we know that it's an image of - some kind, can we replace it with an image of our choosing, instead of the + some kind, can we replace it with an image of our choosing, instead of the Privoxy BLOCKED page (which would only result in a broken image icon). There are some limitations to this though. For instance, you can't just brute-force an image substitution for an entire HTML page in most situations. - + - handle-as-empty-document - - sends an empty document instead of Privoxy's - normal BLOCKED HTML page. This is useful for file types that are neither + handle-as-empty-document - + sends an empty document instead of Privoxy's + normal BLOCKED HTML page. This is useful for file types that are neither HTML nor images, such as blocking JavaScript files. - + @@ -1338,7 +1338,7 @@ How to install the binary packages depends on your operating system: -    pattern - a checkerboard pattern, so that an ad +    pattern - a checkerboard pattern, so that an ad replacement is obvious. This is the default. @@ -1354,14 +1354,14 @@ How to install the binary packages depends on your operating system: of the user's choosing (advanced usage). - + Advanced users will eventually want to explore &my-app; - filters as well. Filters + filters as well. Filters are very different from blocks. A block blocks a site, page, or unwanted contented. Filters @@ -1376,7 +1376,7 @@ How to install the binary packages depends on your operating system: The quickest way to adjust any of these settings is with your browser through the special Privoxy editor at http://config.privoxy.org/show-status - (shortcut: http://p.p/show-status). This + (shortcut: http://p.p/show-status). This is an internal page, and does not require Internet access. @@ -1408,21 +1408,21 @@ How to install the binary packages depends on your operating system: - Right click on the ad image to be blocked, then select + Right click on the ad image to be blocked, then select Copy Link Location from the - pop-up menu. + pop-up menu. - + - Set your browser to + Set your browser to http://config.privoxy.org/show-status - + - Find user.action in the top section, and click + Find user.action in the top section, and click on Edit: @@ -1432,29 +1432,29 @@ How to install the binary packages depends on your operating system: - + [ Screenshot of Actions Files in Use ] - - + + You should have a section with only - block listed under + block listed under Actions:. If not, click a Insert new section below - button, and in the new section that just appeared, click the + button, and in the new section that just appeared, click the Edit button right under the word Actions:. This will bring up a list of all actions. Find block near the top, and click in the Enabled column, then Submit just below the list. - + Now, in the block actions section, @@ -1464,21 +1464,21 @@ How to install the binary packages depends on your operating system: Submit (or OK if in a pop-up window). - + Now go back to the original page, and press SHIFT-Reload (or flush all browser caches). The image should be gone now. - - + + - This is a very crude and simple example. There might be good reasons to use a + This is a very crude and simple example. There might be good reasons to use a wildcard pattern match to include potentially similar images from the same - site. For a more extensive explanation of patterns, and + site. For a more extensive explanation of patterns, and the entire actions concept, see the Actions section. @@ -1489,11 +1489,11 @@ How to install the binary packages depends on your operating system: The ideas explained therein also apply to the web-based editor. - There are also various - filters that can be used for ad blocking - (filters are a special subset of actions). These + There are also various + filters that can be used for ad blocking + (filters are a special subset of actions). These fall into the advanced usage category, and are explained in - depth in later sections. + depth in later sections. @@ -1509,14 +1509,14 @@ How to install the binary packages depends on your operating system: Before launching Privoxy for the first time, you will want to configure your browser(s) to use - Privoxy as a HTTP and HTTPS (SSL) + Privoxy as a HTTP and HTTPS (SSL) proxy. The default is 127.0.0.1 (or localhost) for the proxy address, and port 8118 (earlier versions used port 8000). This is the one configuration step that must be done ! - Please note that Privoxy can only proxy HTTP and + Please note that Privoxy can only proxy HTTP and HTTPS traffic. It will not work with FTP or other protocols. @@ -1527,35 +1527,35 @@ How to install the binary packages depends on your operating system: - + [ Screenshot of Mozilla Proxy Configuration ] - - + + With Firefox, this is typically set under: - + Tools -> Options -> Advanced -> Network ->Connection -> Settings - + Or optionally on some platforms: - + Edit -> Preferences -> General -> Connection Settings -> Manual Proxy Configuration - + With Netscape (and Mozilla), this can be set under: @@ -1569,7 +1569,7 @@ How to install the binary packages depends on your operating system: - For Internet Explorer v.5-7: + For Internet Explorer v.5-7: @@ -1591,7 +1591,7 @@ How to install the binary packages depends on your operating system: - + [ Screenshot of IE Proxy Configuration ] @@ -1602,7 +1602,7 @@ How to install the binary packages depends on your operating system: After doing this, flush your browser's disk and memory caches to force a - re-reading of all pages and to get rid of any ads that may be cached. Remove + re-reading of all pages and to get rid of any ads that may be cached. Remove any cookies, if you want Privoxy to manage that. You are now ready to start enjoying the benefits of using @@ -1666,7 +1666,7 @@ Click on the &my-app; Icon to start Privoxy. If no co Privoxy can run with full Windows service functionality. On Windows only, the &my-app; program has two new command line arguments - to install and uninstall &my-app; as a service. See the + to install and uninstall &my-app; as a service. See the Windows Installation instructions for details. @@ -1733,7 +1733,7 @@ Example Unix startup command: Start Privoxy (with RUN <>NIL:) in your startnet script (AmiTCP), in s:user-startup (RoadShow), as startup program in your - startup script (Genesis), or as startup action (Miami and MiamiDx). + startup script (Genesis), or as startup action (Miami and MiamiDx). Privoxy will automatically quit when you quit your TCP/IP stack (just ignore the harmless warning your TCP/IP stack may display that Privoxy is still running). @@ -1743,7 +1743,7 @@ Example Unix startup command: Gentoo - A script is again used. It will use the file /etc/privoxy/config + A script is again used. It will use the file /etc/privoxy/config as its main configuration file. @@ -1752,11 +1752,11 @@ Example Unix startup command: - Note that Privoxy is not automatically started at - boot time by default. You can change this with the rc-update + Note that Privoxy is not automatically started at + boot time by default. You can change this with the rc-update command. - + rc-update add privoxy default @@ -1778,7 +1778,7 @@ must find a better place for this paragraph actions files. These are where various cookie actions are defined, ad and banner blocking, and other aspects of Privoxy configuration. There are several - such files included, with varying levels of aggressiveness. + such files included, with varying levels of aggressiveness. @@ -1798,7 +1798,7 @@ must find a better place for this paragraph sites is the popup-killing (through +filter{popups}), because your favorite shopping, banking, or leisure site may need - popups (explained below). + popups (explained below). @@ -1814,24 +1814,24 @@ must find a better place for this paragraph - After running Privoxy for a while, you can - start to fine tune the configuration to suit your personal, or site, - preferences and requirements. There are many, many aspects that can - be customized. Actions - can be adjusted by pointing your browser to + After running Privoxy for a while, you can + start to fine tune the configuration to suit your personal, or site, + preferences and requirements. There are many, many aspects that can + be customized. Actions + can be adjusted by pointing your browser to http://config.privoxy.org/ - (shortcut: http://p.p/), - and then follow the link to View & Change the Current Configuration. + (shortcut: http://p.p/), + and then follow the link to View & Change the Current Configuration. (This is an internal page and does not require Internet access.) In fact, various aspects of Privoxy - configuration can be viewed from this page, including - current configuration parameters, source code version numbers, - the browser's request headers, and actions that apply - to a given URL. In addition to the actions file - editor mentioned above, Privoxy can also + configuration can be viewed from this page, including + current configuration parameters, source code version numbers, + the browser's request headers, and actions that apply + to a given URL. In addition to the actions file + editor mentioned above, Privoxy can also be turned on and off (toggled) from this page. @@ -1854,9 +1854,9 @@ must find a better place for this paragraph If you can't get rid of the problem at all, think you've found a bug in - Privoxy, want to propose a new feature or smarter rules, please see the + Privoxy, want to propose a new feature or smarter rules, please see the section Contacting the - Developers below. + Developers below. --> @@ -1879,7 +1879,7 @@ must find a better place for this paragraph Print version info and exit. Unix only. - + --help @@ -1887,7 +1887,7 @@ must find a better place for this paragraph Print short usage info and exit. Unix only. - + --no-daemon @@ -1896,7 +1896,7 @@ must find a better place for this paragraph Don't become a daemon, i.e. don't fork and become process group leader, and don't detach from controlling tty. Unix only. - + --pidfile FILE @@ -1907,7 +1907,7 @@ must find a better place for this paragraph FILE is non-fatal. If no FILE option is given, no PID file will be used. Unix only. - + --user USER[.GROUP] @@ -1923,9 +1923,9 @@ must find a better place for this paragraph --chroot - Before changing to the user ID given in the --user option, + Before changing to the user ID given in the --user option, chroot to that user's home directory, i.e. make the kernel pretend to the &my-app; - process that the directory tree starts there. If set up carefully, this can limit + process that the directory tree starts there. If set up carefully, this can limit the impact of possible vulnerabilities in &my-app; to the files contained in that hierarchy. Unix only. @@ -1953,23 +1953,23 @@ must find a better place for this paragraph configfile - If no configfile is included on the command line, - Privoxy will look for a file named - config in the current directory (except on Win32 - where it will look for config.txt instead). Specify - full path to avoid confusion. If no config file is found, + If no configfile is included on the command line, + Privoxy will look for a file named + config in the current directory (except on Win32 + where it will look for config.txt instead). Specify + full path to avoid confusion. If no config file is found, Privoxy will fail to start. - + - On MS Windows only there are two additional - command-line options to allow Privoxy to install and - run as a service. See the -Window Installation section + On MS Windows only there are two additional + command-line options to allow Privoxy to install and + run as a service. See the +Window Installation section for details. @@ -1983,9 +1983,9 @@ for details. Privoxy Configuration - All Privoxy configuration is stored + All Privoxy configuration is stored in text files. These files can be edited with a text editor. - Many important aspects of Privoxy can + Many important aspects of Privoxy can also be controlled easily with a web browser. @@ -1995,9 +1995,9 @@ for details. Controlling Privoxy with Your Web Browser - Privoxy's user interface can be reached through the special + Privoxy's user interface can be reached through the special URL http://config.privoxy.org/ - (shortcut: http://p.p/), + (shortcut: http://p.p/), which is a built-in page and works without Internet access. You will see the following section: @@ -2039,14 +2039,14 @@ for details. cookie, and URL blocking magic is configured as well as other advanced features of Privoxy. This is an easy way to adjust various aspects of Privoxy configuration. The actions - file, and other configuration files, are explained in detail below. + file, and other configuration files, are explained in detail below. - Toggle Privoxy On or Off is handy for sites that might + Toggle Privoxy On or Off is handy for sites that might have problems with your current actions and filters. You can in fact use - it as a test to see whether it is Privoxy - causing the problem or not. Privoxy continues + it as a test to see whether it is Privoxy + causing the problem or not. Privoxy continues to run as a proxy in this case, but all manipulation is disabled, i.e. Privoxy acts like a normal forwarding proxy. There is even a toggle Bookmarklet offered, so @@ -2076,14 +2076,14 @@ for details. For Unix, *BSD and Linux, all configuration files are located in /etc/privoxy/ by default. For MS Windows, OS/2, and - AmigaOS these are all in the same directory as the + AmigaOS these are all in the same directory as the Privoxy executable. - The installed defaults provide a reasonable starting point, though + The installed defaults provide a reasonable starting point, though some settings may be aggressive by some standards. For the time being, the principle configuration files are: @@ -2097,7 +2097,7 @@ for details. on Linux, Unix, BSD, OS/2, and AmigaOS and config.txt on Windows. This is a required file. - + @@ -2111,23 +2111,23 @@ for details. It should be the second actions file loaded and shouldn't be edited by the user. - Multiple actions files may be defined in config. These - are processed in the order they are defined. Local customizations and locally + Multiple actions files may be defined in config. These + are processed in the order they are defined. Local customizations and locally preferred exceptions to the default policies as defined in match-all.action (which you will most probably want to define sooner or later) are best applied in user.action, where you can preserve them across upgrades. The file isn't installed by all installers, but you can easily create it yourself with a text editor. - + There is also a web based editor that can be accessed from http://config.privoxy.org/show-status (Shortcut: http://p.p/show-status) for the - various actions files. + various actions files. - + @@ -2135,15 +2135,15 @@ for details. file) can be used to re-write the raw page content, including viewable text as well as embedded HTML and JavaScript, and whatever else lurks on any given web page. The filtering jobs are only pre-defined here; - whether to apply them or not is up to the actions files. - default.filter includes various filters made - available for use by the developers. Some are much more intrusive than - others, and all should be used with caution. You may define additional - filter files in config as you can with - actions files. We suggest user.filter for any + whether to apply them or not is up to the actions files. + default.filter includes various filters made + available for use by the developers. Some are much more intrusive than + others, and all should be used with caution. You may define additional + filter files in config as you can with + actions files. We suggest user.filter for any locally defined filters or customizations. - + @@ -2165,15 +2165,15 @@ for details. - The actions files and filter files + The actions files and filter files can use Perl style regular expressions for - maximum flexibility. + maximum flexibility. After making any changes, there is no need to restart Privoxy in order for the changes to take - effect. Privoxy detects such changes + effect. Privoxy detects such changes automatically. Note, however, that it may take one or two additional requests for the change to take effect. When changing the listening address of Privoxy, these wake up requests @@ -2182,9 +2182,9 @@ for details. - While under development, the configuration content is subject to change. - The below documentation may not be accurate by the time you read this. - Also, what constitutes a default setting, may change, so + While under development, the configuration content is subject to change. + The below documentation may not be accurate by the time you read this. + Also, what constitutes a default setting, may change, so please check all your configuration files on important issues. ]]> @@ -2220,15 +2220,15 @@ for details. The actions files are used to define what actions Privoxy takes for which URLs, and thus determines how ad images, cookies and various other aspects of HTTP content and - transactions are handled, and on which sites (or even parts thereof). + transactions are handled, and on which sites (or even parts thereof). There are a number of such actions, with a wide range of functionality. Each action does something a little different. - These actions give us a veritable arsenal of tools with which to exert - our control, preferences and independence. Actions can be combined so that + These actions give us a veritable arsenal of tools with which to exert + our control, preferences and independence. Actions can be combined so that their effects are aggregated when applied against a given set of URLs. - + - There + There are three action files included with Privoxy with differing purposes: @@ -2241,7 +2241,7 @@ for details. content modification, cookie handling etc should be applied by default. It should be the first actions file loaded - + default.action - defines many exceptions (both @@ -2250,15 +2250,15 @@ for details. work reasonably well as-is for most users. This file is only supposed to be edited by the developers. It should be the second actions file loaded. - + - user.action - is intended to be for local site + user.action - is intended to be for local site preferences and exceptions. As an example, if your ISP or your bank - has specific requirements, and need special handling, this kind of + has specific requirements, and need special handling, this kind of thing should go here. This file will not be upgraded. - + Edit Set to Cautious Set to Medium Set to Advanced @@ -2266,16 +2266,16 @@ for details. These have increasing levels of aggressiveness and have no influence on your browsing unless you select them explicitly in the - editor. A default installation should be pre-set to + editor. A default installation should be pre-set to Cautious. New users should try this for a while before - adjusting the settings to more aggressive levels. The more aggressive - the settings, then the more likelihood there is of problems such as sites + adjusting the settings to more aggressive levels. The more aggressive + the settings, then the more likelihood there is of problems such as sites not working as they should. - The Edit button allows you to turn each + The Edit button allows you to turn each action on/off individually for fine-tuning. The Cautious - button changes the actions list to low/safe settings which will activate + button changes the actions list to low/safe settings which will activate ad blocking and a minimal set of &my-app;'s features, and subsequently there will be less of a chance for accidental problems. The Medium button sets the list to a medium level of @@ -2346,7 +2346,7 @@ for details. blocks only blocks only - + Privacy Features low @@ -2415,12 +2415,12 @@ for details. - + - + - The list of actions files to be used are defined in the main configuration + The list of actions files to be used are defined in the main configuration file, and are processed in the order they are defined (e.g. default.action is typically processed before user.action). The content of these can all be viewed and @@ -2431,7 +2431,7 @@ for details. (defined in default.action), followed by any exceptions (typically also in default.action), which are then followed lastly by any - local preferences (typically in user.action). + local preferences (typically in user.action). Generally, user.action has the last word. @@ -2441,7 +2441,7 @@ for details. alias section at the top of that file. Then comes the default set of rules which will apply universally to all sites and pages (be very careful with using such a - universal set in user.action or any other actions file after + universal set in user.action or any other actions file after default.action, because it will override the result from consulting any previous file). And then below that, exceptions to the defined universal policies. You can regard @@ -2450,7 +2450,7 @@ for details. personal settings across Privoxy upgrades easier. - + Actions can be used to block anything you want, including ads, banners, or just some obnoxious URL whose content you would rather not see. Cookies can be accepted or rejected, or accepted only during the current browser session (i.e. not @@ -2466,7 +2466,7 @@ for details. Note that some actions, like cookie suppression or script disabling, may render some sites unusable that rely on these techniques to work properly. Finding the right mix of actions is not always easy and - certainly a matter of personal taste. And, things can always change, requiring + certainly a matter of personal taste. And, things can always change, requiring refinements in the configuration. In general, it can be said that the more aggressive your default settings (in the top section of the actions file) are, the more exceptions for trusted sites you @@ -2498,13 +2498,13 @@ for details. like Cautious, Medium or Advanced. Warning: the Advanced setting is more aggressive, and will be more likely to cause problems for some sites. - Experienced users only! + Experienced users only! If you prefer plain text editing to GUIs, you can of course also directly edit the the actions files with your favorite text editor. Look at - default.action which is richly commented with many + default.action which is richly commented with many good examples. @@ -2532,12 +2532,12 @@ for details. If multiple applying sections set the same action differently, the last match wins. If not, the effects are aggregated. - E.g. a URL might match a regular section with a heading line of { + E.g. a URL might match a regular section with a heading line of { +handle-as-image }, then later another one with just { +block }, resulting - in both actions to apply. And there may well be - cases where you will want to combine actions together. Such a section then + in both actions to apply. And there may well be + cases where you will want to combine actions together. Such a section then might look like: @@ -2564,7 +2564,7 @@ for details. Patterns - + As mentioned, Privoxy uses patterns to determine what actions might apply to which sites and pages your browser attempts to access. These patterns use wild @@ -2572,7 +2572,7 @@ for details. flexibility. This allows one expression to be expanded and potentially match against many similar patterns. - + Generally, an URL pattern has the form <domain><port>/<path>, where the @@ -2584,8 +2584,8 @@ for details. The pattern matching syntax is different for the domain and path parts of - the URL. The domain part uses a simple globbing type matching technique, - while the path part uses more flexible + the URL. The domain part uses a simple globbing type matching technique, + while the path part uses more flexible Regular Expressions (POSIX 1003.2). @@ -2603,7 +2603,7 @@ for details. is a domain-only pattern and will match any request to www.example.com, regardless of which document on that server is requested. So ALL pages in - this domain would be covered by the scope of this action. Note that a + this domain would be covered by the scope of this action. Note that a simple example.com is different and would NOT match. @@ -2675,7 +2675,7 @@ for details. matches nothing, since it would be interpreted as a domain name and - there is no top-level domain called .html. So its + there is no top-level domain called .html. So its a mistake. @@ -2688,7 +2688,7 @@ for details. The matching of the domain part offers some flexible options: if the - domain starts or ends with a dot, it becomes unanchored at that end. + domain starts or ends with a dot, it becomes unanchored at that end. For example: @@ -2726,7 +2726,7 @@ for details. a domain.) This might be www.example.com, news.example.de, or www.example.net/cgi/testing.pl for instance. All these - cases are matched. + cases are matched. @@ -2736,12 +2736,12 @@ for details. Additionally, there are wild-cards that you can use in the domain names themselves. These work similarly to shell globbing type wild-cards: * represents zero or more arbitrary characters (this is - equivalent to the + equivalent to the Regular Expression based syntax of .*), ? represents any single character (this is equivalent to the regular expression syntax of a simple .), and you can define - character classes in square brackets which is similar to + character classes in square brackets which is similar to the same regular expression technique. All of this can be freely mixed: @@ -2750,7 +2750,7 @@ for details. ad*.example.com - matches adserver.example.com, + matches adserver.example.com, ads.example.com, etc but not sfads.example.com @@ -2768,7 +2768,7 @@ for details. matches www.ipix.com, - pictures.epix.com, a.b.c.d.e.upix.com etc. + pictures.epix.com, a.b.c.d.e.upix.com etc. @@ -2776,9 +2776,9 @@ for details. www[1-9a-ez].example.c* - matches www1.example.com, - www4.example.cc, wwwd.example.cy, - wwwz.example.com etc., but not + matches www1.example.com, + www4.example.cc, wwwd.example.cy, + wwwz.example.com etc., but not wwww.example.com. @@ -2812,13 +2812,13 @@ for details. Note that the path pattern is automatically left-anchored at the /, - i.e. it matches as if it would start with a ^ (regular expression speak + i.e. it matches as if it would start with a ^ (regular expression speak for the beginning of a line). Please also note that matching in the path is CASE INSENSITIVE - by default, but you can switch to case sensitive at any point in the pattern by using the + by default, but you can switch to case sensitive at any point in the pattern by using the (?-i) switch: www.example.com/(?-i)PaTtErN.* will match only documents whose path starts with PaTtErN in exactly this capitalization. @@ -2829,7 +2829,7 @@ for details. .example.com/.* - Is equivalent to just .example.com, since any documents + Is equivalent to just .example.com, since any documents within that domain are matched with or without the .* regular expression. This is redundant @@ -2843,9 +2843,9 @@ for details. named index.html, and that is part of some path. For example, it matches www.example.com/testing/index.html but NOT www.example.com/index.html because the regular - expression called for at least two /'s, thus the path - requirement. It also would match - www.example.com/testing/index_html, because of the + expression called for at least two /'s, thus the path + requirement. It also would match + www.example.com/testing/index_html, because of the special meta-character .. @@ -2854,9 +2854,9 @@ for details. .example.com/(.*/)?index\.html$ - This regular expression is conditional so it will match any page - named index.html regardless of path which in this case can - have one or more /'s. And this one must contain exactly + This regular expression is conditional so it will match any page + named index.html regardless of path which in this case can + have one or more /'s. And this one must contain exactly .html (but does not have to end with that!). @@ -2866,7 +2866,7 @@ for details. This regular expression will match any path of example.com - that contains any of the words ads, banner, + that contains any of the words ads, banner, banners (because of the ?) or junk. The path does not have to end in these words, just contain them. @@ -2876,8 +2876,8 @@ for details. .example.com/(.*/)(ads|banners?|junk)/.*\.(jpe?g|gif|png)$ - This is very much the same as above, except now it must end in either - .jpg, .jpeg, .gif or .png. So this + This is very much the same as above, except now it must end in either + .jpg, .jpeg, .gif or .png. So this one is limited to common image formats. @@ -2885,7 +2885,7 @@ for details. - There are many, many good examples to be found in default.action, + There are many, many good examples to be found in default.action, and more tutorials below in Appendix on regular expressions. @@ -2975,23 +2975,23 @@ for details. - + Again, actions are invoked by placing them on a line, enclosed in curly braces and - separated by whitespace, like in + separated by whitespace, like in {+some-action -some-other-action{some-parameter}}, followed by a list of URL patterns, one per line, to which they apply. Together, the actions line and the following pattern lines make up a section - of the actions file. + of the actions file. - + Actions fall into three categories: - + Boolean, i.e the action can only be enabled or disabled. Syntax: @@ -3000,14 +3000,14 @@ for details. +name # enable action name -name # disable action name - + Example: +handle-as-image - + Parameterized, where some value is required in order to enable this type of action. Syntax: @@ -3021,13 +3021,13 @@ for details. Note that if the URL matches multiple positive forms of a parameterized action, the last match wins, i.e. the params from earlier matches are simply ignored. - + Example: +hide-user-agent{Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.8.1.4) Gecko/20070602 Firefox/2.0.0.4} - + - + Multi-value. These look exactly like parameterized actions, but they behave differently: If the action applies multiple times to the same URL, but with different parameters, all the parameters @@ -3042,7 +3042,7 @@ for details. # If it was the last one left, disable the action. -name # disable this action completely and remove all parameters from the list - + Examples: +add-header{X-Fun-Header: Some text} and +filter{html-annoyances} @@ -3061,8 +3061,8 @@ for details. Later defined action sections always over-ride earlier ones of the same type. - So exceptions to any rules you make, should come in the latter part of the file (or - in a file that is processed later when using multiple actions files such + So exceptions to any rules you make, should come in the latter part of the file (or + in a file that is processed later when using multiple actions files such as user.action). For multi-valued actions, the actions are applied in the order they are specified. Actions files are processed in the order they are defined in config (the default @@ -3114,7 +3114,7 @@ for details. Multi-value. - + Parameter: @@ -3125,14 +3125,14 @@ for details. - + Notes: - This action may be specified multiple times, in order to define multiple - headers. This is rarely needed for the typical user. If you don't know what - HTTP headers are, you definitely don't need to worry about this + This action may be specified multiple times, in order to define multiple + headers. This is rarely needed for the typical user. If you don't know what + HTTP headers are, you definitely don't need to worry about this one. @@ -3175,10 +3175,10 @@ for details. the handle-as-image, set-image-blocker, and + linkend="set-image-blocker">set-image-blocker, and handle-as-empty-document actions. - + @@ -3197,7 +3197,7 @@ for details. A block reason that should be given to the user. - + Notes: @@ -3208,18 +3208,18 @@ for details. to the blocked content (the latter only if the force feature is available and enabled). - - A very important exception occurs if both + + A very important exception occurs if both block and handle-as-image, - apply to the same request: it will then be replaced by an image. If + apply to the same request: it will then be replaced by an image. If set-image-blocker (see below) also applies, the type of image will be determined by its parameter, if not, the standard checkerboard pattern is sent. - It is important to understand this process, in order - to understand how Privoxy deals with - ads and other unwanted content. Blocking is a core feature, and one + It is important to understand this process, in order + to understand how Privoxy deals with + ads and other unwanted content. Blocking is a core feature, and one upon which various other features depend. @@ -3240,12 +3240,12 @@ for details. # Block and replace with "blocked" page .nasty-stuff.example.com -{+block{Doubleclick banners.} +handle-as-image} +{+block{Doubleclick banners.} +handle-as-image} # Block and replace with image .ad.doubleclick.net .ads.r.us/banners/ -{+block{Layered ads.} +handle-as-empty-document} +{+block{Layered ads.} +handle-as-empty-document} # Block and then ignore adserver.example.net/.*\.js$ @@ -3303,7 +3303,7 @@ for details. - + Notes: @@ -3368,7 +3368,7 @@ for details. - + Notes: @@ -3433,7 +3433,7 @@ for details. Client headers to which this action applies are filtered on-the-fly through the specified regular expression based substitutions, the result is used as - tag. + tag. @@ -3455,7 +3455,7 @@ for details. - + Notes: @@ -3540,11 +3540,11 @@ TAG:^User-Agent: MPlayer/ Parameter: - Any string. - + Any string. + - + Notes: @@ -3553,7 +3553,7 @@ TAG:^User-Agent: MPlayer/ browser to decide what to do with the document. The value of this header can cause the browser to open a download menu instead of displaying the document by itself, even if the document's format is - supported by the browser. + supported by the browser. The declared content type can also affect which rendering mode @@ -3567,13 +3567,13 @@ TAG:^User-Agent: MPlayer/ Content-Type: text/html, you can use &my-app; to overwrite it with application/xml and validate the web master's claim inside your XHTML-supporting browser. - If the syntax is incorrect, the browser will complain loudly. + If the syntax is incorrect, the browser will complain loudly. You can also go the opposite direction: if your browser prints error messages instead of rendering a document falsely declared as XHTML, you can overwrite the content type with - text/html and have it rendered as broken HTML document. + text/html and have it rendered as broken HTML document. By default content-type-overwrite only replaces @@ -3591,7 +3591,7 @@ TAG:^User-Agent: MPlayer/ Of course you can apply content-type-overwrite to a whole site and then make URL based exceptions, but it's a lot - more work to get the same precision. + more work to get the same precision. @@ -3653,10 +3653,10 @@ new action Any string. - + - + Notes: @@ -3689,7 +3689,7 @@ new action Example usage (section): - # Block the non-existent "Privacy-Violation:" client header + # Block the non-existent "Privacy-Violation:" client header { +crunch-client-header{Privacy-Violation:} } / @@ -3736,10 +3736,10 @@ new action N/A - + - + Notes: @@ -3823,7 +3823,7 @@ new action - + Notes: @@ -3836,7 +3836,7 @@ new action It makes no sense at all to use this action in conjunction with the session-cookies-only action, - since it would prevent the session cookies from being set. See also + since it would prevent the session cookies from being set. See also filter-content-cookies. @@ -3890,10 +3890,10 @@ new action Any string. - + - + Notes: @@ -3974,7 +3974,7 @@ new action - + Notes: @@ -4042,7 +4042,7 @@ new action - + Notes: @@ -4110,7 +4110,7 @@ new action - + Notes: @@ -4190,7 +4190,7 @@ problem-host.example.com Notes: - + Many sites, like yahoo.com, don't just link to other sites. Instead, they will link to some script on their own servers, giving the destination as a parameter, which will then redirect you to the final target. URLs @@ -4208,7 +4208,7 @@ problem-host.example.com This feature is currently not very smart and is scheduled for improvement. If it is enabled by default, you will have to create some exceptions to - this action. It can lead to failures in several ways: + this action. It can lead to failures in several ways: Not every URLs with other URLs as parameters is evil. @@ -4249,7 +4249,7 @@ problem-host.example.com { +fast-redirects{simple-check} } - one.example.com + one.example.com { +fast-redirects{check-decoded-url} } another.example.com/testing @@ -4269,7 +4269,7 @@ problem-host.example.com Typical use: - Get rid of HTML and JavaScript annoyances, banner advertisements (by size), + Get rid of HTML and JavaScript annoyances, banner advertisements (by size), do fun text replacements, add personalized effects, etc. @@ -4294,17 +4294,17 @@ problem-host.example.com Parameterized. - + Parameter: The name of a content filter, as defined in the filter file. - Filters can be defined in one or more files as defined by the + Filters can be defined in one or more files as defined by the filterfile - option in the config file. - default.filter is the collection of filters - supplied by the developers. Locally defined filters should go + option in the config file. + default.filter is the collection of filters + supplied by the developers. Locally defined filters should go in their own file, such as user.filter. @@ -4313,12 +4313,12 @@ problem-host.example.com - + Notes: - For your convenience, there are a number of pre-defined filters available + For your convenience, there are a number of pre-defined filters available in the distribution filter file that you can use. See the examples below for a list. @@ -4332,20 +4332,20 @@ problem-host.example.com Rolling your own - filters requires a knowledge of + filters requires a knowledge of Regular - Expressions and + Expressions and HTML. - This is very powerful feature, and potentially very intrusive. + This is very powerful feature, and potentially very intrusive. Filters should be used with caution, and where an equivalent action is not available. - The amount of data that can be filtered is limited to the + The amount of data that can be filtered is limited to the buffer-limit - option in the main config file. The + option in the main config file. The default is 4096 KB (4 Megs). Once this limit is exceeded, the buffered - data, and all pending data, is passed through unfiltered. + data, and all pending data, is passed through unfiltered. Inappropriate MIME types, such as zipped files, are not filtered at all. @@ -4368,11 +4368,11 @@ problem-host.example.com action in conjunction with filter. - Content filtering can achieve some of the same effects as the + Content filtering can achieve some of the same effects as the block - action, i.e. it can be used to block ads and banners. But the mechanism - works quite differently. One effective use, is to block ad banners - based on their size (see below), since many of these seem to be somewhat + action, i.e. it can be used to block ads and banners. But the mechanism + works quite differently. One effective use, is to block ad banners + based on their size (see below), since many of these seem to be somewhat standardized. @@ -4390,7 +4390,7 @@ problem-host.example.com Example usage (with filters from the distribution default.filter file). - See the Predefined Filters section for + See the Predefined Filters section for more explanation on each: @@ -4522,7 +4522,7 @@ new action Declares a document as text, even if the Content-Type: isn't detected as such. - + @@ -4554,7 +4554,7 @@ new action force-text-mode declares a document as text, without looking at the Content-Type: first. - + Think twice before activating this action. Filtering binary data with regular expressions can cause file damage. @@ -4562,7 +4562,7 @@ new action - + Example usage: @@ -4596,7 +4596,7 @@ new action Overrules the forward directives in the configuration file. - + @@ -4650,7 +4650,7 @@ new action file, but without the URL pattern. It can be used as replacement, but normally it's only used in cases where matching based on the request URL isn't sufficient. - + Please read the description for the forward directives before using this action. Forwarding to the wrong people will reduce your privacy and increase the @@ -4668,7 +4668,7 @@ new action - + Example usage: @@ -4762,7 +4762,7 @@ new action # Block all documents on example.org that end with ".js", -# but send an empty document instead of the usual HTML message. +# but send an empty document instead of the usual HTML message. {+block{Blocked JavaScript} +handle-as-empty-document} example.org/.*\.js$ @@ -4815,14 +4815,14 @@ example.org/.*\.js$ - + Notes: The below generic example section is actually part of default.action. It marks all URLs with well-known image file name extensions as images and should - be left intact. + be left intact. Users will probably only want to use the handle-as-image action in conjunction with @@ -4896,10 +4896,10 @@ new action Keyword: block, or any user defined value. - + - + Notes: @@ -4925,7 +4925,7 @@ new action to a rare language, you should consider that it helps to make your requests unique and thus easier to trace. If you don't plan to change this header frequently, - you should stick to a common language. + you should stick to a common language. @@ -4982,10 +4982,10 @@ new action Keyword: block, or any user defined value. - + - + Notes: @@ -5054,7 +5054,7 @@ new action Effect: - Deletes the If-Modified-Since: HTTP client header or modifies its value. + Deletes the If-Modified-Since: HTTP client header or modifies its value. @@ -5072,10 +5072,10 @@ new action Keyword: block, or a user defined value that specifies a range of hours. - + - + Notes: @@ -5163,12 +5163,12 @@ new action - + Notes: - The keyword block will completely remove the header + The keyword block will completely remove the header (not to be confused with the block action). @@ -5249,7 +5249,7 @@ new action - + Notes: @@ -5278,12 +5278,12 @@ new action will work with referrer checks, as long as content and valid referring page are on the same host. Most of the time that's the case. - + hide-referer is an alternate spelling of hide-referrer and the two can be can be freely substituted with each other. (referrer is the correct English spelling, however the HTTP specification has a bug - it - requires it to be spelled as referer.) + requires it to be spelled as referer.) @@ -5339,16 +5339,16 @@ new action - + Notes: - + This can lead to problems on web sites that depend on looking at this header in order to customize their content for different browsers (which, by the way, is NOT the right thing to do: good web sites - work browser-independently). + work browser-independently). @@ -5357,14 +5357,14 @@ new action not recommended. In single-user, single-browser setups, you might use it to delete your OS version information from the headers, because it is an invitation to exploit known bugs for your - OS. It is also occasionally useful to forge this in order to access - sites that won't let you in otherwise (though there may be a good + OS. It is also occasionally useful to forge this in order to access + sites that won't let you in otherwise (though there may be a good reason in some cases). - More information on known user-agent strings can be found at + More information on known user-agent strings can be found at http://www.user-agents.org/ - and + and http://en.wikipedia.org/wiki/User_agent. @@ -5420,7 +5420,7 @@ new action - + Notes: @@ -5503,7 +5503,7 @@ new action - + Notes: @@ -5523,7 +5523,7 @@ new action Most text-based instances compress very well, the size is seldom decreased by less than 50%, for markup-heavy instances like news feeds saving more than 90% of the original size isn't - unusual. + unusual. Not using compression will therefore slow down the transfer, and you should only @@ -5588,7 +5588,7 @@ new action Effect: - Deletes the Last-Modified: HTTP server header or modifies its value. + Deletes the Last-Modified: HTTP server header or modifies its value. @@ -5607,10 +5607,10 @@ new action One of the keywords: block, reset-to-request-time and randomize - + - + Notes: @@ -5626,7 +5626,7 @@ new action between the original value and the current time. In theory the server could send each document with a different Last-Modified: header to track visits without using cookies. Randomize - makes it impossible and the browser can still revalidate cached documents. + makes it impossible and the browser can still revalidate cached documents. reset-to-request-time overwrites the value of the @@ -5642,7 +5642,7 @@ new action of the request, the random range becomes zero and the value stays the same. Therefore you should later randomize it a second time with hided-if-modified-since, - just to be sure. + just to be sure. It is also recommended to use this action together with @@ -5709,7 +5709,7 @@ new action - + Notes: @@ -5818,7 +5818,7 @@ www.privoxy.org/user-manual/ - + Notes: @@ -5901,7 +5901,7 @@ example.org/instance-that-is-delivered-as-xml-but-is-not - + Notes: @@ -5952,7 +5952,7 @@ example.org/instance-that-is-delivered-as-xml-but-is-not Allow only temporary session cookies (for the current - browser session only). + browser session only). @@ -5984,12 +5984,12 @@ example.org/instance-that-is-delivered-as-xml-but-is-not - + Notes: - This is less strict than crunch-incoming-cookies / + This is less strict than crunch-incoming-cookies / crunch-outgoing-cookies and allows you to browse websites that insist or rely on setting cookies, without compromising your privacy too badly. @@ -5997,7 +5997,7 @@ example.org/instance-that-is-delivered-as-xml-but-is-not Most browsers will not permanently store cookies that have been processed by session-cookies-only and will forget about them between sessions. This makes profiling cookies useless, but won't break sites which require cookies so - that you can log in for transactions. This is generally turned on for all + that you can log in for transactions. This is generally turned on for all sites, and is the recommended setting. @@ -6016,9 +6016,9 @@ example.org/instance-that-is-delivered-as-xml-but-is-not These would have to be removed manually. - Privoxy also uses - the content-cookies filter - to block some types of cookies. Content cookies are not effected by + Privoxy also uses + the content-cookies filter + to block some types of cookies. Content cookies are not effected by session-cookies-only. @@ -6092,7 +6092,7 @@ example.org/instance-that-is-delivered-as-xml-but-is-not target-url to send a redirect to target-url. You can redirect - to any image anywhere, even in your local filesystem via file:/// URL. + to any image anywhere, even in your local filesystem via file:/// URL. (But note that not all browsers support redirecting to a local file system). @@ -6155,8 +6155,8 @@ example.org/instance-that-is-delivered-as-xml-but-is-not Summary Note that many of these actions have the potential to cause a page to - misbehave, possibly even not to display at all. There are many ways - a site designer may choose to design his site, and what HTTP header + misbehave, possibly even not to display at all. There are many ways + a site designer may choose to design his site, and what HTTP header content, and other criteria, he may depend on. There is no way to have hard and fast rules for all sites. See the Appendix for a brief example on troubleshooting @@ -6174,7 +6174,7 @@ example.org/instance-that-is-delivered-as-xml-but-is-not These can in turn be invoked just like the built-in actions. Currently, an alias name can contain any character except space, tab, =, - { and }, but we strongly + { and }, but we strongly recommend that you only use a to z, 0 to 9, +, and -. Alias names are not case sensitive, and are not required to start with a @@ -6241,7 +6241,7 @@ example.org/instance-that-is-delivered-as-xml-but-is-not - ...and put them to use. These sections would appear in the lower part of an + ...and put them to use. These sections would appear in the lower part of an actions file and define exceptions to the default actions (as specified further up for the / pattern): @@ -6259,7 +6259,7 @@ example.org/instance-that-is-delivered-as-xml-but-is-not # Shopping sites: # Allow cookies (for setting and retrieving your customer data) - # + # {shop} .quietpc.com .worldpay.com # for quietpc.com @@ -6273,8 +6273,8 @@ example.org/instance-that-is-delivered-as-xml-but-is-not - Aliases like shop and fragile are typically used for - problem sites that require more than one action to be disabled + Aliases like shop and fragile are typically used for + problem sites that require more than one action to be disabled in order to function properly. @@ -6319,7 +6319,7 @@ hal stop here preceding the action name enables the action, a - disables!). Also note how this long line has been made more readable by splitting it into multiple lines with line continuation. - + @@ -6422,13 +6422,13 @@ mail.google.com require cookies to log in, and pop-up windows for shopping carts or item details. Again, we'll use a pre-defined alias: - + # Shopping sites: # { shop } -.quietpc.com +.quietpc.com .worldpay.com # for quietpc.com .jungle.com .scan.co.uk @@ -6497,7 +6497,7 @@ edit.*.yahoo.com # Known ad generators: # { +block-as-image } -ar.atwola.com +ar.atwola.com .ad.doubleclick.net .ad.*.doubleclick.net .a.yimg.com/(?:(?!/i/).)*$ @@ -6532,7 +6532,7 @@ bs*.gsanet.com { +block{Banner ads.} } # Generic patterns: -# +# ad*. .*ads. banner?. @@ -6553,7 +6553,7 @@ count*. But being very generic, they necessarily also catch URLs that we don't want - to block. The pattern .*ads. e.g. catches + to block. The pattern .*ads. e.g. catches nasty-ads.nasty-corp.com as intended, but also downloads.sourcefroge.net or adsl.some-provider.net. So here come some @@ -6580,7 +6580,7 @@ count*. ########################################################################## # By domain: -# +# { -block } adv[io]*. # (for advogato.org and advice.*) adsl. # (has nothing to do with ads) @@ -6630,13 +6630,13 @@ wiki. So far we are painting with a broad brush by setting general policies, - which would be a reasonable starting point for many people. Now, + which would be a reasonable starting point for many people. Now, you might want to be more specific and have customized rules that are more suitable to your personal habits and preferences. These would be for narrowly defined situations like your ISP or your bank, and should - be placed in user.action, which is parsed after all other + be placed in user.action, which is parsed after all other actions files and hence has the last word, over-riding any previously - defined actions. user.action is also a + defined actions. user.action is also a safe place for your personal settings, since default.action is actively maintained by the Privoxy developers and you'll probably want @@ -6645,7 +6645,7 @@ wiki. So let's look at a few examples of things that one might typically do in - user.action: + user.action: @@ -6668,8 +6668,8 @@ wiki. # (Re-)define aliases for this file: # {{alias}} -# -# These aliases just save typing later, and the alias names should +# +# These aliases just save typing later, and the alias names should # be self explanatory. # +crunch-all-cookies = +crunch-incoming-cookies +crunch-outgoing-cookies @@ -6700,7 +6700,7 @@ handle-as-text = -filter +-block action. Say you've seen an ad on your favourite page on example.com that you want to get rid of. You have right-clicked the image, selected copy image location - and pasted the URL below while removing the leading http://, into a + and pasted the URL below while removing the leading http://, into a { +block{} } section. Note that { +handle-as-image } need not be specified, since all URLs ending in .gif will be tagged as images by the general rules as set @@ -6763,7 +6763,7 @@ stupid-server.example.com/ The URLs of dynamically generated banners, especially from large banner farms, often don't use the well-known image file name extensions, which makes it impossible for Privoxy to guess - the file type just by looking at the URL. + the file type just by looking at the URL. You can use the +block-as-image alias defined above for these cases. Note that objects which match this rule but then turn out NOT to be an @@ -6788,7 +6788,7 @@ stupid-server.example.com/ -- whoa! -- it worked. The fragile aliases disables those actions that are most likely to break a site. Also, good for testing purposes to see if it is Privoxy - that is causing the problem or not. We later find other regular sites + that is causing the problem or not. We later find other regular sites that misbehave, and add those to our personalized list of troublemakers: @@ -6833,19 +6833,19 @@ stupid-server.example.com/ { allow-ads } .sourceforge.net .slashdot.org - .osdn.net + .osdn.net - Note that allow-ads has been aliased to - -block, - -filter{banners-by-size}, and + Note that allow-ads has been aliased to + -block, + -filter{banners-by-size}, and -filter{banners-by-link} above. Invoke another alias here to force an over-ride of the MIME type - application/x-sh which typically would open a download type + application/x-sh which typically would open a download type dialog. In my case, I want to look at the shell script, and then I can save it should I choose to. @@ -6853,7 +6853,7 @@ stupid-server.example.com/ { handle-as-text } - /.*\.sh$ + /.*\.sh$ @@ -6888,7 +6888,7 @@ stupid-server.example.com/ On-the-fly text substitutions need - to be defined in a filter file. Once defined, they + to be defined in a filter file. Once defined, they can then be invoked as an action. @@ -6942,7 +6942,7 @@ stupid-server.example.com/ Substitutions are made at the source level, so if you want to roll - your own filters, you should first be familiar with HTML syntax, + your own filters, you should first be familiar with HTML syntax, and, of course, regular expressions. @@ -6952,7 +6952,7 @@ stupid-server.example.com/ here. Each filter consists of a heading line, that starts with one of the keywords FILTER:, CLIENT-HEADER-FILTER: or SERVER-HEADER-FILTER: - followed by the filter's name, and a short (one line) + followed by the filter's name, and a short (one line) description of what it does. Below that line come the jobs, i.e. lines that define the actual text substitutions. By convention, the name of a filter @@ -6967,7 +6967,7 @@ stupid-server.example.com/ +filter{name} in any actions file. - + Filter definitions start with a header line that contains the filter type, the filter name and the filter description. @@ -6991,13 +6991,13 @@ stupid-server.example.com/ - If you are new to + If you are new to Regular Expressions, you might want to take a look at the Appendix on regular expressions, and see the Perl manual for - the + the s/// operator's syntax and Perl-style regular expressions in general. @@ -7112,7 +7112,7 @@ s|(<script.*)document\.referrer(.*</script>)|$1"Not Your Business!"$2|U Now the pattern is deciphered, but wasn't this about substituting things? So lets look at the substitute: $1"Not Your Business!"$2 is - easy to read: The text remembered as $1, followed by + easy to read: The text remembered as $1, followed by "Not Your Business!" (including the quotation marks!), followed by the text remembered as $2. This produces an exact copy of the original string, with the middle part @@ -7179,7 +7179,7 @@ s/(<body [^>]*)onunload(.*>)/$1never$2/iU Note that the i option makes the pattern matching case-insensitive. Also note that ungreedy matching alone doesn't always guarantee a minimal match: In the first parenthesis, we had to use [^>]* - instead of .* to prevent the match from exceeding the + instead of .* to prevent the match from exceeding the <body> tag if it doesn't contain OnUnload, but the page's content does. @@ -7199,7 +7199,7 @@ s/microsoft(?!\.com)/MicroSuck/ig Note the (?!\.com) part (a so-called negative lookahead) - in the job's pattern, which means: Don't match, if the string + in the job's pattern, which means: Don't match, if the string .com appears directly following microsoft in the page. This prevents links to microsoft.com from being trashed, while still replacing the word everywhere else. @@ -7225,7 +7225,7 @@ s* industry[ -]leading \ The x option in this job turns on extended syntax, and allows for - e.g. the liberal use of (non-interpreted!) whitespace for nicer formatting. + e.g. the liberal use of (non-interpreted!) whitespace for nicer formatting. @@ -7237,11 +7237,11 @@ s* industry[ -]leading \ The Pre-defined Filters - @@ -7281,12 +7281,12 @@ pre-defined filters for your convenience: - Use with caution. This is an aggressive filter, and can break sites that + Use with caution. This is an aggressive filter, and can break sites that rely heavily on JavaScript. - + js-events @@ -7310,7 +7310,7 @@ pre-defined filters for your convenience: This filter will undo many common instances of HTML based abuse. - The BLINK and MARQUEE tags + The BLINK and MARQUEE tags are neutralized (yeah baby!), and browser windows will be created as resizeable (as of course they should be!), and will have location, scroll and menu bars -- even if specified otherwise. @@ -7331,9 +7331,9 @@ pre-defined filters for your convenience: This filter disables most HTML and JavaScript code that reads or sets - cookies. It cannot detect all clever uses of these types of code, so it + cookies. It cannot detect all clever uses of these types of code, so it should not be relied on as an absolute fix. Use it wherever you would also - use the cookie crunch actions. + use the cookie crunch actions. @@ -7342,8 +7342,8 @@ pre-defined filters for your convenience: refresh tags - Disable any refresh tags if the interval is greater than nine seconds (so - that redirections done via refresh tags are not destroyed). This is useful + Disable any refresh tags if the interval is greater than nine seconds (so + that redirections done via refresh tags are not destroyed). This is useful for dial-on-demand setups, or for those who find this HTML feature annoying. @@ -7354,9 +7354,9 @@ pre-defined filters for your convenience: unsolicited-popups - This filter attempts to prevent only unsolicited pop-up - windows from opening, yet still allow pop-up windows that the user - has explicitly chosen to open. It was added in version 3.0.1, + This filter attempts to prevent only unsolicited pop-up + windows from opening, yet still allow pop-up windows that the user + has explicitly chosen to open. It was added in version 3.0.1, as an improvement over earlier such filters. @@ -7367,7 +7367,7 @@ pre-defined filters for your convenience: This is recommended only for browsers that cannot perform this function - reliably themselves. And be aware that some sites require such windows + reliably themselves. And be aware that some sites require such windows in order to function normally. Use with caution. @@ -7400,7 +7400,7 @@ pre-defined filters for your convenience: banners-by-size - This filter removes image tags purely based on what size they are. Fortunately + This filter removes image tags purely based on what size they are. Fortunately for us, many ads and banner images tend to conform to certain standardized sizes, which makes this filter quite effective for ad stripping purposes. @@ -7409,7 +7409,7 @@ pre-defined filters for your convenience: but just happen to be of one of the standard banner sizes. - Recommended only for those who require extreme ad blocking. The default + Recommended only for those who require extreme ad blocking. The default block rules should catch 95+% of all ads without this filter enabled. @@ -7419,7 +7419,7 @@ pre-defined filters for your convenience: banners-by-link - This is an experimental filter that attempts to kill any banners if + This is an experimental filter that attempts to kill any banners if their URLs seem to point to known or suspected click trackers. It is currently not of much value and is not recommended for use by default. @@ -7430,7 +7430,7 @@ pre-defined filters for your convenience: webbugs - Webbugs are small, invisible images (technically 1X1 GIF images), that + Webbugs are small, invisible images (technically 1X1 GIF images), that are used to track users across websites, and collect information on them. As an HTML page is loaded by the browser, an embedded image tag causes the browser to contact a third-party site, disclosing the tracking information @@ -7449,7 +7449,7 @@ pre-defined filters for your convenience: A rather special-purpose filter that can be used to enlarge textareas (those - multi-line text boxes in web forms) and turn off hard word wrap in them. + multi-line text boxes in web forms) and turn off hard word wrap in them. It was written for the sourceforge.net tracker system where such boxes are a nuisance, but it can be handy on other sites, too. @@ -7493,20 +7493,20 @@ pre-defined filters for your convenience: Many Microsoft products that generate HTML use non-standard extensions (read: violations) of the ISO 8859-1 aka Latin-1 character set. This can cause those - HTML documents to display with errors on standard-compliant platforms. + HTML documents to display with errors on standard-compliant platforms. - This filter translates the MS-only characters into Latin-1 equivalents. - It is not necessary when using MS products, and will cause corruption of + This filter translates the MS-only characters into Latin-1 equivalents. + It is not necessary when using MS products, and will cause corruption of all documents that use 8-bit character sets other than Latin-1. It's mostly worthwhile for Europeans on non-MS platforms, if weird garbage characters - sometimes appear on some pages, or user agents that don't correct for this on + sometimes appear on some pages, or user agents that don't correct for this on the fly. +--> @@ -7516,7 +7516,7 @@ pre-defined filters for your convenience: A filter for shockwave haters. As the name suggests, this filter strips code - out of web pages that is used to embed shockwave flash objects. + out of web pages that is used to embed shockwave flash objects. @@ -7592,12 +7592,12 @@ pre-defined filters for your convenience: - + yahoo - Another CSS based block, this time for Yahoo text ads. And removes + Another CSS based block, this time for Yahoo text ads. And removes a width limitation as well. @@ -7607,7 +7607,7 @@ pre-defined filters for your convenience: msn - Another CSS based block, this time for MSN text ads. And removes + Another CSS based block, this time for MSN text ads. And removes tracking URLs, as well as a width limitation. @@ -7636,7 +7636,7 @@ pre-defined filters for your convenience: - + html-to-xml @@ -7715,13 +7715,13 @@ pre-defined filters for your convenience: Privoxy's Template Files - All Privoxy built-in pages, i.e. error pages such as the + All Privoxy built-in pages, i.e. error pages such as the 404 - No Such Domain error page, the BLOCKED page and all pages of its web-based - user interface, are generated from templates. + user interface, are generated from templates. (Privoxy must be running for the above links to work as intended.) @@ -7738,10 +7738,10 @@ pre-defined filters for your convenience: or exports), which Privoxy fills at run time. It is possible to edit the templates with a normal text editor, should you want to customize them. (Not recommended for the casual - user). Should you create your own custom templates, you should use + user). Should you create your own custom templates, you should use the config setting templdir to specify an alternate location, so your templates do not get overwritten - during upgrades. + during upgrades. Note that just like in configuration files, lines starting @@ -7873,7 +7873,7 @@ Requests expressions in its actions files and filter file, through the PCRE and - @@ -7900,7 +7900,7 @@ Requests To make a simple analogy, we do something similar when we use wild-card - characters when listing files with the dir command in DOS. + characters when listing files with the dir command in DOS. *.* matches all filenames. The special character here is the asterisk which matches any and all characters. We can be more specific and use ? to match just individual @@ -7911,7 +7911,7 @@ Requests Regular expressions do essentially the same thing, but are much, much more - powerful. There are many more special characters and ways of + powerful. There are many more special characters and ways of building complex patterns however. Let's look at a few of the common ones, and then some examples: @@ -7947,10 +7947,10 @@ Requests \ - The escape character denotes that - the following character should be taken literally. This is used where one of the + the following character should be taken literally. This is used where one of the special characters (e.g. .) needs to be taken literally and - not as a special meta-character. Example: example\.com, makes - sure the period is recognized only as a period (and not expanded to its + not as a special meta-character. Example: example\.com, makes + sure the period is recognized only as a period (and not expanded to its meta-character meaning of any single character). @@ -7959,7 +7959,7 @@ Requests [ ] - Characters enclosed in brackets will be matched if any of the enclosed characters are encountered. For instance, [0-9] - matches any numeric digit (zero through nine). As an example, we can combine + matches any numeric digit (zero through nine). As an example, we can combine this with + to match any digit one of more times: [0-9]+. @@ -7976,14 +7976,14 @@ Requests | - The bar character works like an or conditional statement. A match is successful if the sub-expression on either side of | matches. As an example: - /(this|that) example/ uses grouping and the bar character + /(this|that) example/ uses grouping and the bar character and would match either this example or that example, and nothing else. - These are just some of the ones you are likely to use when matching URLs with + These are just some of the ones you are likely to use when matching URLs with Privoxy, and is a long way from a definitive list. This is enough to get us started with a few simple examples which may be more illuminating: @@ -7991,12 +7991,12 @@ Requests /.*/banners/.* - A simple example - that uses the common combination of . and * to + that uses the common combination of . and * to denote any character, zero or more times. In other words, any string at all. - So we start with a literal forward slash, then our regular expression pattern + So we start with a literal forward slash, then our regular expression pattern (.*) another literal forward slash, the string banners, another forward slash, and lastly another - .*. We are building + .*. We are building a directory path here. This will match any file with the path that has a directory named banners in it. The .* matches any characters, and this could conceivably be more forward slashes, so it @@ -8012,14 +8012,14 @@ Requests - /.*/adv((er)?ts?|ertis(ing|ements?))?/ - + /.*/adv((er)?ts?|ertis(ing|ements?))?/ - We have several literal forward slashes again (/), so we are - building another expression that is a file path statement. We have another + building another expression that is a file path statement. We have another .*, so we are matching against any conceivable sub-path, just so it matches our expression. The only true literal that must match our pattern is adv, together with the forward slashes. What comes after the adv string is the - interesting part. + interesting part. @@ -8029,29 +8029,29 @@ Requests ((er)?ts?|ertis(ing|ements?)) is optional, as are the individual sub-expressions: (er), (ing|ements?), and the s. The | - means or. We have two of those. For instance, - (ing|ements?), can expand to match either ing + means or. We have two of those. For instance, + (ing|ements?), can expand to match either ing OR ements?. What is being done here, is an - attempt at matching as many variations of advertisement, and + attempt at matching as many variations of advertisement, and similar, as possible. So this would expand to match just adv, or advert, or adverts, or advertising, or advertisement, or - advertisements. You get the idea. But it would not match + advertisements. You get the idea. But it would not match advertizements (with a z). We could fix that by - changing our regular expression to: + changing our regular expression to: /.*/adv((er)?ts?|erti(s|z)(ing|ements?))?/, which would then match either spelling. - /.*/advert[0-9]+\.(gif|jpe?g) - Again - another path statement with forward slashes. Anything in the square brackets + /.*/advert[0-9]+\.(gif|jpe?g) - Again + another path statement with forward slashes. Anything in the square brackets [ ] can be matched. This is using 0-9 as a shorthand expression to mean any digit one through nine. It is the same as saying 0123456789. So any digit matches. The + - means one or more of the preceding expression must be included. The preceding - expression here is what is in the square brackets -- in this case, any digit - one through nine. Then, at the end, we have a grouping: (gif|jpe?g). + means one or more of the preceding expression must be included. The preceding + expression here is what is in the square brackets -- in this case, any digit + one through nine. Then, at the end, we have a grouping: (gif|jpe?g). This includes a |, so this needs to match the expression on either side of that bar character also. A simple gif on one side, and the other side will in turn match either jpeg or jpg, @@ -8081,7 +8081,7 @@ Requests - More reading on Perl Compatible Regular expressions: + More reading on Perl Compatible Regular expressions: http://perldoc.perl.org/perlre.html @@ -8100,22 +8100,22 @@ Requests Privoxy's Internal Pages - Since Privoxy proxies each requested - web page, it is easy for Privoxy to + Since Privoxy proxies each requested + web page, it is easy for Privoxy to trap certain special URLs. In this way, we can talk directly to - Privoxy, and see how it is - configured, see how our rules are being applied, change these + Privoxy, and see how it is + configured, see how our rules are being applied, change these rules and other configuration options, and even turn - Privoxy's filtering off, all with + Privoxy's filtering off, all with a web browser. - The URLs listed below are the special ones that allow direct access + The URLs listed below are the special ones that allow direct access to Privoxy. Of course, - Privoxy must be running to access these. If - not, you will get a friendly error message. Internet access is not + Privoxy must be running to access these. If + not, you will get a friendly error message. Internet access is not necessary either. @@ -8123,11 +8123,11 @@ Requests - - Privoxy main page: + + Privoxy main page:
- + http://config.privoxy.org/
@@ -8139,77 +8139,77 @@ Requests
- - Show information about the current configuration, including viewing and + + Show information about the current configuration, including viewing and editing of actions files:
- + http://config.privoxy.org/show-status
- + - + Show the source code version numbers:
- + http://config.privoxy.org/show-version
- + - + Show the browser's request headers:
- + http://config.privoxy.org/show-request
- + - + Show which actions apply to a URL and why:
- + http://config.privoxy.org/show-url-info
- + - - Toggle Privoxy on or off. This feature can be turned off/on in the main + + Toggle Privoxy on or off. This feature can be turned off/on in the main config file. When toggled off, Privoxy continues to run, but only as a pass-through proxy, with no actions taking place:
- + http://config.privoxy.org/toggle
- Short cuts. Turn off, then on: + Short cuts. Turn off, then on:
- + http://config.privoxy.org/toggle?set=disable
- + http://config.privoxy.org/toggle?set=enable
- +
@@ -8234,7 +8234,7 @@ Requests the bookmark may not be safe - just click OK. Then you can run the Bookmarklet directly from your favorites/bookmarks. For even faster access, you can put them on the Links bar (IE) or the Personal - Toolbar (Netscape), and run them with a single click. + Toolbar (Netscape), and run them with a single click. @@ -8245,47 +8245,47 @@ Requests Privoxy - Enable -
+
Privoxy - Disable - + Privoxy - Toggle Privoxy (Toggles between enabled and disabled) - + Privoxy- View Status - + + + --> Privoxy - Why? - + Credit: The site which gave us the general idea for these bookmarklets is www.bookmarklets.com. They - have more information about bookmarklets. + have more information about bookmarklets. @@ -8298,7 +8298,7 @@ Requests Chain of Events - Let's take a quick look at how some of Privoxy's + Let's take a quick look at how some of Privoxy's core features are triggered, and the ensuing sequence of events when a web page is requested by your browser: @@ -8307,48 +8307,48 @@ Requests - First, your web browser requests a web page. The browser knows to send - the request to Privoxy, which will in turn, - relay the request to the remote web server after passing the following - tests: + First, your web browser requests a web page. The browser knows to send + the request to Privoxy, which will in turn, + relay the request to the remote web server after passing the following + tests: - + - Privoxy traps any request for its own internal CGI + Privoxy traps any request for its own internal CGI pages (e.g http://p.p/) and sends the CGI page back to the browser. - + - Next, Privoxy checks to see if the URL + Next, Privoxy checks to see if the URL matches any +block patterns. If so, the URL is then blocked, and the remote web server will not be contacted. - +handle-as-image - and + +handle-as-image + and +handle-as-empty-document - are then checked, and if there is no match, an + are then checked, and if there is no match, an HTML BLOCKED page is sent back to the browser. Otherwise, if it does match, an image is returned for the former, and an empty text document for the latter. The type of image would depend on the setting of +set-image-blocker (blank, checkerboard pattern, or an HTTP redirect to an image elsewhere). - + Untrusted URLs are blocked. If URLs are being added to the trust file, then that is done. - + If the URL pattern matches the +fast-redirects action, it is then processed. Unwanted parts of the requested URL are stripped. - + Now the rest of the client browser's request headers are processed. If any @@ -8357,24 +8357,24 @@ Requests etc.), headers are suppressed or forged as determined by these actions and their parameters. - + Now the web server starts sending its response back (i.e. typically a web page). - + First, the server headers are read and processed to determine, among other things, the MIME type (document type) and encoding. The headers are then - filtered as determined by the + filtered as determined by the +crunch-incoming-cookies, +session-cookies-only, and +downgrade-http-version actions. - + If any +filter action @@ -8387,35 +8387,35 @@ Requests they are specified in one of the filter files. Animated GIFs, if present, are reduced to either the first or last frame, depending on the action setting.The entire page, which is now filtered, is then sent by - Privoxy back to your browser. + Privoxy back to your browser. If neither a +filter action or +deanimate-gifs - matches, then Privoxy passes the raw data through + matches, then Privoxy passes the raw data through to the client browser as it becomes available. - + - As the browser receives the now (possibly filtered) page content, it + As the browser receives the now (possibly filtered) page content, it reads and then requests any URLs that may be embedded within the page source, e.g. ad images, stylesheets, JavaScript, other HTML documents (e.g. frames), sounds, etc. For each of these objects, the browser issues a separate request (this is easily viewable in Privoxy's logs). And each such request is in turn processed just as above. Note that a - complex web page will have many, many such embedded URLs. If these - secondary requests are to a different server, then quite possibly a very + complex web page will have many, many such embedded URLs. If these + secondary requests are to a different server, then quite possibly a very differing set of actions is triggered. - - + + NOTE: This is somewhat of a simplistic overview of what happens with each URL - request. For the sake of brevity and simplicity, we have focused on + request. For the sake of brevity and simplicity, we have focused on Privoxy's core features only. @@ -8427,7 +8427,7 @@ Requests Troubleshooting: Anatomy of an Action - The way Privoxy applies + The way Privoxy applies actions and filters to any given URL can be complex, and not always so easy to understand what is happening. And sometimes we need to be able to @@ -8436,16 +8436,16 @@ Requests is causing us a problem inadvertently. It can be a little daunting to look at the actions and filters files themselves, since they tend to be filled with regular expressions whose consequences are not - always so obvious. + always so obvious. - One quick test to see if Privoxy is causing a problem - or not, is to disable it temporarily. This should be the first troubleshooting - step. See the Bookmarklets section on a quick - and easy way to do this (be sure to flush caches afterward!). Looking at the - logs is a good idea too. (Note that both the toggle feature and logging are - enabled via config file settings, and may need to be + One quick test to see if Privoxy is causing a problem + or not, is to disable it temporarily. This should be the first troubleshooting + step. See the Bookmarklets section on a quick + and easy way to do this (be sure to flush caches afterward!). Looking at the + logs is a good idea too. (Note that both the toggle feature and logging are + enabled via config file settings, and may need to be turned on.) @@ -8457,7 +8457,7 @@ Requests - Privoxy also provides the + Privoxy also provides the http://config.privoxy.org/show-url-info page that can show us very specifically how actions are being applied to any given URL. This is a big help for troubleshooting. @@ -8465,7 +8465,7 @@ Requests First, enter one URL (or partial URL) at the prompt, and then - Privoxy will tell us + Privoxy will tell us how the current configuration will handle it. This will not help with filtering effects (i.e. the +filter action) from @@ -8481,8 +8481,8 @@ Requests - Let's try an example, google.com, - and look at it one section at a time in a sample configuration (your real + Let's try an example, google.com, + and look at it one section at a time in a sample configuration (your real configuration may vary): @@ -8506,7 +8506,7 @@ Requests +session-cookies-only +set-image-blocker {pattern} / - + { -session-cookies-only } .google.com @@ -8514,17 +8514,17 @@ Requests .google.com In file: user.action [ View ] [ Edit ] -(no matches in this file) +(no matches in this file) - This is telling us how we have defined our + This is telling us how we have defined our actions, and - which ones match for our test case, google.com. + which ones match for our test case, google.com. Displayed is all the actions that are available to us. Remember, the + sign denotes on. - - denotes off. So some are on here, but many + denotes off. So some are on here, but many are off. Each example we try may provide a slightly different end result, depending on our configuration directives. @@ -8552,7 +8552,7 @@ In file: user.action [ View ] [ Edit ].google.com. This will match any hosts and sub-domains, in the google.com domain also, such as - www.google.com or mail.google.com. But it would not + www.google.com or mail.google.com. But it would not match www.google.de! So, apparently, we have these two actions defined as exceptions to the general rules at the top somewhere in the lower part of our default.action file, and @@ -8562,7 +8562,7 @@ In file: user.action [ View ] [ Edit ] Then, for our user.action file, we again have no hits. So there is nothing google-specific that we might have added to our own, local - configuration. If there was, those actions would over-rule any actions from + configuration. If there was, those actions would over-rule any actions from previously processed files, such as default.action. user.action typically has the last word. This is the best place to put hard and fast exceptions, @@ -8570,7 +8570,7 @@ In file: user.action [ View ] [ Edit ] And finally we pull it all together in the bottom section and summarize how - Privoxy is applying all its actions + Privoxy is applying all its actions to google.com: @@ -8579,10 +8579,10 @@ In file: user.action [ View ] [ Edit ] Final results: - + -add-header -block - +change-x-forwarded-for{block} + +change-x-forwarded-for{block} -client-header-filter{hide-tor-exit-notation} -content-type-overwrite -crunch-client-header @@ -8633,15 +8633,15 @@ In file: user.action [ View ] [ Edit ] - Notice the only difference here to the previous listing, is to + Notice the only difference here to the previous listing, is to fast-redirects and session-cookies-only, - which are activated specifically for this site in our configuration, + which are activated specifically for this site in our configuration, and thus show in the Final Results. @@ -8664,25 +8664,25 @@ In file: user.action [ View ] [ Edit ] - We'll just show the interesting part here - the explicit matches. It is - matched three different times. Two +block{} sections, + We'll just show the interesting part here - the explicit matches. It is + matched three different times. Two +block{} sections, and a +block{} +handle-as-image, - which is the expanded form of one of our aliases that had been defined as: + which is the expanded form of one of our aliases that had been defined as: +block-as-image. (Aliases are defined in - the first section of the actions file and typically used to combine more + the first section of the actions file and typically used to combine more than one action.) - Any one of these would have done the trick and blocked this as an unwanted - image. This is unnecessarily redundant since the last case effectively - would also cover the first. No point in taking chances with these guys - though ;-) Note that if you want an ad or obnoxious + Any one of these would have done the trick and blocked this as an unwanted + image. This is unnecessarily redundant since the last case effectively + would also cover the first. No point in taking chances with these guys + though ;-) Note that if you want an ad or obnoxious URL to be invisible, it should be defined as ad.doubleclick.net is done here -- as both a +block{} - and an + and an +handle-as-image. The custom alias +block-as-image just simplifies the process and make it more readable. @@ -8700,9 +8700,9 @@ In file: user.action [ View ] [ Edit ][ View ] [ Edit ] - {-add-header + {-add-header -block - +change-x-forwarded-for{block} + +change-x-forwarded-for{block} -client-header-filter{hide-tor-exit-notation} -content-type-overwrite -crunch-client-header @@ -8710,8 +8710,8 @@ In file: user.action [ View ] [ Edit ][ View ] [ Edit ][ View ] [ Edit ] - Ooops, the /adsl/ is matching /ads in our + Ooops, the /adsl/ is matching /ads in our configuration! But we did not want this at all! Now we see why we get the - blank page. It is actually triggering two different actions here, and - the effects are aggregated so that the URL is blocked, and &my-app; is told + blank page. It is actually triggering two different actions here, and + the effects are aggregated so that the URL is blocked, and &my-app; is told to treat the block as if it were an image. But this is, of course, all wrong. We could now add a new action below this (or better in our own user.action file) that explicitly @@ -8784,14 +8784,14 @@ In file: user.action [ View ] [ Edit ] - Now the page displays ;-) + Now the page displays ;-) Remember to flush your browser's caches when making these kinds of changes to your configuration to insure that you get a freshly delivered page! Or, try using Shift+Reload. - But now what about a situation where we get no explicit matches like + But now what about a situation where we get no explicit matches like we did with: @@ -8805,7 +8805,7 @@ In file: user.action [ View ] [ Edit ] That actually was very helpful and pointed us quickly to where the problem - was. If you don't get this kind of match, then it means one of the default + was. If you don't get this kind of match, then it means one of the default rules in the first section of default.action is causing the problem. This would require some guesswork, and maybe a little trial and error to isolate the offending rule. One likely cause would be one of the @@ -8828,7 +8828,7 @@ In file: user.action [ View ] [ Edit ] - { shop } is an alias that expands to + { shop } is an alias that expands to { -filter -session-cookies-only }. Or you could do your own exception to negate filtering: @@ -8849,23 +8849,23 @@ In file: user.action [ View ] [ Edit ]user.action, for local site exceptions. Note that when a simple domain pattern is used by itself (without - the subsequent path portion), all sub-pages within that domain are included + the subsequent path portion), all sub-pages within that domain are included automatically in the scope of the action. - Images that are inexplicably being blocked, may well be hitting the + Images that are inexplicably being blocked, may well be hitting the +filter{banners-by-size} - rule, which assumes - that images of certain sizes are ad banners (works well + rule, which assumes + that images of certain sizes are ad banners (works well most of the time since these tend to be standardized). { fragile } is an alias that disables most actions that are the most likely to cause trouble. This can be used as a - last resort for problem sites. - + last resort for problem sites. + @@ -8874,16 +8874,16 @@ In file: user.action [ View ] [ Edit ] - + - Remember to flush caches! Note that the - mail.google reference lacks the TLD portion (e.g. - .com). This will effectively match any TLD with - google in it, such as mail.google.de., + Remember to flush caches! Note that the + mail.google reference lacks the TLD portion (e.g. + .com). This will effectively match any TLD with + google in it, such as mail.google.de., just as an example. - + If this still does not work, you will have to go through the remaining actions one by one to find which one(s) is causing the problem. @@ -8894,7 +8894,7 @@ In file: user.action [ View ] [ Edit ][ View ] [ Edit ][ View ] [ Edit ] (size_t)0) { - msecs_length = snprintf(buffer+length, buffer_size - length, ".%.3ld", msecs); + msecs_length = snprintf(buffer+length, buffer_size - length, ".%.3ld", msecs); } if (msecs_length > 0) { @@ -488,7 +488,7 @@ static inline size_t get_clf_timestamp(char *buffer, size_t buffer_size) * the %z field in strftime() */ time_t now; - struct tm *tm_now; + struct tm *tm_now; struct tm gmt; #ifdef HAVE_LOCALTIME_R struct tm dummy; @@ -497,7 +497,7 @@ static inline size_t get_clf_timestamp(char *buffer, size_t buffer_size) size_t length; int tz_length = 0; - time (&now); + time (&now); #ifdef HAVE_GMTIME_R gmt = *gmtime_r(&now, &gmt); #elif defined(MUTEX_LOCKS_AVAILABLE) @@ -511,14 +511,14 @@ static inline size_t get_clf_timestamp(char *buffer, size_t buffer_size) tm_now = localtime_r(&now, &dummy); #elif defined(MUTEX_LOCKS_AVAILABLE) privoxy_mutex_lock(&localtime_mutex); - tm_now = localtime(&now); + tm_now = localtime(&now); privoxy_mutex_unlock(&localtime_mutex); #else - tm_now = localtime(&now); + tm_now = localtime(&now); #endif - days = tm_now->tm_yday - gmt.tm_yday; - hrs = ((days < -1 ? 24 : 1 < days ? -24 : days * 24) + tm_now->tm_hour - gmt.tm_hour); - mins = hrs * 60 + tm_now->tm_min - gmt.tm_min; + days = tm_now->tm_yday - gmt.tm_yday; + hrs = ((days < -1 ? 24 : 1 < days ? -24 : days * 24) + tm_now->tm_hour - gmt.tm_hour); + mins = hrs * 60 + tm_now->tm_min - gmt.tm_min; length = strftime(buffer, buffer_size, "%d/%b/%Y:%H:%M:%S ", tm_now); @@ -546,7 +546,7 @@ static inline size_t get_clf_timestamp(char *buffer, size_t buffer_size) * * Description : Translates a numerical loglevel into a string. * - * Parameters : + * Parameters : * 1 : loglevel = LOG_LEVEL_FOO * * Returns : Log level string. @@ -682,7 +682,7 @@ void log_error(int loglevel, const char *fmt, ...) /* protect the whole function because of the static buffer (outbuf) */ lock_logfile(); - if (NULL == outbuf_save) + if (NULL == outbuf_save) { outbuf_save = (char*)zalloc(log_buffer_size + 1); /* +1 for paranoia */ if (NULL == outbuf_save) @@ -840,7 +840,7 @@ void log_error(int loglevel, const char *fmt, ...) format_string = strerror(ival); } #else /* ifndef _WIN32 */ - ival = errno; + ival = errno; #ifdef HAVE_STRERROR format_string = strerror(ival); #else /* ifndef HAVE_STRERROR */ diff --git a/errlog.h b/errlog.h index 369f8404..8fac4e6f 100644 --- a/errlog.h +++ b/errlog.h @@ -1,6 +1,6 @@ #ifndef ERRLOG_H_INCLUDED #define ERRLOG_H_INCLUDED -#define ERRLOG_H_VERSION "$Id: errlog.h,v 1.25 2010/07/26 11:28:11 fabiankeil Exp $" +#define ERRLOG_H_VERSION "$Id: errlog.h,v 1.26 2010/07/26 11:30:09 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/errlog.h,v $ @@ -12,10 +12,10 @@ * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at diff --git a/filters.c b/filters.c index 34322739..1949b21c 100644 --- a/filters.c +++ b/filters.c @@ -1,4 +1,4 @@ -const char filters_rcs[] = "$Id: filters.c,v 1.143 2011/05/22 10:25:26 fabiankeil Exp $"; +const char filters_rcs[] = "$Id: filters.c,v 1.144 2011/07/30 15:15:25 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/filters.c,v $ @@ -574,7 +574,7 @@ struct http_response *block_url(struct client_state *csp) } if (csp->action->flags & ACTION_REDIRECT) { - log_error(LOG_LEVEL_ERROR, "redirect{} overruled by block."); + log_error(LOG_LEVEL_ERROR, "redirect{} overruled by block."); } /* * Else, prepare a response @@ -668,7 +668,7 @@ struct http_response *block_url(struct client_state *csp) if(csp->action->flags & ACTION_HANDLE_AS_EMPTY_DOCUMENT) { /* - * Send empty document. + * Send empty document. */ new_content_type = csp->action->string[ACTION_STRING_CONTENT_TYPE]; @@ -836,7 +836,7 @@ struct http_response *trust_url(struct client_state *csp) * Export the protocol, host, port, and referrer information */ err = map(exports, "hostport", 1, csp->http->hostport, 1); - if (!err) err = map(exports, "protocol", 1, csp->http->ssl ? "https://" : "http://", 1); + if (!err) err = map(exports, "protocol", 1, csp->http->ssl ? "https://" : "http://", 1); if (!err) err = map(exports, "path", 1, csp->http->path, 1); if (NULL != (p = get_header_value(csp->headers, "Referer:"))) @@ -956,7 +956,7 @@ struct http_response *trust_url(struct client_state *csp) * 2 : b = The filter list to compile * * Returns : NULL in case of errors, otherwise the - * pcrs job list. + * pcrs job list. * *********************************************************************/ pcrs_job *compile_dynamic_pcrs_job_list(const struct client_state *csp, const struct re_filterfile_spec *b) @@ -1025,7 +1025,7 @@ pcrs_job *compile_dynamic_pcrs_job_list(const struct client_state *csp, const st * 2 : pcrs_command = pcrs command formatted as string (s@foo@bar@) * * - * Returns : NULL if the pcrs_command didn't change the url, or + * Returns : NULL if the pcrs_command didn't change the url, or * the result of the modification. * *********************************************************************/ @@ -1084,7 +1084,7 @@ char *rewrite_url(char *old_url, const char *pcrs_command) * * Parameters : * 1 : subject = the string to check - * 2 : redirect_mode = +fast-redirect{} mode + * 2 : redirect_mode = +fast-redirect{} mode * * Returns : NULL if no URL was found, or * the last URL found. @@ -1106,7 +1106,7 @@ char *get_last_url(char *subject, const char *redirect_mode) } if (0 == strcmpic(redirect_mode, "check-decoded-url")) - { + { log_error(LOG_LEVEL_REDIRECTS, "Decoding \"%s\" if necessary.", subject); new_url = url_decode(subject); if (new_url != NULL) @@ -1143,7 +1143,7 @@ char *get_last_url(char *subject, const char *redirect_mode) )) { /* - * Return new URL if we found a redirect + * Return new URL if we found a redirect * or if the subject already was a URL. * * The second case makes sure that we can @@ -1249,7 +1249,7 @@ struct http_response *redirect_url(struct client_state *csp) #endif /* def FEATURE_FAST_REDIRECTS */ csp->action->flags &= ~ACTION_REDIRECT; - /* Did any redirect action trigger? */ + /* Did any redirect action trigger? */ if (new_url) { if (0 == strcmpic(new_url, csp->http->url)) @@ -1503,7 +1503,7 @@ static char *pcrs_filter_response(struct client_state *csp) struct re_filterfile_spec *b; struct list_entry *filtername; - /* + /* * Sanity first */ if (csp->iob->cur >= csp->iob->eod) @@ -1808,7 +1808,7 @@ static jb_err remove_chunked_transfer_coding(char *buffer, size_t *size) break; } } - + /* XXX: Should get its own loglevel. */ log_error(LOG_LEVEL_RE_FILTER, "De-chunking successful. Shrunk from %d to %d", *size, newsize); @@ -2187,7 +2187,7 @@ const struct forward_spec *forward_url(struct client_state *csp, /********************************************************************* * - * Function : direct_response + * Function : direct_response * * Description : Check if Max-Forwards == 0 for an OPTIONS or TRACE * request and if so, return a HTTP 501 to the client. @@ -2196,7 +2196,7 @@ const struct forward_spec *forward_url(struct client_state *csp, * requests properly. Still, what we do here is rfc- * compliant, whereas ignoring or forwarding are not. * - * Parameters : + * Parameters : * 1 : csp = Current client state (buffers, headers, etc...) * * Returns : http_response if , NULL if nonmatch or handler fail @@ -2236,7 +2236,7 @@ struct http_response *direct_response(struct client_state *csp) { return cgi_error_memory(); } - + if (NULL == (rsp->status = strdup("501 Not Implemented"))) { free_http_response(rsp); @@ -2337,7 +2337,7 @@ int content_requires_filtering(struct client_state *csp) * Description : Checks whether there are any content filters * enabled for the current request. * - * Parameters : + * Parameters : * 1 : action = Action spec to check. * * Returns : TRUE for yes, FALSE otherwise diff --git a/filters.h b/filters.h index b0374ce6..6de0af11 100644 --- a/filters.h +++ b/filters.h @@ -1,6 +1,6 @@ #ifndef FILTERS_H_INCLUDED #define FILTERS_H_INCLUDED -#define FILTERS_H_VERSION "$Id: filters.h,v 1.41 2010/09/14 07:16:07 fabiankeil Exp $" +#define FILTERS_H_VERSION "$Id: filters.h,v 1.42 2011/07/30 15:17:35 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/filters.h,v $ @@ -16,10 +16,10 @@ * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -89,8 +89,8 @@ extern int connect_port_is_forbidden(const struct client_state *csp); */ extern void get_url_actions(struct client_state *csp, struct http_request *http); -extern void apply_url_actions(struct current_action_spec *action, - struct http_request *http, +extern void apply_url_actions(struct current_action_spec *action, + struct http_request *http, struct url_actions *b); /* * Determining parent proxies @@ -117,7 +117,7 @@ extern int filters_available(const struct client_state *csp); */ extern struct http_response *direct_response(struct client_state *csp); -/* +/* * Revision control strings from this header and associated .c file */ extern const char filters_rcs[]; diff --git a/gateway.c b/gateway.c index bd5f2888..aaee5033 100644 --- a/gateway.c +++ b/gateway.c @@ -1,4 +1,4 @@ -const char gateway_rcs[] = "$Id: gateway.c,v 1.74 2011/07/17 13:31:35 fabiankeil Exp $"; +const char gateway_rcs[] = "$Id: gateway.c,v 1.75 2011/07/30 15:05:49 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/gateway.c,v $ @@ -68,7 +68,7 @@ const char gateway_rcs[] = "$Id: gateway.c,v 1.74 2011/07/17 13:31:35 fabiankeil #include "miscutil.h" #ifdef FEATURE_CONNECTION_KEEP_ALIVE #ifdef HAVE_POLL -#ifdef __GLIBC__ +#ifdef __GLIBC__ #include #else #include @@ -728,7 +728,7 @@ static jb_socket socks4_connect(const struct forward_spec * fwd, if (err) { log_error(LOG_LEVEL_CONNECT, "socks4_connect: %s", errstr); - csp->error_message = strdup(errstr); + csp->error_message = strdup(errstr); errno = EINVAL; return(JB_INVALID_SOCKET); } @@ -843,7 +843,7 @@ static jb_socket socks4_connect(const struct forward_spec * fwd, if (err) { - csp->error_message = strdup(errstr); + csp->error_message = strdup(errstr); return(JB_INVALID_SOCKET); } diff --git a/gateway.h b/gateway.h index e9ddbc48..03a6df9e 100644 --- a/gateway.h +++ b/gateway.h @@ -1,6 +1,6 @@ #ifndef GATEWAY_H_INCLUDED #define GATEWAY_H_INCLUDED -#define GATEWAY_H_VERSION "$Id: gateway.h,v 1.19 2009/10/03 10:37:49 fabiankeil Exp $" +#define GATEWAY_H_VERSION "$Id: gateway.h,v 1.20 2011/07/30 15:17:35 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/gateway.h,v $ @@ -13,10 +13,10 @@ * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -45,8 +45,8 @@ struct forward_spec; struct http_request; struct client_state; -extern jb_socket forwarded_connect(const struct forward_spec * fwd, - struct http_request *http, +extern jb_socket forwarded_connect(const struct forward_spec * fwd, + struct http_request *http, struct client_state *csp); /* diff --git a/jbsockets.c b/jbsockets.c index 265771fe..7c3ab071 100644 --- a/jbsockets.c +++ b/jbsockets.c @@ -1,4 +1,4 @@ -const char jbsockets_rcs[] = "$Id: jbsockets.c,v 1.107 2011/07/17 13:36:48 fabiankeil Exp $"; +const char jbsockets_rcs[] = "$Id: jbsockets.c,v 1.108 2011/07/30 15:12:02 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/jbsockets.c,v $ @@ -12,10 +12,10 @@ const char jbsockets_rcs[] = "$Id: jbsockets.c,v 1.107 2011/07/17 13:36:48 fabia * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -481,7 +481,7 @@ static jb_socket no_rfc2553_connect_to(const char *host, int portnum, struct cli { #ifdef _WIN32 if (errno == WSAEINPROGRESS) -#elif __OS2__ +#elif __OS2__ if (sock_errno() == EINPROGRESS) #else /* ifndef _WIN32 */ if (errno == EINPROGRESS) @@ -490,7 +490,7 @@ static jb_socket no_rfc2553_connect_to(const char *host, int portnum, struct cli break; } -#ifdef __OS2__ +#ifdef __OS2__ if (sock_errno() != EINTR) #else if (errno != EINTR) @@ -697,7 +697,7 @@ void close_socket(jb_socket fd) #if defined(_WIN32) || defined(__BEOS__) closesocket(fd); #elif defined(AMIGA) - CloseSocket(fd); + CloseSocket(fd); #elif defined(__OS2__) soclose(fd); #else @@ -1056,11 +1056,11 @@ void get_host_information(jb_socket afd, char **ip_address, char **port, } #elif defined(MUTEX_LOCKS_AVAILABLE) privoxy_mutex_lock(&resolver_mutex); - host = gethostbyaddr((const char *)&server.sin_addr, + host = gethostbyaddr((const char *)&server.sin_addr, sizeof(server.sin_addr), AF_INET); privoxy_mutex_unlock(&resolver_mutex); #else - host = gethostbyaddr((const char *)&server.sin_addr, + host = gethostbyaddr((const char *)&server.sin_addr, sizeof(server.sin_addr), AF_INET); #endif if (host == NULL) @@ -1087,7 +1087,7 @@ void get_host_information(jb_socket afd, char **ip_address, char **port, * created using bind_port(). * * Parameters : - * 1 : csp = Client state, cfd, ip_addr_str, and + * 1 : csp = Client state, cfd, ip_addr_str, and * ip_addr_long will be set by this routine. * 2 : fds = File descriptors returned from bind_port * @@ -1265,7 +1265,7 @@ unsigned long resolve_hostname_to_ip(const char *host) while (gethostbyname_r(host, &result, hbuf, HOSTENT_BUFFER_SIZE, &hostp, &thd_err) && (thd_err == TRY_AGAIN) && (dns_retries++ < MAX_DNS_RETRIES)) - { + { log_error(LOG_LEVEL_ERROR, "Timeout #%u while trying to resolve %s. Trying again.", dns_retries, host); @@ -1274,7 +1274,7 @@ unsigned long resolve_hostname_to_ip(const char *host) while (NULL == (hostp = gethostbyname_r(host, &result, hbuf, HOSTENT_BUFFER_SIZE, &thd_err)) && (thd_err == TRY_AGAIN) && (dns_retries++ < MAX_DNS_RETRIES)) - { + { log_error(LOG_LEVEL_ERROR, "Timeout #%u while trying to resolve %s. Trying again.", dns_retries, host); @@ -1296,7 +1296,7 @@ unsigned long resolve_hostname_to_ip(const char *host) privoxy_mutex_lock(&resolver_mutex); while (NULL == (hostp = gethostbyname(host)) && (h_errno == TRY_AGAIN) && (dns_retries++ < MAX_DNS_RETRIES)) - { + { log_error(LOG_LEVEL_ERROR, "Timeout #%u while trying to resolve %s. Trying again.", dns_retries, host); @@ -1329,7 +1329,7 @@ unsigned long resolve_hostname_to_ip(const char *host) errno = WSAEPROTOTYPE; #else errno = EPROTOTYPE; -#endif +#endif log_error(LOG_LEVEL_ERROR, "hostname %s resolves to unknown address type.", host); return(INADDR_NONE); } diff --git a/jbsockets.h b/jbsockets.h index cdee3c21..7221bac7 100644 --- a/jbsockets.h +++ b/jbsockets.h @@ -1,6 +1,6 @@ #ifndef JBSOCKETS_H_INCLUDED #define JBSOCKETS_H_INCLUDED -#define JBSOCKETS_H_VERSION "$Id: jbsockets.h,v 1.18 2011/07/17 13:34:36 fabiankeil Exp $" +#define JBSOCKETS_H_VERSION "$Id: jbsockets.h,v 1.19 2011/07/30 15:17:35 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/jbsockets.h,v $ @@ -14,10 +14,10 @@ * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at diff --git a/jcc.c b/jcc.c index d2c894c0..e3306ec2 100644 --- a/jcc.c +++ b/jcc.c @@ -1,4 +1,4 @@ -const char jcc_rcs[] = "$Id: jcc.c,v 1.363 2011/08/22 18:58:29 fabiankeil Exp $"; +const char jcc_rcs[] = "$Id: jcc.c,v 1.364 2011/08/27 10:36:45 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/jcc.c,v $ @@ -317,7 +317,7 @@ static const struct cruncher crunchers_light[] = { #if !defined(_WIN32) && !defined(__OS2__) && !defined(AMIGA) /********************************************************************* * - * Function : sig_handler + * Function : sig_handler * * Description : Signal handler for different signals. * Exit gracefully on TERM and INT @@ -327,7 +327,7 @@ static const struct cruncher crunchers_light[] = { * Parameters : * 1 : the_signal = the signal cause this function to call * - * Returns : - + * Returns : - * *********************************************************************/ static void sig_handler(int the_signal) @@ -350,10 +350,10 @@ static void sig_handler(int the_signal) #if defined(unix) received_hup_signal = 1; #endif - break; + break; default: - /* + /* * We shouldn't be here, unless we catch signals * in main() that we can't handle here! */ @@ -565,7 +565,7 @@ static jb_err get_server_headers(struct client_state *csp) log_error(LOG_LEVEL_HEADER, "Continue hack in da house."); continue_hack_in_da_house = 1; } - else if (*header == '\0') + else if (*header == '\0') { /* * If the header is empty, but the Continue hack @@ -723,7 +723,7 @@ static void send_crunch_response(const struct client_state *csp, struct http_res if (cgi_error_memory() != rsp) { free_http_response(rsp); - } + } return; } @@ -751,7 +751,7 @@ static int crunch_response_triggered(struct client_state *csp, const struct crun /* * If CGI request crunching is disabled, * check the CGI dispatcher out of order to - * prevent unintentional blocks or redirects. + * prevent unintentional blocks or redirects. */ if (!(csp->config->feature_flags & RUNTIME_FEATURE_CGI_CRUNCHING) && (NULL != (rsp = dispatch_cgi(csp)))) @@ -1339,7 +1339,7 @@ static jb_err receive_client_request(struct client_state *csp) destroy_list(headers); return JB_ERR_PARSE; } - + if (add_to_iob(csp, buf, len)) { /* @@ -1397,7 +1397,7 @@ static jb_err receive_client_request(struct client_state *csp) get_url_actions(csp, http); } - /* + /* * Save a copy of the original request for logging */ http->ocmd = strdup(http->cmd); @@ -2149,7 +2149,7 @@ static void chat(struct client_state *csp) hdr = list_to_text(csp->headers); if (hdr == NULL) { - /* + /* * Memory is too tight to even generate the header. * Send our static "Out-of-memory" page. */ @@ -2206,7 +2206,7 @@ static void chat(struct client_state *csp) { log_error(LOG_LEVEL_ERROR, "Out of memory while looking for end of server headers."); rsp = cgi_error_memory(); - send_crunch_response(csp, rsp); + send_crunch_response(csp, rsp); mark_server_socket_tainted(csp); return; } @@ -3036,7 +3036,7 @@ int main(int argc, char **argv) { char cwd[BUFFER_SIZE]; char *abs_file; - size_t abs_file_size; + size_t abs_file_size; /* make config-filename absolute here */ if (NULL == getcwd(cwd, sizeof(cwd))) @@ -3095,7 +3095,7 @@ int main(int argc, char **argv) for (idx = 0; catched_signals[idx] != 0; idx++) { -#ifdef sun /* FIXME: Is it safe to check for HAVE_SIGSET instead? */ +#ifdef sun /* FIXME: Is it safe to check for HAVE_SIGSET instead? */ if (sigset(catched_signals[idx], sig_handler) == SIG_ERR) #else if (signal(catched_signals[idx], sig_handler) == SIG_ERR) @@ -3265,7 +3265,7 @@ int main(int argc, char **argv) if (putenv(putenv_dummy) != 0) { log_error(LOG_LEVEL_FATAL, "Cannot putenv(): HOME"); - } + } snprintf(putenv_dummy, sizeof(putenv_dummy), "USER=%s", pw->pw_name); if (putenv(putenv_dummy) != 0) @@ -3286,7 +3286,7 @@ int main(int argc, char **argv) */ if (bRunAsService) { - /* Yup, so now we must attempt to establish a connection + /* Yup, so now we must attempt to establish a connection * with the service dispatcher. This will only work if this * process was launched by the service control manager to * actually run as a service. If this isn't the case, i've @@ -3682,7 +3682,7 @@ static void listen_loop(void) #if defined(AMIGA) && !defined(SELECTED_ONE_OPTION) #define SELECTED_ONE_OPTION csp->cfd = ReleaseSocket(csp->cfd, -1); - + #ifdef __amigaos4__ child_id = (int)CreateNewProcTags(NP_Entry, (ULONG)server_thread, NP_Output, Output(), @@ -3723,7 +3723,7 @@ static void listen_loop(void) serve(csp); - /* + /* * If we've been toggled or we've blocked the request, tell Mom */ @@ -3734,7 +3734,7 @@ static void listen_loop(void) } #endif /* def FEATURE_TOGGLE */ -#ifdef FEATURE_STATISTICS +#ifdef FEATURE_STATISTICS if (csp->flags & CSP_FLAG_REJECTED) { rc |= RC_FLAG_BLOCKED; @@ -3754,7 +3754,7 @@ static void listen_loop(void) wait( &child_status ); - /* + /* * Evaluate child's return code: If the child has * - been toggled, toggle ourselves * - blocked its request, bump up the stats counter @@ -3773,7 +3773,7 @@ static void listen_loop(void) { urls_rejected++; } -#endif /* def FEATURE_STATISTICS */ +#endif /* def FEATURE_STATISTICS */ #endif /* !defined(_WIN32) && defined(__CYGWIN__) */ close_socket(csp->cfd); diff --git a/jcc.h b/jcc.h index cf608932..14185097 100644 --- a/jcc.h +++ b/jcc.h @@ -1,21 +1,21 @@ #ifndef JCC_H_INCLUDED #define JCC_H_INCLUDED -#define JCC_H_VERSION "$Id: jcc.h,v 1.28 2010/01/03 12:37:14 fabiankeil Exp $" +#define JCC_H_VERSION "$Id: jcc.h,v 1.29 2010/07/21 14:35:09 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/jcc.h,v $ * - * Purpose : Main file. Contains main() method, main loop, and + * Purpose : Main file. Contains main() method, main loop, and * the main connection-handling function. * * Copyright : Written by and Copyright (C) 2001-2006 the SourceForge * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at diff --git a/list.c b/list.c index 224c52f5..6f6b040d 100644 --- a/list.c +++ b/list.c @@ -1,4 +1,4 @@ -const char list_rcs[] = "$Id: list.c,v 1.23 2011/01/22 12:30:22 fabiankeil Exp $"; +const char list_rcs[] = "$Id: list.c,v 1.24 2011/04/19 13:00:47 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/list.c,v $ @@ -185,13 +185,13 @@ static int list_is_valid (const struct list *the_list) * Note that the 1000 limit was hit by a real user in tracker 911950; * removing it for now. Real circular references should eventually * be caught by the check above, anyway. - */ + */ /* if (entry > 1000) - { + { return 0; - } - */ + } + */ /* * Check this isn't marked as the last entry, unless of course it's @@ -839,7 +839,7 @@ int list_contains_item(const struct list *the_list, const char *str) if (entry->str == NULL) { /* - * NULL pointers are allowed in some lists. + * NULL pointers are allowed in some lists. * For example for csp->headers in case a * header was removed. */ @@ -1040,7 +1040,7 @@ jb_err unmap(struct map *the_map, const char *name) assert(the_map); assert(name); - + last_entry = the_map->first; for (cur_entry = the_map->first; cur_entry != NULL; cur_entry = cur_entry->next) @@ -1060,13 +1060,13 @@ jb_err unmap(struct map *the_map, const char *name) } /* - * Update the map's last pointer + * Update the map's last pointer */ if (cur_entry == the_map->last) { the_map->last = last_entry; } - + /* * Free the map_entry */ diff --git a/list.h b/list.h index 71047360..5c1a0df3 100644 --- a/list.h +++ b/list.h @@ -1,6 +1,6 @@ #ifndef LIST_H_INCLUDED #define LIST_H_INCLUDED -#define LIST_H_VERSION "$Id: list.h,v 1.16 2009/05/16 13:27:20 fabiankeil Exp $" +#define LIST_H_VERSION "$Id: list.h,v 1.17 2010/11/22 10:32:40 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/list.h,v $ @@ -13,10 +13,10 @@ * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at diff --git a/loadcfg.h b/loadcfg.h index 37e400f7..302cd32d 100644 --- a/loadcfg.h +++ b/loadcfg.h @@ -1,12 +1,12 @@ #ifndef LOADCFG_H_INCLUDED #define LOADCFG_H_INCLUDED -#define LOADCFG_H_VERSION "$Id: loadcfg.h,v 1.14 2009/05/16 13:27:20 fabiankeil Exp $" +#define LOADCFG_H_VERSION "$Id: loadcfg.h,v 1.15 2009/09/10 14:45:17 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/loadcfg.h,v $ * * Purpose : Loads settings from the configuration file into - * global variables. This file contains both the + * global variables. This file contains both the * routine to load the configuration and the global * variables it writes to. * @@ -14,10 +14,10 @@ * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at diff --git a/loaders.c b/loaders.c index 685a6de4..34bd59ee 100644 --- a/loaders.c +++ b/loaders.c @@ -1,4 +1,4 @@ -const char loaders_rcs[] = "$Id: loaders.c,v 1.84 2011/07/30 15:12:55 fabiankeil Exp $"; +const char loaders_rcs[] = "$Id: loaders.c,v 1.85 2011/07/30 15:13:32 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/loaders.c,v $ @@ -142,12 +142,12 @@ unsigned int sweep(void) */ csp->config->config_file_list->active = 1; - /* + /* * Actions files */ for (i = 0; i < MAX_AF_FILES; i++) { - if (csp->actions_list[i]) + if (csp->actions_list[i]) { csp->actions_list[i]->active = 1; } @@ -158,7 +158,7 @@ unsigned int sweep(void) */ for (i = 0; i < MAX_AF_FILES; i++) { - if (csp->rlist[i]) + if (csp->rlist[i]) { csp->rlist[i]->active = 1; } @@ -179,7 +179,7 @@ unsigned int sweep(void) last_active = client_list; client_list = client_list->next; } - else + else /* * This client is not active. Free its resources. */ @@ -211,7 +211,7 @@ unsigned int sweep(void) #endif /* def FEATURE_STATISTICS */ freez(client_list); - + client_list = last_active->next; } } @@ -931,7 +931,7 @@ int load_trustfile(struct client_state *csp) freez(buf); } - if(trusted_referrers >= MAX_TRUSTED_REFERRERS) + if(trusted_referrers >= MAX_TRUSTED_REFERRERS) { /* * FIXME: ... after Privoxy 3.0.4 is out. @@ -1006,7 +1006,7 @@ static void unload_re_filterfile(void *f) * * Function : unload_forward_spec * - * Description : Unload the forward spec settings by freeing all + * Description : Unload the forward spec settings by freeing all * memory referenced by members and the memory for * the spec itself. * @@ -1060,7 +1060,7 @@ void unload_current_re_filterfile(void) * * Function : load_re_filterfiles * - * Description : Loads all the filterfiles. + * Description : Loads all the filterfiles. * Generate a chained list of re_filterfile_spec's from * the "FILTER: " blocks, compiling all their substitutions * into chained lists of pcrs_job structs. @@ -1101,7 +1101,7 @@ int load_re_filterfiles(struct client_state *csp) * * Function : load_one_re_filterfile * - * Description : Load a re_filterfile. + * Description : Load a re_filterfile. * Generate a chained list of re_filterfile_spec's from * the "FILTER: " blocks, compiling all their substitutions * into chained lists of pcrs_job structs. @@ -1137,7 +1137,7 @@ int load_one_re_filterfile(struct client_state *csp, int fileid) goto load_re_filterfile_error; } - /* + /* * Open the file or fail */ if ((fp = fopen(csp->config->re_filterfile[fileid], "r")) == NULL) @@ -1147,7 +1147,7 @@ int load_one_re_filterfile(struct client_state *csp, int fileid) log_error(LOG_LEVEL_INFO, "Loading filter file: %s", csp->config->re_filterfile[fileid]); - /* + /* * Read line by line */ while (read_config_line(fp, &linenum, &buf) != NULL) @@ -1215,7 +1215,7 @@ int load_one_re_filterfile(struct client_state *csp, int fileid) } new_bl->name = strdup(chomp(new_bl->name)); - + /* * If this is the first filter block, chain it * to the file_list rather than its (nonexistant) @@ -1238,9 +1238,9 @@ int load_one_re_filterfile(struct client_state *csp, int fileid) continue; } - /* + /* * Else, save the expression, make it a pcrs_job - * and chain it into the current filter's joblist + * and chain it into the current filter's joblist */ if (bl != NULL) { @@ -1267,7 +1267,7 @@ int load_one_re_filterfile(struct client_state *csp, int fileid) log_error(LOG_LEVEL_RE_FILTER, "Adding dynamic re_filter job \'%s\' to filter %s succeeded.", buf, bl->name); freez(buf); - continue; + continue; } else if (bl->dynamic) { @@ -1313,7 +1313,7 @@ int load_one_re_filterfile(struct client_state *csp, int fileid) fclose(fp); - /* + /* * Schedule the now-obsolete old data for unloading */ if ( NULL != current_re_filterfile[fileid] ) diff --git a/loaders.h b/loaders.h index 348551ac..c50a2d4e 100644 --- a/loaders.h +++ b/loaders.h @@ -1,23 +1,23 @@ #ifndef LOADERS_H_INCLUDED #define LOADERS_H_INCLUDED -#define LOADERS_H_VERSION "$Id: loaders.h,v 1.27 2011/03/03 14:38:36 fabiankeil Exp $" +#define LOADERS_H_VERSION "$Id: loaders.h,v 1.28 2011/04/19 13:00:47 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/loaders.h,v $ * * Purpose : Functions to load and unload the various * configuration files. Also contains code to manage - * the list of active loaders, and to automatically + * the list of active loaders, and to automatically * unload files that are no longer in use. * * Copyright : Written by and Copyright (C) 2001-2010 the * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -98,7 +98,7 @@ void unload_current_re_filterfile(void); void unload_forward_spec(struct forward_spec *fwd); -extern void add_loader(int (*loader)(struct client_state *), +extern void add_loader(int (*loader)(struct client_state *), struct configuration_spec * config); extern int run_loader(struct client_state *csp); diff --git a/miscutil.c b/miscutil.c index 58f0c647..34e8e4f2 100644 --- a/miscutil.c +++ b/miscutil.c @@ -1,4 +1,4 @@ -const char miscutil_rcs[] = "$Id: miscutil.c,v 1.66 2011/05/22 10:26:45 fabiankeil Exp $"; +const char miscutil_rcs[] = "$Id: miscutil.c,v 1.67 2011/05/22 10:30:55 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/miscutil.c,v $ @@ -12,7 +12,7 @@ const char miscutil_rcs[] = "$Id: miscutil.c,v 1.66 2011/05/22 10:26:45 fabianke * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * * The timegm replacement function was taken from GnuPG, @@ -23,7 +23,7 @@ const char miscutil_rcs[] = "$Id: miscutil.c,v 1.66 2011/05/22 10:26:45 fabianke * used under the terms of the GPL or the terms of the * "Frontier Artistic License". * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -97,19 +97,19 @@ void *zalloc(size_t size) #if defined(unix) /********************************************************************* * - * Function : write_pid_file + * Function : write_pid_file * - * Description : Writes a pid file with the pid of the main process + * Description : Writes a pid file with the pid of the main process * * Parameters : None * - * Returns : N/A + * Returns : N/A * *********************************************************************/ void write_pid_file(void) { FILE *fp; - + /* * If no --pidfile option was given, * we can live without one. @@ -147,7 +147,7 @@ void write_pid_file(void) *********************************************************************/ unsigned int hash_string( const char* s ) { - unsigned int h = 0; + unsigned int h = 0; for ( ; *s; ++s ) { @@ -209,7 +209,7 @@ int strncmpic(const char *s1, const char *s2, size_t n) if (n <= (size_t)0) return(0); if (!s1) s1 = ""; if (!s2) s2 = ""; - + while (*s1 && *s2) { if ( ( *s1 != *s2 ) && ( ijb_tolower(*s1) != ijb_tolower(*s2) ) ) @@ -243,7 +243,7 @@ char *chomp(char *string) { char *p, *q, *r; - /* + /* * strip trailing whitespace */ p = string + strlen(string); @@ -253,8 +253,8 @@ char *chomp(char *string) } *p = '\0'; - /* - * find end of leading whitespace + /* + * find end of leading whitespace */ q = r = string; while (*q && ijb_isspace(*q)) @@ -282,7 +282,7 @@ char *chomp(char *string) * * Function : string_append * - * Description : Reallocate target_string and append text to it. + * Description : Reallocate target_string and append text to it. * This makes it easier to append to malloc'd strings. * This is similar to the (removed) strsav(), but * running out of memory isn't catastrophic. @@ -427,7 +427,7 @@ jb_err string_join(char **target_string, char *text_to_append) * Parameters : * 1 : string = string to convert * - * Returns : Uppercase copy of string if possible, + * Returns : Uppercase copy of string if possible, * NULL on out-of-memory or if string was NULL. * *********************************************************************/ @@ -440,7 +440,7 @@ char *string_toupper(const char *string) { return NULL; } - + q = string; p = result; @@ -490,11 +490,11 @@ char *bindup(const char *string, size_t len) * * Function : make_path * - * Description : Takes a directory name and a file name, returns + * Description : Takes a directory name and a file name, returns * the complete path. Handles windows/unix differences. * If the file name is already an absolute path, or if - * the directory name is NULL or empty, it returns - * the filename. + * the directory name is NULL or empty, it returns + * the filename. * * Parameters : * 1 : dir: Name of directory or NULL for none. @@ -503,7 +503,7 @@ char *bindup(const char *string, size_t len) * Returns : "dir/file" (Or on windows, "dir\file"). * It allocates the string on the heap. Caller frees. * Returns NULL in error (i.e. NULL file or out of - * memory) + * memory) * *********************************************************************/ char * make_path(const char * dir, const char * file) @@ -616,7 +616,7 @@ char * make_path(const char * dir, const char * file) * Parameters : * 1 : range: Highest possible number to pick. * - * Returns : Picked number. + * Returns : Picked number. * *********************************************************************/ long int pick_from_range(long int range) @@ -632,7 +632,7 @@ long int pick_from_range(long int range) if (range <= 0) return 0; #ifdef HAVE_RANDOM - number = random() % range + 1; + number = random() % range + 1; #elif defined(MUTEX_LOCKS_AVAILABLE) privoxy_mutex_lock(&rand_mutex); #ifdef _WIN32 @@ -736,7 +736,7 @@ size_t privoxy_strlcat(char *destination, const char *source, const size_t size) * Parameters : * 1 : tm: Broken-down time struct. * - * Returns : tm converted into time_t seconds. + * Returns : tm converted into time_t seconds. * *********************************************************************/ time_t timegm(struct tm *tm) @@ -788,7 +788,7 @@ time_t timegm(struct tm *tm) snprintf.c - a portable implementation of snprintf, including vsnprintf.c, asnprintf, vasnprintf, asprintf, vasprintf - + snprintf is a routine to convert numeric and string arguments to formatted strings. It is similar to sprintf(3) provided in a system's C library, yet it requires an additional argument - the buffer size - @@ -1430,7 +1430,7 @@ int portable_vsnprintf(char *str, size_t str_m, const char *fmt, va_list ap) { } } /* zero padding to specified precision? */ - if (num_of_digits < precision) + if (num_of_digits < precision) number_of_zeros_to_pad = precision - num_of_digits; } /* zero padding to specified minimal field width? */ diff --git a/miscutil.h b/miscutil.h index c1ab3e2b..4d2b9d39 100644 --- a/miscutil.h +++ b/miscutil.h @@ -1,6 +1,6 @@ #ifndef MISCUTIL_H_INCLUDED #define MISCUTIL_H_INCLUDED -#define MISCUTIL_H_VERSION "$Id: miscutil.h,v 1.32 2011/05/22 10:26:45 fabiankeil Exp $" +#define MISCUTIL_H_VERSION "$Id: miscutil.h,v 1.33 2011/05/22 10:30:55 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/miscutil.h,v $ @@ -14,10 +14,10 @@ * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at diff --git a/parsers.c b/parsers.c index ff240ded..7721f587 100644 --- a/parsers.c +++ b/parsers.c @@ -1,4 +1,4 @@ -const char parsers_rcs[] = "$Id: parsers.c,v 1.225 2011/07/08 13:30:08 fabiankeil Exp $"; +const char parsers_rcs[] = "$Id: parsers.c,v 1.226 2011/08/31 13:35:21 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/parsers.c,v $ @@ -187,10 +187,10 @@ struct parsers { /** The header prefix to match */ const char *str; - + /** The length of the prefix to match */ const size_t len; - + /** The function to apply to this line */ const parser_func_ptr parser; }; @@ -350,7 +350,7 @@ jb_err add_to_iob(struct client_state *csp, char *buf, long n) { want *= 2; } - + if (want <= csp->config->buffer_limit && NULL != (p = (char *)realloc(iob->buf, want))) { iob->size = want; @@ -406,7 +406,7 @@ jb_err add_to_iob(struct client_state *csp, char *buf, long n) jb_err decompress_iob(struct client_state *csp) { char *buf; /* new, uncompressed buffer */ - char *cur; /* Current iob position (to keep the original + char *cur; /* Current iob position (to keep the original * iob->cur unmodified if we return early) */ size_t bufsize; /* allocated size of the new buffer */ size_t old_size; /* Content size before decompression */ @@ -554,7 +554,7 @@ jb_err decompress_iob(struct client_state *csp) * * Fortunately, add_to_iob() has thoughtfully null-terminated * the buffer; we can just increment the end pointer to include - * the dummy byte. + * the dummy byte. */ csp->iob->eod++; } @@ -638,7 +638,7 @@ jb_err decompress_iob(struct client_state *csp) { bufsize = csp->config->buffer_limit; } - + /* Try to allocate the new buffer. */ tmpbuf = realloc(buf, bufsize); if (NULL == tmpbuf) @@ -710,7 +710,7 @@ jb_err decompress_iob(struct client_state *csp) csp->iob->cur = csp->iob->buf + skip_size; csp->iob->eod = (char *)zstr.next_out; csp->iob->size = bufsize; - + /* * Make sure the new uncompressed iob obeys some minimal * consistency conditions. @@ -882,7 +882,7 @@ char *get_header(struct iob *iob) * Header spans multiple lines, append the next one. */ char *continued_header; - + continued_header = get_header_line(iob); if ((continued_header == NULL) || (*continued_header == '\0')) { @@ -1014,7 +1014,7 @@ char *get_header_value(const struct list *header_list, const char *header_name) } } - /* + /* * Not found */ return NULL; @@ -1026,7 +1026,7 @@ char *get_header_value(const struct list *header_list, const char *header_name) * * Function : scan_headers * - * Description : Scans headers, applies tags and updates action bits. + * Description : Scans headers, applies tags and updates action bits. * * Parameters : * 1 : csp = Current client state (buffers, headers, etc...) @@ -1344,7 +1344,7 @@ static jb_err header_tagger(struct client_state *csp, char *header) b->name); continue; } - + if (!list_contains_item(csp->tags, tag)) { if (JB_ERR_OK != enlist(csp->tags, tag)) @@ -1508,7 +1508,7 @@ static jb_err filter_header(struct client_state *csp, char **header) matches = pcrs_execute(job, *header, size, &newheader, &size); if ( 0 < matches ) { - current_hits += matches; + current_hits += matches; log_error(LOG_LEVEL_HEADER, "Transforming \"%s\" to \"%s\"", *header, newheader); freez(*header); *header = newheader; @@ -1822,7 +1822,7 @@ static jb_err client_save_content_length(struct client_state *csp, char **header * Function : client_connection * * Description : Makes sure a proper "Connection:" header is - * set and signals connection_header_adder + * set and signals connection_header_adder * to do nothing. * * Parameters : @@ -1959,7 +1959,7 @@ static jb_err crunch_server_header(struct client_state *csp, char **header) /* Is the current header the lucky one? */ if (strstr(*header, crunch_pattern)) { - log_error(LOG_LEVEL_HEADER, "Crunching server header: %s (contains: %s)", *header, crunch_pattern); + log_error(LOG_LEVEL_HEADER, "Crunching server header: %s (contains: %s)", *header, crunch_pattern); freez(*header); } } @@ -2040,7 +2040,7 @@ static jb_err server_content_type(struct client_state *csp, char **header) { /* * Make sure the user doesn't accidentally - * change the content type of binary documents. + * change the content type of binary documents. */ if ((csp->content_type & CT_TEXT) || (csp->action->flags & ACTION_FORCE_TEXT_MODE)) { @@ -2139,7 +2139,7 @@ static jb_err server_transfer_coding(struct client_state *csp, char **header) * * If FEATURE_ZLIB is enabled and the compression type * supported, the content is marked for decompression. - * + * * XXX: Doesn't properly deal with multiple or with * unsupported but unknown encodings. * Is case-sensitive but shouldn't be. @@ -2428,7 +2428,7 @@ static jb_err server_content_disposition(struct client_state *csp, char **header return JB_ERR_OK; } else - { + { /* * Replacing Content-Disposition header */ @@ -2493,18 +2493,18 @@ static jb_err server_last_modified(struct client_state *csp, char **header) return JB_ERR_OK; } else if (0 == strcmpic(newval, "reset-to-request-time")) - { + { /* * Setting Last-Modified Header to now. */ get_http_time(0, buf, sizeof(buf)); freez(*header); *header = strdup("Last-Modified: "); - string_append(header, buf); + string_append(header, buf); if (*header == NULL) { - log_error(LOG_LEVEL_HEADER, "Insufficient memory. Last-Modified header got lost, boohoo."); + log_error(LOG_LEVEL_HEADER, "Insufficient memory. Last-Modified header got lost, boohoo."); } else { @@ -2539,7 +2539,7 @@ static jb_err server_last_modified(struct client_state *csp, char **header) if (negative_delta) { - rtime *= -1; + rtime *= -1; log_error(LOG_LEVEL_HEADER, "Server time in the future."); } rtime = pick_from_range(rtime); @@ -2574,7 +2574,7 @@ static jb_err server_last_modified(struct client_state *csp, char **header) if (*header == NULL) { log_error(LOG_LEVEL_ERROR, "Insufficient memory, header crunched without replacement."); - return JB_ERR_MEMORY; + return JB_ERR_MEMORY; } days = rtime / (3600 * 24); @@ -2690,7 +2690,7 @@ static jb_err client_referrer(struct client_state *csp, char **header) /* booleans for parameters we have to check multiple times */ int parameter_conditional_block; int parameter_conditional_forge; - + #ifdef FEATURE_FORCE_LOAD /* * Since the referrer can include the prefix even @@ -2788,18 +2788,18 @@ static jb_err client_accept_language(struct client_state *csp, char **header) return JB_ERR_OK; } else - { + { /* * Replacing Accept-Language header */ freez(*header); *header = strdup("Accept-Language: "); - string_append(header, newval); + string_append(header, newval); if (*header == NULL) { log_error(LOG_LEVEL_ERROR, - "Insufficient memory. Accept-Language header crunched without replacement."); + "Insufficient memory. Accept-Language header crunched without replacement."); } else { @@ -2840,7 +2840,7 @@ static jb_err crunch_client_header(struct client_state *csp, char **header) /* Is the current header the lucky one? */ if (strstr(*header, crunch_pattern)) { - log_error(LOG_LEVEL_HEADER, "Crunching client header: %s (contains: %s)", *header, crunch_pattern); + log_error(LOG_LEVEL_HEADER, "Crunching client header: %s (contains: %s)", *header, crunch_pattern); freez(*header); } } @@ -3145,10 +3145,10 @@ static jb_err client_host(struct client_state *csp, char **header) return JB_ERR_OK; } - if (!csp->http->hostport || (*csp->http->hostport == '*') || + if (!csp->http->hostport || (*csp->http->hostport == '*') || *csp->http->hostport == ' ' || *csp->http->hostport == '\0') { - + if (NULL == (p = strdup((*header)+6))) { return JB_ERR_MEMORY; @@ -3211,13 +3211,13 @@ static jb_err client_if_modified_since(struct client_state *csp, char **header) struct tm gmt; #endif struct tm *timeptr = NULL; - time_t tm = 0; + time_t tm = 0; const char *newval; char * endptr; - + if ( 0 == strcmpic(*header, "If-Modified-Since: Wed, 08 Jun 1955 12:00:00 GMT")) { - /* + /* * The client got an error message because of a temporary problem, * the problem is gone and the client now tries to revalidate our * error message on the real server. The revalidation would always @@ -3257,7 +3257,7 @@ static jb_err client_if_modified_since(struct client_state *csp, char **header) *header, rtime, (rtime == 1 || rtime == -1) ? "e": "es"); if (negative_range) { - rtime *= -1; + rtime *= -1; } rtime *= 60; rtime = pick_from_range(rtime); @@ -3294,7 +3294,7 @@ static jb_err client_if_modified_since(struct client_state *csp, char **header) if (*header == NULL) { log_error(LOG_LEVEL_HEADER, "Insufficient memory, header crunched without replacement."); - return JB_ERR_MEMORY; + return JB_ERR_MEMORY; } hours = rtime / 3600; @@ -3334,7 +3334,7 @@ static jb_err client_if_modified_since(struct client_state *csp, char **header) static jb_err client_if_none_match(struct client_state *csp, char **header) { if (csp->action->flags & ACTION_CRUNCH_IF_NONE_MATCH) - { + { log_error(LOG_LEVEL_HEADER, "Crunching %s", *header); freez(*header); } @@ -3376,7 +3376,7 @@ jb_err client_x_filter(struct client_state *csp, char **header) "force-text-mode overruled the client's request to fetch without filtering!"); } else - { + { csp->content_type = CT_TABOO; /* XXX: This hack shouldn't be necessary */ csp->flags |= CSP_FLAG_NO_FILTERING; log_error(LOG_LEVEL_HEADER, "Accepted the client's request to fetch without filtering."); @@ -3385,7 +3385,7 @@ jb_err client_x_filter(struct client_state *csp, char **header) freez(*header); } } - return JB_ERR_OK; + return JB_ERR_OK; } @@ -3419,7 +3419,7 @@ static jb_err client_range(struct client_state *csp, char **header) freez(*header); } - return JB_ERR_OK; + return JB_ERR_OK; } /* the following functions add headers directly to the header list */ @@ -3788,7 +3788,7 @@ static jb_err server_http(struct client_state *csp, char **header) static jb_err server_set_cookie(struct client_state *csp, char **header) { time_t now; - time_t cookie_time; + time_t cookie_time; time(&now); @@ -3998,7 +3998,7 @@ int strclean(char *string, const char *substring) * to get the numerical respresentation. * * Parameters : - * 1 : header_time = HTTP header time as string. + * 1 : header_time = HTTP header time as string. * 2 : result = storage for header_time in seconds * * Returns : JB_ERR_OK if the time format was recognized, or @@ -4054,7 +4054,7 @@ static jb_err parse_header_time(const char *header_time, time_t *result) * Parameters : * 1 : headers = List of headers (one of them hopefully being * the "Host:" header) - * 2 : http = storage for the result (host, port and hostport). + * 2 : http = storage for the result (host, port and hostport). * * Returns : JB_ERR_MEMORY in case of memory problems, * JB_ERR_PARSE if the host header couldn't be found, @@ -4129,7 +4129,7 @@ jb_err get_destination_from_headers(const struct list *headers, struct http_requ * * Description : Helper for client_referrer to forge a referer as * 'http://[hostname:port/' to fool stupid - * checks for in-site links + * checks for in-site links * * Parameters : * 1 : header = Pointer to header pointer diff --git a/parsers.h b/parsers.h index c6314d52..60fef213 100644 --- a/parsers.h +++ b/parsers.h @@ -1,6 +1,6 @@ #ifndef PARSERS_H_INCLUDED #define PARSERS_H_INCLUDED -#define PARSERS_H_VERSION "$Id: parsers.h,v 1.49 2009/03/13 14:10:07 fabiankeil Exp $" +#define PARSERS_H_VERSION "$Id: parsers.h,v 1.50 2009/05/16 13:27:20 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/parsers.h,v $ @@ -20,10 +20,10 @@ * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at diff --git a/pcrs.c b/pcrs.c index 0f5145aa..3b16dead 100644 --- a/pcrs.c +++ b/pcrs.c @@ -1,4 +1,4 @@ -const char pcrs_rcs[] = "$Id: pcrs.c,v 1.36 2011/03/03 14:49:08 fabiankeil Exp $"; +const char pcrs_rcs[] = "$Id: pcrs.c,v 1.37 2011/04/19 13:00:47 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/pcrs.c,v $ @@ -16,7 +16,7 @@ const char pcrs_rcs[] = "$Id: pcrs.c,v 1.36 2011/03/03 14:49:08 fabiankeil Exp $ * * Copyright (C) 2006, 2007 Fabian Keil * - * This program is free software; you can redistribute it + * This program is free software; you can redistribute it * and/or modify it under the terms of the GNU Lesser * General Public License (LGPL), version 2.1, which should * be included in this distribution (see LICENSE.txt), with @@ -71,7 +71,7 @@ static int is_hex_sequence(const char *sequence); * Function : pcrs_strerror * * Description : Return a string describing a given error code. - * + * * Parameters : * 1 : error = the error code * @@ -94,7 +94,7 @@ const char *pcrs_strerror(const int error) case PCRE_ERROR_UNKNOWN_NODE: return "(pcre:) Bad node in pattern"; /* Can't happen / not passed: */ - case PCRE_ERROR_NOSUBSTRING: return "(pcre:) Fire in power supply"; + case PCRE_ERROR_NOSUBSTRING: return "(pcre:) Fire in power supply"; case PCRE_ERROR_NOMATCH: return "(pcre:) Water in power supply"; #ifdef PCRE_ERROR_MATCHLIMIT @@ -113,7 +113,7 @@ const char *pcrs_strerror(const int error) case PCRS_WARN_TRUNCATION: return "(pcrs:) At least one variable was too big and has been truncated before compilation"; - /* + /* * XXX: With the exception of PCRE_ERROR_MATCHLIMIT we * only catch PCRE errors that can happen with our internal * version. If Privoxy is linked against a newer @@ -139,12 +139,12 @@ const char *pcrs_strerror(const int error) * 'T' (trivial) options but pcrs needs them, the corresponding * flags are set if 'g'or 'T' is encountered. * Note: The 'T' and 'U' options do not conform to Perl. - * + * * Parameters : * 1 : optstring = string with options in perl syntax * 2 : flags = see description * - * Returns : option integer suitable for pcre + * Returns : option integer suitable for pcre * *********************************************************************/ static int pcrs_parse_perl_options(const char *optstring, int *flags) @@ -236,7 +236,7 @@ static pcrs_substitute *pcrs_compile_replacement(const char *replacement, int tr return NULL; } memset(text, '\0', length + 1); - + /* * In trivial mode, just copy the substitute text @@ -305,7 +305,7 @@ static pcrs_substitute *pcrs_compile_replacement(const char *replacement, int tr assert(ascii_value < 256); text[k++] = (char)ascii_value; i += 4; - } + } else { quoted = 1; @@ -337,7 +337,7 @@ static pcrs_substitute *pcrs_compile_replacement(const char *replacement, int tr /* Symbolic backreferences: */ else if (NULL != (symbol = strchr(symbols, replacement[i + 1]))) { - + if (symbol - symbols == 2) /* $+ */ { r->backref[l] = capturecount; @@ -368,10 +368,10 @@ static pcrs_substitute *pcrs_compile_replacement(const char *replacement, int tr else { *errptr = PCRS_WARN_BADREF; - } + } continue; } - + plainchar: /* Plain chars are copied */ text[k++] = replacement[i++]; @@ -403,7 +403,7 @@ plainchar: * 1 : job = pointer to the pcrs_job structure to be freed * * Returns : a pointer to the next job, if there was any, or - * NULL otherwise. + * NULL otherwise. * *********************************************************************/ pcrs_job *pcrs_free_job(pcrs_job *job) @@ -458,7 +458,7 @@ void pcrs_free_joblist(pcrs_job *joblist) * * Function : pcrs_compile_command * - * Description : Parses a string with a Perl-style s/// command, + * Description : Parses a string with a Perl-style s/// command, * calls pcrs_compile, and returns a corresponding * pcrs_job, or NULL if parsing or compiling the job * fails. @@ -478,11 +478,11 @@ pcrs_job *pcrs_compile_command(const char *command, int *errptr) int i, k, l, quoted = FALSE; size_t limit; char delimiter; - char *tokens[4]; + char *tokens[4]; pcrs_job *newjob; - + k = l = 0; - + /* * Tokenize the perl command */ @@ -501,7 +501,7 @@ pcrs_job *pcrs_compile_command(const char *command, int *errptr) for (i = 0; i <= (int)limit; i++) { - + if (command[i] == delimiter && !quoted) { if (l == 3) @@ -513,7 +513,7 @@ pcrs_job *pcrs_compile_command(const char *command, int *errptr) tokens[++l] = tokens[0] + k; continue; } - + else if (command[i] == '\\' && !quoted) { quoted = TRUE; @@ -535,11 +535,11 @@ pcrs_job *pcrs_compile_command(const char *command, int *errptr) free(tokens[0]); return NULL; } - + newjob = pcrs_compile(tokens[1], tokens[2], tokens[3], errptr); free(tokens[0]); return newjob; - + } @@ -571,14 +571,14 @@ pcrs_job *pcrs_compile(const char *pattern, const char *substitute, const char * *errptr = 0; - /* + /* * Handle NULL arguments */ if (pattern == NULL) pattern = ""; if (substitute == NULL) substitute = ""; - /* + /* * Get and init memory */ if (NULL == (newjob = (pcrs_job *)malloc(sizeof(pcrs_job)))) @@ -618,10 +618,10 @@ pcrs_job *pcrs_compile(const char *pattern, const char *substitute, const char * pcrs_free_job(newjob); return NULL; } - - /* - * Determine the number of capturing subpatterns. + + /* + * Determine the number of capturing subpatterns. * This is needed for handling $+ in the substitute. */ if (0 > (*errptr = pcre_fullinfo(newjob->pattern, newjob->hints, PCRE_INFO_CAPTURECOUNT, &capturecount))) @@ -629,7 +629,7 @@ pcrs_job *pcrs_compile(const char *pattern, const char *substitute, const char * pcrs_free_job(newjob); return NULL; } - + /* * Compile the substitute @@ -639,7 +639,7 @@ pcrs_job *pcrs_compile(const char *pattern, const char *substitute, const char * pcrs_free_job(newjob); return NULL; } - + return newjob; } @@ -654,7 +654,7 @@ pcrs_job *pcrs_compile(const char *pattern, const char *substitute, const char * * the joblist to the subject. * The subject itself is left untouched, memory for the result * is malloc()ed and it is the caller's responsibility to free - * the result when it's no longer needed. + * the result when it's no longer needed. * * Note: For convenient string handling, a null byte is * appended to the result. It does not count towards the @@ -664,8 +664,8 @@ pcrs_job *pcrs_compile(const char *pattern, const char *substitute, const char * * Parameters : * 1 : joblist = the chained list of pcrs_jobs to be executed * 2 : subject = the subject string - * 3 : subject_length = the subject's length - * 4 : result = char** for returning the result + * 3 : subject_length = the subject's length + * 4 : result = char** for returning the result * 5 : result_length = size_t* for returning the result's length * * Returns : On success, the number of substitutions that were made. @@ -679,7 +679,7 @@ int pcrs_execute_list(pcrs_job *joblist, char *subject, size_t subject_length, c pcrs_job *job; char *old, *new = NULL; int hits, total_hits; - + old = subject; *result_length = subject_length; total_hits = 0; @@ -724,8 +724,8 @@ int pcrs_execute_list(pcrs_job *joblist, char *subject, size_t subject_length, c * Parameters : * 1 : job = the pcrs_job to be executed * 2 : subject = the subject (== original) string - * 3 : subject_length = the subject's length - * 4 : result = char** for returning the result + * 3 : subject_length = the subject's length + * 4 : result = char** for returning the result * 5 : result_length = size_t* for returning the result's length * * Returns : On success, the number of substitutions that were made. @@ -748,7 +748,7 @@ int pcrs_execute(pcrs_job *job, const char *subject, size_t subject_length, char offset = i = 0; - /* + /* * Sanity check & memory allocation */ if (job == NULL || job->pattern == NULL || job->substitute == NULL || NULL == subject) @@ -781,13 +781,13 @@ int pcrs_execute(pcrs_job *job, const char *subject, size_t subject_length, char matches[i].submatch_offset[k] = offsets[2 * k]; /* Note: Non-found optional submatches have length -1-(-1)==0 */ - matches[i].submatch_length[k] = (size_t)(offsets[2 * k + 1] - offsets[2 * k]); + matches[i].submatch_length[k] = (size_t)(offsets[2 * k + 1] - offsets[2 * k]); /* reserve mem for each submatch as often as it is ref'd */ newsize += matches[i].submatch_length[k] * (size_t)job->substitute->backref_count[k]; } /* plus replacement text size minus match text size */ - newsize += job->substitute->length - matches[i].submatch_length[0]; + newsize += job->substitute->length - matches[i].submatch_length[0]; /* chunk before match */ matches[i].submatch_offset[PCRS_MAX_SUBMATCHES] = 0; @@ -829,12 +829,12 @@ int pcrs_execute(pcrs_job *job, const char *subject, size_t subject_length, char if (submatches < PCRE_ERROR_NOMATCH) { free(matches); - return submatches; + return submatches; } matches_found = i; - /* + /* * Get memory for the result (must be freed by caller!) * and append terminating null byte. */ @@ -849,7 +849,7 @@ int pcrs_execute(pcrs_job *job, const char *subject, size_t subject_length, char } - /* + /* * Replace */ offset = 0; @@ -858,7 +858,7 @@ int pcrs_execute(pcrs_job *job, const char *subject, size_t subject_length, char for (i = 0; i < matches_found; i++) { /* copy the chunk preceding the match */ - memcpy(result_offset, subject + offset, (size_t)(matches[i].submatch_offset[0] - offset)); + memcpy(result_offset, subject + offset, (size_t)(matches[i].submatch_offset[0] - offset)); result_offset += matches[i].submatch_offset[0] - offset; /* For every segment of the substitute.. */ @@ -988,7 +988,7 @@ int pcrs_job_is_dynamic (char *job) * Parameters : * 1 : string = The string to search in * - * Returns : A safe delimiter if one was found, otherwise '\0'. + * Returns : A safe delimiter if one was found, otherwise '\0'. * *********************************************************************/ char pcrs_get_delimiter(const char *string) @@ -1021,11 +1021,11 @@ char pcrs_get_delimiter(const char *string) * * Parameters : * 1 : subject = the subject (== original) string - * 2 : pcrs_command = the pcrs command as string (s@foo@bar@) - * 3 : hits = int* for returning the number of modifications + * 2 : pcrs_command = the pcrs command as string (s@foo@bar@) + * 3 : hits = int* for returning the number of modifications * * Returns : NULL in case of errors, otherwise the - * result of the pcrs command. + * result of the pcrs command. * *********************************************************************/ char *pcrs_execute_single_command(const char *subject, const char *pcrs_command, int *hits) @@ -1069,7 +1069,7 @@ static const char warning[] = "... [too long, truncated]"; * 3 : error = pcrs error code * * Returns : NULL in case of hard errors, otherwise the - * compiled pcrs job. + * compiled pcrs job. * *********************************************************************/ pcrs_job *pcrs_compile_dynamic_command(char *pcrs_command, const struct pcrs_variable v[], int *error) diff --git a/project.h b/project.h index d44eed46..9c91cb12 100644 --- a/project.h +++ b/project.h @@ -1,7 +1,7 @@ #ifndef PROJECT_H_INCLUDED #define PROJECT_H_INCLUDED /** Version string. */ -#define PROJECT_H_VERSION "$Id: project.h,v 1.169 2011/07/08 13:30:08 fabiankeil Exp $" +#define PROJECT_H_VERSION "$Id: project.h,v 1.170 2011/07/17 13:34:36 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/project.h,v $ @@ -148,7 +148,7 @@ typedef int jb_err; #define JB_ERR_CGI_PARAMS 2 /**< Missing or corrupt CGI parameters */ #define JB_ERR_FILE 3 /**< Error opening, reading or writing a file */ #define JB_ERR_PARSE 4 /**< Error parsing file */ -#define JB_ERR_MODIFIED 5 /**< File has been modified outside of the +#define JB_ERR_MODIFIED 5 /**< File has been modified outside of the CGI actions editor. */ #define JB_ERR_COMPRESS 6 /**< Error on decompression */ @@ -173,7 +173,7 @@ typedef int jb_err; */ #define ijb_toupper(__X) toupper((int)(unsigned char)(__X)) #define ijb_tolower(__X) tolower((int)(unsigned char)(__X)) -#define ijb_isspace(__X) isspace((int)(unsigned char)(__X)) +#define ijb_isspace(__X) isspace((int)(unsigned char)(__X)) /** * Use for statically allocated buffers if you have no other choice. @@ -233,7 +233,7 @@ struct list_entry * your own code. */ char *str; - + /** Next entry in the linked list, or NULL if no more. */ struct list_entry *next; }; @@ -675,7 +675,7 @@ struct reusable_connection /* * Flags for use in csp->flags */ - + /** * Flag for csp->flags: Set if this client is processing data. * Cleared when the thread associated with this structure dies. @@ -1012,7 +1012,7 @@ struct file_list * Read-only once the structure has been created. */ time_t lastmodified; - + /** * The full filename. */ @@ -1208,7 +1208,7 @@ struct configuration_spec { /** What to log */ int debug; - + /** Nonzero to enable multithreading. */ int multi_threaded; @@ -1347,7 +1347,7 @@ struct configuration_spec #endif /* def FEATURE_NO_GIFS */ -/* +/* * Hardwired URLs */ diff --git a/ssplit.c b/ssplit.c index a4d9f2de..8c0ed510 100644 --- a/ssplit.c +++ b/ssplit.c @@ -1,4 +1,4 @@ -const char ssplit_rcs[] = "$Id: ssplit.c,v 1.10 2009/05/16 13:27:20 fabiankeil Exp $"; +const char ssplit_rcs[] = "$Id: ssplit.c,v 1.11 2011/05/22 10:20:05 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/ssplit.c,v $ @@ -9,10 +9,10 @@ const char ssplit_rcs[] = "$Id: ssplit.c,v 1.10 2009/05/16 13:27:20 fabiankeil E * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at @@ -63,12 +63,12 @@ const char ssplit_h_rcs[] = SSPLIT_H_VERSION; * 3 : vec[] = results vector (aka. array) [out] * 4 : vec_len = number of usable slots in the vector (aka. array size) * 5 : dont_save_empty_fields = zero if consecutive delimiters - * give a null output field(s), nonzero if they are just + * give a null output field(s), nonzero if they are just * to be considered as single delimeter * 6 : ignore_leading = nonzero to ignore leading field * separators. * - * Returns : -1 => Error: vec_len is too small to hold all the + * Returns : -1 => Error: vec_len is too small to hold all the * data, or str == NULL. * >=0 => the number of fields put in `vec'. * On error, vec and str may still have been overwritten. @@ -122,7 +122,7 @@ int ssplit(char *str, const char *delim, char *vec[], size_t vec_len, || (is_delim[(unsigned)(unsigned char)*str] == 0) ) { /* - * We want empty fields, or the first character in this + * We want empty fields, or the first character in this * field is not a delimiter or the end of string. * So save it. */ @@ -130,24 +130,24 @@ int ssplit(char *str, const char *delim, char *vec[], size_t vec_len, { return(-1); /* overflow */ } - vec[vec_count++] = (char *) str; + vec[vec_count++] = (char *) str; } while ((char_type = is_delim[(unsigned)(unsigned char)*str]) != 2) { - if (char_type == 1) + if (char_type == 1) { /* the char is a separator */ /* null terminate the substring */ - *str++ = '\0'; + *str++ = '\0'; /* Check if we want to save this field */ if ( (!dont_save_empty_fields) || (is_delim[(unsigned)(unsigned char)*str] == 0) ) { /* - * We want empty fields, or the first character in this + * We want empty fields, or the first character in this * field is not a delimiter or the end of string. * So save it. */ @@ -155,7 +155,7 @@ int ssplit(char *str, const char *delim, char *vec[], size_t vec_len, { return(-1); /* overflow */ } - vec[vec_count++] = (char *) str; + vec[vec_count++] = (char *) str; } } else diff --git a/ssplit.h b/ssplit.h index 268d9730..b388c646 100644 --- a/ssplit.h +++ b/ssplit.h @@ -1,6 +1,6 @@ #ifndef SSPLIT_H_INCLUDED #define SSPLIT_H_INCLUDED -#define SSPLIT_H_VERSION "$Id: ssplit.h,v 1.8 2009/05/16 13:27:20 fabiankeil Exp $" +#define SSPLIT_H_VERSION "$Id: ssplit.h,v 1.9 2011/05/22 10:20:05 fabiankeil Exp $" /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/ssplit.h,v $ @@ -11,10 +11,10 @@ * Privoxy team. http://www.privoxy.org/ * * Based on the Internet Junkbuster originally written - * by and Copyright (C) 1997 Anonymous Coders and + * by and Copyright (C) 1997 Anonymous Coders and * Junkbusters Corporation. http://www.junkbusters.com * - * This program is free software; you can redistribute it + * This program 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 2 of the License, or (at diff --git a/templates/blocked b/templates/blocked index 3ebc22ee..3da06f28 100644 --- a/templates/blocked +++ b/templates/blocked @@ -13,7 +13,7 @@ # # Template files are written in plain HTML, with a few # additions: -# +# # - Lines that start with a '#' character like this one # are ignored # @@ -28,7 +28,7 @@ # strings @if-start and if--end@. The strings # should be placed in HTML comments (), so the # html structure won't be messed when the magic happens. -# +# # USABLE SYMBOLS IN THIS TEMPLATE: # -------------------------------- # @@ -82,7 +82,7 @@ # force-support: # Privoxy has been compiled with support for forced loading # of blocked content. In that case, the symbol "force-prefix" is -# avaiable, which translates to the FORCE_PREFIX +# avaiable, which translates to the FORCE_PREFIX # @@ -107,20 +107,20 @@ minWidth = 650; minHeight = 330; - /* + /* * Navigator, Mozilla, Opera */ - if (window.innerWidth - && (window.innerWidth >= minWidth) + if (window.innerWidth + && (window.innerWidth >= minWidth) && (window.innerHeight >= minHeight)) { return false; } - - /* + + /* * MSIE */ - else if (document.body && document.body.clientWidth + else if (document.body && document.body.clientWidth && (document.body.clientWidth >= minWidth) && (document.body.clientHeight >= minHeight)) { diff --git a/templates/cgi-error-404 b/templates/cgi-error-404 index c12b5648..4e010c0e 100644 --- a/templates/cgi-error-404 +++ b/templates/cgi-error-404 @@ -8,7 +8,7 @@ # # Template files are written win plain HTML, with a few # additions: -# +# # - Lines that start with a '#' character like this one # are ignored # @@ -23,7 +23,7 @@ # strings @if-start and if--end@. The strings # should be placed in HTML comments (), so the # html structure won't be messed when the magic happens. -# +# # USABLE SYMBOLS IN THIS TEMPLATE: # -------------------------------- # @@ -84,7 +84,7 @@ 404 - + #include mod-title @@ -142,7 +142,7 @@ - + diff --git a/templates/cgi-error-bad-param b/templates/cgi-error-bad-param index a1e3f055..f8e95a98 100644 --- a/templates/cgi-error-bad-param +++ b/templates/cgi-error-bad-param @@ -8,7 +8,7 @@ # # Template files are written win plain HTML, with a few # additions: -# +# # - Lines that start with a '#' character like this one # are ignored # @@ -23,7 +23,7 @@ # strings @if-start and if--end@. The strings # should be placed in HTML comments (), so the # html structure won't be messed when the magic happens. -# +# # USABLE SYMBOLS IN THIS TEMPLATE: # -------------------------------- # @@ -149,7 +149,7 @@ - + diff --git a/templates/cgi-error-disabled b/templates/cgi-error-disabled index 9faffc6b..b95de2ca 100644 --- a/templates/cgi-error-disabled +++ b/templates/cgi-error-disabled @@ -8,7 +8,7 @@ # # Template files are written win plain HTML, with a few # additions: -# +# # - Lines that start with a '#' character like this one # are ignored # @@ -23,7 +23,7 @@ # strings @if-start and if--end@. The strings # should be placed in HTML comments (), so the # html structure won't be messed when the magic happens. -# +# # USABLE SYMBOLS IN THIS TEMPLATE: # -------------------------------- # @@ -162,7 +162,7 @@ - + diff --git a/templates/cgi-error-file b/templates/cgi-error-file index 09bf2cb2..0d801fe1 100644 --- a/templates/cgi-error-file +++ b/templates/cgi-error-file @@ -8,7 +8,7 @@ # # Template files are written win plain HTML, with a few # additions: -# +# # - Lines that start with a '#' character like this one # are ignored # @@ -23,7 +23,7 @@ # strings @if-start and if--end@. The strings # should be placed in HTML comments (), so the # html structure won't be messed when the magic happens. -# +# # USABLE SYMBOLS IN THIS TEMPLATE: # -------------------------------- # diff --git a/templates/cgi-error-file-read-only b/templates/cgi-error-file-read-only index bfce2779..8137200e 100644 --- a/templates/cgi-error-file-read-only +++ b/templates/cgi-error-file-read-only @@ -8,7 +8,7 @@ # # Template files are written win plain HTML, with a few # additions: -# +# # - Lines that start with a '#' character like this one # are ignored # @@ -23,7 +23,7 @@ # strings @if-start and if--end@. The strings # should be placed in HTML comments (), so the # html structure won't be messed when the magic happens. -# +# # USABLE SYMBOLS IN THIS TEMPLATE: # -------------------------------- # diff --git a/templates/cgi-error-modified b/templates/cgi-error-modified index 3b04b4b3..4c386264 100644 --- a/templates/cgi-error-modified +++ b/templates/cgi-error-modified @@ -8,7 +8,7 @@ # # Template files are written win plain HTML, with a few # additions: -# +# # - Lines that start with a '#' character like this one # are ignored # @@ -23,7 +23,7 @@ # strings @if-start and if--end@. The strings # should be placed in HTML comments (), so the # html structure won't be messed when the magic happens. -# +# # USABLE SYMBOLS IN THIS TEMPLATE: # -------------------------------- # @@ -109,7 +109,7 @@

Possible causes:

  • If you got here using your browser's "back" button, then - that is deliberately disabled for this page. Please + that is deliberately disabled for this page. Please navigate around the configuration editor using the links provided.
  • Perhaps you've got more than one browser window open, and @@ -117,7 +117,7 @@ only have one editor window open at a time. Your other edit window should continue to function.
  • You may have modified the file some other way - perhaps by - editing it with a text editor. Simply go back in to the + editing it with a text editor. Simply go back in to the configuration interface using the links below.

You can go back into the edit interface using the menu below, @@ -150,7 +150,7 @@ - + diff --git a/templates/cgi-error-parse b/templates/cgi-error-parse index 695131c4..7a07bf23 100644 --- a/templates/cgi-error-parse +++ b/templates/cgi-error-parse @@ -8,7 +8,7 @@ # # Template files are written win plain HTML, with a few # additions: -# +# # - Lines that start with a '#' character like this one # are ignored # @@ -23,7 +23,7 @@ # strings @if-start and if--end@. The strings # should be placed in HTML comments (), so the # html structure won't be messed when the magic happens. -# +# # USABLE SYMBOLS IN THIS TEMPLATE: # -------------------------------- # @@ -110,7 +110,7 @@ editor. If you managed to take a valid file and break it this badly using the web-based editor, please file a bug report!

When you've fixed the problem, you can go back into the edit - interface using the menu below, or by clicking here.

@@ -169,7 +169,7 @@ - + diff --git a/templates/cgi-style.css b/templates/cgi-style.css index b9a288df..3a26b9f6 100644 --- a/templates/cgi-style.css +++ b/templates/cgi-style.css @@ -10,7 +10,7 @@ # Original Author: Copyright (C) 2001 Jonathan Foster # http://www.jon-foster.co.uk/ # -# This program is free software; you can redistribute it +# This program 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 2 of the License, or (at @@ -33,7 +33,7 @@ /* * CSS for Privoxy CGI and script output * - * $Id: cgi-style.css,v 1.12 2007/12/11 21:20:53 fabiankeil Exp $ + * $Id: cgi-style.css,v 1.13 2009/05/16 13:27:21 fabiankeil Exp $ */ /* @@ -146,6 +146,6 @@ em.warning, strong.warning { color: #ff0000 } /* * Let the URL and pattern input fields scale with the browser * width and try to prevent vertical scroll bars if the width - * is less than 80 characters. + * is less than 80 characters. */ input.url, input.pattern { width: 95%; } diff --git a/templates/connect-failed b/templates/connect-failed index 3607552a..96b312e3 100644 --- a/templates/connect-failed +++ b/templates/connect-failed @@ -8,7 +8,7 @@ # # Template files are written win plain HTML, with a few # additions: -# +# # - Lines that start with a '#' character like this one # are ignored # @@ -23,7 +23,7 @@ # strings @if-start and if--end@. The strings # should be placed in HTML comments (), so the # html structure won't be messed when the magic happens. -# +# # USABLE SYMBOLS IN THIS TEMPLATE: # -------------------------------- # @@ -94,7 +94,7 @@ 503 - + #include mod-title diff --git a/templates/default b/templates/default index 065aedc2..a4bb7d04 100644 --- a/templates/default +++ b/templates/default @@ -8,7 +8,7 @@ # # Template files are written win plain HTML, with a few # additions: -# +# # - Lines that start with a '#' character like this one # are ignored # @@ -23,7 +23,7 @@ # strings @if-start and if--end@. The strings # should be placed in HTML comments (), so the # html structure won't be messed when the magic happens. -# +# # USABLE SYMBOLS IN THIS TEMPLATE: # -------------------------------- # @@ -124,7 +124,7 @@ - + diff --git a/templates/edit-actions-add-url-form b/templates/edit-actions-add-url-form index f559dc70..d1d92564 100644 --- a/templates/edit-actions-add-url-form +++ b/templates/edit-actions-add-url-form @@ -11,7 +11,7 @@ # Original Author: Copyright (C) 2001 Jonathan Foster # http://www.jon-foster.co.uk/ # -# This program is free software; you can redistribute it +# This program 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 2 of the License, or (at diff --git a/templates/edit-actions-for-url b/templates/edit-actions-for-url index 3addecb9..3999b85c 100644 --- a/templates/edit-actions-for-url +++ b/templates/edit-actions-for-url @@ -4,7 +4,7 @@ # # Purpose : Template used to edit the actions associated with a # particular section in an actions file. -# +# # # Copyright : Written by and Copyright (C) 2001-2008 the SourceForge # Privoxy team. http://www.privoxy.org/ @@ -351,7 +351,7 @@ function show_limit_connect_opts(tf) id="change_x_forwarded_for_mode_block" @change-x-forwarded-for-param-block@>