From f219eb93eb24f488bbe0fe1da98d11505498b798 Mon Sep 17 00:00:00 2001 From: Tim Ruehsen Date: Wed, 23 Apr 2014 15:57:18 +0200 Subject: [PATCH] First libpsl docs commit --- api-index-full.html | 112 +++++ ch01.html | 33 ++ deprecated-api-index.html | 30 ++ home.png | Bin 0 -> 256 bytes index.html | 39 ++ index.sgml | 25 + left-insensitive.png | Bin 0 -> 395 bytes left.png | Bin 0 -> 262 bytes libpsl-Public-Suffix-List-functions.html | 579 +++++++++++++++++++++++ libpsl.devhelp2 | 29 ++ object-tree.html | 33 ++ right-insensitive.png | Bin 0 -> 373 bytes right.png | Bin 0 -> 261 bytes style.css | 461 ++++++++++++++++++ up-insensitive.png | Bin 0 -> 374 bytes up.png | Bin 0 -> 260 bytes 16 files changed, 1341 insertions(+) create mode 100644 api-index-full.html create mode 100644 ch01.html create mode 100644 deprecated-api-index.html create mode 100644 home.png create mode 100644 index.html create mode 100644 index.sgml create mode 100644 left-insensitive.png create mode 100644 left.png create mode 100644 libpsl-Public-Suffix-List-functions.html create mode 100644 libpsl.devhelp2 create mode 100644 object-tree.html create mode 100644 right-insensitive.png create mode 100644 right.png create mode 100644 style.css create mode 100644 up-insensitive.png create mode 100644 up.png diff --git a/api-index-full.html b/api-index-full.html new file mode 100644 index 0000000..7bc5f95 --- /dev/null +++ b/api-index-full.html @@ -0,0 +1,112 @@ + + + + +libpsl Reference Manual: API Index + + + + + + + + + + + + + + + + +
+

+API Index

+

B

+
+psl_builtin, function in Public Suffix List functions +
+
+
+psl_builtin_compile_time, function in Public Suffix List functions +
+
+
+psl_builtin_filename, function in Public Suffix List functions +
+
+
+psl_builtin_file_time, function in Public Suffix List functions +
+
+
+psl_builtin_sha1sum, function in Public Suffix List functions +
+
+

C

+
+psl_ctx_t, typedef in Public Suffix List functions +
+
+

F

+
+psl_free, function in Public Suffix List functions +
+
+

I

+
+psl_is_cookie_domain_acceptable, function in Public Suffix List functions +
+
+
+psl_is_public_suffix, function in Public Suffix List functions +
+
+

L

+
+psl_load_file, function in Public Suffix List functions +
+
+
+psl_load_fp, function in Public Suffix List functions +
+
+

R

+
+psl_registrable_domain, function in Public Suffix List functions +
+
+

S

+
+psl_suffix_count, function in Public Suffix List functions +
+
+
+psl_suffix_exception_count, function in Public Suffix List functions +
+
+

U

+
+psl_unregistrable_domain, function in Public Suffix List functions +
+
+
+ + + \ No newline at end of file diff --git a/ch01.html b/ch01.html new file mode 100644 index 0000000..a46611b --- /dev/null +++ b/ch01.html @@ -0,0 +1,33 @@ + + + + +libpsl Reference Manual: libpsl functions + + + + + + + + + + + + + + + + +
+

+libpsl functions

+
+libpsl — Public Suffix List library functions +
+
+ + + \ No newline at end of file diff --git a/deprecated-api-index.html b/deprecated-api-index.html new file mode 100644 index 0000000..2647606 --- /dev/null +++ b/deprecated-api-index.html @@ -0,0 +1,30 @@ + + + + +libpsl Reference Manual: Index of deprecated API + + + + + + + + + + + + + + + +
+

+Index of deprecated API

