Added login URL posting.

This commit is contained in:
Bastian Kleineidam 2010-10-14 18:36:11 +02:00
parent 4483635552
commit 25d75bd4a2
15 changed files with 630 additions and 244 deletions

View file

@ -169,6 +169,7 @@
#internlinks=^http://www\.my(other)?domain\.net/
[authentication]
# You can provide different user/password pairs for different link types.
# Entries are a triple (link regular expression, username, password),
# separated by whitespace.
@ -176,7 +177,19 @@
# for authentication. The commandline options -u,-p match every link
# and therefore override the entries given here. The first match wins.
# At the moment, authentication is used/needed for http[s] and ftp links.
[authentication]
#entry=
# ^http://treasure\.calvinsplayground\.de/~calvin/isnichmehr/ lebowski lebowski
# ^ftp://void.cs.uni-sb.de calvin hutzli
# if the website requires a login the URL and optionally the user and
# password CGI fieldnames can be provided.
#loginurl=http://www.example.com/
# The name of the user and password CGI field
#loginuserfield=login
#loginpasswordfield=password
# Optionally any additional CGI name/value pairs. Note that the default
# values are submitted automatically.
#loginextrafields=
# name1:value1
# name 2:value 2

2
debian/control vendored
View file

@ -16,7 +16,7 @@ XB-Python-Version: ${python:Versions}
Provides: ${python:Provides}
Suggests: apache2 | httpd, python-optcomplete (>= 1.2-5),
python-geoip (>= 1.2.1-2), clamav-daemon, python-utidylib,
python-cssutils, python-pysqlite2
python-cssutils, python-pysqlite2, python-twill
Description: check websites and HTML documents for broken links
Provides a command line program and web interface to check links
of websites and HTML documents.

View file

@ -1,4 +1,4 @@
5.4 "" (released xx.xx.2010)
5.4 "" (released xx.10.2010)
Fixes:
- gui: Enable the cancel button again after it has been clicked and
@ -21,6 +21,9 @@ Features:
Closes: SF bug #2931320
- config: Added configuration file option for the --cookies command line
option.
- http: Allow specifying a login URL in the configuration file which
gets visited before checking submits login data.
Closes: SF bug #3041527
5.3 "Inception" (released 29.9.2010)

304
doc/de.po
View file

