1 /* 2 * $LynxId: userdefs.h,v 1.274 2013/06/12 09:20:28 tom Exp $ 3 * 4 * Lynx - Hypertext navigation system 5 * 6 * (c) Copyright 1992, 1993, 1994 University of Kansas 7 * 1995, 1996: GNU General Public License 8 * 9 * Copyrights 1996-2007 Lynx Developers Group 10 * Note: GNU General Public License is not a copyright. 11 */ 12 13 /******************************************************************* 14 * There are four sections to this document: 15 * Section 1. Things you MUST verify. Unix platforms use a configure 16 * script to provide sensible default values. If your site 17 * has special requirements, that may not be sufficient. 18 * For non-Unix platforms (e.g., VMS), there is no 19 * configure script, so the defaults here are more 20 * critical. 21 * Section 1a) VMS specific things 22 * Section 1b) non-VMS specific things 23 * Section 1c) ALL Platforms 24 * 25 * Section 2. Things you should probably check! 26 * 27 * Section 3. Things you should only change after you have a good 28 * understanding of the program! 29 * 30 * Section 4. Things you MUST check only if you plan to use Lynx in 31 * an anonymous account (allow public access to Lynx)! 32 * 33 */ 34 35 #ifndef USERDEFS_H 36 #define USERDEFS_H 37 38 /******************************************************************* 39 * Insure definition of NOT_ASCII, etc. precedes use below. 40 */ 41 #ifndef HTUTILS_H 42 #include <HTUtils.h> 43 #endif 44 45 #ifdef HAVE_CONFIG_H 46 #include <lynx_cfg.h> 47 #endif 48 49 /******************************************************************* 50 * Things you must change 51 * Section 1. 52 */ 53 54 /******************************************************************* 55 * Things you must change - VMS specific 56 * Section 1a). 57 */ 58 #ifdef VMS 59 /************************** 60 * TEMP_SPACE is where Lynx temporary cache files will be placed. 61 * Temporary files are removed automatically as long as nothing 62 * goes terribly wrong :) If you include "$USER" in the definition 63 * (e.g., "device:[dir.$USER]"), Lynx will replace the "$USER" with 64 * the username of the account which invoked the Lynx image. Such 65 * directories should already exist, and have protections/ACLs set 66 * so that only the appropriate user(s) will have read/write access. 67 * On VMS, "sys$scratch:" defaults to "sys$login:" if it has not been 68 * defined externally, or you can use "sys$login:" explicitly here. 69 * If the path has SHELL syntax and includes a tilde (e.g, "~/lynxtmp"), 70 * Lynx will replace the tilde with the full path for the user's home 71 * and convert the result to VMS syntax. 72 * The definition here can be overridden at run time by defining a 73 * "LYNX_TEMP_SPACE" VMS logical. 74 */ 75 #define TEMP_SPACE "sys$scratch:" 76 77 /************************** 78 * LYNX_CFG_FILE is the location and name of the default lynx 79 * global configuration file. It is sought and processed at 80 * startup of Lynx, followed by a seek and processing of a 81 * personal RC file (.lynxrc in the user's HOME directory, 82 * created if the user saves values in the 'o'ptions menu). 83 * You also can define the location and name of the global 84 * configuration file via a VMS logical, "LYNX_CFG", which 85 * will override the "LYNX_CFG_FILE" definition here. SYS$LOGIN: 86 * can be used as the device in either or both definitions if 87 * you want lynx.cfg treated as a personal configuration file. 88 * You also can use Unix syntax with a '~' for a subdirectory 89 * of the login directory, (e.g., ~/lynx/lynx.cfg). 90 * The -cfg command line switch will override these definitions. 91 * You can pass the compilation default via build.com or descrip.mms. 92 * 93 * Note that some implementations of telnet allow passing of 94 * environment variables, which might be used by unscrupulous 95 * people to modify the environment in anonymous accounts. When 96 * making Lynx and Web access publicly available via anonymous 97 * accounts intended to run Lynx captively, be sure the wrapper 98 * uses the -cfg switch and specifies the startfile, rather than 99 * relying on the LYNX_CFG, LYNX_CFG_FILE, or WWW_HOME variables. 100 * 101 * Note that any SUFFIX or VIEWER mappings in the configuration 102 * file will be overridden by any suffix or viewer mappings 103 * that are established as defaults in src/HTInit.c. You can 104 * override the src/HTInit.c defaults via the mime.types and 105 * mailcap files (see the examples in the samples directory). 106 */ 107 #ifndef LYNX_CFG_FILE 108 #define LYNX_CFG_FILE "Lynx_Dir:lynx.cfg" 109 #endif /* LYNX_CFG_FILE */ 110 111 /************************** 112 * The EXTENSION_MAP file allows you to map file suffixes to 113 * mime types. 114 * The file locations defined here can be overridden in lynx.cfg. 115 * Mappings in these global and personal files override any SUFFIX 116 * definitions in lynx.cfg and built-in defaults from src/HTInit.c. 117 */ 118 #define GLOBAL_EXTENSION_MAP "Lynx_Dir:mime.types" 119 #define PERSONAL_EXTENSION_MAP "mime.types" 120 121 /************************** 122 * The MAILCAP file allows you to map file MIME types to 123 * external viewers. 124 * The file locations defined here can be overridden in lynx.cfg. 125 * Mappings in these global and personal files override any VIEWER 126 * definitions in lynx.cfg and built-in defaults from src/HTInit.c. 127 */ 128 #define GLOBAL_MAILCAP "Lynx_Dir:mailcap" 129 #define PERSONAL_MAILCAP ".mailcap" 130 131 /************************** 132 * XLOADIMAGE_COMMAND will be used as a default in src/HTInit.c 133 * for viewing image content types when the DECW$DISPLAY logical 134 * is set. Make it the foreign command for your system's X image 135 * viewer (commonly, "xv"). It can be anything that will handle GIF, 136 * TIFF and other popular image formats. Freeware ports of xv for 137 * VMS are available in the ftp://ftp.wku.edu/vms/unsupported and 138 * http://www.openvms.digital.com/cd/XV310A/ subdirectories. You 139 * must also have a "%s" for the filename. The default defined 140 * here can be overridden in lynx.cfg, or via the global or personal 141 * mailcap files. 142 * Make this NULL if you don't have such a viewer or don't want to 143 * use any default viewers for image types. 144 */ 145 #define XLOADIMAGE_COMMAND "xv %s" 146 147 /************************** 148 * SYSTEM_MAIL must be defined here to your mail sending command, 149 * and SYSTEM_MAIL_FLAGS to appropriate qualifiers. They can be 150 * changed in lynx.cfg. 151 * 152 * The mail command will be spawned as a subprocess of lynx 153 * and used to send the email, with headers specified in a 154 * temporary file for PMDF. If you define SYSTEM_MAIL to the 155 * "generic" MAIL utility for VMS, headers cannot be specified 156 * via a header file (and thus may not be included), and the 157 * subject line will be specified by use of the /subject="SUBJECT" 158 * qualifier. 159 * 160 * If your mailer uses another syntax, some hacking of the 161 * mailform(), mailmsg() and reply_by_mail() functions in 162 * LYMail.c, and printfile() function in LYPrint.c, may be 163 * required. 164 */ 165 #define SYSTEM_MAIL "PMDF SEND" 166 #define SYSTEM_MAIL_FLAGS "/headers" 167 /* #define SYSTEM_MAIL "MAIL" */ 168 /* #define SYSTEM_MAIL_FLAGS "" */ 169 170 /************************* 171 * Below is the argument for an sprintf command that will add 172 * "IN%""ADDRESS""" to the Internet mail address given by the user. 173 * It is structured for PMDF's IN%"INTERNET_ADDRESS" scheme. The %s 174 * is replaced with the address given by the user. If you are using 175 * a different Internet mail transport, change the IN appropriately 176 * (e.g., to SMTP, MX, or WINS), here or in lynx.cfg. 177 */ 178 #define MAIL_ADRS "\"IN%%\"\"%s\"\"\"" 179 180 /********************************* 181 * On VMS, CSwing (an XTree emulation for VTxxx terminals) is intended for 182 * use as the Directory/File Manager (sources, objects, or executables are 183 * available from ftp://narnia.memst.edu/). CSWING_PATH should be defined 184 * here or in lynx.cfg to your foreign command for CSwing, with any 185 * regulatory switches you want included. If not defined, or defined as 186 * a zero-length string ("") or "none" (case-insensitive), the support 187 * will be disabled. It will also be disabled if the -nobrowse or 188 * -selective switches are used, or if the file_url restriction is set. 189 * 190 * When enabled, the DIRED_MENU command (normally 'f' or 'F') will invoke 191 * CSwing, normally with the current default directory as an argument to 192 * position the user on that node of the directory tree. However, if the 193 * current document is a local directory listing, or a local file and not 194 * one of the temporary menu or list files, the associated directory will 195 * be passed as an argument, to position the user on that node of the tree. 196 */ 197 /* #define CSWING_PATH "swing" */ 198 199 /********************************* 200 * If USE_FIXED_RECORDS is set to TRUE here and/or in lynx.cfg, Lynx will 201 * convert 'd'ownloaded binary files to FIXED 512 record format before saving 202 * them to disk or acting on a DOWNLOADER option. If set to FALSE, the 203 * headers of such files will indicate that they are Stream_LF with Implied 204 * Carriage Control, which is incorrect, and can cause downloading software 205 * to get confused and unhappy. If you do set it FALSE, you can use the 206 * FIXED512.COM command file, which is included in this distribution, to do 207 * the conversion externally. 208 */ 209 #define USE_FIXED_RECORDS TRUE /* convert binaries to FIXED 512 */ 210 211 /******************************** 212 * If NO_ANONYMOUS_EMAIL is defined, Lynx will not offer to insert X-From 213 * and X_Personal_Name lines in the body of email messages. On VMS, the 214 * actual From and Personal Name (if defined for the account) headers always 215 * are those of the account running the Lynx image. If the account is not 216 * the one to which the recipient should reply, you can indicate the alternate 217 * address and personal name via the X-From and X_Personal_Name entries, but 218 * the recipient must explicitly send the reply to the X_From address, rather 219 * than using the VMS REPLY command (which will use the actual From address). 220 * 221 * This symbol constant might be defined on Unix for security reasons that 222 * don't apply on VMS. There is no security reason for defining this on VMS, 223 * but if you have no anonymous accounts (i.e., the From always will point to 224 * the actual user's email address, you can define it to avoid the bother of 225 * X-From and X_Personal_Name offers. 226 */ 227 /*#define NO_ANONYMOUS_EMAIL TRUE */ 228 229 /************************** 230 * LYNX_LSS_FILE is the location and name of the default lynx 231 * character style sheet file. It is sought and processed at 232 * startup of Lynx only if experimental character style code has 233 * been compiled in, otherwise it will be ignored. Note that use 234 * of the character style option is _experimental_ AND _unsupported_. 235 * There is no documentation other than a sample lynx.lss file in 236 * the samples subdirectory. This code probably won't even work on 237 * VMS. You can define the location and name of this file via an 238 * environment variable, "lynx_lss", which will override the definition 239 * here. You can use '~' to refer to the user's home directory. The 240 * -lss command line switch will override these definitions. 241 */ 242 #ifndef LYNX_LSS_FILE 243 #define LYNX_LSS_FILE "Lynx_Dir:lynx.lss" 244 #endif /* LYNX_LSS_FILE */ 245 246 /* 247 * FTP_FORMAT uses the same codes as LIST_FORMAT, but applies to files shown 248 * in an ftp listing. 249 */ 250 #define FTP_FORMAT "%d %-16.16t %a %K" 251 252 /******************************************************************* 253 * Things you must change - non-VMS specific 254 * Section 1b). 255 */ 256 #else /* non-VMS: UNIX etc. */ 257 258 /************************** 259 * NOTE: This variable is set by the configure script; editing changes will 260 * be ignored. 261 * 262 * LYNX_CFG_FILE is the location and name of the default lynx 263 * global configuration file. It is sought and processed at 264 * startup of Lynx, followed by a seek and processing of a 265 * personal RC file (.lynxrc in the user's HOME directory, 266 * created if the user saves values in the 'o'ptions menu). 267 * You also can define the location and name of the global 268 * configuration file via an environment variable, "LYNX_CFG", 269 * which will override the "LYNX_CFG_FILE" definition here. 270 * You can use '~' in either or both definitions if you want 271 * lynx.cfg treated as a personal configuration file. The 272 * -cfg command line switch will override these definitions. 273 * You can pass the compilation default via the Makefile. 274 * 275 * If you are building Lynx using the configure script, you should specify 276 * the default location of the configuration file via that script, since it 277 * also generates the makefile and install-cfg rules. 278 * 279 * Note that many implementations of telnetd allow passing of 280 * environment variables, which might be used by unscrupulous 281 * people to modify the environment in anonymous accounts. When 282 * making Lynx and Web access publicly available via anonymous 283 * accounts intended to run Lynx captively, be sure the wrapper 284 * uses the -cfg switch and specifies the startfile, rather than 285 * relying on the LYNX_CFG, LYNX_CFG_FILE, or WWW_HOME variables. 286 * 287 * Note that any SUFFIX or VIEWER mappings in the configuration 288 * file will be overridden by any suffix or viewer mappings 289 * that are established as defaults in src/HTInit.c. You can 290 * override the src/HTInit.c defaults via the mime.types and 291 * mailcap files (see the examples in the samples directory). 292 */ 293 #ifndef HAVE_CONFIG_H 294 #ifndef LYNX_CFG_FILE 295 #ifdef DOSPATH 296 #define LYNX_CFG_FILE "./lynx.cfg" 297 #else 298 #define LYNX_CFG_FILE "/usr/local/lib/lynx.cfg" 299 #endif /* DOSPATH */ 300 #endif /* LYNX_CFG_FILE */ 301 #endif /* HAVE_CONFIG_H */ 302 303 #ifndef MIME_LIBDIR 304 #define MIME_LIBDIR "/etc/" 305 #endif 306 307 /************************** 308 * The EXTENSION_MAP file allows you to map file suffixes to 309 * mime types. 310 * The file locations defined here can be overridden in lynx.cfg. 311 * Mappings in these global and personal files override any SUFFIX 312 * definitions in lynx.cfg and built-in defaults from src/HTInit.c. 313 */ 314 #define GLOBAL_EXTENSION_MAP MIME_LIBDIR "mime.types" 315 #define PERSONAL_EXTENSION_MAP "~/.mime.types" 316 317 /************************** 318 * The MAILCAP file allows you to map file MIME types to 319 * external viewers. 320 * The file locations defined here can be overridden in lynx.cfg. 321 * Mappings in these global and personal files override any VIEWER 322 * definitions in lynx.cfg and built-in defaults from src/HTInit.c. 323 */ 324 #define GLOBAL_MAILCAP MIME_LIBDIR "mailcap" 325 #define PERSONAL_MAILCAP "~/.mailcap" 326 327 /************************** 328 * XLOADIMAGE_COMMAND will be used as a default in src/HTInit.c for 329 * viewing image content types when the DISPLAY environment variable 330 * is set. Make it the full path and name of the xli (also known as 331 * xloadimage or xview) command, or other image viewer. It can be 332 * anything that will handle GIF, TIFF and other popular image formats 333 * (xli does). The freeware distribution of xli is available in the 334 * ftp://ftp.x.org/contrib/ subdirectory. The shareware, xv, also is 335 * suitable. You must also have a "%s" for the filename; "&" for 336 * background is optional. The default defined here can be overridden 337 * in lynx.cfg, or via the global or personal mailcap files. 338 * Make this NULL if you don't have such a viewer or don't want to 339 * use any default viewers for image types. Note that open is used as 340 * the default for NeXT, instead of the XLOADIMAGE_COMMAND definition. 341 */ 342 #define XLOADIMAGE_COMMAND "xloadimage -quiet %s" 343 344 /************************** 345 * For UNIX systems, SYSTEM_MAIL and SYSTEM_MAIL_FLAGS are set by the 346 * configure-script. 347 */ 348 349 /************************** 350 * A place to put temporary files, it is almost always in "/tmp/" 351 * for UNIX systems. If you include "$USER" in the definition 352 * (e.g., "/tmp/$USER"), Lynx will replace the "$USER" with the 353 * username of the account which invoked the Lynx image. Such 354 * directories should already exist, and have protections/ACLs set 355 * so that only the appropriate user(s) will have read/write access. 356 * If the path includes a tilde (e.g, "~" or "~/lynxtmp"), Lynx will 357 * replace the tilde with the full path for the user's home. 358 * The definition here can be overridden at run time by setting a 359 * "LYNX_TEMP_SPACE" environment variable, or (if that is not set) 360 * the "TMPDIR" (unix), or "TEMP" or "TMP" (Windows,DOS,OS/2) 361 * variable. 362 */ 363 #define TEMP_SPACE "/tmp/" 364 365 /******************************** 366 * Comment this line out to disable code that implements command logging 367 * and scripting. 368 */ 369 #define USE_CMD_LOGGING 1 370 371 /******************************** 372 * Comment this line out to disable code that randomizes the names given to 373 * temporary files. 374 */ 375 #define USE_RAND_TEMPNAME 1 376 377 /******************************** 378 * Comment this line out to let the user enter his/her email address 379 * when sending a message. There should be no need to do this unless 380 * your mailer agent does not put in the From: field for you. (If your 381 * mailer agent does not automatically put in the From: field, you should 382 * upgrade, because anonymous mail makes it far too easy for a user to 383 * spoof someone else's email address.) 384 */ 385 /*#define NO_ANONYMOUS_EMAIL TRUE */ 386 387 /******************************** 388 * LIST_FORMAT defines the display for local files when LONG_LIST 389 * is defined in the Makefile. The default set here can be changed 390 * in lynx.cfg. 391 * 392 * The percent items in the list are interpreted as follows: 393 * 394 * %p Unix-style permission bits 395 * %l link count 396 * %o owner of file 397 * %g group of file 398 * %d date of last modification 399 * %a anchor pointing to file or directory 400 * %A as above but don't show symbolic links 401 * %t type of file (description derived from MIME type) 402 * %T MIME type as known by Lynx (from mime.types or default) 403 * %k size of file in Kilobytes 404 * %K as above but omit size for directories 405 * %s size of file in bytes 406 * 407 * Anything between the percent and the letter is passed on to sprintf. 408 * A double percent yields a literal percent on output. Other characters 409 * are passed through literally. 410 * 411 * If you want only the filename: " %a" 412 * 413 * If you want a brief output: " %4K %-12.12d %a" 414 * 415 * For the Unix "ls -l" format: " %p %4l %-8.8o %-8.8g %7s %-12.12d %a" 416 */ 417 #ifdef DOSPATH 418 #define LIST_FORMAT " %4K %-12.12d %a" 419 #else 420 #define LIST_FORMAT " %p %4l %-8.8o %-8.8g %7s %-12.12d %a" 421 #endif 422 423 /* 424 * FTP_FORMAT uses the same codes as LIST_FORMAT, but applies to files shown 425 * in an ftp listing. 426 */ 427 #define FTP_FORMAT "%d %-16.16t %a %K" 428 429 /* 430 * If NO_FORCED_CORE_DUMP is set to TRUE, Lynx will not force 431 * core dumps via abort() calls on fatal errors or assert() 432 * calls to check potentially fatal errors. The default defined 433 * here can be changed in lynx.cfg, and the compilation or 434 * configuration default can be toggled via the -core command 435 * line switch. 436 */ 437 #define NO_FORCED_CORE_DUMP FALSE 438 439 /************************** 440 * LYNX_LSS_FILE is the location and name of the default lynx 441 * character style sheet file. It is sought and processed at 442 * startup of Lynx only if experimental character style code 443 * has been compiled in, otherwise it will be ignored. Note 444 * that use of the character style option is _experimental_ AND 445 * _unsupported_. There is no documentation other than a sample 446 * lynx.lss file in the samples subdirectory. You also can 447 * define the location and name of this file via environment 448 * variables "LYNX_LSS" or "lynx_lss" which will override the 449 * "LYNX_LSS_FILE" definition here. You can use '~' in either or 450 * both definitions to refer to the user's home directory. The 451 * -lss command line switch will override these definitions. 452 */ 453 #ifndef LYNX_LSS_FILE 454 #define LYNX_LSS_FILE "/usr/local/lib/lynx.lss" 455 #endif /* LYNX_LSS_FILE */ 456 457 #endif /* VMS OR UNIX */ 458 459 /************************************************************* 460 * Section 1c) Every platform must change or verify these 461 * 462 */ 463 464 /***************************** 465 * STARTFILE is the default starting URL if none is specified 466 * on the command line or via a WWW_HOME environment variable; 467 * Lynx will refuse to start without a starting URL of some kind. 468 * STARTFILE can be remote, e.g., http://www.w3.org/default.html , 469 * or local, e.g., file://localhost/PATH_TO/FILENAME , 470 * where PATH_TO is replaced with the complete path to FILENAME 471 * using Unix shell syntax and including the device on VMS. 472 * 473 * Normally we expect you will connect to a remote site, e.g., the Lynx starting 474 * site: 475 */ 476 /* #define STARTFILE "http://lynx.isc.org/" */ 477 /* 478 * As an alternative, you may want to use a local URL. A good choice for this 479 * is the user's home directory: 480 *#define STARTFILE "file://localhost/~/" 481 * 482 * Your choice of STARTFILE should reflect your site's needs, and be a URL that 483 * you can connect to reliably. Otherwise users will become confused and think 484 * that they cannot run Lynx. 485 */ 486 #define STARTFILE "file://localhost/~/" 487 488 /***************************** 489 * HELPFILE must be defined as a URL and must have a 490 * complete path if local: 491 * file://localhost/PATH_TO/lynx_help/lynx_help_main.html 492 * Replace PATH_TO with the path to the lynx_help subdirectory 493 * for this distribution (use SHELL syntax including the device 494 * on VMS systems). 495 * The default HELPFILE is: 496 * http://lynx.isc.org/release/lynx2-8-7/lynx_help/lynx_help_main.html 497 * This should be changed here or in lynx.cfg to the local path. 498 * The definition here can be overridden at run time by defining a 499 * "LYNX_HELPFILE" environment variable. 500 */ 501 #define HELPFILE "http://lynx.isc.org/release/lynx2-8-7/lynx_help/lynx_help_main.html" 502 /* #define HELPFILE "file://localhost/PATH_TO/lynx_help/lynx_help_main.html" */ 503 504 /***************************** 505 * DEFAULT_INDEX_FILE is the default file retrieved when the 506 * user presses the 'I' key when viewing any document. 507 * An index to your CWIS can be placed here or a document containing 508 * pointers to lots of interesting places on the web. 509 */ 510 #define DEFAULT_INDEX_FILE "http://scout.wisc.edu/" 511 512 /***************************** 513 * If USE_TRACE_LOG is set FALSE, then when TRACE mode is invoked the 514 * syserr messages will not be directed to a log file named Lynx.trace 515 * in the account's HOME directory. The default defined here can be 516 * toggled via the -tlog command line switch. Also, it is set FALSE 517 * automatically when Lynx is executed in an anonymous or validation 518 * account (if indicated via the -anonymous or -validate command line 519 * switches, or via the check for the ANONYMOUS_USER, defined below). 520 * When FALSE, the TRACE_LOG command (normally ';') cannot be used to 521 * examine the Lynx Trace Log during the current session. If left 522 * TRUE, but you wish to use command line piping of stderr to a file 523 * you specify, include the -tlog toggle on the command line. Note 524 * that once TRACE mode is turned on during a session and stderr is 525 * directed to the log, all stderr messages will continue going to 526 * the log, even if TRACE mode is turned off via the TOGGLE_TRACE 527 * (Control-T) command. 528 */ 529 #define USE_TRACE_LOG TRUE 530 531 /******************************* 532 * If GOTOBUFFER is set to TRUE here or in lynx.cfg the last entered 533 * goto URL, if any, will be offered as a default for reuse or editing 534 * when the 'g'oto command is entered. All previously used goto URLs 535 * can be accessed for reuse or editing via a circular buffer invoked 536 * with the Up-Arrow or Down-Arrow keys after entering the 'g'oto 537 * command, whether or not a default is offered. 538 */ 539 #define GOTOBUFFER FALSE 540 541 /***************************** 542 * If FTP_PASSIVE is set to TRUE here or in lynx.cfg, ftp transfers will 543 * be done in passive mode. 544 * Note: if passive transfers fail, lynx falls back to active mode, and 545 * vice versa if active transfers fail at first. 546 */ 547 #define FTP_PASSIVE TRUE 548 549 /***************************** 550 * JUMPFILE is the default local file checked for shortcut URLs when 551 * the user presses the 'J' (JUMP) key. The user will be prompted for 552 * a shortcut entry (analogously to 'g'oto), and can enter one 553 * or use '?' for a list of the shortcuts with associated links to 554 * their actual URLs. See the sample jumps files in the samples 555 * subdirectory. Make sure your jumps file includes a '?' shortcut 556 * for a file://localhost URL to itself: 557 * 558 * <dt>?<dd><a href="file://localhost/path/jumps.html">This Shortcut List</a> 559 * 560 * If not defined here or in lynx.cfg, the JUMP command will invoke 561 * the NO_JUMPFILE status line message (see LYMessages_en.h). The prompt 562 * associated with the default jumps file is defined as JUMP_PROMPT in 563 * LYMessages_en.h and can be modified in lynx.cfg. Additional, alternate 564 * jumps files can be defined and mapped to keystrokes, and alternate 565 * prompts can be set for them, in lynx.cfg, but at least one default 566 * jumps file and associated prompt should be established before adding 567 * others. 568 * 569 * On VMS, use Unix SHELL syntax (including a lead slash) to define it. 570 * 571 * Do not include "file://localhost" in the definition. 572 */ 573 /* #define JUMPFILE "/Lynx_Dir/jumps.html" */ 574 575 /******************************* 576 * If JUMPBUFFER is set to TRUE here or in lynx.cfg the last entered 577 * jump shortcut, if any, will be offered as a default for reuse or 578 * editing when the JUMP command is entered. All previously used 579 * shortcuts can be accessed for reuse or editing via a circular buffer 580 * invoked with the Up-Arrow or Down-Arrow keys after entering the JUMP 581 * command, whether or not a default is offered. If you have multiple 582 * jumps files and corresponding key mappings, each will have its own 583 * circular buffer. 584 */ 585 #define JUMPBUFFER FALSE 586 587 /******************************** 588 * If PERMIT_GOTO_FROM_JUMP is defined, then a : or / in a jump target 589 * will be treated as a full or partial URL (to be resolved versus the 590 * startfile), and will be handled analogously to a 'g'oto command. 591 * Such "random URLs" will be entered in the circular buffer for goto 592 * URLs, not the buffer for jump targets (shortcuts). If the target 593 * is the single character ':', it will be treated equivalently to an 594 * Up-Arrow or Down-Arrow following a 'g'oto command, for accessing the 595 * circular buffer of goto URLs. 596 */ 597 /* #define PERMIT_GOTO_FROM_JUMP */ 598 599 /***************************** 600 * If LYNX_HOST_NAME is defined here and/or in lynx.cfg, it will be 601 * treated as an alias for the local host name in checks for URLs on 602 * the local host (e.g., when the -localhost switch is set), and this 603 * host name, "localhost", and HTHostName (the fully qualified domain 604 * name of the system on which Lynx is running) will all be passed as 605 * local. A different definition in lynx.cfg will override this one. 606 */ 607 /* #define LYNX_HOST_NAME "www.cc.ukans.edu" */ 608 609 /********************* 610 * LOCAL_DOMAIN is used for a tail match with the ut_host element of 611 * the utmp or utmpx structure on systems with utmp capabilities, to 612 * determine if a user is local to your campus or organization when 613 * handling -restrictions=inside_foo or outside_foo settings for ftp, 614 * news, telnet/tn3270 and rlogin URLs. An "inside" user is assumed 615 * if your system does not have utmp capabilities. CHANGE THIS here 616 * or in lynx.cfg. 617 */ 618 #define LOCAL_DOMAIN "ukans.edu" 619 620 /******************************** 621 * The DEFAULT_CACHE_SIZE specifies the number of WWW documents to be 622 * cached in memory at one time. 623 * 624 * This so-called cache size (actually, number) may be modified in lynx.cfg 625 * and or with the command line argument -cache=NUMBER The minimum allowed 626 * value is 2, for the current document and at least one to fetch, and there 627 * is no absolute maximum number of cached documents. On Unix, and VMS not 628 * compiled with VAXC, whenever the number is exceeded the least recently 629 * displayed document will be removed from memory. 630 * 631 * On VMS compiled with VAXC, the DEFAULT_VIRTUAL_MEMORY_SIZE specifies the 632 * amount (bytes) of virtual memory that can be allocated and not yet be freed 633 * before previous documents are removed from memory. If the values for both 634 * the DEFAULT_CACHE_SIZE and DEFAULT_VIRTUAL_MEMORY_SIZE are exceeded, then 635 * least recently displayed documents will be freed until one or the other 636 * value is no longer exceeded. The value can be modified in lynx.cfg. 637 * 638 * The Unix and VMS but not VAXC implementations use the C library malloc 639 * and calloc for memory allocation, and procedures for taking the actual 640 * amount of cache into account still need to be developed. They use only 641 * the DEFAULT_CACHE_SIZE value, and that specifies the absolute maximum 642 * number of documents to cache (rather than the maximum number only if 643 * DEFAULT_VIRTUAL_MEMORY_SIZE has been exceeded, as with VAXC/VAX). 644 */ 645 #define DEFAULT_CACHE_SIZE 10 646 647 #if defined(VMS) && defined(VAXC) && !defined(__DECC) 648 #define DEFAULT_VIRTUAL_MEMORY_SIZE 512000 649 #endif /* VMS && VAXC && !__DECC */ 650 651 /******************************** 652 * If ALWAYS_RESUBMIT_POSTS is set TRUE, Lynx always will resubmit forms 653 * with method POST, dumping any cache from a previous submission of the 654 * form, including when the document returned by that form is sought with 655 * the PREV_DOC command or via the history list. Lynx always resubmits 656 * forms with method POST when a submit button or a submitting text input 657 * is activated, but normally retrieves the previously returned document 658 * if it had links which you activated, and then go back with the PREV_DOC 659 * command or via the history list. 660 * 661 * The default defined here can be changed in lynx.cfg, and can be toggled 662 * via the -resubmit_posts command line switch. 663 */ 664 #define ALWAYS_RESUBMIT_POSTS FALSE 665 666 /******************************** 667 * CHARACTER_SET defines the default character set, i.e., that assumed 668 * to be installed on the user's terminal. It determines which characters 669 * or strings will be used to represent 8-bit character entities within 670 * HTML. New character sets may be defined as explained in the README 671 * files of the src/chrtrans directory in the Lynx source code distribution. 672 * For Asian (CJK) character sets, it also determines how Kanji code will 673 * be handled. The default defined here can be changed in lynx.cfg, and 674 * via the 'o'ptions menu. The 'o'ptions menu setting will be stored in 675 * the user's RC file whenever those settings are saved, and thereafter 676 * will be used as the default. Also see lynx.cfg for information about 677 * the -raw switch and LYK_RAW_TOGGLE command. 678 * 679 * Since Lynx now supports a wide range of platforms it may be useful 680 * to note that cpXXX codepages used by IBM PC compatible computers, 681 * and windows-xxxx used by native MS-Windows apps. 682 * 683 * Recognized character sets include: 684 * 685 * string for 'O'ptions Menu MIME name 686 * =========================== ========= 687 * 7 bit approximations (US-ASCII) us-ascii 688 * Western (ISO-8859-1) iso-8859-1 689 * Western (cp850) cp850 690 * Western (windows-1252) windows-1252 691 * IBM PC US codepage (cp437) cp437 692 * DEC Multinational dec-mcs 693 * Macintosh (8 bit) macintosh 694 * NeXT character set next 695 * HP Roman8 hp-roman8 696 * Chinese euc-cn 697 * Japanese (EUC-JP) euc-jp 698 * Japanese (Shift_JIS) shift_jis 699 * Korean euc-kr 700 * Taipei (Big5) big5 701 * Vietnamese (VISCII) viscii 702 * Eastern European (ISO-8859-2) iso-8859-2 703 * Eastern European (cp852) cp852 704 * Eastern European (windows-1250) windows-1250 705 * Latin 3 (ISO-8859-3) iso-8859-3 706 * Latin 4 (ISO-8859-4) iso-8859-4 707 * Baltic Rim (cp775) cp775 708 * Baltic Rim (windows-1257) windows-1257 709 * Cyrillic (ISO-8859-5) iso-8859-5 710 * Cyrillic (cp866) cp866 711 * Cyrillic (windows-1251) windows-1251 712 * Cyrillic (KOI8-R) koi8-r 713 * Arabic (ISO-8859-6) iso-8859-6 714 * Arabic (cp864) cp864 715 * Arabic (windows-1256) windows-1256 716 * Greek (ISO-8859-7) iso-8859-7 717 * Greek (cp737) cp737 718 * Greek2 (cp869) cp869 719 * Greek (windows-1253) windows-1253 720 * Hebrew (ISO-8859-8) iso-8859-8 721 * Hebrew (cp862) cp862 722 * Hebrew (windows-1255) windows-1255 723 * Turkish (ISO-8859-9) iso-8859-9 724 * ISO-8859-10 iso-8859-10 725 * Ukrainian Cyrillic (cp866u) cp866u 726 * Ukrainian Cyrillic (KOI8-U) koi8-u 727 * UNICODE (UTF-8) utf-8 728 * RFC 1345 w/o Intro mnemonic+ascii+0 729 * RFC 1345 Mnemonic mnemonic 730 * Transparent x-transparent 731 */ 732 #define CHARACTER_SET "iso-8859-1" 733 734 /***************************** 735 * PREFERRED_LANGUAGE is the language in MIME notation (e.g., "en", 736 * "fr") which will be indicated by Lynx in its Accept-Language headers 737 * as the preferred language. If available, the document will be 738 * transmitted in that language. This definition can be overridden via 739 * lynx.cfg. Users also can change it via the 'o'ptions menu and save 740 * that preference in their RC file. This may be a comma-separated list 741 * of languages in decreasing preference. 742 */ 743 #define PREFERRED_LANGUAGE "" 744 745 /***************************** 746 * PREFERRED_CHARSET specifies the character set in MIME notation (e.g., 747 * "ISO-8859-2", "ISO-8859-5") which Lynx will indicate you prefer in 748 * requests to http servers using an Accept-Charsets header. 749 * This definition can be overridden via lynx.cfg. Users also can change it 750 * via the 'o'ptions menu and save that preference in their RC file. 751 * The value should NOT include "ISO-8859-1" or "US-ASCII", since those 752 * values are always assumed by default. 753 * If a file in that character set is available, the server will send it. 754 * If no Accept-Charset header is present, the default is that any 755 * character set is acceptable. If an Accept-Charset header is present, 756 * and if the server cannot send a response which is acceptable 757 * according to the Accept-Charset header, then the server SHOULD send 758 * an error response with the 406 (not acceptable) status code, though 759 * the sending of an unacceptable response is also allowed. (RFC2068) 760 */ 761 #define PREFERRED_CHARSET "" 762 763 /***************************** 764 * If MULTI_BOOKMARK_SUPPORT is set to MBM_STANDARD or MBM_ADVANCED, and 765 * BLOCK_MULTI_BOOKMARKS (see below) is FALSE, and sub-bookmarks exist, all 766 * bookmark operations will first prompt the user to select an active 767 * sub-bookmark file or the default bookmark file. MBM_OFF is the default so 768 * that one (the default) bookmark file will be available initially. The 769 * default set here can be overridden in lynx.cfg. The user can turn on 770 * multiple bookmark support via the 'o'ptions menu, and can save that choice as 771 * the startup default via the .lynxrc file. When on, the setting can be 772 * STANDARD or ADVANCED. If support is set to the latter, and the user mode 773 * also is ADVANCED, the VIEW_BOOKMARK command will invoke a status line prompt 774 * at which the user can enter the letter token (A - Z) of the desired bookmark, 775 * or '=' to get a menu of available bookmark files. The menu always is 776 * presented in NOVICE or INTERMEDIATE mode, or if the support is set to 777 * STANDARD. No prompting or menu display occurs if only one (the startup 778 * default) bookmark file has been defined (define additional ones via the 779 * 'o'ptions menu). The startup default, however set, can be overridden on the 780 * command line via the -restrictions=multibook or the -anonymous or -validate 781 * switches. 782 */ 783 #ifndef MULTI_BOOKMARK_SUPPORT 784 #define MULTI_BOOKMARK_SUPPORT MBM_OFF 785 #endif /* MULTI_BOOKMARK_SUPPORT */ 786 787 /***************************** 788 * If BLOCK_MULTI_BOOKMARKS is set TRUE, multiple bookmark support will 789 * be forced off, and cannot be toggled on via the 'o'ptions menu. This 790 * compilation setting can be overridden via lynx.cfg. 791 */ 792 #ifndef BLOCK_MULTI_BOOKMARKS 793 #define BLOCK_MULTI_BOOKMARKS FALSE 794 #endif /* BLOCK_MULTI_BOOKMARKS */ 795 796 /******************************** 797 * URL_DOMAIN_PREFIXES and URL_DOMAIN_SUFFIXES are strings which will be 798 * prepended (together with a scheme://) and appended to the first element 799 * of command line or 'g'oto arguments which are not complete URLs and 800 * cannot be opened as a local file (file://localhost/string). Both 801 * can be comma-separated lists. Each prefix must end with a dot, each 802 * suffix must begin with a dot, and either may contain other dots (e.g., 803 * .co.jp). The default lists are defined here, and can be changed 804 * in lynx.cfg. Each prefix will be used with each suffix, in order, 805 * until a valid Internet host is created, based on a successful DNS 806 * lookup (e.g., foo will be tested as www.foo.com and then www.foo.edu 807 * etc.). The first element can include a :port and/or /path which will 808 * be restored with the expanded host (e.g., wfbr:8002/dir/lynx will 809 * become http://www.wfbr.edu:8002/dir/lynx). The prefixes will not be 810 * used if the first element ends in a dot (or has a dot before the 811 * :port or /path), and similarly the suffixes will not be used if the 812 * the first element begins with a dot (e.g., .nyu.edu will become 813 * http://www.nyu.edu without testing www.nyu.com). Lynx will try to 814 * guess the scheme based on the first field of the expanded host name, 815 * and use "http://" as the default (e.g., gopher.wfbr.edu or gopher.wfbr. 816 * will be made gopher://gopher.wfbr.edu). 817 */ 818 #define URL_DOMAIN_PREFIXES "" 819 #define URL_DOMAIN_SUFFIXES "" 820 821 /******************************** 822 * If LIST_NEWS_NUMBERS is set TRUE, Lynx will use an ordered list 823 * and include the numbers of articles in news listings, instead of 824 * using an unordered list. 825 * 826 * The default defined here can be changed in lynx.cfg. 827 */ 828 #define LIST_NEWS_NUMBERS FALSE 829 830 /******************************** 831 * If LIST_NEWS_DATES is set TRUE, Lynx will include the dates of 832 * articles in news listings. The dates always are included in the 833 * articles, themselves. 834 * 835 * The default defined here can be changed in lynx.cfg. 836 */ 837 #define LIST_NEWS_DATES FALSE 838 839 /************************* 840 * Set NEWS_POSTING to FALSE if you do not want to support posting to 841 * news groups via Lynx. If left TRUE, Lynx will use its news gateway to 842 * post new messages or followups to news groups, using the URL schemes 843 * described in the "Supported URL" section of the online 'h'elp. The 844 * posts will be attempted via the nntp server specified in the URL, or 845 * if none was specified, via the NNTPSERVER configuration or environment 846 * variable. Links with these URLs for posting or sending followups are 847 * created by the news gateway when reading group listings or articles 848 * from nntp servers if the server indicates that it permits posting. 849 * The setting here can be changed in lynx.cfg. 850 */ 851 #define NEWS_POSTING TRUE 852 853 /************************* 854 * Define LYNX_SIG_FILE to the name of a file containing a signature which 855 * can be appended to email messages and news postings or followups. The 856 * user will be prompted whether to append it. It is sought in the home 857 * directory. If it is in a subdirectory, begin it with a dot-slash 858 * (e.g., ./lynx/.lynxsig). The definition here can be changed in lynx.cfg. 859 */ 860 #define LYNX_SIG_FILE ".etc/sig" 861 862 /******************************** 863 * BIBP_GLOBAL_SERVER is the default global server for bibp: links, used 864 * when a local bibhost or document-specified citehost is unavailable. 865 */ 866 #define BIBP_GLOBAL_SERVER "http://usin.org/" 867 868 /******************************** 869 * If USE_SELECT_POPUPS is set FALSE, Lynx will present a vertical list 870 * of radio buttons for the OPTIONs in SELECT blocks which lack the 871 * MULTIPLE attribute, instead of using a popup menu. Note that if 872 * the MULTIPLE attribute is present in the SELECT start tag, Lynx 873 * always will create a vertical list of checkboxes for the OPTIONs. 874 * 875 * The default defined here can be changed in lynx.cfg. It can be 876 * set and saved via the 'o'ptions menu to override the compilation 877 * and configuration defaults, and the default always can be toggled 878 * via the -popup command line switch. 879 */ 880 #define USE_SELECT_POPUPS TRUE 881 882 /******************************** 883 * If COLLAPSE_BR_TAGS is set FALSE, Lynx will not collapse serial 884 * BR tags. If set TRUE, two or more concurrent BRs will be collapsed 885 * into a single blank line. Note that the valid way to insert extra 886 * blank lines in HTML is via a PRE block with only newlines in the 887 * block. 888 * 889 * The default defined here can be changed in lynx.cfg. 890 */ 891 #define COLLAPSE_BR_TAGS TRUE 892 893 /******************************** 894 * If SET_COOKIES is set FALSE, Lynx will ignore Set-Cookie headers 895 * in http server replies. 896 * 897 * The default defined here can be changed in lynx.cfg, and can be toggled 898 * via the -cookies command line switch. 899 */ 900 #define SET_COOKIES TRUE 901 902 /******************************** 903 * If SEND_USERAGENT is set FALSE, Lynx will not send a user-agent string. 904 * You can override this in the 'O'ptions menu. 905 */ 906 #define SEND_USERAGENT TRUE 907 908 /******************************* 909 * If ACCEPT_ALL_COOKIES is set TRUE, and SET_COOKIES is TRUE, Lynx will 910 * accept all cookies. 911 * 912 * The default defined here can be changed in lynx.cfg, and .lynxrc, or 913 * toggled via the -accept_all_cookies command line switch. 914 */ 915 #define ACCEPT_ALL_COOKIES FALSE 916 917 /**************************************************************** 918 * Section 2. Things that you probably want to change or review 919 * 920 */ 921 922 /***************************** 923 * The following three definitions set the number of seconds for 924 * pauses following status line messages that would otherwise be 925 * replaced immediately, and are more important than the unpaused 926 * progress messages. Those set by INFOSECS are also basically 927 * progress messages (e.g., that a prompted input has been canceled) 928 * and should have the shortest pause. Those set by MESSAGESECS are 929 * informational (e.g., that a function is disabled) and should have 930 * a pause of intermediate duration. Those set by ALERTSECS typically 931 * report a serious problem and should be paused long enough to read 932 * whenever they appear (typically unexpectedly). The default values 933 * defined here can be modified via lynx.cfg, should longer pauses be 934 * desired for braille-based access to Lynx. 935 */ 936 #define INFOSECS 1 937 #define MESSAGESECS 2 938 #define ALERTSECS 3 939 940 #define DEBUGSECS 0 941 #define REPLAYSECS 0 942 943 /****************************** 944 * SHOW_COLOR controls whether the program displays in color by default. 945 */ 946 #ifdef COLOR_CURSES 947 #define SHOW_COLOR TRUE 948 #else 949 #define SHOW_COLOR FALSE 950 #endif 951 952 /****************************** 953 * SHOW_CURSOR controls whether or not the cursor is hidden or appears 954 * over the current link, or current option in select popup windows. 955 * Showing the cursor is handy if you are a sighted user with a poor 956 * terminal that can't do bold and reverse video at the same time or 957 * at all. It also can be useful to blind users, as an alternative 958 * or supplement to setting LINKS_AND_FIELDS_ARE_NUMBERED or 959 * LINKS_ARE_NUMBERED. 960 * 961 * The default defined here can be changed in lynx.cfg. It can be 962 * set and saved via the 'o'ptions menu to override the compilation 963 * and configuration defaults, and the default always can be toggled 964 * via the -show_cursor command line switch. 965 */ 966 #define SHOW_CURSOR FALSE 967 968 /****************************** 969 * UNDERLINE_LINKS controls whether links are underlined by default, or shown 970 * in bold. Normally this default is set from the configure script. 971 */ 972 #ifndef HAVE_CONFIG_H 973 #define UNDERLINE_LINKS FALSE 974 #endif 975 976 /****************************** 977 * VERBOSE_IMAGES controls whether or not Lynx replaces the [LINK], [INLINE] 978 * and [IMAGE] comments (for images without ALT) with filenames of these 979 * images. This is extremely useful because now we can determine immediately 980 * what images are just decorations (button.gif, line.gif) and what images are 981 * important. 982 * 983 * The default defined here can be changed in lynx.cfg. 984 */ 985 #define VERBOSE_IMAGES TRUE 986 987 /****************************** 988 * BOXVERT and BOXHORI control the layout of popup menus. Set to 0 if your 989 * curses supports line-drawing characters, set to '*' or any other character 990 * to not use line-drawing (e.g., '|' for vertical and '-' for horizontal). 991 */ 992 #ifndef HAVE_CONFIG_H 993 #ifdef DOSPATH 994 #define BOXVERT 0 995 #define BOXHORI 0 996 #else 997 #define BOXVERT '|' 998 /* #define BOXVERT 0 */ 999 #define BOXHORI '-' 1000 /* #define BOXHORI 0 */ 1001 #endif /* DOSPATH */ 1002 #endif /* !HAVE_CONFIG_H */ 1003 1004 /****************************** 1005 * LY_UMLAUT controls the 7-bit expansion of characters with dieresis or 1006 * umlaut. If defined, a digraph is displayed, e.g., auml --> ae 1007 * Otherwise, a single character is displayed, e.g., auml --> a 1008 * Note that this is currently not supported with the chartrans code, 1009 * or rather it doesn't have an effect if translations for a display 1010 * character set are taken from one of the *.tbl files in src/chrtrans. 1011 * One would have to modify the corresponding *.tbl file to change the 1012 # 7-bit replacements for these characters. 1013 */ 1014 #define LY_UMLAUT 1015 1016 /******************************* 1017 * Execution links/scripts configuration. 1018 * 1019 * Execution links and scripts allow you to run 1020 * local programs by activating links within Lynx. 1021 * 1022 * An execution link is of the form: 1023 * 1024 * lynxexec:<COMMAND> 1025 * or: 1026 * lynxexec://<COMMAND> 1027 * or: 1028 * lynxprog:<COMMAND> 1029 * or: 1030 * lynxprog://<COMMAND> 1031 * 1032 * where <COMMAND> is a command that Lynx will run when the link is 1033 * activated. The double-slash should be included if the command begins 1034 * with an '@', as for executing VMS command files. Otherwise, the double- 1035 * slash can be omitted. 1036 * Use lynxexec for commands or scripts that generate a screen output which 1037 * should be held via a prompt to press <return> before returning to Lynx 1038 * for display of the current document. 1039 * Use lynxprog for programs such as mail which do not require a pause before 1040 * Lynx restores the display of the current document. 1041 * 1042 * Execution scripts take the form of a standard 1043 * URL. Extension mapping or MIME typing is used 1044 * to decide if the file is a script and should be 1045 * executed. The current extensions are: 1046 * .csh, .ksh, and .sh on UNIX systems and .com on 1047 * VMS systems. Any time a file of this type is 1048 * accessed Lynx will look at the user's options 1049 * settings to decide if the script can be executed. 1050 * Current options include: Only exec files that 1051 * reside on the local machine and are referenced 1052 * with a "file://localhost" URL, All execution 1053 * off, and all execution on. 1054 * 1055 * The following definitions will add execution 1056 * capabilities to Lynx. You may define none, one 1057 * or both. 1058 * 1059 * I strongly recommend that you define neither one 1060 * of these since execution links/scripts can represent 1061 * very serious security risk to your system and its 1062 * users. If you do define these I suggest that 1063 * you only allow users to execute files/scripts 1064 * that reside on your local machine. 1065 * 1066 * YOU HAVE BEEN WARNED! 1067 * 1068 * Note: if you are enabling execution scripts you should 1069 * also see src/HTInit.c to verify/change the execution 1070 * script extensions and/or commands. 1071 */ 1072 /* #define EXEC_LINKS */ 1073 /* #define EXEC_SCRIPTS */ 1074 1075 #if defined(EXEC_LINKS) || defined(EXEC_SCRIPTS) 1076 1077 /********** 1078 * if ENABLE_OPTS_CHANGE_EXEC is defined, the user will be able to change 1079 * the execution status within the Options Menu. 1080 */ 1081 /* #define ENABLE_OPTS_CHANGE_EXEC */ 1082 1083 /********** 1084 * if NEVER_ALLOW_REMOTE_EXEC is defined, 1085 * local execution of scripts or lynxexec & lynxprog URLs will be implemented 1086 * only from HTML files that were accessed via a "file://localhost/" URL 1087 * and the Options Menu for "Local executions links" will allow toggling 1088 * only between "ALWAYS OFF" and "FOR LOCAL FILES ONLY". 1089 */ 1090 /* #define NEVER_ALLOW_REMOTE_EXEC */ 1091 1092 /***************************** 1093 * These are for executable shell scripts and links. 1094 * Set to FALSE unless you really know what you're 1095 * doing. 1096 * 1097 * This only applies if you are compiling with EXEC_LINKS or 1098 * EXEC_SCRIPTS defined. 1099 * 1100 * The first two settings: 1101 * LOCAL_EXECUTION_LINKS_ALWAYS_ON 1102 * LOCAL_EXECUTION_LINKS_ON_BUT_NOT_REMOTE 1103 * specify the DEFAULT settings of the users execution link 1104 * options (they can also be overridden in lynx.cfg), but 1105 * the user may still change those options. 1106 * If you do not wish the user to be able to change the 1107 * execution link settings you may wish to use the command line option: 1108 * -restrictions=exec_frozen 1109 * 1110 * LOCAL_EXECUTION_LINKS_ALWAYS_ON will be FALSE 1111 * if NEVER_ALLOW_REMOTE_EXEC has been defined. 1112 * 1113 * if LOCAL_EXECUTION_LINKS_ALWAYS_OFF_FOR_ANONYMOUS is true, 1114 * all execution links will be disabled when the -anonymous 1115 * command-line option is used. Anonymous users are not allowed 1116 * to change the execution options from within the Lynx Options Menu, 1117 * so you might be able to use this option to enable execution links 1118 * and set LOCAL_EXECUTION_LINKS_ON_BUT_NOT_REMOTE to TRUE 1119 * to give anonymous execution-link capability without compromising 1120 * your system (see comments about TRUSTED_EXEC rules in lynx.cfg ). 1121 */ 1122 1123 #define LOCAL_EXECUTION_LINKS_ALWAYS_ON FALSE 1124 #define LOCAL_EXECUTION_LINKS_ON_BUT_NOT_REMOTE FALSE 1125 #define LOCAL_EXECUTION_LINKS_ALWAYS_OFF_FOR_ANONYMOUS FALSE 1126 1127 #endif /* defined(EXEC_LINKS) || defined(EXEC_SCRIPTS) */ 1128 1129 /********** 1130 * *** This is for those -- e.g. DOS users -- who do not have configure; 1131 * *** others should use the configure switch --enable-lynxcgi-links . 1132 * 1133 * UNIX: 1134 * ===== 1135 * CGI script support. Defining LYNXCGI_LINKS allows you to use the 1136 * 1137 * lynxcgi:path 1138 * 1139 * URL which allows lynx to access a cgi script directly without the need for 1140 * a http daemon. Redirection is not supported but just about everything 1141 * else is. If the path is not an executable file then the URL is 1142 * rewritten as file://localhost and passed to the file loader. This means 1143 * that if your http:html files are currently set up to use relative 1144 * addressing, you should be able to fire up your main page with lynxcgi:path 1145 * and everything should work as if you were talking to the http daemon. 1146 * 1147 * Note that TRUSTED_LYNXCGI directives must be defined in your lynx.cfg file 1148 * if you wish to place restrictions on source documents and/or paths for 1149 * lynxcgi links. 1150 * 1151 * The cgi scripts are called with a fork()/execve() sequence so you don't 1152 * have to worry about people trying to abuse the code. :-) 1153 * 1154 * George Lindholm (George.Lindholm@ubc.ca) 1155 * 1156 * VMS: 1157 * ==== 1158 * The lynxcgi scheme, if enabled, yields an informational message regardless 1159 * of the path, and use of the freeware OSU DECthreads server as a local 1160 * script server is recommended instead of lynxcgi URLs. Uncomment the 1161 * following line to define LYNXCGI_LINKS, and when running Lynx, enter 1162 * lynxcgi:advice as a G)oto URL for more information and links to the 1163 * OSU server distribution. 1164 */ 1165 #ifndef HAVE_CONFIG_H 1166 /* #define LYNXCGI_LINKS */ 1167 #endif 1168 1169 /********************************* 1170 * MAIL_SYSTEM_ERROR_LOGGING will send a message to the owner of 1171 * the information if there is one, every time 1172 * that a document cannot be accessed! 1173 * This is just the default, it can be changed in lynx.cfg, and error 1174 * logging can be turned off with the -nolog command line option. 1175 * 1176 * NOTE: This can generate A LOT of mail, be warned. 1177 */ 1178 #define MAIL_SYSTEM_ERROR_LOGGING FALSE /*mail a message for every error? */ 1179 1180 /********************************* 1181 * If a document cannot be accessed, and MAIL_SYSTEM_ERROR_LOGGING 1182 * is on and would send a message to the owner of the information, 1183 * but no owner is known, then the message will be sent to ALERTMAIL 1184 * instead - if it is defined as a non-empty email address. 1185 * 1186 * NOTE: This can generate A REAL LOT of mail, be warned!!! 1187 */ 1188 /* #define ALERTMAIL "webmaster@localhost" */ /*error recipient if no owner */ 1189 1190 /********************************* 1191 * If CHECKMAIL is set to TRUE, the user will be informed (via a status line 1192 * message) about the existence of any unread mail at startup of Lynx, and 1193 * will get status line messages if subsequent new mail arrives. If a jumps 1194 * file with a lynxprog URL for invoking mail is available, or your html 1195 * pages include an mail launch file URL, the user thereby can access mail 1196 * and read the messages. 1197 * This is just the default, it can be changed in lynx.cfg. The checks and 1198 * status line reports will not be performed if Lynx has been invoked with 1199 * the -restrictions=mail switch. 1200 * 1201 * VMS USERS !!! 1202 * New mail is normally broadcast as it arrives, via "unsolicited screen 1203 * broadcasts", which can be "wiped" from the Lynx display via the Ctrl-W 1204 * command. You may prefer to disable the broadcasts and use CHECKMAIL 1205 * instead (e.g., in a public account which will be used by people who 1206 * are ignorant about VMS). 1207 */ 1208 #define CHECKMAIL FALSE /* report unread and new mail messages */ 1209 1210 /********************************* 1211 * Vi or Emacs movement keys. These are defaults, 1212 * which can be changed in lynx.cfg , the Options Menu or .lynxrc . 1213 */ 1214 #define VI_KEYS_ALWAYS_ON FALSE /* familiar h j k l */ 1215 #define EMACS_KEYS_ALWAYS_ON FALSE /* familiar ^N ^P ^F ^B */ 1216 1217 /********************************* 1218 * DEFAULT_KEYPAD_MODE may be set to NUMBERS_AS_ARROWS 1219 * or LINKS_ARE_NUMBERED 1220 * or LINKS_AND_FIELDS_ARE_NUMBERED 1221 * to specify whether numbers (e.g. [10]) appear before all links, 1222 * allowing immediate access by entering the number on the keyboard, 1223 * or numbers on the numeric key-pad work like arrows; 1224 * the 3rd option causes form fields also to be preceded by numbers. 1225 * The first two options (but not the last) can be changed in lynx.cfg 1226 * and all three can be changed via the Options Menu. 1227 */ 1228 #define DEFAULT_KEYPAD_MODE NUMBERS_AS_ARROWS 1229 1230 /******************************** 1231 * The default search. 1232 * This is a default that can be overridden in lynx.cfg or by the user! 1233 */ 1234 #define CASE_SENSITIVE_ALWAYS_ON FALSE /* case sensitive user search */ 1235 1236 /******************************** 1237 * If NO_DOT_FILES is set TRUE here or in lynx.cfg, the user will not be 1238 * allowed to specify files beginning with a dot in reply to output filename 1239 * prompts, and files beginning with a dot (e.g., file://localhost/foo/.lynxrc) 1240 * will not be included in the directory browser's listings. The setting here 1241 * will be overridden by the setting in lynx.cfg. If FALSE, you can force it 1242 * to be treated as TRUE via -restrictions=dotfiles (or -anonymous, which sets 1243 * this and most other restrictions). 1244 * 1245 * If it is FALSE at startup of Lynx, the user can regulate it via the 1246 * 'o'ptions menu, and may save the preference in the RC file. 1247 */ 1248 #define NO_DOT_FILES TRUE /* disallow access to dot files */ 1249 1250 /******************************** 1251 * If MAKE_LINKS_FOR_ALL_IMAGES is TRUE, all images will be given links 1252 * which can be ACTIVATEd. For inlines, the ALT or pseudo-ALT ("[INLINE]") 1253 * strings will be links for the resolved SRC rather than just text. For 1254 * ISMAP or other graphic links, the ALT or pseudo-ALT ("[ISMAP]" or "[LINK]") 1255 * strings will have '-' and a link labeled "[IMAGE]" for the resolved SRC 1256 * appended. See also VERBOSE_IMAGES flag. 1257 * 1258 * The default defined here can be changed in lynx.cfg, and the user can 1259 * use LYK_IMAGE_TOGGLE to toggle the feature on or off at run time. 1260 * 1261 * The default also can be toggled via an "-image_links" command line switch. 1262 */ 1263 #define MAKE_LINKS_FOR_ALL_IMAGES FALSE /* inlines cast to links */ 1264 1265 /******************************** 1266 * If MAKE_PSEUDO_ALTS_FOR_INLINES is FALSE, inline images which do not 1267 * specify an ALT string will not have "[INLINE]" inserted as a pseudo-ALT, 1268 * i.e., they'll be treated as having ALT="". If MAKE_LINKS_FOR_ALL_IMAGES 1269 * is defined or toggled to TRUE, however, the pseudo-ALTs will be created 1270 * for inlines, so that they can be used as links to the SRCs. 1271 * See also VERBOSE_IMAGES flag. 1272 * 1273 * The default defined here can be changed in lynx.cfg, and the user can 1274 * use LYK_INLINE_TOGGLE to toggle the feature on or off at run time. 1275 * 1276 * The default also can be toggled via a "-pseudo_inlines" command line 1277 * switch. 1278 */ 1279 #define MAKE_PSEUDO_ALTS_FOR_INLINES TRUE /* Use "[INLINE]" pseudo-ALTs */ 1280 1281 /******************************** 1282 * If SUBSTITUTE_UNDERSCORES is TRUE, the _underline_ format will be used 1283 * for emphasis tags in dumps. 1284 * 1285 * The default defined here can be changed in lynx.cfg, and the user can 1286 * toggle the default via a "-underscore" command line switch. 1287 */ 1288 #define SUBSTITUTE_UNDERSCORES FALSE /* Use _underline_ format in dumps */ 1289 1290 /******************************** 1291 * If QUIT_DEFAULT_YES is defined as TRUE then when the QUIT command 1292 * is entered, any response other than n or N will confirm. Define it 1293 * as FALSE if you prefer the more conservative action of requiring an 1294 * explicit Y or y to confirm. The default defined here can be changed 1295 * in lynx.cfg. 1296 */ 1297 #define QUIT_DEFAULT_YES TRUE 1298 1299 /******************************** 1300 * If TEXT_SUBMIT_CONFIRM_WANTED is defined (to anything), the user will be 1301 * prompted for confirmation before Lynx submits a form with only one input 1302 * field (of type text) to the server, after the user has pressed <return> 1303 * or <enter> on the field. Since the is no other way such as a "submit" 1304 * button to submit, normally the form gets submitted automatically in this 1305 * case, but some users may find this surprising and expect <return> to just 1306 * move to the next link as for other text entry fields. 1307 */ 1308 /* #define TEXT_SUBMIT_CONFIRM_WANTED */ 1309 1310 /******************************** 1311 * If TEXTFIELDS_MAY_NEED_ACTIVATION is defined (to anything), 1312 * the option TEXTFIELDS_NEED_ACTIVATION in lynx.cfg or the command 1313 * line option -tna can be used to require explicit activation 1314 * before text input fields can be changed with the built-in line 1315 * editor. 1316 */ 1317 1318 #define TEXTFIELDS_MAY_NEED_ACTIVATION 1319 1320 /******************************** 1321 * The following three definitions control some aspects of extended 1322 * textarea handling. TEXTAREA_EXPAND_SIZE is the number of new empty 1323 * lines that get appended at the end of a textarea by a GROWTEXTAREA 1324 * key. If TEXTAREA_AUTOGROW is defined (to anything), <return> or 1325 * <enter> in the last line of a textarea automatically extends the 1326 * area by adding a new line. If TEXTAREA_AUTOEXTEDIT is defined (to 1327 * anything), a key mapped to DWIMEDIT will invoke the external editor 1328 * like EDITTEXTAREA when used in a text input field. Comment those 1329 * last two definitions out to disable the corresponding behavior. 1330 * See under KEYMAP in lynx.cfg for mapping keys to GROWTEXTAREA or 1331 * DWIMEDIT actions. 1332 */ 1333 #define TEXTAREA_EXPAND_SIZE 5 1334 #define TEXTAREA_AUTOGROW 1335 #define TEXTAREA_AUTOEXTEDIT 1336 1337 /******************************** 1338 * If BUILTIN_SUFFIX_MAPS is defined (to anything), default mappings 1339 * for file extensions (aka suffixes) will be compiled in (see 1340 * src/HTInit.c). By removing the definition, the default mappings 1341 * are suppressed except for a few very basic ones for text/html. 1342 * See GLOBAL_EXTENSION_MAP, PERSONAL_EXTENSION_MAP above and SUFFIX, 1343 * SUFFIX_ORDER in lynx.cfg for other ways to map file extensions. 1344 */ 1345 1346 #define BUILTIN_SUFFIX_MAPS 1347 1348 /******************************** 1349 * These definitions specify files created or used in conjunction 1350 * with traversals. See CRAWL.ANNOUNCE for more information. 1351 */ 1352 #define TRAVERSE_FILE "traverse.dat" 1353 #define TRAVERSE_FOUND_FILE "traverse2.dat" 1354 #define TRAVERSE_REJECT_FILE "reject.dat" 1355 #define TRAVERSE_ERRORS "traverse.errors" 1356 1357 /**************************************************************** 1358 * The LYMessages_en.h header defines default, English strings 1359 * used in status line prompts, messages, and warnings during 1360 * program execution. See the comments in LYMessages_en.h for 1361 * information on translating or customizing them for your site. 1362 */ 1363 #ifndef LYMESSAGES_EN_H 1364 #include <LYMessages_en.h> 1365 #endif /* !LYMESSAGES_EN_H */ 1366 1367 /**************************************************************** 1368 * DEFAULT_VISITED_LINKS may be set to one or more of 1369 * VISITED_LINKS_AS_FIRST_V 1370 * VISITED_LINKS_AS_TREE 1371 * VISITED_LINKS_AS_LATEST 1372 * VISITED_LINKS_REVERSE 1373 * to change the organization of the Visited Links page. 1374 * 1375 * (Not all combinations are meaningful; see src/LYrcFile.c for a list 1376 * in the visited_links_tbl table). 1377 */ 1378 #define DEFAULT_VISITED_LINKS (VISITED_LINKS_AS_LATEST | VISITED_LINKS_REVERSE) 1379 1380 /**************************************************************** 1381 * If USE_CACHEJAR is set to TRUE the user will be able to view, 1382 * access and delete cached documents in current lynx session. 1383 */ 1384 #ifndef USE_CACHEJAR 1385 /* #define USE_CACHEJAR TRUE */ 1386 #endif 1387 1388 /**************************************************************** 1389 * If USE_SESSIONS is set to TRUE the user will be able to save, 1390 * resume and in general manipulate with lynx sessions. 1391 */ 1392 #ifndef USE_SESSIONS 1393 /* #define USE_SESSIONS TRUE */ 1394 #endif 1395 1396 #define MAX_SESSIONS 10000 1397 1398 /* 1399 * If USE_SESSIONS is TRUE you may tune it fine how it will work: 1400 */ 1401 #define GOTOURL_IN_SESSION /* Allow to save goto url */ 1402 #define GOTOURL_OUT_SESSION /* Allow to restore goto url */ 1403 #define HISTORY_IN_SESSION /* Allow to save history */ 1404 #define HISTORY_OUT_SESSION /* Allow to restore history */ 1405 #define SEARCH_IN_SESSION /* Allow to save search string */ 1406 #define SEARCH_OUT_SESSION /* Allow to restore search string */ 1407 #define VLINK_IN_SESSION /* Allow to save visited link */ 1408 #define VLINK_OUT_SESSION /* Allow to restore visited link */ 1409 1410 /**************************************************************** 1411 * The STATUSBUFSIZE defines how many entries will be stored in 1412 * cyclic buffer of statusline messages. This is specially useful 1413 * for users who use lynx on a terminal with more than 40 lines. 1414 */ 1415 /* #define STATUSBUFSIZE 90 */ 1416 1417 /**************************************************************** 1418 * If USE_PROGRESSBAR is TRUE the user will be able to set 1419 * download progress as odometer(thermometer) display, ie: 1420 * 1421 * 80% IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII 1422 * 1423 */ 1424 /* #define USE_PROGRESSBAR TRUE */ 1425 1426 /**************************************************************** 1427 * Section 3. Things that you should not change until you 1428 * have a good knowledge of the program 1429 */ 1430 1431 #define LYNX_NAME "Lynx" 1432 /* The strange-looking comments on the next line tell PRCS to replace 1433 * the version definition with the Project Version on checkout. Just 1434 * ignore it. - kw */ 1435 /* $Format: "#define LYNX_VERSION \"$ProjectVersion$\""$ */ 1436 #ifndef LYNX_VERSION 1437 #define LYNX_VERSION "2.8.8dev.16" 1438 #endif 1439 #define LYNX_WWW_HOME "http://lynx.isc.org/" 1440 #define LYNX_WWW_DIST "http://lynx.isc.org/current/" 1441 /* $Format: "#define LYNX_DATE \"$ProjectDate$\""$ */ 1442 #define LYNX_DATE "Mon, 29 Jul 2013 14:38:35 -0700" 1443 #define LYNX_DATE_OFF 5 /* truncate the automatically-generated date */ 1444 #define LYNX_DATE_LEN 11 /* truncate the automatically-generated date */ 1445 1446 #ifdef UNICODE 1447 #define W32_STRING(s) L##s 1448 #else 1449 #define W32_STRING(s) s 1450 #endif 1451 1452 #define LYNX_SUBKEY W32_STRING("Software\\Lynx") 1453 1454 #define LINESIZE 1024 /* max length of line to read from file */ 1455 #define MAXLINKS 1024 /* max links on one screen */ 1456 1457 #ifndef SEARCH_GOAL_LINE 1458 #define SEARCH_GOAL_LINE 4 /* try to position search target there */ 1459 #endif 1460 1461 #define MAXCHARSETS 60 /* max character sets supported */ 1462 #define TRST_MAXROWSPAN 200 /* max rowspan accepted by TRST code */ 1463 #define TRST_MAXCOLSPAN 200 /* max colspan and COL/COLGROUP span accepted */ 1464 #define MAX_TABLE_ROWS 200 /* max rows for tables */ 1465 #define MAX_TABLE_COLS 200 /* max cols for tables */ 1466 #define SAVE_TIME_NOT_SPACE /* minimize number of some malloc calls */ 1467 1468 /* Win32 may support more, but old win16 helper apps may not. */ 1469 #if defined(__DJGPP__) || defined(_WINDOWS) 1470 #define FNAMES_8_3 1471 #endif 1472 1473 #if 1 /* #ifdef FNAMES_8_3 */ 1474 #define HTML_SUFFIX ".htm" 1475 #else 1476 #define HTML_SUFFIX ".html" 1477 #endif 1478 1479 #ifndef FNAME_LYNXRC 1480 #ifdef FNAMES_8_3 1481 #define FNAME_LYNXRC "lynx.rc" 1482 #else 1483 #define FNAME_LYNXRC ".etc/lynxrc" 1484 #endif /* FNAMES_8_3 */ 1485 #endif 1486 1487 #ifndef FNAME_LYNX_COOKIES 1488 #ifdef FNAMES_8_3 1489 #define FNAME_LYNX_COOKIES "cookies" 1490 #else 1491 #define FNAME_LYNX_COOKIES ".etc/cookies.txt" 1492 #endif /* FNAMES_8_3 */ 1493 #endif 1494 1495 #ifndef FNAME_LYNX_TRACE 1496 #ifdef FNAMES_8_3 1497 #define FNAME_LYNX_TRACE "LY-TRACE.LOG" 1498 #else 1499 #define FNAME_LYNX_TRACE "Lynx.trace" 1500 #endif /* FNAMES_8_3 */ 1501 #endif 1502 1503 #ifndef BLAT_MAIL 1504 #define BLAT_MAIL "blat" 1505 #endif 1506 1507 #ifndef ALTBLAT_MAIL 1508 #define ALTBLAT_MAIL "blatj" 1509 #endif 1510 1511 #define BIN_SUFFIX ".bin" 1512 #define TEXT_SUFFIX ".txt" 1513 1514 #ifdef VMS 1515 /* 1516 ** Use the VMS port of gzip for uncompressing both .Z and .gz files. 1517 */ 1518 #define UNCOMPRESS_PATH "gzip -d" 1519 #define COPY_PATH "copy/nolog/noconf" 1520 #define GZIP_PATH "gzip" 1521 #define BZIP2_PATH "bzip2" 1522 #define TELNET_PATH "telnet" 1523 #define TN3270_PATH "tn3270" 1524 #define RLOGIN_PATH "rlogin" 1525 1526 #else 1527 1528 #ifdef DOSPATH 1529 1530 /* 1531 * Define this to setup feature that uses directory of lynx.exe to locate 1532 * associated configuration files. 1533 #define USE_PROGRAM_DIR 1 1534 */ 1535 1536 #ifdef _WINDOWS 1537 1538 #ifndef USE_BLAT_MAILER 1539 #define USE_BLAT_MAILER 1 1540 #endif 1541 1542 #else 1543 /* have to define something... */ 1544 #undef SYSTEM_MAIL 1545 #define SYSTEM_MAIL "sendmail" 1546 #define SYSTEM_MAIL_FLAGS "-t -oi" 1547 #endif /* _WINDOWS */ 1548 1549 /* 1550 ** The following executables may be used at run time. Unless you change 1551 ** the definitions to include the full directories, they will be sought 1552 ** from your PATH at run-time; they should be available as "cp.exe", 1553 ** "mv.exe" and so on. To get those programs look for GNU-port stuff 1554 ** elsewhere. 1555 ** Currently, if compiled with -DUSE_ZLIB and without -DDIRED_SUPPORT 1556 ** (default), the following from the list below are required: 1557 ** MV_PATH (mv.exe) - for bookmark handling (DEL_BOOKMARK command) 1558 ** UNCOMPRESS_PATH - for automatic decompression of files in Unix 1559 ** compress format 1560 ** TELNET_PATH, TN3270_PATH, RLOGIN_PATH - for access to "telnet:", 1561 ** "tn3270:", and "rlogin:" URLs. 1562 ** If they are not defined right, the corresponding operations may fail 1563 ** in unexpected and obscure ways! 1564 ** 1565 ** WINDOWS/DOS 1566 ** =========== 1567 */ 1568 #ifndef HAVE_CONFIG_H 1569 #define COMPRESS_PATH "compress" 1570 #define UNCOMPRESS_PATH "uncompress" 1571 #define UUDECODE_PATH "uudecode" 1572 #define ZCAT_PATH "zcat" 1573 #define GZIP_PATH "gzip" 1574 #define BZIP2_PATH "bzip2" 1575 #define MV_PATH "mv" 1576 #define INSTALL_PATH "install" 1577 #define TAR_PATH "tar" 1578 #define ZIP_PATH "zip" 1579 #define UNZIP_PATH "unzip" 1580 #define RM_PATH "rm" 1581 #define TELNET_PATH "telnet" 1582 #define TN3270_PATH "tn3270" 1583 #define RLOGIN_PATH "rlogin" 1584 1585 /* see src/LYLocal.c for these */ 1586 #define TAR_UP_OPTIONS "-cf" 1587 #define TAR_DOWN_OPTIONS "-xf" 1588 #define TAR_PIPE_OPTIONS "-" 1589 #define TAR_FILE_OPTIONS "" 1590 1591 /* 1592 * These are not used: 1593 * #define COPY_PATH "cp" 1594 * #define CHMOD_PATH "chmod" 1595 * #define MKDIR_PATH "mkdir" 1596 * #define TOUCH_PATH "touch" 1597 */ 1598 #endif /* HAVE_CONFIG_H */ 1599 1600 #else /* Unix */ 1601 /* Standard locations are defined via the configure script. When 1602 * helper applications are in your home directory or other nonstandard 1603 * locations, you probably will have to preset the path to them with 1604 * environment variables (see INSTALLATION, Section II-1d). 1605 */ 1606 #endif /* DOSPATH */ 1607 #endif /* VMS */ 1608 1609 /***************************** 1610 * I have not ported multibyte support for EBCDIC. In fact, some multibyte 1611 * code in LYLowerCase() crashes on EBCDIC strings. -- gil 1612 */ 1613 #if ! defined(NOT_ASCII) 1614 /***************************** 1615 * SUPPORT_MULTIBYTE_EDIT provides better support of CJK characters to 1616 * Lynx' Line Editor. JIS X0201 Kana is partially supported. The 1617 * reason why I didn't support it fully is I think supporting it is not 1618 * required so much and I don't have an environment to test it. - TH 1619 */ 1620 #define SUPPORT_MULTIBYTE_EDIT 1621 #endif /* ! defined(NOT_ASCII) */ 1622 1623 /***************************** 1624 * SUPPORT_CHDIR provides CD command (bound to 'C' by default). It allows 1625 * changing directory to arbitrary location (if OS allows them). If dired is 1626 * enabled, user will be able to visit any directory and view any file allowed 1627 * according to file permissions or ACLs. 1628 */ 1629 #define SUPPORT_CHDIR 1630 1631 /***************************** 1632 * MARK_HIDDEN_LINKS controls whether hidden links are shown with the title 1633 * set by the HIDDEN_LINK_MARKER string in lynx.cfg 1634 */ 1635 #define MARK_HIDDEN_LINKS 1636 1637 /***************************** 1638 * USE_TH_JP_AUTO_DETECT and KANJI_CODE_OVERRIDE are the macros 1639 * for Japanese. - TH 1640 */ 1641 /***************************** 1642 * USE_TH_JP_AUTO_DETECT enables a new Japanese charset detection routine. 1643 * With the old detection strategy, Lynx always thought a document was 1644 * written in mixture of three kanji codes (JIS, EUC and SJIS). The new 1645 * strategy is for Lynx to first assume the document is written in one code 1646 * or JIS + one other kanji code (JIS, EUC, SJIS, EUC+JIS and SJIS+JIS). 1647 * The first assumption is usually correct, but if the assumption is wrong, 1648 * Lynx falls back to the old assumption of the three kanji codes mixed. 1649 */ 1650 #define USE_TH_JP_AUTO_DETECT 1651 1652 /***************************** 1653 * Uncomment the following line to enable the kanji code override routine. 1654 * The code can be changed by pressing Shift-J. More precisely, this allows 1655 * the user to override the assumption about the kanji code for the document 1656 * which Lynx has made on the basis of a META tag and HTTP response. 1657 */ 1658 #define KANJI_CODE_OVERRIDE 1659 1660 /************************** 1661 * SSL_CERT_FILE contains valid SSL CA certificates. Set this to a string 1662 * to provide a runtime default value. 1663 */ 1664 #define SSL_CERT_FILE NULL 1665 1666 /**************************************************************** 1667 * Section 4. Things you MUST check only if you plan to use Lynx 1668 * in an anonymous account (allow public access to Lynx). 1669 * This section may be skipped by those people building 1670 * Lynx for private use only. 1671 * 1672 */ 1673 1674 /***************************** 1675 * Enter the name of your anonymous account if you have one 1676 * as ANONYMOUS_USER. UNIX systems will use a cuserid 1677 * or get_login call to determine if the current user is 1678 * the ANONYMOUS_USER. VMS systems will use getenv("USER"). 1679 * 1680 * You may use the "-anonymous" option for multiple accounts, 1681 * or for precautionary reasons in the anonymous account, as well. 1682 * 1683 * Specify privileges for the anonymous account below. 1684 * 1685 * It is very important to have this correctly defined or include 1686 * the "-anonymous" command line option for invocation of Lynx 1687 * in an anonymous account! If you do not you will be putting 1688 * yourself at GREAT security risk! 1689 */ 1690 #define ANONYMOUS_USER "" 1691 1692 /******************************* 1693 * In the following four pairs of defines, 1694 * INSIDE_DOMAIN means users connecting from inside your local domain, 1695 * OUTSIDE_DOMAIN means users connecting from outside your local domain. 1696 * 1697 * set to FALSE if you don't want users of your anonymous 1698 * account to be able to telnet back out 1699 */ 1700 #define CAN_ANONYMOUS_INSIDE_DOMAIN_TELNET TRUE 1701 #define CAN_ANONYMOUS_OUTSIDE_DOMAIN_TELNET FALSE 1702 1703 /******************************* 1704 * set to FALSE if you don't want users of your anonymous 1705 * account to be able to use ftp 1706 */ 1707 #define CAN_ANONYMOUS_INSIDE_DOMAIN_FTP TRUE 1708 #define CAN_ANONYMOUS_OUTSIDE_DOMAIN_FTP FALSE 1709 1710 /******************************* 1711 * set to FALSE if you don't want users of your anonymous 1712 * account to be able to use rlogin 1713 */ 1714 #define CAN_ANONYMOUS_INSIDE_DOMAIN_RLOGIN TRUE 1715 #define CAN_ANONYMOUS_OUTSIDE_DOMAIN_RLOGIN FALSE 1716 1717 /******************************* 1718 * set to FALSE if you don't want users of your anonymous 1719 * account to be able to read news OR post news articles. 1720 * These flags apply to "news", "nntp", "newspost", and "newsreply" 1721 * URLs, but not to "snews", "snewspost", or "snewsreply" 1722 * in case they are supported. 1723 */ 1724 #define CAN_ANONYMOUS_INSIDE_DOMAIN_READ_NEWS TRUE 1725 #define CAN_ANONYMOUS_OUTSIDE_DOMAIN_READ_NEWS FALSE 1726 1727 /******************************* 1728 * set to FALSE if you don't want users of your anonymous 1729 * account to be able to goto random URLs. (The 'g' command) 1730 */ 1731 #define CAN_ANONYMOUS_GOTO TRUE 1732 1733 /******************************* 1734 * set to FALSE if you don't want users of your anonymous 1735 * account to be able to goto particular URLs. 1736 */ 1737 #define CAN_ANONYMOUS_GOTO_BIBP TRUE /* BIBP maps to HTTP */ 1738 #define CAN_ANONYMOUS_GOTO_CSO FALSE 1739 #define CAN_ANONYMOUS_GOTO_FILE FALSE 1740 #define CAN_ANONYMOUS_GOTO_FINGER TRUE 1741 #define CAN_ANONYMOUS_GOTO_FTP FALSE 1742 #define CAN_ANONYMOUS_GOTO_GOPHER FALSE 1743 #define CAN_ANONYMOUS_GOTO_HTTP TRUE 1744 #define CAN_ANONYMOUS_GOTO_HTTPS FALSE 1745 #define CAN_ANONYMOUS_GOTO_LYNXCGI FALSE 1746 #define CAN_ANONYMOUS_GOTO_LYNXEXEC FALSE 1747 #define CAN_ANONYMOUS_GOTO_LYNXPROG FALSE 1748 #define CAN_ANONYMOUS_GOTO_MAILTO TRUE 1749 #define CAN_ANONYMOUS_GOTO_NEWS FALSE 1750 #define CAN_ANONYMOUS_GOTO_NNTP FALSE 1751 #define CAN_ANONYMOUS_GOTO_RLOGIN FALSE 1752 #define CAN_ANONYMOUS_GOTO_SNEWS FALSE 1753 #define CAN_ANONYMOUS_GOTO_TELNET FALSE 1754 #define CAN_ANONYMOUS_GOTO_TN3270 FALSE 1755 #define CAN_ANONYMOUS_GOTO_WAIS TRUE 1756 1757 /******************************* 1758 * set to FALSE if you don't want users of your anonymous 1759 * account to be able to specify a port in 'g'oto commands 1760 * for telnet URLs. 1761 */ 1762 #define CAN_ANONYMOUS_GOTO_TELNET_PORT FALSE 1763 1764 /******************************* 1765 * set to FALSE if you don't want users of your anonymous 1766 * account to be able to jump to URLs (The 'J' command) 1767 * via the shortcut entries in your JUMPFILE. 1768 */ 1769 #define CAN_ANONYMOUS_JUMP FALSE 1770 1771 /******************************* 1772 * set to FALSE if you don't want users of your anonymous 1773 * account to be able to mail 1774 */ 1775 #define CAN_ANONYMOUS_MAIL TRUE 1776 1777 /******************************* 1778 * set to FALSE if you don't want users of your anonymous 1779 * account to be able to print 1780 */ 1781 #define CAN_ANONYMOUS_PRINT FALSE 1782 1783 /******************************* 1784 * set to FALSE if users with anonymous restrictions should 1785 * not be able to view configuration file (lynx.cfg) info 1786 * via special LYNXCFG: links. (This does not control access 1787 * to lynx.cfg as a normal file, e.g., through a "file:" URL, 1788 * if other restrictions allow that.) 1789 */ 1790 #define CAN_ANONYMOUS_VIEW_LYNXCFG_INFO FALSE 1791 1792 /******************************* 1793 * set to FALSE if users with anonymous restrictions should 1794 * not be able to view extended configuration file (lynx.cfg) 1795 * info @@@ or perform special config info functions (reloading 1796 * at run-time) via special LYNXCFG: links @@@. This only applies 1797 * if the lynxcfg_info" restriction controlled by the previous 1798 * item is not in effect and if Lynx has been compiled without 1799 * NO_CONFIG_INFO defined (--disable-config-info wasn't used 1800 * if Lynx was built with the autoconf configure script). 1801 * The extended info may include details on configuration file 1802 * names and location and links for reading the files, as well 1803 * as information on nesting of included configuration files. 1804 */ 1805 #define CAN_ANONYMOUS_VIEW_LYNXCFG_EXTENDED_INFO FALSE 1806 1807 /******************************* 1808 * set to FALSE if users with anonymous restrictions should 1809 * not be able to view information on compile time configuration 1810 * via special LYNXCOMPILEOPTS: links. This only applies 1811 * if the autoconf configure script was used to build Lynx 1812 * AND --disable-config-info wasn't used, otherwise this 1813 * special URL scheme isn't recognized anyway. 1814 */ 1815 #define CAN_ANONYMOUS_VIEW_COMPILEOPTS_INFO FALSE 1816 1817 /******************************* 1818 * set to FALSE if you don't want users of your anonymous 1819 * account to be able to 'g'oto special URLs for showing 1820 * configuration info (LYNXCFG: and LYNXCOMPILEOPTS:) if 1821 * they are otherwise allowed. 1822 */ 1823 #define CAN_ANONYMOUS_GOTO_CONFIGINFO FALSE 1824 1825 /***************************** 1826 * Be sure you have read about and set defines above in Sections 1827 * 1, 2 and 3 that could affect Lynx in an anonymous account, 1828 * especially LOCAL_EXECUTION_LINKS_ALWAYS_OFF_FOR_ANONYMOUS. 1829 * 1830 * This ends the section specific to anonymous accounts. 1831 */ 1832 1833 /***************************** 1834 * These can be uncommmented to get more detail when debugging changes to 1835 * the color-style and layout logic. 1836 */ 1837 /*#define DEBUG_APPCH 1*/ 1838 /*#define DEBUG_STYLE 1*/ 1839 1840 #ifdef DEBUG_STYLE 1841 #define CTRACE_STYLE(p) CTRACE2(TRACE_STYLE, p) 1842 #else 1843 #define CTRACE_STYLE(p) /* nothing */ 1844 #endif 1845 1846 /* #define DEBUG_SPLITLINE */ 1847 1848 #ifdef DEBUG_SPLITLINE 1849 #define CTRACE_SPLITLINE(p) CTRACE(p) 1850 #else 1851 #define CTRACE_SPLITLINE(p) /*nothing */ 1852 #endif 1853 1854 #endif /* USERDEFS_H */ 1855