+ +
+ + + \ No newline at end of file diff --git a/home.png b/home.png new file mode 100644 index 0000000000000000000000000000000000000000..9346b336a784463192c7daab5133a3673dd69845 GIT binary patch literal 256 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Y)RhkE)4%caKYZ?lYt_f1s;*b zKpodXn9)gNb_Gz7y~NYkmHjTefRMbARQqaxysz9Q}BI-m)~Y zggoA|1V*z2{cQ=d;!=?fvu4~`n82RKrk1UubNXTJj1GP|o-=>$A29f{JgJ9K`^t{Q z-oWs>M&_hvT&MjX@T4-&sBW+1^4oB5G4r2q!qGktZ!n*!)hjrjd0_4L6;4%u<}orJ u%Vo~x?#i!!ww+1OGuHe}T=cKQUzn^_t)8|WlnDbmjKR~@&t;ucLK6T + + + +libpsl Reference Manual: libpsl Reference Manual + + + + + + + +
+
+
+
+

+ for libpsl [VERSION]. + The latest version of this documentation can be found on-line at + GitHub. +

+
+
+
+
+
libpsl functions
+
+libpsl — Public Suffix List library functions +
+
Object Hierarchy
+
API Index
+
Index of deprecated API
+
+
+ + + \ No newline at end of file diff --git a/index.sgml b/index.sgml new file mode 100644 index 0000000..7825391 --- /dev/null +++ b/index.sgml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/left-insensitive.png b/left-insensitive.png new file mode 100644 index 0000000000000000000000000000000000000000..3269393a7f72af744a772c437bd7b3976c23709d GIT binary patch literal 395 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Y)RhkE)4%caKYZ?lYt_f1s;*b zKpodXn9)gNb_Gz7y~NYkmHjTefH0HbvDJm`3=E7Co-U3d7N^fnTIWJ3j{^~q!iyia4kV=mdU|Jhfgdm;SLIpiYJ7wv^kjFiECCc&8T30!RG0~&BG=X zlu#U4@Z`))V`EG9e^NqDr#{!5k|)wT* zYTNt0`@q%TAD$){%#eQ?;$^ly8}yZCU%T~u0XM^%t?f#e znB*EuLv2rP%K3BMvFO}YmnR}KSgH;`EHL$)^!tH~iBxZ#h^zJi*#P5Xb6B50U@nx2 mU;T=yfcwnSOsS9SKd{M#MlNkCuvG>I8-u5-pUXO@geCx5`k@p6 literal 0 HcmV?d00001 diff --git a/left.png b/left.png new file mode 100644 index 0000000000000000000000000000000000000000..2abde032b0c98b756b12d380da4318205cd78470 GIT binary patch literal 262 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Y)RhkE)4%caKYZ?lYt_f1s;*b zKpodXn9)gNb_Gz7y~NYkmHjTefRMaSLay~*pwMJb7sn8b(^oI8=R24v(*CjE{-BFv z0BhvLm?o9(UC{-Ci?lD?Ve-7-xypA!PTC(0^;>UheG4Altep3@`rO0#Rjs1)RxCLr zE5mee>7m*=%yEk+GVvGkRy0O&*&MTd5SjH(lgq~7r%6oRW$l1p-*S}iC>@fyDsz%y z`UIW8^Ao=maGhj3E8{7Cd_qof`K4oa->23`>&M2+XBtd2J`8jogQu&X%Q~loCIG_? BVG#fT literal 0 HcmV?d00001 diff --git a/libpsl-Public-Suffix-List-functions.html b/libpsl-Public-Suffix-List-functions.html new file mode 100644 index 0000000..bd2c210 --- /dev/null +++ b/libpsl-Public-Suffix-List-functions.html @@ -0,0 +1,579 @@ + + + + +libpsl Reference Manual: libpsl + + + + + + + + + + + + + + + + +
+
+
+ + +
+

libpsl

+

libpsl — Public Suffix List library functions

+
+
+

Stability Level

+Unstable, unless otherwise indicated +
+
+

Functions

+
++++ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+psl_ctx_t * + +psl_load_file () +
+psl_ctx_t * + +psl_load_fp () +
const psl_ctx_t * + +psl_builtin () +
+void + +psl_free () +
+int + +psl_is_public_suffix () +
const char * + +psl_unregistrable_domain () +
const char * + +psl_registrable_domain () +
+int + +psl_suffix_count () +
+int + +psl_suffix_exception_count () +
+time_t + +psl_builtin_compile_time () +
+time_t + +psl_builtin_file_time () +
const char * + +psl_builtin_sha1sum () +
const char * + +psl_builtin_filename () +
+int + +psl_is_cookie_domain_acceptable () +
+
+
+

Types and Values

+
++++ + + + + +
typedefpsl_ctx_t
+
+
+

Object Hierarchy

+
+
+
+
+

Includes

+
#include <libpsl.h>
+
+
+
+

Description

+

Public Suffix List library functions.

+
+
+

Functions

+
+

psl_load_file ()

+
psl_ctx_t *
+psl_load_file (const char *fname);
+

This function loads the public suffixes file named fname +. +To free the allocated resources, call psl_free().

+
+

Parameters

+
+++++ + + + + + +

fname

Name of PSL file

 
+
+
+

Returns

+

Pointer to a PSL context or NULL on failure.

+

+
+

Since 0.1

+
+
+
+

psl_load_fp ()

+
psl_ctx_t *
+psl_load_fp (FILE *fp);
+

This function loads the public suffixes from a FILE pointer. +To free the allocated resources, call psl_free().

+
+

Parameters

+
+++++ + + + + + +

fp

FILE pointer

 
+
+
+

Returns

+

Pointer to a PSL context or NULL on failure.

+

+
+

Since 0.1

+
+
+
+

psl_builtin ()

+
const psl_ctx_t *
+psl_builtin (void);
+

This function returns the PSL context that has been generated and built in at compile-time. +You don't have to free the returned context explicitely.

+

If the generation of built-in data has been disabled during compilation, NULL will be returned.

+
+

Returns

+

Pointer to the built in PSL data or NULL if this data is not available.

+

+
+

Since 0.1

+
+
+
+

psl_free ()

+
void
+psl_free (psl_ctx_t *psl);
+
+
+
+

psl_is_public_suffix ()

+
int
+psl_is_public_suffix (const psl_ctx_t *psl,
+                      const char *domain);
+

This function checks if domain + is a public suffix by the means of the +Mozilla Public Suffix List.

+

For cookie domain checking see psl_is_cookie_domain_acceptable().

+

psl + is a context returned by either psl_load_file(), psl_load_fp() or +psl_builtin().

+
+

Parameters

+
+++++ + + + + + + + + + + + + +

psl

PSL context

 

domain

Domain string

 
+
+
+

Returns

+

1 if domain is a public suffix, 0 if not.

+

+
+

Since 0.1

+
+
+
+

psl_unregistrable_domain ()

+
const char *
+psl_unregistrable_domain (const psl_ctx_t *psl,
+                          const char *domain);
+

This function finds the longest publix suffix part of domain + by the means +of the Mozilla Public Suffix List.

+

psl + is a context returned by either psl_load_file(), psl_load_fp() or +psl_builtin().

+
+

Parameters

+
+++++ + + + + + + + + + + + + +

psl

PSL context

 

domain

Domain string

 
+
+
+

Returns

+

Pointer to longest public suffix part of domain +or NULL if domain +does not contain a public suffix (or if psl +is NULL).

+

+
+

Since 0.1

+
+
+
+

psl_registrable_domain ()

+
const char *
+psl_registrable_domain (const psl_ctx_t *psl,
+                        const char *domain);
+

This function finds the shortest private suffix part of domain + by the means +of the Mozilla Public Suffix List.

+

psl + is a context returned by either psl_load_file(), psl_load_fp() or +psl_builtin().

+
+

Parameters

+
+++++ + + + + + + + + + + + + +

psl

PSL context

 

domain

Domain string

 
+
+
+

Returns

+

Pointer to shortest private suffix part of domain +or NULL if domain +does not contain a private suffix (or if psl +is NULL).

+

+
+

Since 0.1

+
+
+
+

psl_suffix_count ()

+
int
+psl_suffix_count (const psl_ctx_t *psl);
+

This function returns number of public suffixes maintained by psl +. +The number of exceptions within the Public Suffix List are not included.

+

If the generation of built-in data has been disabled during compilation, 0 will be returned.

+
+

Parameters

+
+++++ + + + + + +

psl

PSL context pointer

 
+
+
+

Returns

+

Number of public suffixes entries in PSL context.

+

+
+

Since 0.1

+
+
+
+

psl_suffix_exception_count ()

+
int
+psl_suffix_exception_count (const psl_ctx_t *psl);
+

This function returns number of public suffix exceptions maintained by psl +.

+

If the generation of built-in data has been disabled during compilation, 0 will be returned.

+
+

Parameters

+
+++++ + + + + + +

psl

PSL context pointer

 
+
+
+

Returns

+

Number of public suffix exceptions in PSL context.

+

+
+

Since 0.1

+
+
+
+

psl_builtin_compile_time ()

+
time_t
+psl_builtin_compile_time (void);
+

This function returns the time when the Publix Suffix List has been compiled into C code (by psl2c).

+

If the generation of built-in data has been disabled during compilation, 0 will be returned.

+
+

Returns

+

time_t value or 0.

+

+
+

Since 0.1

+
+
+
+

psl_builtin_file_time ()

+
time_t
+psl_builtin_file_time (void);
+

This function returns the mtime of the Publix Suffix List file that has been built in.

+

If the generation of built-in data has been disabled during compilation, 0 will be returned.

+
+

Returns

+

time_t value or 0.

+

+
+

Since 0.1

+
+
+
+

psl_builtin_sha1sum ()

+
const char *
+psl_builtin_sha1sum (void);
+

This function returns the SHA1 checksum of the Publix Suffix List file that has been built in. +The returned string is in lowercase hex encoding, e.g. "2af1e9e3044eda0678bb05949d7cca2f769901d8".

+

If the generation of built-in data has been disabled during compilation, an empty string will be returned.

+
+

Returns

+

String containing SHA1 checksum or an empty string.

+

+
+

Since 0.1

+
+
+
+

psl_builtin_filename ()

+
const char *
+psl_builtin_filename (void);
+

This function returns the file name of the Publix Suffix List file that has been built in.

+

If the generation of built-in data has been disabled during compilation, an empty string will be returned.

+
+

Returns

+

String containing the PSL file name or an empty string.

+

+
+

Since 0.1

+
+
+
+

psl_is_cookie_domain_acceptable ()

+
int
+psl_is_cookie_domain_acceptable (const psl_ctx_t *psl,
+                                 const char *hostname,
+                                 const char *cookie_domain);
+

This helper function checks whether cookie_domain + is an acceptable cookie domain value for the request +hostname +.

+

Examples:

+
    +
  1. Cookie domain 'example.com' would be acceptable for hostname 'www.example.com', +but '.com' or 'com' would NOT be acceptable since 'com' is a public suffix.

  2. +
  3. Cookie domain 'his.name' would be acceptable for hostname 'remember.his.name', +but NOT for 'forgot.his.name' since 'forgot.his.name' is a public suffix.

  4. +
+
+

Parameters

+
+++++ + + + + + + + + + + + + + + + + + +

psl

PSL context pointer

 

hostname

The request hostname.

 

cookie_domain

The domain value from a cookie

 
+
+
+

Returns

+

1 if acceptable, 0 if not acceptable.

+

+
+

Since 0.1

+
+
+
+

Types and Values

+
+

psl_ctx_t

+
typedef struct _psl_ctx_st psl_ctx_t;
+
+
+
+
+ + + \ No newline at end of file diff --git a/libpsl.devhelp2 b/libpsl.devhelp2 new file mode 100644 index 0000000..9bfc890 --- /dev/null +++ b/libpsl.devhelp2 @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/object-tree.html b/object-tree.html new file mode 100644 index 0000000..76deeb2 --- /dev/null +++ b/object-tree.html @@ -0,0 +1,33 @@ + + + + +libpsl Reference Manual: Object Hierarchy + + + + + + + + + + + + + + + + +
+

+Object Hierarchy

+
+
+
+
+ + + \ No newline at end of file diff --git a/right-insensitive.png b/right-insensitive.png new file mode 100644 index 0000000000000000000000000000000000000000..4c95785b907b978f36674cd98bf5302669c15c1b GIT binary patch literal 373 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Y)RhkE)4%caKYZ?lYt_f1s;*b zKpodXn9)gNb_Gz7y~NYkmHjTefG`u!(zUX23=E7+o-U3d7N^fn+URvSL8NuRG*{E) z?#-+97X-^pidQ*u@StO1(S@7g8g>nnA24$?ty?)cmuaa|Y>ez2*_Ia?6HP4j{3LIs zTr!s1ao_Sz^~3e4zRJGAjKZGn=XP#)Wmuo-QN>teTzzI!&R*jMI^Oa#7_ukLYdicf zOx;1mb-rt04s-c|uIH8fnX}$)XJa^0_-F3(pA%=sGI<|(n_*&=yYt96+n5InXn_GN+EraJI9q(O+n{6MQKErp&KxRvpfn0xh z`sSMqH(2Z%?kaFBTf06W^y=UDA9gR9YrwNS*1pjB((0K%&+SbAx3`XA&dKZ}j*nX7 QfdRze>FVdQ&MBb@09|aA9{>OV literal 0 HcmV?d00001 diff --git a/right.png b/right.png new file mode 100644 index 0000000000000000000000000000000000000000..76260ec8865f4e13cd269ec62eccd78a33adba3c GIT binary patch literal 261 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Y)RhkE)4%caKYZ?lYt_f1s;*b zKpodXn9)gNb_Gz7y~NYkmHjTefRMbR+#PqI2*V^#7sn8b(^oI8=W9$9IsUQVezxzH zy`G{eu0`y#boSlU-NAlQG~=D)BPJG4k(^0qdDa(AdQvI0d|vJT=i7_<_D6`Cy?Dm; zP0@1EeB~D|O$oQe*sxL-P;q{2UCr}fN-o#M~tpZzsGyfNz46SZlIJCbKH zZQscEqpOfBCPDgx dd > dl > dt +{ + padding-top: 0.25em; + padding-bottom: 0.25em; +} + +dl.toc > dt +{ + padding-top: 1em; + padding-bottom: 0.5em; + font-weight: bold; +} + +.parameter +{ + font-style: normal; +} + +.footer +{ + padding-top: 3.5em; + /* tango:aluminium 3 */ + color: #babdb6; + text-align: center; + font-size: 80%; +} + +.informalfigure, +.figure +{ + margin: 1em; +} + +.informalexample, +.example +{ + margin-top: 1em; + margin-bottom: 1em; +} + +.warning +{ + /* tango:orange 0/1 */ + background: #ffeed9; + background: rgba(252, 175, 62, 0.1); + border-color: #ffb04f; + border-color: rgba(252, 175, 62, 0.2); +} +.note +{ + /* tango:chameleon 0/0.5 */ + background: #d8ffb2; + background: rgba(138, 226, 52, 0.1); + border-color: #abf562; + border-color: rgba(138, 226, 52, 0.2); +} +div.blockquote +{ + border-color: #eeeeec; +} +.note, .warning, div.blockquote +{ + padding: 0.5em; + border-width: 1px; + border-style: solid; + margin: 2em; +} +.note p, .warning p +{ + margin: 0; +} + +div.warning h3.title, +div.note h3.title +{ + display: none; +} + +p + div.section +{ + margin-top: 1em; +} + +div.refnamediv, +div.refsynopsisdiv, +div.refsect1, +div.refsect2, +div.toc, +div.section +{ + margin-bottom: 1em; +} + +/* blob links */ +h2 .extralinks, h3 .extralinks +{ + float: right; + /* tango:aluminium 3 */ + color: #babdb6; + font-size: 80%; + font-weight: normal; +} + +.lineart +{ + color: #d3d7cf; + font-weight: normal; +} + +.annotation +{ + /* tango:aluminium 5 */ + color: #555753; + font-weight: normal; +} + +.structfield +{ + font-style: normal; + font-weight: normal; +} + +/* code listings */ + +.listing_code .programlisting .cbracket { color: #a40000; } /* tango: scarlet red 3 */ +.listing_code .programlisting .comment { color: #a1a39d; } /* tango: aluminium 4 */ +.listing_code .programlisting .function { color: #000000; font-weight: bold; } +.listing_code .programlisting .function a { color: #11326b; font-weight: bold; } /* tango: sky blue 4 */ +.listing_code .programlisting .keyword { color: #4e9a06; } /* tango: chameleon 3 */ +.listing_code .programlisting .linenum { color: #babdb6; } /* tango: aluminium 3 */ +.listing_code .programlisting .normal { color: #000000; } +.listing_code .programlisting .number { color: #75507b; } /* tango: plum 2 */ +.listing_code .programlisting .preproc { color: #204a87; } /* tango: sky blue 3 */ +.listing_code .programlisting .string { color: #c17d11; } /* tango: chocolate 2 */ +.listing_code .programlisting .type { color: #000000; } +.listing_code .programlisting .type a { color: #11326b; } /* tango: sky blue 4 */ +.listing_code .programlisting .symbol { color: #ce5c00; } /* tango: orange 3 */ + +.listing_frame { + /* tango:sky blue 1 */ + border: solid 1px #729fcf; + border: solid 1px rgba(114, 159, 207, 0.2); + padding: 0px; +} + +.listing_lines, .listing_code { + margin-top: 0px; + margin-bottom: 0px; + padding: 0.5em; +} +.listing_lines { + /* this just adds visual clutter and + takes precious room from small screens */ + display: none; +} +.listing_lines { + /* tango:sky blue 0.5 */ + background: #a6c5e3; + background: rgba(114, 159, 207, 0.2); + /* tango:aluminium 6 */ + color: #2e3436; +} +.listing_code { + /* tango:sky blue 0 */ + background: #e6f3ff; + background: rgba(114, 159, 207, 0.1); +} +.listing_code .programlisting { + /* override from previous */ + border: none 0px; + padding: 0px; + background: none; +} +.listing_lines pre, .listing_code pre { + margin: 0px; +} + diff --git a/up-insensitive.png b/up-insensitive.png new file mode 100644 index 0000000000000000000000000000000000000000..f40498606db349a7321cf6b470523e836ee7ac2e GIT binary patch literal 374 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Y)RhkE)4%caKYZ?lYt_f1s;*b zKpodXn9)gNb_Gz7y~NYkmHjTefG~@Ex#w@70gTL^E{-7zACwHGSRJaopUzr*FR_KPpkxheNzTDP+%{a~ox zRb6~e-_l%s#;V|Jw-)bO$G_X=4F`Y7SBoCzyjAZQ8BPW>ywAP8?pbBsZ|wt?+h6S6&uqY)kkMnwQQEd@7k`4t@sCCO z@7MoiEI4Q_#IB70vhu7Ab+>SXLxu@LWH Qzz|~aboFyt=akR{08E^fv;Y7A literal 0 HcmV?d00001 diff --git a/up.png b/up.png new file mode 100644 index 0000000000000000000000000000000000000000..80b4b37e997d69b2e128bc3090bc447ccb74bbe9 GIT binary patch literal 260 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Y)RhkE)4%caKYZ?lYt_f1s;*b zKpodXn9)gNb_Gz7y~NYkmHjTefRFevZLys@4W>+6GUE!tU04Ii{0w_tkMIDB?rA5 zttYTN