@ -5,8 +5,8 @@
msgid ""
msgstr ""
"Project-Id-Version: linkchecker 3.4\n"
"POT-Creation-Date: 2010-10-12 00:31+0300\n"
"PO-Revision-Date: 2010-10-12 00:18+0100\n"
"POT-Creation-Date: 2010-10-14 18:25+0300\n"
"PO-Revision-Date: 2010-10-14 18:29+0100\n"
"Last-Translator: Bastian Kleineidam <calvin@users.sourceforge.net>\n"
"Language-Team: de <de@li.org>\n"
"Language: \n"
@ -249,7 +249,7 @@ msgstr "B<-I>, B<--interactive>"
# type: Plain text
#. type: Plain text
#: en/linkchecker.1:65 en/linkcheckerrc.5:137
#: en/linkchecker.1:65 en/linkcheckerrc.5:152
msgid "Ask for URL if none are given on the commandline."
msgstr "Frage nach URLs, falls keine auf der Kommandozeile eingegeben wurden."
@ -520,7 +520,7 @@ msgstr "B<-o>I<TYP>[B</>I<ENKODIERUNG>], B<--output=>I<TYP>[B</>I<ENKODIERUNG>]"
# type: Plain text
#. type: Plain text
#: en/linkchecker.1:130 en/linkcheckerrc.5:158
#: en/linkchecker.1:130 en/linkcheckerrc.5:173
msgid ""
"Specify output type as B<text>, B<html>, B<sql>, B<csv>, B<gml>, B<dot>, "
"B<xml>, B<none> or B<blacklist>. Default type is B<text>. The various "
@ -532,7 +532,7 @@ msgstr ""
# type: Plain text
#. type: Plain text
#: en/linkchecker.1:134 en/linkcheckerrc.5:162
#: en/linkchecker.1:134 en/linkcheckerrc.5:177
msgid ""
"The I<ENCODING> specifies the output encoding, the default is that of your "
"locale. Valid encodings are listed at B<http://docs.python.org/library/"
@ -1812,7 +1812,7 @@ msgstr ""
# type: SH
#. type: SH
#: en/linkchecker.1:530 en/linkcheckerrc.5:409 en/linkchecker-gui.1:11
#: en/linkchecker.1:530 en/linkcheckerrc.5:424 en/linkchecker-gui.1:11
#, no-wrap
msgid "SEE ALSO"
msgstr "SIEHE AUCH"
@ -1825,27 +1825,27 @@ msgstr "B<linkcheckerrc>(5)"
# type: SH
#. type: SH
#: en/linkchecker.1:533 en/linkcheckerrc.5:412 en/linkchecker-gui.1:14
#: en/linkchecker.1:533 en/linkcheckerrc.5:427 en/linkchecker-gui.1:14
#, no-wrap
msgid "AUTHOR"
msgstr "AUTHOR"
# type: Plain text
#. type: Plain text
#: en/linkchecker.1:535 en/linkcheckerrc.5:414 en/linkchecker-gui.1:16
#: en/linkchecker.1:535 en/linkcheckerrc.5:429 en/linkchecker-gui.1:16
msgid "Bastian Kleineidam E<lt>calvin@users.sourceforge.netE<gt>"
msgstr "Bastian Kleineidam E<lt>calvin@users.sourceforge.netE<gt>"
# type: SH
#. type: SH
#: en/linkchecker.1:536 en/linkcheckerrc.5:415 en/linkchecker-gui.1:17
#: en/linkchecker.1:536 en/linkcheckerrc.5:430 en/linkchecker-gui.1:17
#, no-wrap
msgid "COPYRIGHT"
msgstr "COPYRIGHT"
# type: Plain text
#. type: Plain text
#: en/linkchecker.1:537 en/linkcheckerrc.5:416
#: en/linkchecker.1:537 en/linkcheckerrc.5:431
msgid "Copyright \\(co 2000-2010 Bastian Kleineidam"
msgstr "Copyright \\(co 2000-2010 Bastian Kleineidam"
@ -2065,7 +2065,7 @@ msgstr "Dateiname von B<clamd.conf> Konfigurationsdatei."
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:90 en/linkcheckerrc.5:113 en/linkcheckerrc.5:119
#: en/linkcheckerrc.5:212 en/linkcheckerrc.5:228
#: en/linkcheckerrc.5:227 en/linkcheckerrc.5:243
msgid "Command line option: none"
msgstr "Kommandozeilenoption: keine"
@ -2183,7 +2183,7 @@ msgstr "[authentication]"
#: en/linkcheckerrc.5:120
#, no-wrap
msgid "B<entry=>I<REGEX> I<USER> I<PASS> (MULTILINE)"
msgstr "B<entry=>I<REGEX> I<USER> I<PASS> (MULTILINE)"
msgstr "B<entry=>I<REGEX> I<BENUTZER> I<PASSWORT> (MULTILINE)"
# type: Plain text
#. type: Plain text
@ -2218,36 +2218,94 @@ msgstr ""
msgid "Command line option: B<-u>, B<-p>"
msgstr "Kommandozeilenoption: B<-u>, B<-p>"
# type: TP
#. type: TP
#: en/linkcheckerrc.5:133
#, no-wrap
msgid "B<loginurl=>I<URL>"
msgstr "B<loginurl=>I<URL>"
#. type: Plain text
#: en/linkcheckerrc.5:138
msgid ""
"A login URL to be visited before checking. Also needs authentication data "
"set for it, and implies using cookies because most logins use cookies "
"nowadays."
msgstr ""
"Eine Anmelde-URL, die vor der Prüfung besucht wird. Benötigt einen Eintrag "
"zur Authentifizierung und impliziert die Benutzung von Cookies, weil die "
"meisten Anmeldungen heutzutage Cookies benutzen."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:138
#, no-wrap
msgid "B<loginuserfield=>I<STRING>"
msgstr "B<loginuserfield=>I<NAME>"
#. type: Plain text
#: en/linkcheckerrc.5:141
msgid "The name of the user CGI field. Default name is B<login>."
msgstr "Der Name für das Benutzer CGI-Feld. Der Standardname ist B<login>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:141
#, no-wrap
msgid "B<loginpasswordfield=>I<STRING>"
msgstr "B<loginpasswordfield=>I<NAME>"
#. type: Plain text
#: en/linkcheckerrc.5:144
msgid "The name of the password CGI field. Default name is B<password>."
msgstr "Der Name für das Passwort CGI-Feld. Der Standardname ist B<password>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:144
#, no-wrap
msgid "B<loginextrafields=>I<NAME>B<:>I<VALUE> (MULTILINE)"
msgstr "B<loginextrafields=>I<NAME>B<:>I<WERT> (MULTILINE)"
#. type: Plain text
#: en/linkcheckerrc.5:148
msgid ""
"Optionally any additional CGI name/value pairs. Note that the default values "
"are submitted automatically."
msgstr ""
"Optional zusätzliche CGI Namen/Werte-Paare. Die Default-Werte werden "
"automatisch übermittelt."
# type: SS
#. type: SS
#: en/linkcheckerrc.5:133
#: en/linkcheckerrc.5:148
#, no-wrap
msgid "[output]"
msgstr "[output]"
# type: TP
#. type: TP
#: en/linkcheckerrc.5:134
#: en/linkcheckerrc.5:149
#, no-wrap
msgid "B<interactive=>[B<0>|B<1>]"
msgstr "B<interactive=>[B<0>|B<1>]"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:139
#: en/linkcheckerrc.5:154
msgid "Command line option: B<--interactive>"
msgstr "Kommandozeilenoption: B<--interactive>"
# type: TP
#. type: TP
#: en/linkcheckerrc.5:139
#: en/linkcheckerrc.5:154
#, no-wrap
msgid "B<debug=>I<STRING>[B<,>I<STRING>...]"
msgstr "B<debug=>I<STRING>[B<,>I<STRING>...]"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:145
#: en/linkcheckerrc.5:160
msgid ""
"Print debugging output for the given loggers. Available loggers are "
"B<cmdline>, B<checking>, B<cache>, B<gui>, B<dns>, B<thread> and B<all>. "
@ -2259,52 +2317,52 @@ msgstr ""
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:147
#: en/linkcheckerrc.5:162
msgid "Command line option: B<--debug>"
msgstr "[output]"
# type: TP
#. type: TP
#: en/linkcheckerrc.5:147
#: en/linkcheckerrc.5:162
#, no-wrap
msgid "B<status=>[B<0>|B<1>]"
msgstr "B<status=>[B<0>|B<1>]"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:150
#: en/linkcheckerrc.5:165
msgid "Control printing check status messages. Default is 1."
msgstr "Kontrolle der Statusmeldungen. Standard ist 1."
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:152
#: en/linkcheckerrc.5:167
msgid "Command line option: B<--no-status>"
msgstr "Kommandozeilenoption: B<--no-status>"
# type: TP
#. type: TP
#: en/linkcheckerrc.5:152
#: en/linkcheckerrc.5:167
#, no-wrap
msgid "B<log=>I<TYPE>[B</>I<ENCODING>]"
msgstr "B<log=>I<TYPE>[B</>I<ENCODING>]"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:164
#: en/linkcheckerrc.5:179
msgid "Command line option: B<--output>"
msgstr "Kommandozeilenoption: B<--output>"
# type: TP
#. type: TP
#: en/linkcheckerrc.5:164
#: en/linkcheckerrc.5:179
#, no-wrap
msgid "B<verbose=>[B<0>|B<1>]"
msgstr "B<verbose=>[B<0>|B<1>]"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:167
#: en/linkcheckerrc.5:182
msgid ""
"If set log all checked URLs once. Default is to log only errors and warnings."
msgstr ""
@ -2313,20 +2371,20 @@ msgstr ""
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:169 en/linkcheckerrc.5:186
#: en/linkcheckerrc.5:184 en/linkcheckerrc.5:201
msgid "Command line option: B<--verbose>"
msgstr "Kommandozeilenoption: B<--verbose>"
# type: TP
#. type: TP
#: en/linkcheckerrc.5:169
#: en/linkcheckerrc.5:184
#, no-wrap
msgid "B<complete=>[B<0>|B<1>]"
msgstr "B<complete=>[B<0>|B<1>]"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:173
#: en/linkcheckerrc.5:188
msgid ""
"If set log all checked URLs, even duplicates. Default is to log duplicate "
"URLs only once."
@ -2336,20 +2394,20 @@ msgstr ""
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:175
#: en/linkcheckerrc.5:190
msgid "Command line option: B<--complete>"
msgstr "Kommandozeilenoption: B<--complete>"
# type: TP
#. type: TP
#: en/linkcheckerrc.5:175
#: en/linkcheckerrc.5:190
#, no-wrap
msgid "B<warnings=>[B<0>|B<1>]"
msgstr "B<warnings=>[B<0>|B<1>]"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:178
#: en/linkcheckerrc.5:193
msgid "If set log warnings. Default is to log warnings."
msgstr ""
"Falls gesetzt, gebe keine Warnungen aus. Standard ist die Ausgabe von "
@ -2357,20 +2415,20 @@ msgstr ""
# type: TP
#. type: Plain text
#: en/linkcheckerrc.5:180
#: en/linkcheckerrc.5:195
msgid "Command line option: B<--no-warnings>"
msgstr "Kommandozeilenoption: B<--no-warnings>"
# type: TP
#. type: TP
#: en/linkcheckerrc.5:180
#: en/linkcheckerrc.5:195
#, no-wrap
msgid "B<quiet=>[B<0>|B<1>]"
msgstr "B<quiet=>[B<0>|B<1>]"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:184
#: en/linkcheckerrc.5:199
msgid ""
"If set, operate quiet. An alias for B<log=none>. This is only useful with "
"B<fileoutput>."
@ -2380,14 +2438,14 @@ msgstr ""
# type: TP
#. type: TP
#: en/linkcheckerrc.5:186
#: en/linkcheckerrc.5:201
#, no-wrap
msgid "B<fileoutput=>I<TYPE>[B<,>I<TYPE>...]"
msgstr "B<fileoutput=>I<TYPE>[B<,>I<TYPE>...]"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:191
#: en/linkcheckerrc.5:206
msgid ""
"Output to a files B<linkchecker-out.>I<TYPE>, B<$HOME/.linkchecker/"
"blacklist> for B<blacklist> output."
@ -2397,7 +2455,7 @@ msgstr ""
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:197
#: en/linkcheckerrc.5:212
msgid ""
"Valid file output types are B<text>, B<html>, B<sql>, B<csv>, B<gml>, "
"B<dot>, B<xml>, B<none> or B<blacklist> Default is no file output. The "
@ -2411,29 +2469,29 @@ msgstr ""
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:199
#: en/linkcheckerrc.5:214
msgid "Command line option: B<--file-output>"
msgstr "Kommandozeilenoption: B<--file-output>"
# type: TP
#. type: SS
#: en/linkcheckerrc.5:199
#: en/linkcheckerrc.5:214
#, no-wrap
msgid "[text]"
msgstr "[text]"
# type: TP
#. type: TP
#: en/linkcheckerrc.5:200 en/linkcheckerrc.5:262 en/linkcheckerrc.5:272
#: en/linkcheckerrc.5:282 en/linkcheckerrc.5:298 en/linkcheckerrc.5:314
#: en/linkcheckerrc.5:345 en/linkcheckerrc.5:352 en/linkcheckerrc.5:362
#: en/linkcheckerrc.5:215 en/linkcheckerrc.5:277 en/linkcheckerrc.5:287
#: en/linkcheckerrc.5:297 en/linkcheckerrc.5:313 en/linkcheckerrc.5:329
#: en/linkcheckerrc.5:360 en/linkcheckerrc.5:367 en/linkcheckerrc.5:377
#, no-wrap
msgid "B<filename=>I<STRING>"
msgstr "B<filename=>I<STRING>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:204
#: en/linkcheckerrc.5:219
msgid ""
"Specify output filename for text logging. Default filename is B<linkchecker-"
"out.txt>."
@ -2443,22 +2501,22 @@ msgstr ""
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:206
#: en/linkcheckerrc.5:221
msgid "Command line option: B<--file-output=>"
msgstr "Kommandozeilenoption: B<--file-output=>"
# type: TP
#. type: TP
#: en/linkcheckerrc.5:206 en/linkcheckerrc.5:265 en/linkcheckerrc.5:275
#: en/linkcheckerrc.5:285 en/linkcheckerrc.5:301 en/linkcheckerrc.5:317
#: en/linkcheckerrc.5:355 en/linkcheckerrc.5:365
#: en/linkcheckerrc.5:221 en/linkcheckerrc.5:280 en/linkcheckerrc.5:290
#: en/linkcheckerrc.5:300 en/linkcheckerrc.5:316 en/linkcheckerrc.5:332
#: en/linkcheckerrc.5:370 en/linkcheckerrc.5:380
#, no-wrap
msgid "B<parts=>I<STRING>"
msgstr "B<parts=>I<STRING>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:210
#: en/linkcheckerrc.5:225
msgid ""
"Comma-separated list of parts that have to be logged. See B<LOGGER PARTS> "
"below."
@ -2468,16 +2526,16 @@ msgstr ""
# type: TP
#. type: TP
#: en/linkcheckerrc.5:212 en/linkcheckerrc.5:268 en/linkcheckerrc.5:278
#: en/linkcheckerrc.5:288 en/linkcheckerrc.5:304 en/linkcheckerrc.5:320
#: en/linkcheckerrc.5:348 en/linkcheckerrc.5:358 en/linkcheckerrc.5:368
#: en/linkcheckerrc.5:227 en/linkcheckerrc.5:283 en/linkcheckerrc.5:293
#: en/linkcheckerrc.5:303 en/linkcheckerrc.5:319 en/linkcheckerrc.5:335
#: en/linkcheckerrc.5:363 en/linkcheckerrc.5:373 en/linkcheckerrc.5:383
#, no-wrap
msgid "B<encoding=>I<STRING>"
msgstr "B<encoding=>I<STRING>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:217
#: en/linkcheckerrc.5:232
msgid ""
"Valid encodings are listed in B<http://docs.python.org/library/codecs."
"html#standard-encodings>. Default encoding is B<iso-8859-15>."
@ -2488,14 +2546,14 @@ msgstr ""
# type: TP
#. type: TP
#: en/linkcheckerrc.5:217
#: en/linkcheckerrc.5:232
#, no-wrap
msgid "I<color*>"
msgstr "I<color*>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:226
#: en/linkcheckerrc.5:241
msgid ""
"Color settings for the various log parts, syntax is I<color> or I<type>B<;"
">I<color>. The I<type> can be B<bold>, B<light>, B<blink>, B<invert>. The "
@ -2511,363 +2569,363 @@ msgstr ""
# type: TP
#. type: TP
#: en/linkcheckerrc.5:228
#: en/linkcheckerrc.5:243
#, no-wrap
msgid "B<colorparent=>I<STRING>"
msgstr "B<colorparent=>I<STRING>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:231
#: en/linkcheckerrc.5:246
msgid "Set parent color. Default is B<white>."
msgstr "Setze Farbe des Vaters. Standard ist B<white>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:231
#: en/linkcheckerrc.5:246
#, no-wrap
msgid "B<colorurl=>I<STRING>"
msgstr "B<colorurl=>I<STRING>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:234
#: en/linkcheckerrc.5:249
msgid "Set URL color. Default is B<default>."
msgstr "Setze URL Farbe. Standard ist B<default>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:234
#: en/linkcheckerrc.5:249
#, no-wrap
msgid "B<colorname=>I<STRING>"
msgstr "B<colorname=>I<STRING>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:237
#: en/linkcheckerrc.5:252
msgid "Set name color. Default is B<default>."
msgstr "Kommandozeilenoption: B<--file-output=>"
# type: TP
#. type: TP
#: en/linkcheckerrc.5:237
#: en/linkcheckerrc.5:252
#, no-wrap
msgid "B<colorreal=>I<STRING>"
msgstr "B<colorreal=>I<STRING>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:240
#: en/linkcheckerrc.5:255
msgid "Set real URL color. Default is B<cyan>."
msgstr "Setze Farbe für tatsächliche URL. Default ist B<cyan>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:240
#: en/linkcheckerrc.5:255
#, no-wrap
msgid "B<colorbase=>I<STRING>"
msgstr "B<colorbase=>I<STRING>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:243
#: en/linkcheckerrc.5:258
msgid "Set base URL color. Default is B<purple>."
msgstr "Setzt Basisurl Farbe. Standard ist B<purple>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:243
#: en/linkcheckerrc.5:258
#, no-wrap
msgid "B<colorvalid=>I<STRING>"
msgstr "B<colorvalid=>I<STRING>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:246
#: en/linkcheckerrc.5:261
msgid "Set valid color. Default is B<bold;green>."
msgstr "Setze gültige Farbe. Standard ist B<bold;green>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:246
#: en/linkcheckerrc.5:261
#, no-wrap
msgid "B<colorinvalid=>I<STRING>"
msgstr "B<colorinvalid=>I<STRING>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:249
#: en/linkcheckerrc.5:264
msgid "Set invalid color. Default is B<bold;red>."
msgstr "Setze ungültige Farbe. Standard ist B<bold;red>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:249
#: en/linkcheckerrc.5:264
#, no-wrap
msgid "B<colorinfo=>I<STRING>"
msgstr "B<colorinfo=>I<STRING>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:252
#: en/linkcheckerrc.5:267
msgid "Set info color. Default is B<default>."
msgstr "Setzt Informationsfarbe. Standard ist B<default>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:252
#: en/linkcheckerrc.5:267
#, no-wrap
msgid "B<colorwarning=>I<STRING>"
msgstr "B<colorwarning=>I<STRING>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:255
#: en/linkcheckerrc.5:270
msgid "Set warning color. Default is B<bold;yellow>."
msgstr "Setze Warnfarbe. Standard ist B<bold;yellow>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:255
#: en/linkcheckerrc.5:270
#, no-wrap
msgid "B<colordltime=>I<STRING>"
msgstr "B<colordltime=>I<STRING>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:258
#: en/linkcheckerrc.5:273
msgid "Set download time color. Default is B<default>."
msgstr "Setze Downloadzeitfarbe. Standard ist B<default>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:258
#: en/linkcheckerrc.5:273
#, no-wrap
msgid "B<colorreset=>I<STRING>"
msgstr "B<colorreset=>I<STRING>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:261
#: en/linkcheckerrc.5:276
msgid "Set reset color. Default is B<deault>."
msgstr "Setze Reset Farbe. Standard ist B<default>."
# type: SS
#. type: SS
#: en/linkcheckerrc.5:261
#: en/linkcheckerrc.5:276
#, no-wrap
msgid "[gml]"
msgstr "[gml]"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:265 en/linkcheckerrc.5:268 en/linkcheckerrc.5:271
#: en/linkcheckerrc.5:275 en/linkcheckerrc.5:278 en/linkcheckerrc.5:281
#: en/linkcheckerrc.5:285 en/linkcheckerrc.5:288 en/linkcheckerrc.5:291
#: en/linkcheckerrc.5:301 en/linkcheckerrc.5:304 en/linkcheckerrc.5:307
#: en/linkcheckerrc.5:317 en/linkcheckerrc.5:320 en/linkcheckerrc.5:323
#: en/linkcheckerrc.5:348 en/linkcheckerrc.5:351 en/linkcheckerrc.5:355
#: en/linkcheckerrc.5:358 en/linkcheckerrc.5:361 en/linkcheckerrc.5:365
#: en/linkcheckerrc.5:368 en/linkcheckerrc.5:371
#: en/linkcheckerrc.5:280 en/linkcheckerrc.5:283 en/linkcheckerrc.5:286
#: en/linkcheckerrc.5:290 en/linkcheckerrc.5:293 en/linkcheckerrc.5:296
#: en/linkcheckerrc.5:300 en/linkcheckerrc.5:303 en/linkcheckerrc.5:306
#: en/linkcheckerrc.5:316 en/linkcheckerrc.5:319 en/linkcheckerrc.5:322
#: en/linkcheckerrc.5:332 en/linkcheckerrc.5:335 en/linkcheckerrc.5:338
#: en/linkcheckerrc.5:363 en/linkcheckerrc.5:366 en/linkcheckerrc.5:370
#: en/linkcheckerrc.5:373 en/linkcheckerrc.5:376 en/linkcheckerrc.5:380
#: en/linkcheckerrc.5:383 en/linkcheckerrc.5:386
msgid "See [text] section above."
msgstr "Siehe [text] Sektion weiter oben."
# type: SS
#. type: SS
#: en/linkcheckerrc.5:271
#: en/linkcheckerrc.5:286
#, no-wrap
msgid "[dot]"
msgstr "[dot]"
# type: SS
#. type: SS
#: en/linkcheckerrc.5:281
#: en/linkcheckerrc.5:296
#, no-wrap
msgid "[csv]"
msgstr "[csv]"
# type: TP
#. type: TP
#: en/linkcheckerrc.5:291 en/linkcheckerrc.5:310
#: en/linkcheckerrc.5:306 en/linkcheckerrc.5:325
#, no-wrap
msgid "B<separator=>I<CHAR>"
msgstr "B<separator=>I<CHAR>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:294
#: en/linkcheckerrc.5:309
msgid "Set CSV separator. Default is a comma (B<,>)."
msgstr "Das CSV Trennzeichen. Standard ist Komma (B<,>)."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:294
#: en/linkcheckerrc.5:309
#, no-wrap
msgid "B<quotechar=>I<CHAR>"
msgstr "B<quotechar=>I<CHAR>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:297
#: en/linkcheckerrc.5:312
msgid "Set CSV quote character. Default is a double quote (B<\">)."
msgstr ""
"Setze CSV Quotezeichen. Standard ist das doppelte Anführungszeichen (B<\">)."
# type: SS
#. type: SS
#: en/linkcheckerrc.5:297
#: en/linkcheckerrc.5:312
#, no-wrap
msgid "[sql]"
msgstr "[sql]"
# type: TP
#. type: TP
#: en/linkcheckerrc.5:307
#: en/linkcheckerrc.5:322
#, no-wrap
msgid "B<dbname=>I<STRING>"
msgstr "B<dbname=>I<STRING>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:310
#: en/linkcheckerrc.5:325
msgid "Set database name to store into. Default is B<linksdb>."
msgstr "Setze Datenbankname zum Speichern. Standard ist B<linksdb>."
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:313
#: en/linkcheckerrc.5:328
msgid "Set SQL command separator character. Default is a semicolor (B<;>)."
msgstr "Setze SQL Kommandotrennzeichen. Standard ist ein Strichpunkt (B<;>)."
# type: TP
#. type: SS
#: en/linkcheckerrc.5:313
#: en/linkcheckerrc.5:328
#, no-wrap
msgid "[html]"
msgstr "[html]"
# type: TP
#. type: TP
#: en/linkcheckerrc.5:323
#: en/linkcheckerrc.5:338
#, no-wrap
msgid "B<colorbackground=>I<COLOR>"
msgstr "B<colorbackground=>I<COLOR>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:326
#: en/linkcheckerrc.5:341
msgid "Set HTML background color. Default is B<#fff7e5>."
msgstr "Setze Reset Farbe. Standard ist B<default>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:326
#: en/linkcheckerrc.5:341
#, no-wrap
msgid "B<colorurl=>"
msgstr "B<colorurl=>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:329
#: en/linkcheckerrc.5:344
msgid "Set HTML URL color. Default is B<#dcd5cf>."
msgstr "Setze HTML URL Farbe. Standard ist B<#dcd5cf>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:329
#: en/linkcheckerrc.5:344
#, no-wrap
msgid "B<colorborder=>"
msgstr "B<colorborder=>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:332
#: en/linkcheckerrc.5:347
msgid "Set HTML border color. Default is B<#000000>."
msgstr "Setze HTML Rahmenfarbe. Standard ist B<#000000>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:332
#: en/linkcheckerrc.5:347
#, no-wrap
msgid "B<colorlink=>"
msgstr "B<colorlink=>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:335
#: en/linkcheckerrc.5:350
msgid "Set HTML link color. Default is B<#191c83>."
msgstr "Setze HTML Verknüpfungsfarbe. Standard ist B<#191c83>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:335
#: en/linkcheckerrc.5:350
#, no-wrap
msgid "B<colorwarning=>"
msgstr "B<colorwarning=>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:338
#: en/linkcheckerrc.5:353
msgid "Set HTML warning color. Default is B<#e0954e>."
msgstr "Setze HTML Warnfarbe. Standard ist B<#e0954e>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:338
#: en/linkcheckerrc.5:353
#, no-wrap
msgid "B<colorerror=>"
msgstr "B<colorerror=>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:341
#: en/linkcheckerrc.5:356
msgid "Set HTML error color. Default is B<#db4930>."
msgstr "Setze HTML Fehlerfarbe. Standard ist B<#db4930>."
# type: TP
#. type: TP
#: en/linkcheckerrc.5:341
#: en/linkcheckerrc.5:356
#, no-wrap
msgid "B<colorok=>"
msgstr "B<colorok=>"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:344
#: en/linkcheckerrc.5:359
msgid "Set HTML valid color. Default is B<#3ba557>."
msgstr "Setze HTML Gültigkeitsfarbe. Standard ist B<#3ba557>."
# type: TP
#. type: SS
#: en/linkcheckerrc.5:344
#: en/linkcheckerrc.5:359
#, no-wrap
msgid "[blacklist]"
msgstr "[blacklist]"
# type: SS
#. type: SS
#: en/linkcheckerrc.5:351
#: en/linkcheckerrc.5:366
#, no-wrap
msgid "[xml]"
msgstr "[xml]"
# type: TP
#. type: SS
#: en/linkcheckerrc.5:361
#: en/linkcheckerrc.5:376
#, no-wrap
msgid "[gxml]"
msgstr "[gxml]"
# type: SH
#. type: SH
#: en/linkcheckerrc.5:372
#: en/linkcheckerrc.5:387
#, no-wrap
msgid "LOGGER PARTS"
msgstr "AUSGABE PARTS"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:388
#: en/linkcheckerrc.5:403
#, no-wrap
msgid ""
" B<all> (for all parts)\n"
@ -2904,14 +2962,14 @@ msgstr ""
# type: SH
#. type: SH
#: en/linkcheckerrc.5:388
#: en/linkcheckerrc.5:403
#, no-wrap
msgid "MULTILINE"
msgstr "MULTILINE"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:392
#: en/linkcheckerrc.5:407
msgid ""
"Some option values can span multiple lines. Each line has to be indented for "
"that to work. Lines starting with a hash (B<#>) will be ignored, though they "
@ -2923,7 +2981,7 @@ msgstr ""
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:398
#: en/linkcheckerrc.5:413
#, no-wrap
msgid ""
" ignore=\n"
@ -2939,14 +2997,14 @@ msgstr ""
# type: SH
#. type: SH
#: en/linkcheckerrc.5:399
#: en/linkcheckerrc.5:414
#, no-wrap
msgid "EXAMPLE"
msgstr "BEISPIEL"
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:402
#: en/linkcheckerrc.5:417
#, no-wrap
msgid ""
" [output]\n"
@ -2957,7 +3015,7 @@ msgstr ""
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:405
#: en/linkcheckerrc.5:420
#, no-wrap
msgid ""
" [checking]\n"
@ -2968,7 +3026,7 @@ msgstr ""
# type: Plain text
#. type: Plain text
#: en/linkcheckerrc.5:408
#: en/linkcheckerrc.5:423
#, no-wrap
msgid ""
" [filtering]\n"
@ -2979,7 +3037,7 @@ msgstr ""
# type: TH
#. type: Plain text
#: en/linkcheckerrc.5:411
#: en/linkcheckerrc.5:426
msgid "linkchecker(1)"
msgstr "BEISPIEL"

