1 Privoxy Developer Manual
6 $Id: developer-manual.sgml,v 1.25 2002/04/06 05:07:28 hal9 Exp $
9 The developer manual gives the users information on how to help the developer
10 team. It provides guidance on coding, testing, documentation and other issues.
12 Privoxy is a web proxy with advanced filtering capabilities for protecting
13 privacy, filtering web page content, managing cookies, controlling access, and
14 removing ads, banners, pop-ups and other obnoxious Internet junk. Privoxy has a
15 very flexible configuration and can be customized to suit individual needs and
16 tastes. Privoxy has application for both stand-alone systems and multi-user
19 Privoxy is based on the code of the Internet Junkbuster (tm). Junkbuster was
20 originally written by JunkBusters Corporation, and was released as free
21 open-source software under the GNU GPL. Stefan Waldherr made many improvements,
22 and started the SourceForge project to continue development.
24 Privoxy continues the Junkbuster tradition, but adds many refinements,
25 enhancements and new features.
27 You can find the latest version of the this manual at http://www.privoxy.org/
28 developer-manual/. Please see the Contact section on how to contact the
31 -------------------------------------------------------------------------------
35 3. Quickstart to Privoxy Development
36 4. Documentation Guidelines
37 4.1. Quickstart to Docbook and SGML
41 4.2. Privoxy Documentation Style
42 4.3. Privoxy Custom Entities
48 5.2.1. Comment, Comment, Comment
49 5.2.2. Use blocks for comments
50 5.2.3. Keep Comments on their own line
51 5.2.4. Comment each logical step
52 5.2.5. Comment All Functions Thoroughly
53 5.2.6. Comment at the end of braces if the content is more than one
57 5.3. Naming Conventions
60 5.3.3. Header file prototypes
61 5.3.4. Enumerations, and #defines
66 5.4.1. Put braces on a line by themselves.
67 5.4.2. ALL control statements should have a block
68 5.4.3. Do not belabor/blow-up boolean expressions
69 5.4.4. Use white space freely because it is free
70 5.4.5. Don't use white space around structure operators
71 5.4.6. Make the last brace of a function stand out
72 5.4.7. Use 3 character indentions
76 5.5.1. Initialize all variables
80 5.6.1. Name functions that return a boolean as a question.
81 5.6.2. Always specify a return type for a function.
82 5.6.3. Minimize function calls when iterating by using variables
83 5.6.4. Pass and Return by Const Reference
84 5.6.5. Pass and Return by Value
85 5.6.6. Names of include files
86 5.6.7. Provide multiple inclusion protection
87 5.6.8. Use `extern "C"` when appropriate
88 5.6.9. Where Possible, Use Forward Struct Declaration Instead of
92 5.7. General Coding Practices
93 5.7.1. Turn on warnings
94 5.7.2. Provide a default case for all switch statements
95 5.7.3. Try to avoid falling through cases in a switch statement.
96 5.7.4. Use 'long' or 'short' Instead of 'int'
97 5.7.5. Don't mix size_t and other types
98 5.7.6. Declare each variable and struct on its own line.
99 5.7.7. Use malloc/zalloc sparingly
100 5.7.8. The Programmer Who Uses 'malloc' is Responsible for Ensuring
102 5.7.9. Add loaders to the `file_list' structure and in order
103 5.7.10. "Uncertain" new code and/or changes to exitinst code, use FIXME
106 5.8. Addendum: Template for files and function comment blocks:
109 6. Version Control Guidelines
110 7. Testing Guidelines
111 7.1. Testplan for releases
115 8. Releasing a new version
116 8.1. Before the Release
117 8.2. Update the webserver
131 9. Contacting the developers, Bug Reporting and Feature Requests
132 10. Copyright and History
140 -------------------------------------------------------------------------------
143 Privoxy, as an heir to Junkbuster, is an Open Source project and licensed under
144 the GPL. As such, Privoxy development is potentially open to anyone who has the
145 time, knowledge, and desire to contribute in any capacity. Our goals are simply
146 to continue the mission, to improve Privoxy, and to make it available to as
147 wide an audience as possible.
149 One does not have to be a programmer to contribute. Packaging, testing, and
150 porting, are all important jobs as well.
151 -------------------------------------------------------------------------------
153 3. Quickstart to Privoxy Development
155 You'll need an account on Sourceforge to support our development. Mail your ID
156 to the list and wait until a project manager has added you.
158 For the time being (read, this section is under construction), please note the
159 following guidelines for changing stuff in the code. If it is
161 1. A bugfix / clean-up / cosmetic thing: shoot
163 2. A new feature that can be turned off: shoot
165 3. A clear improvement w/o side effects on other parts of the code: shoot
167 4. A matter of taste: ask the list
169 5. A major redesign of some part of the code: ask the list
172 -------------------------------------------------------------------------------
173 4. Documentation Guidelines
175 All formal documents are maintained in docbook SGML and located in the doc/
176 source directory. You will need docbook and the docbook stylesheets (or
177 comparable alternatives), and either jade or openjade (recommended) installed
178 in order to build docs from source. Currently there is user-manual, FAQ, and,
179 of course this, the developer-manual in this format. The README, is also now
180 maintained as SGML. The README in the top-level source directory is a generated
181 file. DO NOT edit this directly. Edit the SGML source!
183 Other, less formal documents (e.g. AUTHORS, LICENSE) are maintained as plain
184 text files in the toplevel source directory. At least for the time being.
186 Packagers are encouraged to include this documentation. For those without the
187 ability to build the docs locally, text versions of each are kept in CVS. Or
188 HTML versions can be downloaded from the www.privoxy.org website, which should
189 be fairly current. (This is only a temporary solution.)
191 Formal documents are built with the Makefile targets of make dok, or
192 alternately make redhat-dok. If you have problems, try both. The build process
193 uses the document SGML sources in doc/source to update all text files in doc/
194 text and to update all HTML documents in doc/webserver.
196 Documentation writers should please make sure documents build successfully
197 before committing to CVS.
199 How do you update the webserver (i.e. the pages on privoxy.org)?
201 1. First, build the docs by running make dok (or alternately make redhat-dok).
203 2. Run make webserver which copies all files from doc/webserver to the
204 sourceforge webserver via scp.
207 -------------------------------------------------------------------------------
208 4.1. Quickstart to Docbook and SGML
210 If you are not familiar with SGML, it is a markup language similar to HTML. In
211 fact, HTML is an SGML application. Both use "tags" to format text and other
212 content. SGML tags are much more varied, and flexible, but do much of the same
213 kinds of things. The tags, or "elements", are definable in SGML. There is no
214 set "standards". Since we are using Docbook, our tags are those that are
215 defined by Docbook. Much of how the finish document is rendered is determined
216 by the "stylesheets". The stylesheets determine how each tag gets translated to
217 HTML, or other formats.
219 Tags in SGML need to be always "closed". If not, you will likely generate
220 errors. Example: <title>My Title</title>. They are also case-insensitive, but
221 we strongly suggest using all lower case. This keeps compatibility with
224 Our documents use "sections" for the most part. Sections will be processed into
225 HTML headers (e.g. h1 for sect1). The Docbook stylesheets will use these to
226 also generate the Table of Contents for each doc. Our TOC's are set to a depth
227 of three. Meaning sect1, sect2, and sect3 will have TOC entries, but sect4 will
228 not. Each section requires a <title> element, and at least one <para>. There is
229 a limit of five section levels in Docbook, but generally three should be
230 sufficient for our purposes.
232 Some common elements that you likely will use:
234 <para></para>, paragraph delimiter. Most text needs to be within paragraph
236 <emphasis></emphasis>, stylesheets make this italics.
237 <filename></filename>, files and directories.
238 <command></command>, command examples.
239 <literallayout></literllayout>, like <pre>, more or less.
240 <itemizedlist></itemizdelist>, list with bullets.
241 <listitem></listitem>, member of the above.
242 <screen></screen>, screen output, implies <literallayout>.
243 <ulink url="example.com"></ulink>, like HTML <a> tag.
244 <quote></quote>, for, doh, quoting text.
246 Look at any of the existing docs for examples of all these and more.
247 -------------------------------------------------------------------------------
249 4.2. Privoxy Documentation Style
251 It will be easier if everyone follows a similar writing style. This just makes
252 it easier to read what someone else has written if it is all done in a similar
257 * All tags should be lower case.
259 * Tags delimiting a block of text should be on their own line. Like:
265 Tags marking individual words, or few words, should be in-line:
267 Just to <emphasis>emphasize</emphasis>, some text goes here.
270 * Tags should be nested and step indented like:
276 Some text goes here in our list example.
282 This makes it easier to find the text amongst the tags ;-)
283 * Use white space to separate logical divisions within a document, like
284 between sections. Running everything together consistently makes it harder
287 * Do not hesitate to make comments. Comments can either use the <comment>
288 element, or the <!-- --> style comment familiar from HTML.
290 * We have an international audience. Refrain from slang, or English
291 idiosyncrasies (too many to list :).
293 * Try to keep overall line lengths in source files to 80 characters or less
294 for obvious reasons. This is not always possible, with lenghty URLs for
297 * Our documents are available in differing formats. Right now, they are just
298 plain text, and HTML, but PDF, and others is always a future possibility.
299 Be careful with URLs (<ulink>), and avoid this mistake:
301 My favorite site is <ulink url="http://example.com">here</ulink>.
303 This will render as "My favorite site is here", which is not real helpful
304 in a text doc. Better like this:
306 My favorite site is <ulink url="http://example.com">example.com</ulink>.
308 * All documents should be spell checked occasionally. aspell can check SGML
309 with the -H option. (ispell I think too.)
312 -------------------------------------------------------------------------------
313 4.3. Privoxy Custom Entities
315 Privoxy documentation is using a number of customized "entities" to facilitate
316 documentation maintenance.
318 We are using a set of "boilerplate" files with generic text, that is used by
319 multiple docs. This way we can write something once, and use it repeatedly
320 without having to re-write the same content over and over again. If editing
321 such a file, keep in mind that it should be generic. That is the purpose; so it
322 can be used in varying contexts without additional modifications.
324 We are also using what Docbook calls "internal entities". These are like
325 variables in programming. Well, sort of. For instance, we have the p-version
326 entity that contains the current Privoxy version string. You are strongly
327 encouraged to use these where possible. Some of these obviously require
328 re-setting with each release. A sampling of custom entities are listed below.
329 See any of the main docs for examples.
331 * Re-cyclable "boilerplate" text entities are defined like:
333 <!entity supported SYSTEM "supported.sgml">
335 In this example, the contents of the file, supported.sgml is available for
336 inclusion anywhere in the doc. To make this happen, just reference the now
337 defined entity: &supported; (starts with an ampersand and ends with a
338 semi-colon), and the contents will be dumped into the finished doc at that
341 * Commonly used "internal entities":
343 p-version: the Privoxy version string, e.g. "2.9.13".
344 p-status: the project status, either "ALPHA", "BETA", or "STABLE".
345 p-not-stable: use to conditionally include text in "not stable" releases
347 p-stable: just the opposite.
348 p-text: this doc is only generated as text.
352 There are others in various places that are defined for a specific purpose.
354 -------------------------------------------------------------------------------
360 This set of standards is designed to make our lives easier. It is developed
361 with the simple goal of helping us keep the "new and improved Privoxy"
362 consistent and reliable. Thus making maintenance easier and increasing chances
363 of success of the project.
365 And that of course comes back to us as individuals. If we can increase our
366 development and product efficiencies then we can solve more of the request for
367 changes/improvements and in general feel good about ourselves. ;->
368 -------------------------------------------------------------------------------
372 5.2.1. Comment, Comment, Comment
376 Comment as much as possible without commenting the obvious. For example do not
377 comment "aVariable is equal to bVariable". Instead explain why aVariable should
378 be equal to the bVariable. Just because a person can read code does not mean
379 they will understand why or what is being done. A reader may spend a lot more
380 time figuring out what is going on when a simple comment or explanation would
381 have prevented the extra research. Please help your brother IJB'ers out!
383 The comments will also help justify the intent of the code. If the comment
384 describes something different than what the code is doing then maybe a
385 programming error is occurring.
388 /* if page size greater than 1k ... */
389 if ( PageLength() > 1024 )
391 ... "block" the page up ...
394 /* if page size is small, send it in blocks */
395 if ( PageLength() > 1024 )
397 ... "block" the page up ...
400 This demonstrates 2 cases of "what not to do". The first is a
401 "syntax comment". The second is a comment that does not fit what
402 is actually being done.
403 -------------------------------------------------------------------------------
405 5.2.2. Use blocks for comments
409 Comments can help or they can clutter. They help when they are differentiated
410 from the code they describe. One line comments do not offer effective
411 separation between the comment and the code. Block identifiers do, by
412 surrounding the code with a clear, definable pattern.
415 /*********************************************************************
416 * This will stand out clearly in your code!
417 *********************************************************************/
418 if ( thisVariable == thatVariable )
420 DoSomethingVeryImportant();
424 /* unfortunately, this may not */
425 if ( thisVariable == thatVariable )
427 DoSomethingVeryImportant();
431 if ( thisVariable == thatVariable ) /* this may not either */
433 DoSomethingVeryImportant();
438 If you are trying to add a small logic comment and do not wish to "disrubt" the
439 flow of the code, feel free to use a 1 line comment which is NOT on the same
441 -------------------------------------------------------------------------------
443 5.2.3. Keep Comments on their own line
447 It goes back to the question of readability. If the comment is on the same line
448 as the code it will be harder to read than the comment that is on its own line.
450 There are three exceptions to this rule, which should be violated freely and
451 often: during the definition of variables, at the end of closing braces, when
452 used to comment parameters.
455 /*********************************************************************
456 * This will stand out clearly in your code,
457 * But the second example won't.
458 *********************************************************************/
459 if ( thisVariable == thatVariable )
461 DoSomethingVeryImportant();
464 if ( thisVariable == thatVariable ) /*can you see me?*/
466 DoSomethingVeryImportant(); /*not easily*/
470 /*********************************************************************
471 * But, the encouraged exceptions:
472 *********************************************************************/
473 int urls_read = 0; /* # of urls read + rejected */
474 int urls_rejected = 0; /* # of urls rejected */
478 DoSomethingVeryImportant();
482 short DoSomethingVeryImportant(
483 short firstparam, /* represents something */
484 short nextparam /* represents something else */ )
488 } /* -END- DoSomethingVeryImportant */
489 -------------------------------------------------------------------------------
491 5.2.4. Comment each logical step
495 Logical steps should be commented to help others follow the intent of the
496 written code and comments will make the code more readable.
498 If you have 25 lines of code without a comment, you should probably go back
499 into it to see where you forgot to put one.
501 Most "for", "while", "do", etc... loops _probably_ need a comment. After all,
502 these are usually major logic containers.
503 -------------------------------------------------------------------------------
505 5.2.5. Comment All Functions Thoroughly
509 A reader of the code should be able to look at the comments just prior to the
510 beginning of a function and discern the reason for its existence and the
511 consequences of using it. The reader should not have to read through the code
512 to determine if a given function is safe for a desired use. The proper
513 information thoroughly presented at the introduction of a function not only
514 saves time for subsequent maintenance or debugging, it more importantly aids in
515 code reuse by allowing a user to determine the safety and applicability of any
516 function for the problem at hand. As a result of such benefits, all functions
517 should contain the information presented in the addendum section of this
519 -------------------------------------------------------------------------------
521 5.2.6. Comment at the end of braces if the content is more than one screen
526 Each closing brace should be followed on the same line by a comment that
527 describes the origination of the brace if the original brace is off of the
528 screen, or otherwise far away from the closing brace. This will simplify the
529 debugging, maintenance, and readability of the code.
531 As a suggestion , use the following flags to make the comment and its brace
534 use following a closing brace: } /* -END- if() or while () or etc... */
539 DoSomethingVeryImportant();
540 ...some long list of commands...
541 } /* -END- if x is 1 */
547 DoSomethingVeryImportant();
548 ...some long list of commands...
549 } /* -END- if ( 1 == X ) */
550 -------------------------------------------------------------------------------
552 5.3. Naming Conventions
554 5.3.1. Variable Names
558 Use all lowercase, and seperate words via an underscore ('_'). Do not start an
559 identifier with an underscore. (ANSI C reserves these for use by the compiler
560 and system headers.) Do not use identifiers which are reserved in ANSI C++.
561 (E.g. template, class, true, false, ...). This is in case we ever decide to
565 int ms_iis5_hack = 0;
569 int msiis5hack = 0; int msIis5Hack = 0;
570 -------------------------------------------------------------------------------
572 5.3.2. Function Names
576 Use all lowercase, and seperate words via an underscore ('_'). Do not start an
577 identifier with an underscore. (ANSI C reserves these for use by the compiler
578 and system headers.) Do not use identifiers which are reserved in ANSI C++.
579 (E.g. template, class, true, false, ...). This is in case we ever decide to
583 int load_some_file( struct client_state *csp )
587 int loadsomefile( struct client_state *csp )
588 int loadSomeFile( struct client_state *csp )
589 -------------------------------------------------------------------------------
591 5.3.3. Header file prototypes
595 Use a descriptive parameter name in the function prototype in header files. Use
596 the same parameter name in the header file that you use in the c file.
599 (.h) extern int load_aclfile( struct client_state *csp );
600 (.c) int load_aclfile( struct client_state *csp )
603 (.h) extern int load_aclfile( struct client_state * ); or
604 (.h) extern int load_aclfile();
605 (.c) int load_aclfile( struct client_state *csp )
606 -------------------------------------------------------------------------------
608 5.3.4. Enumerations, and #defines
612 Use all capital letters, with underscores between words. Do not start an
613 identifier with an underscore. (ANSI C reserves these for use by the compiler
617 (enumeration) : enum Boolean { FALSE, TRUE };
618 (#define) : #define DEFAULT_SIZE 100;
620 Note: We have a standard naming scheme for #defines that toggle a feature in
621 the preprocessor: FEATURE_>, where > is a short (preferably 1 or 2 word)
625 #define FEATURE_FORCE 1
628 #define FORCE_PREFIX blah
629 #endif /* def FEATURE_FORCE */
630 -------------------------------------------------------------------------------
636 Spell common words out entirely (do not remove vowels).
638 Use only widely-known domain acronyms and abbreviations. Capitalize all letters
641 Use underscore (_) to separate adjacent acronyms and abbreviations. Never
642 terminate a name with an underscore.
645 #define USE_IMAGE_LIST 1
649 #define USE_IMG_LST 1 or
650 #define _USE_IMAGE_LIST 1 or
651 #define USE_IMAGE_LIST_ 1 or
652 #define use_image_list 1 or
653 #define UseImageList 1
654 -------------------------------------------------------------------------------
658 5.4.1. Put braces on a line by themselves.
662 The brace needs to be on a line all by itself, not at the end of the statement.
663 Curly braces should line up with the construct that they're associated with.
664 This practice makes it easier to identify the opening and closing braces for a
675 if ( this == that ) { ... }
679 if ( this == that ) { ... }
681 Note: In the special case that the if-statement is inside a loop, and it is
682 trivial, i.e. it tests for a condidtion that is obvious from the purpose of the
683 block, one-liners as above may optically preserve the loop structure and make
686 Status: developer-discrection.
689 while ( more lines are read )
691 /* Please document what is/is not a comment line here */
692 if ( it's a comment ) continue;
694 do_something( line );
696 -------------------------------------------------------------------------------
698 5.4.2. ALL control statements should have a block
702 Using braces to make a block will make your code more readable and less prone
703 to error. All control statements should have a block defined.
714 if ( this == that ) DoSomething(); DoSomethingElse();
718 if ( this == that ) DoSomething();
720 Note: The first example in "Instead of" will execute in a manner other than
721 that which the developer desired (per indentation). Using code braces would
722 have prevented this "feature". The "explanation" and "exception" from the point
724 -------------------------------------------------------------------------------
726 5.4.3. Do not belabor/blow-up boolean expressions
729 structure->flag = ( condition );
733 if ( condition ) { structure->flag = 1; } else { structure->flag = 0; }
735 Note: The former is readable and consice. The later is wordy and inefficient.
736 Please assume that any developer new to the project has at least a "good"
737 knowledge of C/C++. (Hope I do not offend by that last comment ... 8-)
738 -------------------------------------------------------------------------------
740 5.4.4. Use white space freely because it is free
744 Make it readable. The notable exception to using white space freely is listed
745 in the next guideline.
750 int anotherValue = 0;
751 int thisVariable = 0;
753 if ( thisVariable == thatVariable )
755 firstValue = oldValue + ( ( someValue - anotherValue ) - whatever )
756 -------------------------------------------------------------------------------
758 5.4.5. Don't use white space around structure operators
762 - structure pointer operator ( "->" ) - member operator ( "." ) - functions and
765 It is a general coding practice to put pointers, references, and function
766 parentheses next to names. With spaces, the connection between the object and
767 variable/function name is not as clear.
774 Instead of: aStruct -> aMember; aStruct . aMember; FunctionName ();
775 -------------------------------------------------------------------------------
777 5.4.6. Make the last brace of a function stand out
785 } /* -END- function1 */
790 } /* -END- function2 */
794 int function1( ... ) { ...code... return( retCode ); } int function2( ... ) { }
796 Note: Use 1 blank line before the closing brace and 2 lines afterwards. This
797 makes the end of function standout to the most casual viewer. Although function
798 comments help seperate functions, this is still a good coding practice. In
799 fact, I follow these rules when using blocks in "for", "while", "do" loops, and
800 long if {} statements too. After all whitespace is free!
802 Status: developer-discrection on the number of blank lines. Enforced is the end
803 of function comments.
804 -------------------------------------------------------------------------------
806 5.4.7. Use 3 character indentions
810 If some use 8 character TABs and some use 3 character TABs, the code can look *
811 very* ragged. So use 3 character indentions only. If you like to use TABs, pass
812 your code through a filter such as "expand -t3" before checking in your code.
815 static const char * const url_code_map[256] =
825 return( ALWAYS_TRUE );
829 return( HOW_DID_YOU_GET_HERE );
832 return( NEVER_GETS_HERE );
835 -------------------------------------------------------------------------------
839 5.5.1. Initialize all variables
843 Do not assume that the variables declared will not be used until after they
844 have been assigned a value somewhere else in the code. Remove the chance of
845 accidentally using an unassigned variable.
852 Note: It is much easier to debug a SIGSEGV if the message says you are trying
853 to access memory address 00000000 and not 129FA012; or arrayPtr[20] causes a
854 SIGSEV vs. arrayPtr[0].
856 Status: developer-discrection if and only if the variable is assigned a value
857 "shortly after" declaration.
858 -------------------------------------------------------------------------------
862 5.6.1. Name functions that return a boolean as a question.
866 Value should be phrased as a question that would logically be answered as a
867 true or false statement
873 -------------------------------------------------------------------------------
875 5.6.2. Always specify a return type for a function.
879 The default return for a function is an int. To avoid ambiguity, create a
880 return for a function when the return has a purpose, and create a void return
881 type if the function does not need to return anything.
882 -------------------------------------------------------------------------------
884 5.6.3. Minimize function calls when iterating by using variables
888 It is easy to write the following code, and a clear argument can be made that
889 the code is easy to understand:
892 for ( size_t cnt = 0; cnt < blockListLength(); cnt ++ )
897 Note: Unfortunately, this makes a function call for each and every iteration.
898 This increases the overhead in the program, because the compiler has to look up
899 the function each time, call it, and return a value. Depending on what occurs
900 in the blockListLength() call, it might even be creating and destroying
901 structures with each iteration, even though in each case it is comparing "cnt"
902 to the same value, over and over. Remember too - even a call to blockListLength
903 () is a function call, with the same overhead.
905 Instead of using a function call during the iterations, assign the value to a
906 variable, and evaluate using the variable.
909 size_t len = blockListLength();
911 for ( size_t cnt = 0; cnt < len; cnt ++ )
916 Exceptions: if the value of blockListLength() *may* change or could *
917 potentially* change, then you must code the function call in the for/while
919 -------------------------------------------------------------------------------
921 5.6.4. Pass and Return by Const Reference
925 This allows a developer to define a const pointer and call your function. If
926 your function does not have the const keyword, we may not be able to use your
927 function. Consider strcmp, if it were defined as: extern int strcmp( char *s1,
930 I could then not use it to compare argv's in main: int main( int argc, const
931 char *argv[] ) { strcmp( argv[0], "privoxy" ); }
933 Both these pointers are *const*! If the c runtime library maintainers do it, we
935 -------------------------------------------------------------------------------
937 5.6.5. Pass and Return by Value
941 Most structures cannot fit onto a normal stack entry (i.e. they are not 4 bytes
942 or less). Aka, a function declaration like: int load_aclfile( struct
945 would not work. So, to be consistent, we should declare all prototypes with
946 "pass by value": int load_aclfile( struct client_state *csp )
947 -------------------------------------------------------------------------------
949 5.6.6. Names of include files
953 Your include statements should contain the file name without a path. The path
954 should be listed in the Makefile, using -I as processor directive to search the
955 indicated paths. An exception to this would be for some proprietary software
956 that utilizes a partial path to distinguish their header files from system or
960 #include <iostream.h> /* This is not a local include */
961 #include "config.h" /* This IS a local include */
965 /* This is not a local include, but requires a path element. */
966 #include <sys/fileName.h>
968 Note: Please! do not add "-I." to the Makefile without a _very_ good reason.
969 This duplicates the #include "file.h" behaviour.
970 -------------------------------------------------------------------------------
972 5.6.7. Provide multiple inclusion protection
976 Prevents compiler and linker errors resulting from redefinition of items.
978 Wrap each header file with the following syntax to prevent multiple inclusions
979 of the file. Of course, replace PROJECT_H with your file name, with "." Changed
980 to "_", and make it uppercase.
983 #ifndef PROJECT_H_INCLUDED
984 #define PROJECT_H_INCLUDED
986 #endif /* ndef PROJECT_H_INCLUDED */
987 -------------------------------------------------------------------------------
989 5.6.8. Use `extern "C"` when appropriate
993 If our headers are included from C++, they must declare our functions as
994 `extern "C"`. This has no cost in C, but increases the potential re-usability
1001 #endif /* def __cplusplus */
1003 ... function definitions here ...
1007 #endif /* def __cplusplus */
1008 -------------------------------------------------------------------------------
1010 5.6.9. Where Possible, Use Forward Struct Declaration Instead of Includes
1014 Useful in headers that include pointers to other struct's. Modifications to
1015 excess header files may cause needless compiles.
1018 /*********************************************************************
1019 * We're avoiding an include statement here!
1020 *********************************************************************/
1022 extern file_list *xyz;
1024 Note: If you declare "file_list xyz;" (without the pointer), then including the
1025 proper header file is necessary. If you only want to prototype a pointer,
1026 however, the header file is unneccessary.
1028 Status: Use with discrection.
1029 -------------------------------------------------------------------------------
1031 5.7. General Coding Practices
1033 5.7.1. Turn on warnings
1037 Compiler warnings are meant to help you find bugs. You should turn on as many
1038 as possible. With GCC, the switch is "-Wall". Try and fix as many warnings as
1040 -------------------------------------------------------------------------------
1042 5.7.2. Provide a default case for all switch statements
1046 What you think is guaranteed is never really guaranteed. The value that you
1047 don't think you need to check is the one that someday will be passed. So, to
1048 protect yourself from the unknown, always have a default step in a switch
1052 switch( hash_string( cmd ) )
1054 case hash_actions_file :
1064 ... anomly code goes here ...
1065 continue; / break; / exit( 1 ); / etc ...
1067 } /* end switch( hash_string( cmd ) ) */
1069 Note: If you already have a default condition, you are obviously exempt from
1070 this point. Of note, most of the WIN32 code calls `DefWindowProc' after the
1071 switch statement. This API call *should* be included in a default statement.
1073 Another Note: This is not so much a readability issue as a robust programming
1074 issue. The "anomly code goes here" may be no more than a print to the STDERR
1075 stream (as in load_config). Or it may really be an ABEND condition.
1077 Status: Programmer discretion is advised.
1078 -------------------------------------------------------------------------------
1080 5.7.3. Try to avoid falling through cases in a switch statement.
1084 In general, you will want to have a 'break' statement within each 'case' of a
1085 switch statement. This allows for the code to be more readable and
1086 understandable, and furthermore can prevent unwanted surprises if someone else
1087 later gets creative and moves the code around.
1089 The language allows you to plan the fall through from one case statement to
1090 another simply by omitting the break statement within the case statement. This
1091 feature does have benefits, but should only be used in rare cases. In general,
1092 use a break statement for each case statement.
1094 If you choose to allow fall through, you should comment both the fact of the
1095 fall through and reason why you felt it was necessary.
1096 -------------------------------------------------------------------------------
1098 5.7.4. Use 'long' or 'short' Instead of 'int'
1102 On 32-bit platforms, int usually has the range of long. On 16-bit platforms,
1103 int has the range of short.
1105 Status: open-to-debate. In the case of most FSF projects (including X/
1106 GNU-Emacs), there are typedefs to int4, int8, int16, (or equivalence ... I
1107 forget the exact typedefs now). Should we add these to IJB now that we have a
1109 -------------------------------------------------------------------------------
1111 5.7.5. Don't mix size_t and other types
1115 The type of size_t varies across platforms. Do not make assumptions about
1116 whether it is signed or unsigned, or about how long it is. Do not compare a
1117 size_t against another variable of a different type (or even against a
1118 constant) without casting one of the values. Try to avoid using size_t if you
1120 -------------------------------------------------------------------------------
1122 5.7.6. Declare each variable and struct on its own line.
1126 It can be tempting to declare a series of variables all on one line. Don't.
1137 Explanation: - there is more room for comments on the individual variables -
1138 easier to add new variables without messing up the original ones - when
1139 searching on a variable to find its type, there is less clutter to "visually"
1142 Exceptions: when you want to declare a bunch of loop variables or other trivial
1143 variables; feel free to declare them on 1 line. You should, although, provide a
1144 good comment on their functions.
1146 Status: developer-discrection.
1147 -------------------------------------------------------------------------------
1149 5.7.7. Use malloc/zalloc sparingly
1153 Create a local stuct (on the stack) if the variable will live and die within
1154 the context of one function call.
1156 Only "malloc" a struct (on the heap) if the variable's life will extend beyond
1157 the context of one function call.
1160 If a function creates a struct and stores a pointer to it in a
1161 list, then it should definately be allocated via `malloc'.
1162 -------------------------------------------------------------------------------
1164 5.7.8. The Programmer Who Uses 'malloc' is Responsible for Ensuring 'free'
1168 If you have to "malloc" an instance, you are responsible for insuring that the
1169 instance is `free'd, even if the deallocation event falls within some other
1170 programmer's code. You are also responsible for ensuring that deletion is
1171 timely (i.e. not too soon, not too late). This is known as "low-coupling" and
1172 is a "good thing (tm)". You may need to offer a free/unload/destuctor type
1173 function to accomodate this.
1176 int load_re_filterfile( struct client_state *csp ) { ... }
1177 static void unload_re_filterfile( void *f ) { ... }
1181 The developer cannot be expected to provide `free'ing functions for C run-time
1182 library functions ... such as `strdup'.
1184 Status: developer-discrection. The "main" use of this standard is for
1185 allocating and freeing data structures (complex or nested).
1186 -------------------------------------------------------------------------------
1188 5.7.9. Add loaders to the `file_list' structure and in order
1192 I have ordered all of the "blocker" file code to be in alpha order. It is
1193 easier to add/read new blockers when you expect a certain order.
1195 Note: It may appear that the alpha order is broken in places by POPUP tests
1196 coming before PCRS tests. But since POPUPs can also be referred to as
1197 KILLPOPUPs, it is clear that it should come first.
1198 -------------------------------------------------------------------------------
1200 5.7.10. "Uncertain" new code and/or changes to exitinst code, use FIXME
1204 If you have enough confidence in new code or confidence in your changes, but
1205 are not *quite* sure of the reprocussions, add this:
1207 /* FIXME: this code has a logic error on platform XYZ, * attempthing to fix */
1208 #ifdef PLATFORM ...changed code here... #endif
1212 /* FIXME: I think the original author really meant this... */ ...changed code
1217 /* FIXME: new code that *may* break something else... */ ...new code here...
1219 Note: If you make it clear that this may or may not be a "good thing (tm)", it
1220 will be easier to identify and include in the project (or conversly exclude
1222 -------------------------------------------------------------------------------
1224 5.8. Addendum: Template for files and function comment blocks:
1226 Example for file comments:
1227 const char FILENAME_rcs[] = "$Id: developer-manual.sgml,v 1.25 2002/04/06 05:07:28 hal9 Exp $";
1228 /*********************************************************************
1232 * Purpose : (Fill me in with a good description!)
1234 * Copyright : Written by and Copyright (C) 2001 the SourceForge
1235 * Privoxy team. http://www.privoxy.org/
1237 * Based on the Internet Junkbuster originally written
1238 * by and Copyright (C) 1997 Anonymous Coders and
1239 * Junkbusters Corporation. http://www.junkbusters.com
1241 * This program is free software; you can redistribute it
1242 * and/or modify it under the terms of the GNU General
1243 * Public License as published by the Free Software
1244 * Foundation; either version 2 of the License, or (at
1245 * your option) any later version.
1247 * This program is distributed in the hope that it will
1248 * be useful, but WITHOUT ANY WARRANTY; without even the
1249 * implied warranty of MERCHANTABILITY or FITNESS FOR A
1250 * PARTICULAR PURPOSE. See the GNU General Public
1251 * License for more details.
1253 * The GNU General Public License should be included with
1254 * this file. If not, you can view it at
1255 * http://www.gnu.org/copyleft/gpl.html
1256 * or write to the Free Software Foundation, Inc., 59
1257 * Temple Place - Suite 330, Boston, MA 02111-1307, USA.
1262 *********************************************************************/
1267 ...necessary include files for us to do our work...
1269 const char FILENAME_h_rcs[] = FILENAME_H_VERSION;
1271 Note: This declares the rcs variables that should be added to the
1272 "show-proxy-args" page. If this is a brand new creation by you, you are free to
1273 change the "Copyright" section to represent the rights you wish to maintain.
1275 Note: The formfeed character that is present right after the comment flower box
1276 is handy for (X|GNU)Emacs users to skip the verbige and get to the heart of the
1277 code (via `forward-page' and `backward-page'). Please include it if you can.
1279 Example for file header comments:
1282 #define FILENAME_H_VERSION "$Id: developer-manual.sgml,v 1.25 2002/04/06 05:07:28 hal9 Exp $"
1283 /*********************************************************************
1287 * Purpose : (Fill me in with a good description!)
1289 * Copyright : Written by and Copyright (C) 2001 the SourceForge
1290 * Privoxy team. http://www.privoxy.org/
1292 * Based on the Internet Junkbuster originally written
1293 * by and Copyright (C) 1997 Anonymous Coders and
1294 * Junkbusters Corporation. http://www.junkbusters.com
1296 * This program is free software; you can redistribute it
1297 * and/or modify it under the terms of the GNU General
1298 * Public License as published by the Free Software
1299 * Foundation; either version 2 of the License, or (at
1300 * your option) any later version.
1302 * This program is distributed in the hope that it will
1303 * be useful, but WITHOUT ANY WARRANTY; without even the
1304 * implied warranty of MERCHANTABILITY or FITNESS FOR A
1305 * PARTICULAR PURPOSE. See the GNU General Public
1306 * License for more details.
1308 * The GNU General Public License should be included with
1309 * this file. If not, you can view it at
1310 * http://www.gnu.org/copyleft/gpl.html
1311 * or write to the Free Software Foundation, Inc., 59
1312 * Temple Place - Suite 330, Boston, MA 02111-1307, USA.
1317 *********************************************************************/
1320 #include "project.h"
1326 ... function headers here ...
1329 /* Revision control strings from this header and associated .c file */
1330 extern const char FILENAME_rcs[];
1331 extern const char FILENAME_h_rcs[];
1338 #endif /* ndef _FILENAME_H */
1346 Example for function comments:
1347 /*********************************************************************
1349 * Function : FUNCTION_NAME
1351 * Description : (Fill me in with a good description!)
1354 * 1 : param1 = pointer to an important thing
1355 * 2 : x = pointer to something else
1357 * Returns : 0 => Ok, everything else is an error.
1359 *********************************************************************/
1360 int FUNCTION_NAME( void *param1, const char *x )
1367 Note: If we all follow this practice, we should be able to parse our code to
1368 create a "self-documenting" web page.
1369 -------------------------------------------------------------------------------
1371 6. Version Control Guidelines
1373 To be filled. note on cvs comments. Don't only comment what you did, but also
1375 -------------------------------------------------------------------------------
1377 7. Testing Guidelines
1380 -------------------------------------------------------------------------------
1382 7.1. Testplan for releases
1384 Explain release numbers. major, minor. developer releases. etc.
1386 1. Remove any existing rpm with rpm -e
1388 2. Remove any file that was left over. This includes (but is not limited to)
1396 + /etc/init.d/privoxy
1401 3. Install the rpm. Any error messages?
1403 4. start,stop,status Privoxy with the specific script (e.g. /etc/rc.d/init/
1404 privoxy stop). Reboot your machine. Does autostart work?
1406 5. Start browsing. Does Privoxy work? Logfile written?
1408 6. Remove the rpm. Any error messages? All files removed?
1411 -------------------------------------------------------------------------------
1414 Please submit test reports only with the test form at sourceforge. Three simple
1417 * Select category: the distribution you test on.
1419 * Select group: the version of Privoxy that we are about to release.
1421 * Fill the Summary and Detailed Description with something intelligent (keep
1422 it short and precise).
1425 Do not mail to the mailinglist (we cannot keep track on issues there).
1426 -------------------------------------------------------------------------------
1428 8. Releasing a new version
1430 To minimize trouble with distribution contents, webpage errors and the like, we
1431 strongly encourage you to follow this section if you prepare a new release of
1432 code or new pages on the webserver.
1434 The following programs are required to follow this process: ncftpput (ncftp),
1435 scp (ssh), gmake (GNU's version of make), autoconf, cvs, ???.
1436 -------------------------------------------------------------------------------
1438 8.1. Before the Release
1440 The following must be done by one of the developers prior to each new release:
1442 * Make sure that everybody who has worked on the code in the last couple of
1443 days has had a chance to yell "no!" in case they have pending changes/fixes
1446 * Increment the version number in configure.in in CVS. Also, the RPM release
1447 number in configure.in. Do NOT touch version information after export from
1448 CVS. All packages will use the version and release data from configure.in.
1449 Local files should not be changed, except prior to a CVS commit!!! This way
1450 we are all on the same page!
1452 * If the default actionsfile has changed since last release, bump up its
1453 version info in this line:
1455 {+add-header{X-Actions-File-Version: A.B} -filter -no-popups}
1458 Then change the version info in doc/webserver/actions/index.php, line:
1459 '$required_actions_file_version = "A.B";'
1461 * Tag all files in CVS with the version number with "cvs tag v_X_Y_Z" (where
1462 X = major, Y = minor, Z = point). Don't use vX_Y_Z, ver_X_Y_Z, v_X.Y.Z
1465 * The first package uploaded should be the official "tarball" release. This
1466 is built with the "make tarball-dist" Makefile target, and then can be
1467 uploaded with "make tarball-upload" (see below).
1470 -------------------------------------------------------------------------------
1471 8.2. Update the webserver
1473 All files must be group-readable and group-writable (or no one else will be
1474 able to change them). To update the webserver, create any pages locally in the
1475 doc/webserver directory (or create new directories under doc/webserver), then
1481 Note that "make dok" (or "make redhat-dok") creates doc/webserver/user-manual,
1482 doc/webserver/developer-manual, doc/webserver/faq and doc/webserver/man-page
1485 Please do NOT use any other means of transferring files to the webserver. "make
1486 webserver" not only uploads, but will make sure that the appropriate
1487 permissions are preserved for shared group access.
1488 -------------------------------------------------------------------------------
1490 8.3. SuSE or Red Hat
1492 Ensure that you have the latest code version. Hence run:
1495 cvs -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa login
1496 cvs -z3 -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa export -r v_X_Y_Z current
1501 autoheader && autoconf && ./configure
1506 make suse-dist or make redhat-dist
1509 To upload the package to Sourceforge, simply issue
1511 make suse-upload or make redhat-upload
1514 Go to the displayed URL and release the file publicly on Sourceforge.
1515 -------------------------------------------------------------------------------
1519 Ensure that you have the latest code version. Hence run:
1522 cvs -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa login
1523 cvs -z3 -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa export -r v_X_Y_Z current
1525 cvs -z3 -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa co os2setup
1528 You will need a mix of development tools. The main compilation takes place with
1529 IBM Visual Age C++. Some ancillary work takes place with GNU tools, available
1530 from various sources like hobbes.nmsu.edu. Specificially, you will need
1531 autoheader, autoconf and sh tools. The packaging takes place with WarpIN,
1532 available from various sources, including its home page: xworkplace.
1534 Change directory to the os2setup directory. Edit the os2build.cmd file to set
1535 the final executable filename. For example,
1536 installExeName='privoxyos2_setup_X.Y.Z.exe'
1538 Next, edit the IJB.wis file so the release number matches in the PACKAGEID
1540 PACKAGEID="Privoxy Team\Privoxy\Privoxy Package\X\Y\Z"
1542 You're now ready to build. Run:
1545 And in the ./files directory you will have the WarpIN-installable executable.
1546 Upload this anonymously to uploads.sourceforge.net/incoming, create a release
1547 for it, and you're done.
1548 -------------------------------------------------------------------------------
1552 Login to Sourceforge's compilefarm via ssh
1554 ssh cf.sourceforge.net
1557 Choose the right operating system (not the Debian one). If you have downloaded
1561 cvs -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa login
1562 cvs -z3 -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa export -r v_X_Y_Z current
1565 If not, please checkout Privoxy via CVS first. Run:
1567 autoheader && autoconf && ./configure
1575 which creates a gzip'ed tar archive. Sadly, you cannot use make solaris-upload
1576 on the Sourceforge machine (no ncftpput). You now have to manually upload the
1577 archive to Sourceforge's ftp server and release the file publicly.
1578 -------------------------------------------------------------------------------
1582 Ensure that you have the latest code version. Hence run
1585 cvs -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa login
1586 cvs -z3 -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa export -r v_X_Y_Z current
1591 autoheader && autoconf && ./configure
1595 -------------------------------------------------------------------------------
1599 Ensure that you have the latest code version. Hence run:
1602 cvs -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa login
1603 cvs -z3 -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa export -r v_X_Y_Z current
1608 autoheader && autoconf && ./configure
1612 -------------------------------------------------------------------------------
1616 Ensure that you have the latest code version. Hence run:
1619 cvs -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa login
1620 cvs -z3 -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa export -r v_X_Y_Z current
1622 cvs -z3 -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa co osxsetup
1625 From the osxsetup directory, run:
1629 This will run autoheader, autoconf and configure as well as make. Finally, it
1630 will copy over the necessary files to the ./osxsetup/files directory for
1631 further processing by PackageMaker.
1633 Bring up PackageMaker with the PrivoxyPackage.pmsp definition file, modify the
1634 package name to match the release, and hit the "Create package" button. If you
1635 specify ./Privoxy.pkg as the output package name, you can then create the
1636 distributable zip file with the command:
1637 zip -r privoxyosx_setup_x.y.z.zip Privoxy.pkg
1639 You can then upload privoxyosx_setup_x.y.z.zip anonymously to
1640 uploads.sourceforge.net/incoming, create a release for it, and you're done.
1641 -------------------------------------------------------------------------------
1645 Change the version number of Privoxy in the configure.in file. Run:
1646 autoheader && autoconf && ./configure
1650 Login to Sourceforge's compilefarm via ssh:
1652 ssh cf.sourceforge.net
1655 Choose the right operating system. If you have downloaded Privoxy before,
1658 cvs -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa login
1659 cvs -z3 -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa export -r v_X_Y_Z current
1662 If not, please checkout Privoxy via CVS first. Run:
1664 autoheader && autoconf && ./configure
1672 which creates a gzip'ed tar archive. Sadly, you cannot use make freebsd-upload
1673 on the Sourceforge machine (no ncftpput). You now have to manually upload the
1674 archive to Sourceforge's ftp server and release the file publicly.
1675 -------------------------------------------------------------------------------
1679 Ensure that you have the latest code version. Hence run:
1682 cvs -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa login
1683 cvs -z3 -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa export -r v_X_Y_Z current
1689 autoheader && autoconf && ./configure
1697 To upload the package to Sourceforge, simply issue
1702 Goto the displayed URL and release the file publicly on Sourceforge.
1703 -------------------------------------------------------------------------------
1707 Ensure that you have the latest code version. Hence run:
1710 cvs -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa login
1711 cvs -z3 -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa export -r v_X_Y_Z current
1716 autoheader && autoconf && ./configure
1720 -------------------------------------------------------------------------------
1724 Ensure that you have the latest code version. Hence run:
1727 cvs -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa login
1728 cvs -z3 -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa export -r v_X_Y_Z current
1733 autoheader && autoconf && ./configure
1737 -------------------------------------------------------------------------------
1741 Login to Sourceforge's compilefarm via ssh:
1743 ssh cf.sourceforge.net
1746 Choose the right operating system. If you have downloaded Privoxy before:
1749 cvs -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa login
1750 cvs -z3 -d:pserver:anonymous@cvs.ijbswa.sourceforge.net:/cvsroot/ijbswa export -r v_X_Y_Z current
1753 If not, please checkout Privoxy via CVS first. Run:
1755 autoheader && autoconf && ./configure
1763 which creates a gzip'ed tar archive. Sadly, you cannot use make aix-upload on
1764 the Sourceforge machine (no ncftpput). You now have to manually upload the
1765 archive to Sourceforge's ftp server and release the file publicly.
1766 -------------------------------------------------------------------------------
1768 9. Contacting the developers, Bug Reporting and Feature Requests
1770 We value your feedback. However, to provide you with the best support, please
1773 * Use the Sourceforge Support Forum to get help:
1775 http://sourceforge.net/tracker/?group_id=11118&atid=211118
1778 * Submit bugs only through our Sourceforge Bug Forum:
1780 http://sourceforge.net/tracker/?group_id=11118&atid=111118.
1783 Make sure that the bug has not already been submitted. Please try to verify
1784 that it is a Privoxy bug, and not a browser or site bug first. If you are
1785 using your own custom configuration, please try the stock configs to see if
1786 the problem is a configuration related bug. And if not using the latest
1787 development snapshot, please try the latest one. Or even better, CVS
1788 sources. Please be sure to include the Privoxy/Junkbuster version,
1789 platform, browser, any pertinent log data, any other relevant details
1790 (please be specific) and, if possible, some way to reproduce the bug.
1792 * Submit feature requests only through our Sourceforge feature request
1795 http://sourceforge.net/tracker/?atid=361118&group_id=11118&func=browse.
1798 * We will soon have an automated way to submit advertisements, incorrectly
1799 blocked images, popups and the like. Check back.
1802 * For any other issues, feel free to use the mailing lists:
1804 http://sourceforge.net/mail/?group_id=11118.
1807 Anyone interested in actively participating in development and related
1808 discussions can also join the appropriate mailing list. Archives are
1812 -------------------------------------------------------------------------------
1813 10. Copyright and History
1817 Privoxy is free software; you can redistribute it and/or modify it under the
1818 terms of the GNU General Public License as published by the Free Software
1819 Foundation; either version 2 of the License, or (at your option) any later
1822 This program is distributed in the hope that it will be useful, but WITHOUT ANY
1823 WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
1824 PARTICULAR PURPOSE. See the GNU General Public License for more details, which
1825 is available from the Free Software Foundation, Inc, 59 Temple Place - Suite
1826 330, Boston, MA 02111-1307, USA.
1828 You should have received a copy of the GNU General Public License along with
1829 this program; if not, write to the Free Software Foundation, Inc., 59 Temple
1830 Place, Suite 330, Boston, MA 02111-1307 USA.
1831 -------------------------------------------------------------------------------
1835 Privoxy is evolved, and derived from, the Internet Junkbuster, with many
1836 improvments and enhancements over the original.
1838 Junkbuster was originally written by Anonymous Coders and Junkbuster's
1839 Corporation, and was released as free open-source software under the GNU GPL.
1840 Stefan Waldherr made many improvements, and started the SourceForge project
1841 Privoxy to rekindle development. There are now several active developers
1842 contributing. The last stable release of Junkbuster was v2.0.2, which has now
1844 -------------------------------------------------------------------------------
1848 Other references and sites of interest to Privoxy users:
1850 http://www.privoxy.org/, The Privoxy Home page.
1852 http://sourceforge.net/projects/ijbswa, the Project Page for Privoxy on
1855 http://p.p/, access Privoxy from your browser. Alternately, http://
1856 config.privoxy.org may work in some situations where the first does not.
1858 http://www.junkbusters.com/ht/en/cookies.html
1860 http://www.waldherr.org/junkbuster/
1862 http://privacy.net/analyze/
1864 http://www.squid-cache.org/