aboutsummaryrefslogtreecommitdiffstats
path: root/sample.rcfile
blob: 865b3a1891fd27fcbacb59dcc80fd8ca750b667d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
# fetchmail control file sample (remove this header comment from yours!)
#
# This file (or one of your own creation, rather) should be located 
# in your home directory with the name .fetchmailrc.  Permissions on this
# file may be no greater than -rw------- (0600), or fetchmail will refuse to
# use it.
#
# To see what effect your ~/.fetchmailrc file has, do 
#
#	fetchmail --version
#
# This will display the fetchmail version number and an explanation
# in English of what the currently set options and defaults mean.
#
# Comments begin with a '#' and extend through the end of the line.
# Blank lines between server entries are ignored.
# Keywords and identifiers are case sensitive.
# When there is a conflict between the command-line arguments and the
# arguments in this file, the command-line arguments take precedence.
#
# Legal keywords are
#   poll                      -- must be followed by a mailserver name or label
#   skip                      -- must be followed by a mailserver name or label
#   via                       -- must be followed by true name of host to poll
#   interval                  -- must be followed by an interval skip count
#   protocol (or proto)       -- must be followed by a protocol ID
#   uidl
#   no uidl
#   port                      -- must be followed by a TCP/IP port number
#   principal                 -- must be followed by a principal name
#   ssl
#   sslkeyfile                -- must be followed by path to private key file
#   sslcertfile               -- must be followed by path to certificate file
#   authenticate (or auth)    -- must be followed by an authentication type
#   timeout                   -- must be followed by a numeric timeout value
#   envelope                  -- must be followed by an envelope header name
#   qvirtual                  -- must be followed by a name prefix
#   no envelope
#   aka                       -- must be followed by one or more server aliases
#   localdomains              -- must be followed by one or more domain names
#   interface                 -- must be followed by device/IP address/mask
#   monitor                   -- must be followed by device
#   plugin                    -- must be followed by a string command name
#   plugout                   -- must be followed by a string command name
#   dns
#   no dns
#   checkalias                -- do multidrop address comparison by IP address
#   no checkalias             -- do multidrop address comparison by name
#
#   username (or user)        -- must be followed by a name
#   is                        -- must be followed by one or more names
#   folder                    -- must be followed by remote folder names
#   password (or pass)        -- must be followed by a password string
#   smtphost (or smtp)        -- must be followed by host names
#   smtpaddress               -- must be followed by a host name
#   antispam                  -- must be followed by a numeric response value
#   mda                       -- must be followed by an MDA command string
#   bsmtp                     -- must be followed by a filename or -
#   lmtp
#   preconnect (or pre)       -- must be followed by an executable command
#   postconnect (or post)     -- must be followed by an executable command
#
#   keep
#   flush
#   fetchall
#   rewrite
#   forcecr
#   stripcr
#   pass8bits
#   dropstatus
#   mimedecode
#   idle
#   no keep
#   no flush
#   no fetchall
#   no rewrite
#   no forcecr
#   no stripcr
#   no pass8bits
#   no dropstatus
#   no mimedecode
#   no idle
#   limit                     -- must be followed by numeric size limit
#   warnings                  -- must be followed by numeric size limit
#   fetchlimit                -- must be followed by numeric msg fetch limit
#   batchlimit                -- must be followed by numeric SMTP batch limit
#   expunge                   -- must be followed by numeric delete count
#   properties                -- must be followed by a string
#
# Legal protocol identifiers are
#   pop2 (or POP2)
#   pop3 (or POP3)
#   imap (or IMAP)
#   imap-k4 (or IMAP-K4)
#   apop (or APOP)
#   rpop (or RPOP)
#   kpop (or KPOP)
#   etrn (or ETRN)
#
# Add ssl for protocols operating over an SSL connection (POP3 and IMAP)
#   Default port for IMAPS (IMAP over SSL) is 993
#   Default port for POP3S (POP3 over SSL) is 995
#      Taken from assigned numbers and compatible with netscape/outlook usage.
#
# Legal authentication types are
#   login
#   kerberos
#   kerberos_v5
#
# Legal global option statements are
#
#   set logfile			-- must be followed by a string
#   set idfile			-- must be followed by a string
#   set postmaster		-- must be followed by a string
#   set daemon			-- must be followed by a number   
#   set syslog
#   set invisible
#   set showdots
#
# The noise keywords `and', `with', `has', `wants', and `options' are ignored
# anywhere in an entry; they can be used to make it resemble English.  The
# punctuation characters `,' `:' `;' are also ignored. 
#
# The run control file format is fully described (with more examples) on the
# fetchmail manual page.
# 
# This is what the developer's .fetchmailrc looks like:

set daemon 300	# Poll at 5-minute intervals

defaults
	interface "sl0/10.0.2.15"	# SLIRP standard address
	user esr is esr fetchmail-friends magic-numbers here
	fetchall

# Use this for production
poll imap.ccil.org protocol IMAP:
	no dns, aka snark.thyrsus.com thyrsus.com locke.ccil.org ccil.org 
	password my_remote_password;

# Use this to test POP3
skip pop3.ccil.org with protocol APOP:
	no dns, aka snark.thyrsus.com thyrsus.com locke.ccil.org ccil.org 
	password my_apop_secret;

# Use this to test against a different server
skip pop3.netaxs.com:
	password my_netaxs.password;
ss="p">, options, long_options, opt_index, 0); } /* Like getopt_long, but '-' as well as '--' can indicate a long option. If an option that starts with '-' (not '--') doesn't match a long option, but does match a short option, it is parsed as a short option instead. */ int getopt_long_only (argc, argv, options, long_options, opt_index) int argc; char *const *argv; const char *options; const struct option *long_options; int *opt_index; { return _getopt_internal (argc, argv, options, long_options, opt_index, 1); } #endif /* _LIBC or not __GNU_LIBRARY__. */ #ifdef TEST #include <stdio.h> int main (argc, argv) int argc; char **argv; { int c; int digit_optind = 0; while (1) { int this_option_optind = optind ? optind : 1; int option_index = 0; static struct option long_options[] = { {"add", 1, 0, 0}, {"append", 0, 0, 0}, {"delete", 1, 0, 0}, {"verbose", 0, 0, 0}, {"create", 0, 0, 0}, {"file", 1, 0, 0}, {0, 0, 0, 0} }; c = getopt_long (argc, argv, "abc:d:0123456789", long_options, &option_index); if (c == EOF) break; switch (c) { case 0: printf ("option %s", long_options[option_index].name); if (optarg) printf (" with arg %s", optarg); printf ("\n"); break; case '0': case '1': case '2': case '3': case '4': case '5': case '6': case '7': case '8': case '9': if (digit_optind != 0 && digit_optind != this_option_optind) printf ("digits occur in two different argv-elements.\n"); digit_optind = this_option_optind; printf ("option %c\n", c); break; case 'a': printf ("option a\n"); break; case 'b': printf ("option b\n"); break; case 'c': printf ("option c with value `%s'\n", optarg); break; case 'd': printf ("option d with value `%s'\n", optarg); break; case '?': break; default: printf ("?? getopt returned character code 0%o ??\n", c); } } if (optind < argc) { printf ("non-option ARGV-elements: "); while (optind < argc) printf ("%s ", argv[optind++]); printf ("\n"); } exit (0); } #endif /* TEST */