View file

@ -125,7 +125,7 @@ hinzuzufügen. Standard ist dass URLs der Kommandozeile als intern gelten.
Kommandozeilenoption: keine
.SS [authentication]
.TP
\fBentry=\fP\fIREGEX\fP \fIUSER\fP \fIPASS\fP (MULTILINE)
\fBentry=\fP\fIREGEX\fP \fIBENUTZER\fP \fIPASSWORT\fP (MULTILINE)
Erstelle verschiedene Benutzer/Passwort Parre für verschiedene
Verknüpfungsarten. Einträge sind ein Tripel (Verknüpfung regulärer Ausdruck,
Benutzername, Passwort), getrennt durch Leerzeichen.
@ -137,6 +137,21 @@ hier. Der erste Treffer gewinnt. Im Moment wird Authentifizierung für
http[s] und ftp Verknüpfungen benutzt.
.br
Kommandozeilenoption: \fB\-u\fP, \fB\-p\fP
.TP
\fBloginurl=\fP\fIURL\fP
Eine Anmelde\-URL, die vor der Prüfung besucht wird. Benötigt einen Eintrag
zur Authentifizierung und impliziert die Benutzung von Cookies, weil die
meisten Anmeldungen heutzutage Cookies benutzen.
.TP
\fBloginuserfield=\fP\fINAME\fP
Der Name für das Benutzer CGI\-Feld. Der Standardname ist \fBlogin\fP.
.TP
\fBloginpasswordfield=\fP\fINAME\fP
Der Name für das Passwort CGI\-Feld. Der Standardname ist \fBpassword\fP.
.TP
\fBloginextrafields=\fP\fINAME\fP\fB:\fP\fIWERT\fP (MULTILINE)
Optional zusätzliche CGI Namen/Werte\-Paare. Die Default\-Werte werden
automatisch übermittelt.
.SS [output]
.TP
\fBinteractive=\fP[\fB0\fP|\fB1\fP]

View file

@ -130,6 +130,21 @@ match wins. At the moment, authentication is used/needed for
http[s] and ftp links.
.br
Command line option: \fB\-u\fP, \fB\-p\fP
.TP
\fBloginurl=\fP\fIURL\fP
A login URL to be visited before checking. Also needs authentication
data set for it, and implies using cookies because most logins use
cookies nowadays.
.TP
\fBloginuserfield=\fP\fISTRING\fP
The name of the user CGI field. Default name is \fBlogin\fP.
.TP
\fBloginpasswordfield=\fP\fISTRING\fP
The name of the password CGI field. Default name is \fBpassword\fP.
.TP
\fBloginextrafields=\fP\fINAME\fP\fB:\fP\fIVALUE\fP (MULTILINE)
Optionally any additional CGI name/value pairs. Note that the default
values are submitted automatically.
.SS \fB[output]\fP
.TP
\fBinteractive=\fP[\fB0\fP|\fB1\fP]

View file

@ -39,6 +39,9 @@ Requirements for Unix/Linux or Mac OS X
6. *Optional, used for Virus checking:*
ClamAv from http://www.clamav.net/
7. *Optional, used for login form submission:*
Twill from http://twill.idyll.org/
Requirements for Windows
------------------------
@ -113,22 +116,23 @@ Setup for Windows - compiling from source:
ClamAv from http://www.sosdg.org/clamav-win32/
[http://clamav-sosdg.googlecode.com/files/clamav-0.95-1a.exe]
5. *Optional, for country code display:*
5. *Optional, for displaying country codes:*
Pygeoip from http://code.google.com/p/pygeoip/
[http://pygeoip.googlecode.com/files/pygeoip-0.1.3-py2.6.egg]
6. The MinGW suite from http://mingw.sourceforge.net/
6. *Optional, used for login form submission:*
Twill from http://twill.idyll.org/
7. The MinGW suite from http://mingw.sourceforge.net/
[http://sourceforge.net/projects/mingw/files/Automated%20MinGW%20Installer/mingw-get-inst/mingw-get-inst-20100909/mingw-get-inst-20100909.exe/download]
7. Install InnoSetup from http://www.jrsoftware.org/isinfo.php
8. Install InnoSetup from http://www.jrsoftware.org/isinfo.php
[http://www.jrsoftware.org/download.php/is.exe]
8. Generate and execute the LinkChecker installer
9. Generate and execute the LinkChecker installer
Close the MSYS application (by typing ``exit``) and open a DOS command
prompt.
Change to the ``linkchecker-X.Y`` directory and run
``scripts\bdist.bat`` to build a binary installer.
``dist.bat`` to build a binary installer.
This generates a binary installer
``dist\LinkChecker-X.Y.exe`` which you just have to execute.

View file

@ -7,7 +7,7 @@
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"POT-Creation-Date: 2010-10-12 00:31+0300\n"
"POT-Creation-Date: 2010-10-14 18:25+0300\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@ -194,7 +194,7 @@ msgid "B<-I>, B<--interactive>"
msgstr ""
#. type: Plain text
#: en/linkchecker.1:65 en/linkcheckerrc.5:137
#: en/linkchecker.1:65 en/linkcheckerrc.5:152
msgid "Ask for URL if none are given on the commandline."
msgstr ""
@ -405,7 +405,7 @@ msgid "B<-o>I<TYPE>[B</>I<ENCODING>], B<--output=>I<TYPE>[B</>I<ENCODING>]"
msgstr ""
#. type: Plain text
#: en/linkchecker.1:130 en/linkcheckerrc.5:158
#: en/linkchecker.1:130 en/linkcheckerrc.5:173
msgid ""
"Specify output type as B<text>, B<html>, B<sql>, B<csv>, B<gml>, B<dot>, "
"B<xml>, B<none> or B<blacklist>. Default type is B<text>. The various "
@ -413,7 +413,7 @@ msgid ""
msgstr ""
#. type: Plain text
#: en/linkchecker.1:134 en/linkcheckerrc.5:162
#: en/linkchecker.1:134 en/linkcheckerrc.5:177
msgid ""
"The I<ENCODING> specifies the output encoding, the default is that of your "
"locale. Valid encodings are listed at "
@ -1399,7 +1399,7 @@ msgid ""
msgstr ""
#. type: SH
#: en/linkchecker.1:530 en/linkcheckerrc.5:409 en/linkchecker-gui.1:11
#: en/linkchecker.1:530 en/linkcheckerrc.5:424 en/linkchecker-gui.1:11
#, no-wrap
msgid "SEE ALSO"
msgstr ""
@ -1410,24 +1410,24 @@ msgid "B<linkcheckerrc>(5)"
msgstr ""
#. type: SH
#: en/linkchecker.1:533 en/linkcheckerrc.5:412 en/linkchecker-gui.1:14
#: en/linkchecker.1:533 en/linkcheckerrc.5:427 en/linkchecker-gui.1:14
#, no-wrap
msgid "AUTHOR"
msgstr ""
#. type: Plain text
#: en/linkchecker.1:535 en/linkcheckerrc.5:414 en/linkchecker-gui.1:16
#: en/linkchecker.1:535 en/linkcheckerrc.5:429 en/linkchecker-gui.1:16
msgid "Bastian Kleineidam E<lt>calvin@users.sourceforge.netE<gt>"
msgstr ""
#. type: SH
#: en/linkchecker.1:536 en/linkcheckerrc.5:415 en/linkchecker-gui.1:17
#: en/linkchecker.1:536 en/linkcheckerrc.5:430 en/linkchecker-gui.1:17
#, no-wrap
msgid "COPYRIGHT"
msgstr ""
#. type: Plain text
#: en/linkchecker.1:537 en/linkcheckerrc.5:416
#: en/linkchecker.1:537 en/linkcheckerrc.5:431
msgid "Copyright \\(co 2000-2010 Bastian Kleineidam"
msgstr ""
@ -1611,7 +1611,7 @@ msgid "Filename of B<clamd.conf> config file."
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:90 en/linkcheckerrc.5:113 en/linkcheckerrc.5:119 en/linkcheckerrc.5:212 en/linkcheckerrc.5:228
#: en/linkcheckerrc.5:90 en/linkcheckerrc.5:113 en/linkcheckerrc.5:119 en/linkcheckerrc.5:227 en/linkcheckerrc.5:243
msgid "Command line option: none"
msgstr ""
@ -1729,31 +1729,80 @@ msgstr ""
msgid "Command line option: B<-u>, B<-p>"
msgstr ""
#. type: SS
#. type: TP
#: en/linkcheckerrc.5:133
#, no-wrap
msgid "B<loginurl=>I<URL>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:138
msgid ""
"A login URL to be visited before checking. Also needs authentication data "
"set for it, and implies using cookies because most logins use cookies "
"nowadays."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:138
#, no-wrap
msgid "B<loginuserfield=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:141
msgid "The name of the user CGI field. Default name is B<login>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:141
#, no-wrap
msgid "B<loginpasswordfield=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:144
msgid "The name of the password CGI field. Default name is B<password>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:144
#, no-wrap
msgid "B<loginextrafields=>I<NAME>B<:>I<VALUE> (MULTILINE)"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:148
msgid ""
"Optionally any additional CGI name/value pairs. Note that the default values "
"are submitted automatically."
msgstr ""
#. type: SS
#: en/linkcheckerrc.5:148
#, no-wrap
msgid "[output]"
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:134
#: en/linkcheckerrc.5:149
#, no-wrap
msgid "B<interactive=>[B<0>|B<1>]"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:139
#: en/linkcheckerrc.5:154
msgid "Command line option: B<--interactive>"
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:139
#: en/linkcheckerrc.5:154
#, no-wrap
msgid "B<debug=>I<STRING>[B<,>I<STRING>...]"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:145
#: en/linkcheckerrc.5:160
msgid ""
"Print debugging output for the given loggers. Available loggers are "
"B<cmdline>, B<checking>, B<cache>, B<gui>, B<dns>, B<thread> and B<all>. "
@ -1761,117 +1810,117 @@ msgid ""
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:147
#: en/linkcheckerrc.5:162
msgid "Command line option: B<--debug>"
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:147
#: en/linkcheckerrc.5:162
#, no-wrap
msgid "B<status=>[B<0>|B<1>]"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:150
#: en/linkcheckerrc.5:165
msgid "Control printing check status messages. Default is 1."
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:152
#: en/linkcheckerrc.5:167
msgid "Command line option: B<--no-status>"
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:152
#: en/linkcheckerrc.5:167
#, no-wrap
msgid "B<log=>I<TYPE>[B</>I<ENCODING>]"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:164
#: en/linkcheckerrc.5:179
msgid "Command line option: B<--output>"
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:164
#: en/linkcheckerrc.5:179
#, no-wrap
msgid "B<verbose=>[B<0>|B<1>]"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:167
#: en/linkcheckerrc.5:182
msgid ""
"If set log all checked URLs once. Default is to log only errors and "
"warnings."
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:169 en/linkcheckerrc.5:186
#: en/linkcheckerrc.5:184 en/linkcheckerrc.5:201
msgid "Command line option: B<--verbose>"
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:169
#: en/linkcheckerrc.5:184
#, no-wrap
msgid "B<complete=>[B<0>|B<1>]"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:173
#: en/linkcheckerrc.5:188
msgid ""
"If set log all checked URLs, even duplicates. Default is to log duplicate "
"URLs only once."
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:175
#: en/linkcheckerrc.5:190
msgid "Command line option: B<--complete>"
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:175
#: en/linkcheckerrc.5:190
#, no-wrap
msgid "B<warnings=>[B<0>|B<1>]"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:178
#: en/linkcheckerrc.5:193
msgid "If set log warnings. Default is to log warnings."
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:180
#: en/linkcheckerrc.5:195
msgid "Command line option: B<--no-warnings>"
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:180
#: en/linkcheckerrc.5:195
#, no-wrap
msgid "B<quiet=>[B<0>|B<1>]"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:184
#: en/linkcheckerrc.5:199
msgid ""
"If set, operate quiet. An alias for B<log=none>. This is only useful with "
"B<fileoutput>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:186
#: en/linkcheckerrc.5:201
#, no-wrap
msgid "B<fileoutput=>I<TYPE>[B<,>I<TYPE>...]"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:191
#: en/linkcheckerrc.5:206
msgid ""
"Output to a files B<linkchecker-out.>I<TYPE>, "
"B<$HOME/.linkchecker/blacklist> for B<blacklist> output."
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:197
#: en/linkcheckerrc.5:212
msgid ""
"Valid file output types are B<text>, B<html>, B<sql>, B<csv>, B<gml>, "
"B<dot>, B<xml>, B<none> or B<blacklist> Default is no file output. The "
@ -1880,55 +1929,55 @@ msgid ""
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:199
#: en/linkcheckerrc.5:214
msgid "Command line option: B<--file-output>"
msgstr ""
#. type: SS
#: en/linkcheckerrc.5:199
#: en/linkcheckerrc.5:214
#, no-wrap
msgid "[text]"
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:200 en/linkcheckerrc.5:262 en/linkcheckerrc.5:272 en/linkcheckerrc.5:282 en/linkcheckerrc.5:298 en/linkcheckerrc.5:314 en/linkcheckerrc.5:345 en/linkcheckerrc.5:352 en/linkcheckerrc.5:362
#: en/linkcheckerrc.5:215 en/linkcheckerrc.5:277 en/linkcheckerrc.5:287 en/linkcheckerrc.5:297 en/linkcheckerrc.5:313 en/linkcheckerrc.5:329 en/linkcheckerrc.5:360 en/linkcheckerrc.5:367 en/linkcheckerrc.5:377
#, no-wrap
msgid "B<filename=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:204
#: en/linkcheckerrc.5:219
msgid ""
"Specify output filename for text logging. Default filename is "
"B<linkchecker-out.txt>."
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:206
#: en/linkcheckerrc.5:221
msgid "Command line option: B<--file-output=>"
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:206 en/linkcheckerrc.5:265 en/linkcheckerrc.5:275 en/linkcheckerrc.5:285 en/linkcheckerrc.5:301 en/linkcheckerrc.5:317 en/linkcheckerrc.5:355 en/linkcheckerrc.5:365
#: en/linkcheckerrc.5:221 en/linkcheckerrc.5:280 en/linkcheckerrc.5:290 en/linkcheckerrc.5:300 en/linkcheckerrc.5:316 en/linkcheckerrc.5:332 en/linkcheckerrc.5:370 en/linkcheckerrc.5:380
#, no-wrap
msgid "B<parts=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:210
#: en/linkcheckerrc.5:225
msgid ""
"Comma-separated list of parts that have to be logged. See B<LOGGER PARTS> "
"below."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:212 en/linkcheckerrc.5:268 en/linkcheckerrc.5:278 en/linkcheckerrc.5:288 en/linkcheckerrc.5:304 en/linkcheckerrc.5:320 en/linkcheckerrc.5:348 en/linkcheckerrc.5:358 en/linkcheckerrc.5:368
#: en/linkcheckerrc.5:227 en/linkcheckerrc.5:283 en/linkcheckerrc.5:293 en/linkcheckerrc.5:303 en/linkcheckerrc.5:319 en/linkcheckerrc.5:335 en/linkcheckerrc.5:363 en/linkcheckerrc.5:373 en/linkcheckerrc.5:383
#, no-wrap
msgid "B<encoding=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:217
#: en/linkcheckerrc.5:232
msgid ""
"Valid encodings are listed in "
"B<http://docs.python.org/library/codecs.html#standard-encodings>. Default "
@ -1936,13 +1985,13 @@ msgid ""
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:217
#: en/linkcheckerrc.5:232
#, no-wrap
msgid "I<color*>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:226
#: en/linkcheckerrc.5:241
msgid ""
"Color settings for the various log parts, syntax is I<color> or "
"I<type>B<;>I<color>. The I<type> can be B<bold>, B<light>, B<blink>, "
@ -1952,302 +2001,302 @@ msgid ""
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:228
#: en/linkcheckerrc.5:243
#, no-wrap
msgid "B<colorparent=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:231
#: en/linkcheckerrc.5:246
msgid "Set parent color. Default is B<white>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:231
#: en/linkcheckerrc.5:246
#, no-wrap
msgid "B<colorurl=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:234
#: en/linkcheckerrc.5:249
msgid "Set URL color. Default is B<default>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:234
#: en/linkcheckerrc.5:249
#, no-wrap
msgid "B<colorname=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:237
#: en/linkcheckerrc.5:252
msgid "Set name color. Default is B<default>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:237
#: en/linkcheckerrc.5:252
#, no-wrap
msgid "B<colorreal=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:240
#: en/linkcheckerrc.5:255
msgid "Set real URL color. Default is B<cyan>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:240
#: en/linkcheckerrc.5:255
#, no-wrap
msgid "B<colorbase=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:243
#: en/linkcheckerrc.5:258
msgid "Set base URL color. Default is B<purple>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:243
#: en/linkcheckerrc.5:258
#, no-wrap
msgid "B<colorvalid=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:246
#: en/linkcheckerrc.5:261
msgid "Set valid color. Default is B<bold;green>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:246
#: en/linkcheckerrc.5:261
#, no-wrap
msgid "B<colorinvalid=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:249
#: en/linkcheckerrc.5:264
msgid "Set invalid color. Default is B<bold;red>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:249
#: en/linkcheckerrc.5:264
#, no-wrap
msgid "B<colorinfo=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:252
#: en/linkcheckerrc.5:267
msgid "Set info color. Default is B<default>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:252
#: en/linkcheckerrc.5:267
#, no-wrap
msgid "B<colorwarning=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:255
#: en/linkcheckerrc.5:270
msgid "Set warning color. Default is B<bold;yellow>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:255
#: en/linkcheckerrc.5:270
#, no-wrap
msgid "B<colordltime=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:258
#: en/linkcheckerrc.5:273
msgid "Set download time color. Default is B<default>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:258
#: en/linkcheckerrc.5:273
#, no-wrap
msgid "B<colorreset=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:261
#: en/linkcheckerrc.5:276
msgid "Set reset color. Default is B<deault>."
msgstr ""
#. type: SS
#: en/linkcheckerrc.5:261
#: en/linkcheckerrc.5:276
#, no-wrap
msgid "[gml]"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:265 en/linkcheckerrc.5:268 en/linkcheckerrc.5:271 en/linkcheckerrc.5:275 en/linkcheckerrc.5:278 en/linkcheckerrc.5:281 en/linkcheckerrc.5:285 en/linkcheckerrc.5:288 en/linkcheckerrc.5:291 en/linkcheckerrc.5:301 en/linkcheckerrc.5:304 en/linkcheckerrc.5:307 en/linkcheckerrc.5:317 en/linkcheckerrc.5:320 en/linkcheckerrc.5:323 en/linkcheckerrc.5:348 en/linkcheckerrc.5:351 en/linkcheckerrc.5:355 en/linkcheckerrc.5:358 en/linkcheckerrc.5:361 en/linkcheckerrc.5:365 en/linkcheckerrc.5:368 en/linkcheckerrc.5:371
#: en/linkcheckerrc.5:280 en/linkcheckerrc.5:283 en/linkcheckerrc.5:286 en/linkcheckerrc.5:290 en/linkcheckerrc.5:293 en/linkcheckerrc.5:296 en/linkcheckerrc.5:300 en/linkcheckerrc.5:303 en/linkcheckerrc.5:306 en/linkcheckerrc.5:316 en/linkcheckerrc.5:319 en/linkcheckerrc.5:322 en/linkcheckerrc.5:332 en/linkcheckerrc.5:335 en/linkcheckerrc.5:338 en/linkcheckerrc.5:363 en/linkcheckerrc.5:366 en/linkcheckerrc.5:370 en/linkcheckerrc.5:373 en/linkcheckerrc.5:376 en/linkcheckerrc.5:380 en/linkcheckerrc.5:383 en/linkcheckerrc.5:386
msgid "See [text] section above."
msgstr ""
#. type: SS
#: en/linkcheckerrc.5:271
#: en/linkcheckerrc.5:286
#, no-wrap
msgid "[dot]"
msgstr ""
#. type: SS
#: en/linkcheckerrc.5:281
#: en/linkcheckerrc.5:296
#, no-wrap
msgid "[csv]"
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:291 en/linkcheckerrc.5:310
#: en/linkcheckerrc.5:306 en/linkcheckerrc.5:325
#, no-wrap
msgid "B<separator=>I<CHAR>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:294
#: en/linkcheckerrc.5:309
msgid "Set CSV separator. Default is a comma (B<,>)."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:294
#: en/linkcheckerrc.5:309
#, no-wrap
msgid "B<quotechar=>I<CHAR>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:297
#: en/linkcheckerrc.5:312
msgid "Set CSV quote character. Default is a double quote (B<\">)."
msgstr ""
#. type: SS
#: en/linkcheckerrc.5:297
#: en/linkcheckerrc.5:312
#, no-wrap
msgid "[sql]"
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:307
#: en/linkcheckerrc.5:322
#, no-wrap
msgid "B<dbname=>I<STRING>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:310
#: en/linkcheckerrc.5:325
msgid "Set database name to store into. Default is B<linksdb>."
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:313
#: en/linkcheckerrc.5:328
msgid "Set SQL command separator character. Default is a semicolor (B<;>)."
msgstr ""
#. type: SS
#: en/linkcheckerrc.5:313
#: en/linkcheckerrc.5:328
#, no-wrap
msgid "[html]"
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:323
#: en/linkcheckerrc.5:338
#, no-wrap
msgid "B<colorbackground=>I<COLOR>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:326
#: en/linkcheckerrc.5:341
msgid "Set HTML background color. Default is B<#fff7e5>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:326
#: en/linkcheckerrc.5:341
#, no-wrap
msgid "B<colorurl=>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:329
#: en/linkcheckerrc.5:344
msgid "Set HTML URL color. Default is B<#dcd5cf>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:329
#: en/linkcheckerrc.5:344
#, no-wrap
msgid "B<colorborder=>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:332
#: en/linkcheckerrc.5:347
msgid "Set HTML border color. Default is B<#000000>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:332
#: en/linkcheckerrc.5:347
#, no-wrap
msgid "B<colorlink=>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:335
#: en/linkcheckerrc.5:350
msgid "Set HTML link color. Default is B<#191c83>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:335
#: en/linkcheckerrc.5:350
#, no-wrap
msgid "B<colorwarning=>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:338
#: en/linkcheckerrc.5:353
msgid "Set HTML warning color. Default is B<#e0954e>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:338
#: en/linkcheckerrc.5:353
#, no-wrap
msgid "B<colorerror=>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:341
#: en/linkcheckerrc.5:356
msgid "Set HTML error color. Default is B<#db4930>."
msgstr ""
#. type: TP
#: en/linkcheckerrc.5:341
#: en/linkcheckerrc.5:356
#, no-wrap
msgid "B<colorok=>"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:344
#: en/linkcheckerrc.5:359
msgid "Set HTML valid color. Default is B<#3ba557>."
msgstr ""
#. type: SS
#: en/linkcheckerrc.5:344
#: en/linkcheckerrc.5:359
#, no-wrap
msgid "[blacklist]"
msgstr ""
#. type: SS
#: en/linkcheckerrc.5:351
#: en/linkcheckerrc.5:366
#, no-wrap
msgid "[xml]"
msgstr ""
#. type: SS
#: en/linkcheckerrc.5:361
#: en/linkcheckerrc.5:376
#, no-wrap
msgid "[gxml]"
msgstr ""
#. type: SH
#: en/linkcheckerrc.5:372
#: en/linkcheckerrc.5:387
#, no-wrap
msgid "LOGGER PARTS"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:388
#: en/linkcheckerrc.5:403
#, no-wrap
msgid ""
" B<all> (for all parts)\n"
@ -2269,13 +2318,13 @@ msgid ""
msgstr ""
#. type: SH
#: en/linkcheckerrc.5:388
#: en/linkcheckerrc.5:403
#, no-wrap
msgid "MULTILINE"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:392
#: en/linkcheckerrc.5:407
msgid ""
"Some option values can span multiple lines. Each line has to be indented for "
"that to work. Lines starting with a hash (B<#>) will be ignored, though they "
@ -2283,7 +2332,7 @@ msgid ""
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:398
#: en/linkcheckerrc.5:413
#, no-wrap
msgid ""
" ignore=\n"
@ -2294,13 +2343,13 @@ msgid ""
msgstr ""
#. type: SH
#: en/linkcheckerrc.5:399
#: en/linkcheckerrc.5:414
#, no-wrap
msgid "EXAMPLE"
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:402
#: en/linkcheckerrc.5:417
#, no-wrap
msgid ""
" [output]\n"
@ -2308,7 +2357,7 @@ msgid ""
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:405
#: en/linkcheckerrc.5:420
#, no-wrap
msgid ""
" [checking]\n"
@ -2316,7 +2365,7 @@ msgid ""
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:408
#: en/linkcheckerrc.5:423
#, no-wrap
msgid ""
" [filtering]\n"
@ -2324,7 +2373,7 @@ msgid ""
msgstr ""
#. type: Plain text
#: en/linkcheckerrc.5:411
#: en/linkcheckerrc.5:426
msgid "linkchecker(1)"
msgstr ""

View file

@ -1,4 +1,4 @@
- [HTTP] Allow sending POST data for login at beginning of check.
- [GUI] Allow login URL to be configured.
- [GUI] Move the debug tab someplace else. Perhaps make a separate
debug window out of it that gets displayed only on demand.
- [GUI] Show detailed URL properties

View file

@ -22,6 +22,7 @@ import sys
import os
import logging.config
import urllib
import urlparse
import shutil
import _LinkChecker_configdata as configdata
from .. import (log, LOG_CHECK, LOG_ROOT, ansicolor, lognames, clamav,
@ -77,6 +78,10 @@ class Configuration (dict):
self["interactive"] = False
# on ftp, password is set by Pythons ftplib
self["authentication"] = []
self["loginurl"] = None
self["loginuserfield"] = "login"
self["loginpasswordfield"] = "password"
self["loginextrafields"] = {}
self["proxy"] = urllib.getproxies()
self["recursionlevel"] = -1
self["wait"] = 0
@ -260,6 +265,8 @@ class Configuration (dict):
self.sanitize_scanvirus()
if self['storecookies']:
self.sanitize_cookies()
if self['loginurl']:
self.sanitize_loginurl()
def sanitize_anchors (self):
if not self["warnings"]:
@ -307,6 +314,36 @@ class Configuration (dict):
"because storecookies is active."))
self['sendcookies'] = True
def sanitize_loginurl (self):
url = self["loginurl"]
disable = False
if not self["loginpasswordfield"]:
log.warn(LOG_CHECK,
_("warning: no CGI password fieldname given for login URL."))
disable = True
if not self["loginuserfield"]:
log.warn(LOG_CHECK,
_("warning: no CGI user fieldname given for login URL."))
disable = True
if self.get_user_password(url) == (None, None):
log.warn(LOG_CHECK,
_("warning: no user/password authentication data found for login URL."))
disable = True
if not url.lower().startswith(("http:", "https:")):
log.warn(LOG_CHECK, _("warning: login URL is not a HTTP URL."))
disable = True
urlparts = urlparse.urlsplit(url)
if not urlparts[0] or not urlparts[1] or not urlparts[2]:
log.warn(LOG_CHECK, _("warning: login URL is incomplete."))
disable = True
if disable:
log.warn(LOG_CHECK,
_("warning: disabling login URL %(url)s.") % {"url": url})
self["loginurl"] = None
elif not self['storecookies']:
# login URL implies storing and sending cookies
self['storecookies'] = self['sendcookies'] = True
def copy_sys_config (syspath, userpath):
"""Try to copy the system configuration to the user configuration

View file

@ -185,6 +185,24 @@ class LCConfigParser (ConfigParser.RawConfigParser, object):
'user': auth[1],
'password': auth[2]})
i += 1
# read login URL and field names
if self.has_option(section, "loginurl"):
val = self.get(section, "loginurl").strip()
if not (val.lower().startswith("http:") or
val.lower().startswith("https:")):
raise LinkCheckerError(LOG_CHECK,
_("Invalid login URL `%s'. Only " \
"HTTP and HTTPS URLs are supported.") % val)
self.config["loginurl"] = val
self.config["storecookies"] = self.config["sendcookies"] = True
for key in ("loginuserfield", "loginpasswordfield"):
if self.has_option(section, key):
self.config[key] = self.get(section, key)
# read login extra fields
if self.has_option(section, "loginextrafields"):
for val in read_multiline(self.get(section, "loginextrafields")):
name, value = val.split(":", 1)
self.config["loginextrafields"][name] = value
def read_filtering_config (self):
"""

View file

@ -351,3 +351,80 @@ def from_headers (strheader):
scheme = headers.get("Scheme", "http")
path= headers.get("Path", "/")
return (headers, scheme, host, path)
## Taken and adpated from the _mechanize package included in Twill.
def cookie_str(cookie):
"""Return string representation of Cookie."""
h = [(cookie.name, unquote(cookie.value)),
("path", cookie.path),
("domain", cookie.domain)]
if cookie.port is not None: h.append(("port", cookie.port))
#if cookie.path_specified: h.append(("path_spec", None))
#if cookie.port_specified: h.append(("port_spec", None))
#if cookie.domain_initial_dot: h.append(("domain_dot", None))
if cookie.secure: h.append(("secure", None))
if cookie.expires: h.append(("expires",
time2isoz(float(cookie.expires))))
if cookie.discard: h.append(("discard", None))
if cookie.comment: h.append(("comment", cookie.comment))
if cookie.comment_url: h.append(("commenturl", cookie.comment_url))
#if cookie.rfc2109: h.append(("rfc2109", None))
keys = cookie.nonstandard_attr_keys()
keys.sort()
for k in keys:
h.append((k, str(cookie.get_nonstandard_attr(k))))
h.append(("version", str(cookie.version)))
return join_header_words([h])
def time2isoz(t=None):
"""Return a string representing time in seconds since epoch, t.
If the function is called without an argument, it will use the current
time.
The format of the returned string is like "YYYY-MM-DD hh:mm:ssZ",
representing Universal Time (UTC, aka GMT). An example of this format is:
1994-11-24 08:49:37Z
"""
if t is None: t = time.time()
year, mon, mday, hour, min, sec = time.gmtime(t)[:6]
return "%04d-%02d-%02d %02d:%02d:%02dZ" % (
year, mon, mday, hour, min, sec)
join_escape_re = re.compile(r"([\"\\])")
def join_header_words(lists):
"""Do the inverse of the conversion done by split_header_words.
Takes a list of lists of (key, value) pairs and produces a single header
value. Attribute values are quoted if needed.
>>> join_header_words([[("text/plain", None), ("charset", "iso-8859/1")]])
'text/plain; charset="iso-8859/1"'
>>> join_header_words([[("text/plain", None)], [("charset", "iso-8859/1")]])
'text/plain, charset="iso-8859/1"'
"""
headers = []
for pairs in lists:
attr = []
for k, v in pairs:
if v is not None:
if not re.search(r"^\w+$", v):
v = join_escape_re.sub(r"\\\1", v) # escape " and \
v = '"%s"' % v
if k is None: # Netscape cookies may have no name
k = v
else:
k = "%s=%s" % (k, v)
attr.append(k)
if attr: headers.append("; ".join(attr))
return ", ".join(headers)

View file

@ -20,9 +20,87 @@ Management of checking a queue of links with several threads.
import time
import os
import thread
from .. import log, LOG_CHECK, LinkCheckerInterrupt
import urlparse
from cStringIO import StringIO
from .. import log, LOG_CHECK, LinkCheckerInterrupt, cookies, dummy
from ..cache import urlqueue, robots_txt, cookie, connection
from . import aggregator, console
from ..httplib2 import HTTPMessage
def visit_loginurl (aggregate):
"""Check for a login URL and visit it."""
config = aggregate.config
url = config["loginurl"]
if not url:
return
try:
from twill import commands as tc
except ImportError:
log.warn(LOG_CHECK, _("Could not import twill for login URL visit"))
return
log.debug(LOG_CHECK, u"Visiting login URL %s", url)
configure_twill(tc)
tc.go(url)
if tc.get_browser().get_code() != 200:
log.warn(LOG_CHECK, _("Error visiting login URL %(url)s.") % \
{"url": url})
return
submit_login_form(config, url, tc)
if tc.get_browser().get_code() != 200:
log.warn(LOG_CHECK, _("Error posting form at login URL %(url)s.") % \
{"url": url})
return
store_cookies(tc.get_browser().cj, aggregate.cookies, url)
resulturl = tc.get_browser().get_url()
log.debug(LOG_CHECK, u"URL after POST is %s" % resulturl)
# add URL to check list
if config["checkloginresult"]:
from ..checker import get_url_from
aggregate.urlqueue.put(get_url_from(resulturl, 0, aggregate))
def configure_twill (tc):
"""Configure twill to be used by LinkChecker.
Note that there is no need to set a proxy since twill uses the same
ones (provided from urllib) as LinkChecker does.
"""
# make sure readonly controls are writeable (might be needed)
tc.config("readonly_controls_writeable", True)
# fake IE 6.0 to talk sense into some sites (eg. SourceForge)
tc.agent("Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)")
# tell twill to shut up
tc.OUT = dummy.Dummy()
from twill import browser
browser.OUT = dummy.Dummy()
# set debug level
if log.is_debug(LOG_CHECK):
tc.debug("http", 1)
def submit_login_form (config, url, tc):
"""Fill and submit login form."""
user, password = config.get_user_password(url)
cgiuser = config["loginuserfield"]
cgipassword = config["loginpasswordfield"]
formname = ""
tc.formvalue(formname, cgiuser, user)
tc.formvalue(formname, cgipassword, password)
for key, value in config["loginextrafields"].items():
tc.formvalue(formname, key, value)
tc.submit()
def store_cookies (cookiejar, cookiecache, url):
"""Store cookies in cookiejar into the cookiecache."""
cookielst = []
for c in cookiejar:
cookielst.append("Set-Cookie2: %s" % cookies.cookie_str(c))
log.debug(LOG_CHECK, "Store cookies %s", cookielst)
headers = HTTPMessage(StringIO("\r\n".join(cookielst)))
urlparts = urlparse.urlsplit(url)
scheme, host, path = urlparts[0:3]
cookiecache.add(headers, scheme, host, path)
def check_urls (aggregate):
@ -30,6 +108,12 @@ def check_urls (aggregate):
with Ctrl-C.
@return: None
"""
try:
visit_loginurl(aggregate)
except Exception, msg:
log.warn(LOG_CHECK, _("Error using login URL: %(msg)s.") % \
{'msg': str(msg)})
raise
try:
aggregate.logger.start_log_output()
if not aggregate.urlqueue.empty():

View file

@ -29,8 +29,15 @@ entry=
imadoofus1 user1 pass1
# IMADOOFUS
imadoofus2 user2 pass2
http://www.example.com/ user3 pass3
entry1=oldimadoofus1 user1 pass1
entry2=oldimadoofus2 user2 pass2
loginurl=http://www.example.com/
loginuserfield=mylogin
loginpasswordfield=mypassword
loginextrafields=
name1:value1
name 2:value 2
[output]
interactive=1

View file

@ -63,6 +63,12 @@ class TestConfig (unittest.TestCase):
for suffix in ("1", "2"):
key = "%simadoofus%s" % (prefix, suffix)
self.assertTrue(key in patterns)
self.assertEqual(config["loginurl"], "http://www.example.com/")
self.assertEqual(config["loginuserfield"], "mylogin")
self.assertEqual(config["loginpasswordfield"], "mypassword")
self.assertEqual(config["loginextrafields"]["name1"], "value1")
self.assertEqual(config["loginextrafields"]["name 2"], "value 2")
self.assertEqual(len(config["loginextrafields"]), 2)
# output section
self.assertTrue(config["interactive"])
self.assertTrue(linkcheck.log.is_debug(linkcheck.LOG_THREAD))