emacs - mu4e headers
[dotfiles.git] / miscellanea / offlineimap.conf
1 # Offlineimap sample configuration file
2
3 # This file documents *all* possible options and can be quite scary.
4 # Looking for a quick start?  Take a look at offlineimap.conf.minimal.
5 # More details can be found at http://www.offlineimap.org .
6
7 ##################################################
8 # Overview
9 ##################################################
10
11 # The default configuration file is "~/.offlineimaprc".
12 #
13 # OfflineIMAP ships with a file named "offlineimap.conf" that you should copy to
14 # that location and then edit.
15 #
16 # OfflineIMAP also ships a file named "offlineimap.conf.minimal" that you can
17 # also try.  It's useful if you want to get started with the most basic feature
18 # set, and you can read about other features later with "offlineimap.conf".
19 #
20 # If you want to be XDG-compatible, you can put your configuration file into
21 # "$XDG_CONFIG_HOME/offlineimap/config".
22
23 ##################################################
24 # General definitions
25 ##################################################
26
27 # NOTE 1: Settings generally support python interpolation. This means
28 # values can contain python format strings which refer to other values
29 # in the same section, or values in a special DEFAULT section. This
30 # allows you for example to use common settings for multiple accounts:
31 #
32 # [Repository Gmail1]
33 # trashfolder: %(gmailtrashfolder)s
34 #
35 # [Repository Gmail2]
36 # trashfolder: %(gmailtrashfolder)s
37 #
38 # [DEFAULT]
39 # gmailtrashfolder = [Gmail]/Papierkorb
40 #
41 # would set the trashfolder setting for your German Gmail accounts.
42
43 # NOTE 2: Above feature implies that any '%' needs to be encoded as '%%'
44
45 # NOTE 3: Any variable that is subject to the environment variables
46 # ($NAME) and tilde (~username/~) expansions will receive tilde
47 # expansion first and only after the environment variable will be
48 # expanded in the resulting string. This behaviour is intentional
49 # as it coincides with typical shell expansion strategy.
50
51 # NOTE 4: multiple same-named sections.
52 # The library used to parse the configuration file has known issue when multiple
53 # sections have the same name. In such case, only the last section is considered.
54 # It is strongly discouraged to have multiple sections with the same name.
55 # See https://github.com/OfflineIMAP/offlineimap/issues/143 for more details.
56
57 [general]
58
59 # This specifies where OfflineIMAP is to store its metadata.
60 # This directory will be created if it does not already exist.
61 #
62 # Tilde and environment variable expansions will be performed.
63 #
64 #metadata = ~/.offlineimap
65
66
67 # This option stands in the [general] section.
68 #
69 # This variable specifies which accounts are defined. Separate them with commas.
70 # Account names should be alphanumeric only. You will need to specify one
71 # section per account below. You may not use "general" for an account name.
72 #
73 # Always use ASCII characters only.
74 #
75 accounts = Test
76
77
78 # This option stands in the [general] section.
79 #
80 # Offlineimap can synchronize more than one account at a time. If you want to
81 # enable this feature, set the below value to something greater than 1.  To
82 # force it to synchronize only one account at a time, set it to 1.
83 #
84 # NOTE: if you are using autorefresh and have more than one account, you must
85 # set this number to be >= to the number of accounts you have; since any given
86 # sync run never "finishes" due to a timer, you will never sync your additional
87 # accounts if this is 1.
88 #
89 #maxsyncaccounts = 1
90
91
92 # This option stands in the [general] section.
93 #
94 # You can specify one or more user interface. OfflineIMAP will try the first in
95 # the list, and if it fails, the second, and so forth.
96 #
97 # The pre-defined options are:
98 # Blinkenlights -- A fancy (terminal) interface
99 # TTYUI         -- a text-based (terminal) interface
100 # Basic         -- Noninteractive interface suitable for cron'ing
101 # Quiet         -- Noninteractive interface, generates no output
102 #                  except for errors.
103 # MachineUI     -- Interactive interface suitable for machine
104 #                  parsing.
105 #
106 # See also offlineimapui(7)
107 #
108 # You can override this with a command-line option -u.
109 #
110 #ui = basic
111
112
113 # This option stands in the [general] section.
114 #
115 # If you try to synchronize messages to a folder which the IMAP server
116 # considers read-only, OfflineIMAP will generate a warning.  If you want
117 # to suppress these warnings, set ignore-readonly to yes.  Read-only
118 # IMAP folders allow reading but not modification, so if you try to
119 # change messages in the local copy of such a folder, the IMAP server
120 # will prevent OfflineIMAP from propagating those changes to the IMAP
121 # server.  Note that ignore-readonly is UNRELATED to the "readonly"
122 # setting which prevents a repository from being modified at all.
123 #
124 #ignore-readonly = no
125
126
127 ########## Advanced settings
128
129 # This option stands in the [general] section.
130 #
131 # You can give a Python source filename here and all config file
132 # python snippets will be evaluated in the context of that file.
133 # This allows you to e.g. define helper functions in the Python
134 # source file and call them from this config file.  You can find
135 # an example of this in the manual.
136 #
137 # Tilde and environment variable expansions will be performed.
138 #
139 #pythonfile = ~/.offlineimap.py
140
141
142 # This option is in the [general] section.
143 #
144 # By default, OfflineIMAP will not exit due to a network error until the
145 # operating system returns an error code.  Operating systems can sometimes take
146 # forever to notice this.  Here you can activate a timeout on the socket.  This
147 # timeout applies to individual socket reads and writes, not to an overall sync
148 # operation.  You could perfectly well have a 30s timeout here and your sync
149 # still take minutes.
150 #
151 # Values in the 30-120 second range are reasonable.
152 #
153 # The default is to have no timeout beyond the OS.  Times are given in seconds.
154 #
155 #socktimeout = 60
156
157
158 # This option stands in the [general] section.
159 #
160 # By default, OfflineIMAP will use fsync() to force data out to disk at
161 # opportune times to ensure consistency.  This can, however, reduce performance.
162 # Users where /home is on SSD (Flash) may also wish to reduce write cycles.
163 # Therefore, you can disable OfflineIMAP's use of fsync().  Doing so will come
164 # at the expense of greater risk of message duplication in the event of a system
165 # crash or power loss.  Default is true.  Set it to false to disable fsync.
166 #
167 #fsync = true
168
169
170 ##################################################
171 # Mailbox name recorder
172 ##################################################
173
174 [mbnames]
175
176 # OfflineIMAP can record your mailbox names in a format you specify.
177 # You can define the header, each mailbox item, the separator,
178 # and the footer.  Here is an example for Mutt.
179 # If enabled is yes, all six setting must be specified, even if they
180 # are just the empty string "".
181 #
182 # The header, peritem, sep, and footer are all Python expressions passed
183 # through eval, so you can (and must) use Python quoting.
184 #
185 # The incremental setting controls whether the file is written after each
186 # account completes or once all synced accounts are complete. This is usefull if
187 # an account is sightly slower than the other. It allows keeping the previous
188 # file rather than having it partially written.
189 # This works best with "no" if in one-shot mode started by cron or systemd
190 # timers. Default: no.
191 #
192 # The following hash key are available to the expansion for 'peritem':
193 # - accountname: the name of the corresponding account;
194 # - foldername: the name of the folder;
195 # - localfolders: path to the local directory hosting all Maildir
196 #   folders for the account.
197 #
198 # Tilde and environment variable expansions will be performed
199 # for "filename" knob.
200 #
201 #enabled = no
202 #filename = ~/Mutt/muttrc.mailboxes
203 #header = "mailboxes "
204 #peritem = "+%(accountname)s/%(foldername)s"
205 #sep = " "
206 #footer = "\n"
207 #incremental = no
208
209
210 # This option stands in the [mbnames] section.
211 #
212 # You can also specify a folderfilter.  It will apply to the *translated* folder
213 # name here, and it takes TWO arguments: accountname and foldername.  In all
214 # other ways, it will behave identically to the folderfilter for accounts.
215 # Please see the folderfilter option for more information and examples.
216 #
217 # This filter can be used only to further restrict mbnames to a subset of
218 # folders that pass the account's folderfilter.
219 #
220 # You can customize the order in which mailbox names are listed in the generated
221 # file by specifying a sort_keyfunc, which takes a single dict argument
222 # containing keys 'accountname' and 'foldername'.  This function will be called
223 # once for each mailbox, and should return a suitable sort key that defines this
224 # mailbox' position in the custom ordering.
225 #
226 # This is useful with e.g. Mutt-sidebar, which uses the mailbox order from the
227 # generated file when listing mailboxes in the sidebar.
228 #
229 # Default setting is:
230 #sort_keyfunc = lambda d: (d['accountname'], d['foldername'])
231
232
233 ##################################################
234 # Accounts
235 ##################################################
236
237 # This is an account definition clause.  You'll have one of these for each
238 # account listed in the "accounts" option in [general] section (above).
239
240 [Account Test]
241
242 # These settings specify the two folders that you will be syncing.
243 # You'll need to have a "Repository ..." section for each one.
244
245 localrepository = LocalExample
246 remoterepository = RemoteExample
247
248
249 ########## Advanced settings
250
251 # This option stands in the [Account Test] section.
252 #
253 # You can have OfflineIMAP continue running indefinitely, automatically syncing
254 # your mail periodically.  If you want that, specify how frequently to do that
255 # (in minutes) here.  Fractional minutes (ie, 3.25) is allowed.
256 #
257 #autorefresh = 5
258
259
260 # This option stands in the [Account Test] section.
261 #
262 # OfflineImap can replace a number of full updates by quick synchronizations.
263 # This option is ignored if maxage or startdate are used.
264 #
265 # It only synchronizes a folder if
266 #
267 #   1) a Maildir folder has changed
268 #
269 # or
270 #
271 #   2) if an IMAP folder has received new messages or had messages deleted, ie
272 #   it does not update if only IMAP flags have changed.
273 #
274 # Full updates need to fetch ALL flags for all messages, so this makes quite a
275 # performance difference (especially if syncing between two IMAP servers).
276 #
277 # Specify 0 for never, -1 for always (works even in non-autorefresh mode)
278 #
279 # A positive integer <n> to do <n> quick updates before doing another full
280 # synchronization (requires autorefresh).  Updates are always performed after
281 # <autorefresh> minutes, be they quick or full.
282 #
283 #quick = 10
284
285
286 # This option stands in the [Account Test] section.
287 #
288 # You can specify a pre and post sync hook to execute a external command.  In
289 # this case a call to imapfilter to filter mail before the sync process starts
290 # and a custom shell script after the sync completes.
291 #
292 # The pre sync script has to complete before a sync to the account will start.
293 #
294 #presynchook = imapfilter -c someotherconfig.lua
295 #postsynchook = notifysync.sh
296
297
298 # This option stands in the [Account Test] section.
299 #
300 # You can specify a newmail hook to execute an external command upon receipt
301 # of new mail in the INBOX.
302 #
303 # This example plays a sound file of your chosing when new mail arrives.
304 #
305 #newmail_hook = lambda: os.system("cvlc --play-and-stop --play-and-exit /path/to/sound/file.mp3" +
306 #                                " > /dev/null 2>&1")
307
308
309 # This option stands in the [Account Test] section.
310 #
311 # OfflineImap caches the state of the synchronisation to e.g. be able to
312 # determine if a mail has been added or deleted on either side.
313 #
314 # The default and historical backend is 'plain' which writes out the
315 # state in plain text files. On Repositories with large numbers of
316 # mails, the performance might not be optimal, as we write out the
317 # complete file for each change.  Another new backend 'sqlite' is
318 # available which stores the status in sqlite databases.
319 #
320 # If you switch the backend, you may want to delete the old cache
321 # directory in ~/.offlineimap/Account-<account>/LocalStatus manually
322 # once you are sure that things work.
323 #
324 #status_backend = plain
325
326
327 # This option stands in the [Account Test] section.
328 #
329 # If you have a limited amount of bandwidth available you can exclude larger
330 # messages (e.g. those with large attachments etc).  If you do this it will
331 # appear to OfflineIMAP that these messages do not exist at all.  They will not
332 # be copied, have flags changed etc.  For this to work on an IMAP server the
333 # server must have server side search enabled.  This works with Gmail and most
334 # imap servers (e.g. cyrus etc)
335 #
336 # The maximum size should be specified in bytes - e.g. 2000000 for approx 2MB
337 #
338 #maxsize = 2000000
339
340
341 # This option stands in the [Account Test] section.
342 #
343 # maxage enables you to sync only recent messages. There are two ways to specify
344 # what "recent" means: if maxage is given as an integer, then only messages from
345 # the last maxage days will be synced. If maxage is given as a date, then only
346 # messages later than that date will be synced.
347 #
348 # Messages older than the cutoff will not be synced, their flags will not be
349 # changed, they will not be deleted, etc. For OfflineIMAP it will be like these
350 # messages do not exist. This will perform an IMAP search in the case of IMAP or
351 # Gmail and therefore requires that the server support server side searching.
352 #
353 # Known edge cases are described in offlineimap(1).
354 #
355 # maxage is allowed only when the local folder is of type Maildir. It can't be
356 # used with startdate.
357 #
358 # The maxage option expects an integer (for the number of days) or a date of the
359 # form yyyy-mm-dd.
360 #
361 #maxage = 3
362 #maxage = 2015-04-01
363
364
365 # This option stands in the [Account Test] section.
366 #
367 # Maildir file format uses colon (:) separator between uniq name and info.
368 # Unfortunatelly colon is not allowed character in windows file name. If you
369 # enable maildir-windows-compatible option, OfflineIMAP will be able to store
370 # messages on windows drive, but you will probably loose compatibility with
371 # other programs working with the maildir.
372 #
373 #maildir-windows-compatible = no
374
375
376 # This option stands in the [Account Test] section.
377 #
378 # Specifies if we want to sync GMail labels with the local repository.
379 # Effective only for GMail IMAP repositories.
380 #
381 # Non-ASCII characters in labels are bad handled or won't work at all.
382 #
383 #synclabels = no
384
385
386 # This option stands in the [Account Test] section.
387 #
388 # Name of the header to use for label storage.  Format for the header
389 # value differs for different headers, because there are some de-facto
390 # "standards" set by popular clients:
391 #
392 # - X-Label or Keywords keep values separated with spaces; for these
393 #   you, obviously, should not have label values that contain spaces;
394 #
395 # - X-Keywords use comma (',') as the separator.
396 #
397 # To be consistent with the usual To-like headers, for the rest of header
398 # types we use comma as the separator.
399 #
400 # Use ASCII characters only.
401 #
402 #labelsheader = X-Keywords
403
404
405 # This option stands in the [Account Test] section.
406 #
407 # Set of labels to be ignored.  Comma-separated list.  GMail-specific
408 # labels all start with backslash ('\').
409 #
410 # Use ASCII characters only.
411 #
412 #ignorelabels = \Inbox, \Starred, \Sent, \Draft, \Spam, \Trash, \Important
413
414
415 # This option stands in the [Account Test] section.
416 #
417 # OfflineIMAP can strip off some headers when your messages are propagated
418 # back to the IMAP server.  This option carries the comma-separated list
419 # of headers to trim off.  Header name matching is case-sensitive.
420 #
421 # This knob is respected only by IMAP-based accounts.  Value of labelsheader
422 # for GMail-based accounts is automatically added to this list, you don't
423 # need to specify it explicitely.
424 #
425 # Use ASCII characters only.
426 #
427 #filterheaders = X-Some-Weird-Header
428
429
430 # This option stands in the [Account Test] section.
431 #
432 # Use proxy connection for this account. Usefull to bypass the GFW in China.
433 # To specify a proxy connection, join proxy type, host and port with colons.
434 # Available proxy types are SOCKS5, SOCKS4, HTTP.
435 # You also need to install PySocks through pip.
436 #
437 # Currently, this feature leaks DNS support.
438 #
439 #proxy = SOCKS5:IP:9999
440
441 [Repository LocalExample]
442
443 # Each repository requires a "type" declaration. The types supported for
444 # local repositories are Maildir, GmailMaildir and IMAP.
445 #
446 type = Maildir
447
448
449 # This option stands in the [Repository LocalExample] section.
450 #
451 # Specify local repository.  Your IMAP folders will be synchronized
452 # to maildirs created under this path.  OfflineIMAP will create the
453 # maildirs for you as needed.
454 #
455 localfolders = ~/Test
456
457
458 # This option stands in the [Repository LocalExample] section.
459 #
460 # You can specify the "folder separator character" used for your Maildir
461 # folders.  It is inserted in-between the components of the tree. If you
462 # want your folders to be nested directories, set it to "/". 'sep' is
463 # ignored for IMAP repositories, as it is queried automatically.
464 # Otherwise, default value is ".".
465 #
466 # Don't use quotes.
467 #
468 #sep = .
469
470
471 # This option stands in the [Repository LocalExample] section.
472 #
473 # startdate syncs mails starting from a given date. It applies the date
474 # restriction to LocalExample only. The remote repository MUST be empty
475 # at the first sync where this option is used.
476 #
477 # Unlike maxage, this is supported for IMAP-IMAP sync.
478 #
479 # startdate can't be used with maxage.
480 #
481 # The startdate option expects a date in the format yyyy-mm-dd.
482 #
483 #startdate = 2015-04-01
484
485
486 # This option stands in the [Repository LocalExample] section.
487 #
488 # Some users may not want the atime (last access time) of folders to be
489 # modified by OfflineIMAP.  If 'restoreatime' is set to yes, OfflineIMAP
490 # will restore the atime of the "new" and "cur" folders in each maildir
491 # folder to their original value after each sync.
492 #
493 # In nearly all cases, the default should be fine.
494 #
495 #restoreatime = no
496
497
498 # This option stands in the [Repository LocalExample] section.
499 #
500 # Set modification time of messages basing on the message's "Date" header. This
501 # option makes sense for the Maildir type, only.
502 #
503 # This is useful if you are doing some processing/finding on your Maildir (for
504 # example, finding messages older than 3 months), without parsing each
505 # file/message content.
506 #
507 # If enabled, this forbid the -q (quick mode) CLI option to work correctly.
508 #
509 # Default: no.
510 #
511 #utime_from_header = no
512
513
514 # This option stands in the [Repository LocalExample] section.
515 #
516 # This option is similar to "utime_from_header" and could be use as a
517 # complementary feature to keep track of a message date. This option only
518 # makes sense for the Maildir type.
519 #
520 # By default each message is stored in a file which prefix is the fetch
521 # timestamp and an order rank such as "1446590057_0". In a multithreading
522 # environment message are fetched in a random order, then you can't trust
523 # the file name to sort your boxes.
524 #
525 # If set to "yes" the file name prefix if build on the message "Date" header
526 # (which should be present) or the "Received-date" if "Date" is not
527 # found. If neither "Received-date" nor "Date" is found, the current system
528 # date is used.  Now you can quickly sort your messages using their file
529 # names.
530 #
531 # Used in combination with "utime_from_header" all your message would be in
532 # order with the correct mtime attribute.
533 #
534 #filename_use_mail_timestamp = no
535
536 # This option stands in the [Repository LocalExample] section.
537 #
538 # Map IMAP [user-defined] keywords to lowercase letters, similar to Dovecot's
539 # format described in http://wiki2.dovecot.org/MailboxFormat/Maildir . This
540 # option makes sense for the Maildir type, only.
541 #
542 # Configuration example:
543 #      customflag_x = some_keyword
544 #
545 # With the configuration example above enabled, all IMAP messages that have
546 # 'some_keyword' in their FLAGS field will have an 'x' in the flags part of the
547 # maildir filename:
548 #      1234567890.M20046P2137.mailserver,S=4542,W=4642:2,Sx
549 #
550 # Valid fields are customflag_[a-z], valid values are whatever the IMAP server
551 # allows.
552 #
553 # Comparison in offlineimap is case-sensitive.
554 #
555 #customflag_a = some_keyword
556 #customflag_b = $OtherKeyword
557 #customflag_c = NonJunk
558 #customflag_d = ToDo
559
560 [Repository GmailLocalExample]
561
562 # This type of repository enables syncing of Gmail. All Maildir
563 # configuration settings are also valid here.
564 #
565 # This is a separate Repository type from Maildir because it involves
566 # some extra overhead which sometimes may be significant.  We look for
567 # modified tags in local messages by looking only to the files
568 # modified since last run.  This is usually rather fast, but the first
569 # time OfflineIMAP runs with synclabels enabled, it will have to check
570 # the contents of all individual messages for labels and this may take
571 # a while.
572 #
573 type = GmailMaildir
574
575
576 [Repository RemoteExample]
577
578 # The remote repository.  We only support IMAP or Gmail here.
579 #
580 type = IMAP
581
582
583 # This option stands in the [Repository RemoteExample] section.
584 #
585 # Configure which address family to use for the connection. If not specified,
586 # AF_UNSPEC is used as a fallback (default).
587 #
588 # AF_INET6:
589 #ipv6 = True
590 #
591 # AF_INET:
592 #ipv6 = False
593
594
595 # These options stands in the [Repository RemoteExample] section.
596 #
597 # The following can fetch the account credentials via a python expression that
598 # is parsed from the pythonfile parameter. For example, a function called
599 # "getcredentials" that parses a file "filename" and returns the account
600 # details for "hostname".
601 #
602 #remotehosteval = getcredentials("filename", "hostname", "hostname")
603 #remoteporteval = getcredentials("filename", "hostname", "port")
604 #remoteusereval = getcredentials("filename", "hostname", "user")
605 #remotepasseval = getcredentials("filename", "hostname", "passwd")
606
607
608 # This option stands in the [Repository RemoteExample] section.
609 #
610 # Specify the remote hostname.
611 #
612 remotehost = examplehost
613
614
615 # This option stands in the [Repository RemoteExample] section.
616 #
617 # Whether or not to use SSL.
618 #
619 # Note: be care to configure the 'remotehost' line with the domain name defined
620 # in the certificate. E.g., if you trust your provider and want to use the
621 # certificate it provides on a shared server. Otherwise, OfflineIMAP will stop
622 # and say that the domain is not named in the certificate.
623 #
624 #ssl = yes
625
626
627 # This option stands in the [Repository RemoteExample] section.
628 #
629 # SSL Client certificate (optional).
630 #
631 # Tilde and environment variable expansions will be performed.
632 #
633 #sslclientcert = /path/to/file.crt
634
635
636 # This option stands in the [Repository RemoteExample] section.
637 #
638 # SSL Client key (optional).
639 #
640 # Tilde and environment variable expansions will be performed.
641 #
642 #sslclientkey = /path/to/file.key
643
644
645 # This option stands in the [Repository RemoteExample] section.
646 #
647 # SSL CA Cert(s) to verify the server cert against (optional).
648 # No SSL verification is done without this option. If it is
649 # specified, the CA Cert(s) need to verify the Server cert AND
650 # match the hostname (* wildcard allowed on the left hand side)
651 # The certificate should be in PEM format.
652 #
653 # Tilde and environment variable expansions will be performed.
654 #
655 # Special value OS-DEFAULT makes OfflineIMAP to automatically
656 # determine system-wide location of standard trusted CA roots file
657 # for known OS distributions and use the first bundle encountered
658 # (if any).  If no system-wide CA bundle is found, OfflineIMAP
659 # will refuse to continue; this is done to prevent creation
660 # of false security expectations ("I had configured CA bundle,
661 # thou certificate verification shalt be present").
662 #
663 # You can also use fingerprint verification via cert_fingerprint.
664 # See below for more verbose explanation.
665 #
666 #sslcacertfile = /path/to/cacertfile.crt
667
668
669 # This option stands in the [Repository RemoteExample] section.
670 #
671 # If you connect via SSL/TLS (ssl = yes) and you have no CA certificate
672 # specified, OfflineIMAP will refuse to sync as it connects to a server
673 # with an unknown "fingerprint". If you are sure you connect to the
674 # correct server, you can then configure the presented server
675 # fingerprint here. OfflineIMAP will verify that the server fingerprint
676 # has not changed on each connect and refuse to connect otherwise.
677 #
678 # You can also configure fingerprint validation in addition to
679 # CA certificate validation above and it will check both:
680 # OfflineIMAP fill verify certificate first and if things will be fine,
681 # fingerprint will be validated.
682 #
683 # Multiple fingerprints can be specified, separated by commas.
684 #
685 # In Windows, Microsoft uses the term "thumbprint" instead of "fingerprint".
686 #
687 # Fingerprints must be in hexadecimal form without leading '0x':
688 # 40 hex digits like bbfe29cf97acb204591edbafe0aa8c8f914287c9.
689 #
690 #cert_fingerprint = <SHA1_of_server_certificate_here>[, <another_SHA1>]
691
692
693 # This option stands in the [Repository RemoteExample] section.
694 #
695 # Set SSL version to use (optional).
696 #
697 # It is best to leave this unset, in which case the correct version will be
698 # automatically detected. In rare cases, it may be necessary to specify a
699 # particular version from: tls1, ssl2, ssl3, ssl23.
700 #
701 # ssl23 is the highest protocol version that both the client and server support.
702 # Despite the name, this option can select “TLS” protocols as well as “SSL”.
703 #
704 # See the configuration option tls_level to automatically disable insecure
705 # protocols.
706 #
707 #ssl_version = ssl23
708
709
710 # This option stands in the [Repository RemoteExample] section.
711 #
712 # TLS support level (optional).
713 #
714 # Specify the level of support that should be allowed for this repository.
715 # Can be used to disallow insecure SSL versions as defined by IETF
716 # (see https://tools.ietf.org/html/rfc6176).
717 #
718 # Supported values are:
719 # tls_secure, tls_no_ssl, tls_compat (the default).
720 #
721 #tls_level = tls_compat
722
723
724 # This option stands in the [Repository RemoteExample] section.
725 #
726 # Specify the port.  If not specified, use a default port.
727 #
728 #remoteport = 993
729
730
731 # This option stands in the [Repository RemoteExample] section.
732 #
733 # Specify the remote user name.
734 #
735 remoteuser = username
736
737
738 # This option stands in the [Repository RemoteExample] section.
739 #
740 # Specify the user to be authorized as.  Sometimes we want to
741 # authenticate with our login/password, but tell the server that we
742 # really want to be treated as some other user; perhaps server will
743 # allow us to do that (or maybe not).  Some IMAP servers migrate
744 # account names using this functionality: your credentials remain
745 # intact, but remote identity changes.
746 #
747 # Currently this variable is used only for SASL PLAIN authentication
748 # mechanism, so consider using auth_mechanisms to prioritize PLAIN
749 # or even make it the only mechanism to be tried.
750 #
751 #remote_identity = authzuser
752
753
754 # This option stands in the [Repository RemoteExample] section.
755 #
756 # Specify which authentication/authorization mechanisms we should try and the
757 # order in which OfflineIMAP will try them.
758 #
759 # NOTE: any given mechanism will be tried ONLY if it is supported by the remote
760 # IMAP server.
761 #
762 # Default value is ranged is from strongest to more weak ones. Due to technical
763 # limitations, if GSSAPI is set, it will be tried first, no matter where it was
764 # specified in the list.
765 #
766 #auth_mechanisms = GSSAPI, CRAM-MD5, XOAUTH2, PLAIN, LOGIN
767
768
769 # This option stands in the [Repository RemoteExample] section.
770 #
771 # XOAuth2 authentication (for instance, to use with Gmail).
772 #
773 # This option was tested on Gmail only, but should work
774 # with type = IMAP for compatible servers.
775 #
776 # Mandatory parameters are "oauth2_client_id", "oauth2_client_secret" and
777 # either "oauth2_refresh_token" or "oauth2_access_token".
778 # See below to learn how to get those.
779 #
780 # Specify the OAuth2 client id and secret to use for the connection..
781 # Here's how to register an OAuth2 client for Gmail, as of 10-2-2016:
782 #    - Go to the Google developer console
783 #         https://console.developers.google.com/project
784 #    - Create a new project
785 #    - In API & Auth, select Credentials
786 #    - Setup the OAuth Consent Screen
787 #    - Then add Credentials of type OAuth 2.0 Client ID
788 #    - Choose application type Other; type in a name for your client
789 #    - You now have a client ID and client secret
790 #
791 #oauth2_client_id = YOUR_CLIENT_ID
792 #oauth2_client_secret = YOUR_CLIENT_SECRET
793
794 # Specify the refresh token to use for the connection to the mail server.
795 # Here's an example of a way to get a refresh token:
796 #    - Clone this project: https://github.com/google/gmail-oauth2-tools
797 #    - Type the following command-line in a terminal and follow the instructions
798 #         python python/oauth2.py --generate_oauth2_token \
799 #            --client_id=YOUR_CLIENT_ID --client_secret=YOUR_CLIENT_SECRET
800 #    - Access token can be obtained using refresh token with command
801 #         python python/oauth2.py --user=YOUR_EMAIL --client_id=YOUR_CLIENT_ID
802 #            --client_secret=YOUR_CLIENT_SECRET --refresh_token=REFRESH_TOKEN
803 #
804 #oauth2_refresh_token = REFRESH_TOKEN
805 #oauth2_access_token = ACCESS_TOKEN
806
807 ########## Passwords
808
809 # There are six ways to specify the password for the IMAP server:
810 #
811 # 1. No password at all specified in the config file.
812 #    If a matching entry is found in ~/.netrc (see netrc (5) for
813 #    information) this password will be used. Do note that netrc only
814 #    allows one entry per hostname. If there is no ~/.netrc file but
815 #    there is an /etc/netrc file, the password will instead be taken
816 #    from there. Otherwise you will be prompted for the password when
817 #    OfflineIMAP starts when using a UI that supports this.
818 #
819 # 2. The remote password stored in this file with the remotepass
820 #    option. Any '%' needs to be encoded as '%%'. Example:
821 #    remotepass = mypassword
822 #
823 # 3. The remote password stored as a single line in an external
824 #    file, which is referenced by the remotefile option.  Example:
825 #    remotepassfile = ~/Password.IMAP.Account1
826 #
827 # 4. With a preauth tunnel.  With this method, you invoke an external
828 #    program that is guaranteed *NOT* to ask for a password, but rather
829 #    to read from stdin and write to stdout an IMAP procotol stream that
830 #    begins life in the PREAUTH state.  When you use a tunnel, you do
831 #    NOT specify a user or password (if you do, they'll be ignored.)
832 #    Instead, you specify a preauthtunnel, as this example illustrates
833 #    for Courier IMAP on Debian:
834 #    preauthtunnel = ssh -q imaphost '/usr/bin/imapd ./Maildir'
835 #
836 # 5. If you are using Kerberos and have the Python Kerberos package
837 #    installed, you should not specify a remotepass.  If the user has a
838 #    valid Kerberos TGT, OfflineIMAP will figure out the rest all by
839 #    itself, and fall back to password authentication if needed.
840 #
841 # 6. Using arbitrary python code.  With this method, you invoke a
842 #    function from your pythonfile.  To use this method assign the name
843 #    of the function to the variable 'remotepasseval'.  Example:
844 #    remotepasseval = get_password("imap.example.net")
845 #    You can also query for the username:
846 #    remoteusereval = get_username("imap.example.net")
847 #    This method can be used to design more elaborate setups, e.g. by
848 #    querying the gnome-keyring via its python bindings.
849
850
851 ########## Advanced settings
852
853
854 # These options stands in the [Repository RemoteExample] section.
855 #
856 # Tunnels. There are two types:
857 #
858 # - preauth: they teleport your connection to the remote system
859 #   and you don't need to authenticate yourself there; the sole
860 #   fact that you succeeded to get the tunnel running is enough.
861 #   This tunnel type was explained above in the 'Passwords' section.
862 #
863 # - transport: the just provide the transport (probably encrypted)
864 #   to the IMAP server, but you still need to authenticate at the
865 #   IMAP server.
866 #
867 # Tunnels are currently working only with IMAP servers and their
868 # derivatives (GMail currently).  Additionally, for GMail accounts
869 # preauth tunnel settings are ignored: we don't believe that there
870 # are ways to preauthenticate at Google mail system IMAP servers.
871 #
872 # You must choose at most one tunnel type, be wise M'Lord!
873 #
874 #preauthtunnel = ssh -q imaphost '/usr/bin/imapd ./Maildir'
875 #transporttunnel = openssl s_client -host myimap -port 993 -quiet
876
877
878 # This option stands in the [Repository RemoteExample] section.
879 #
880 # Some IMAP servers need a "reference" which often refers to the "folder root".
881 #
882 # This is most commonly needed with UW IMAP, where you might need to specify the
883 # directory in which your mail is stored. The 'reference' value will be prefixed
884 # to all folder paths refering to that repository. E.g. accessing folder 'INBOX'
885 # with "reference = Mail" will try to access Mail/INBOX.
886 #
887 # The nametrans and folderfilter functions will apply to the full path,
888 # including the reference prefix.  Most users will not need this.
889 #
890 #reference = Mail
891
892
893 # This option stands in the [Repository RemoteExample] section.
894 #
895 # IMAP defines an encoding for non-ASCII ("international") characters. Enable
896 # this option if you want to decode them to the nowadays ubiquitous UTF-8.
897 #
898 # Note that the IMAP 4rev1 specification (RFC 3501) allows both UTF-8 and
899 # modified UTF-7 folder names.
900 #
901 # WARNING: with this option enabled:
902 # - compatibility with any other version is NOT GUARANTED (including newer);
903 # - no support is provided.
904 #
905 #decodefoldernames = no
906
907
908 # This option stands in the [Repository RemoteExample] section.
909 #
910 # In between synchronisations, OfflineIMAP can monitor mailboxes for new
911 # messages using the IDLE command. If you want to enable this, specify here the
912 # folders you wish to monitor. IMAP protocol requires a separate connection for
913 # each folder monitored in this way, so setting this option will force settings
914 # for:
915 #
916 #  - maxconnections: to be at least the number of folders you give
917 #  - holdconnectionopen: to be true
918 #  - keepalive: to be 29 minutes unless you specify otherwise
919 #
920 # This feature isn't complete and may well have problems. See the "Known Issues"
921 # entry in the manual for more details.
922 #
923 # This option should return a Python list. For example
924 #
925 #idlefolders = ['INBOX', 'INBOX.Alerts']
926
927
928 # This option stands in the [Repository RemoteExample] section.
929 #
930 # OfflineIMAP can use a compressed connection to the IMAP server.
931 # This can result in faster downloads for some cases.
932 #
933 #usecompression = yes
934
935
936 # This option stands in the [Repository RemoteExample] section.
937 #
938 # OfflineIMAP can use multiple connections to the server in order
939 # to perform multiple synchronization actions simultaneously.
940 # This may place a higher burden on the server.  In most cases,
941 # setting this value to 2 or 3 will speed up the sync, but in some
942 # cases, it may slow things down.  The safe answer is 1.  You should
943 # probably never set it to a value more than 5.
944 #
945 #maxconnections = 2
946
947
948 # This option stands in the [Repository RemoteExample] section.
949 #
950 # OfflineIMAP normally closes IMAP server connections between refreshes if
951 # the global option autorefresh is specified.  If you wish it to keep the
952 # connection open, set this to true.  If not specified, the default is
953 # false.  Keeping the connection open means a faster sync start the
954 # next time and may use fewer server resources on connection, but uses
955 # more server memory.  This setting has no effect if autorefresh is not set.
956 #
957 #holdconnectionopen = no
958
959
960 # This option stands in the [Repository RemoteExample] section.
961 #
962 # If you want to have "keepalives" sent while waiting between syncs, specify the
963 # amount of time IN SECONDS between keepalives here.  Note that sometimes more
964 # than this amount of time might pass, so don't make it tight.  This setting has
965 # no effect if autorefresh and holdconnectionopen are not both set.
966 #
967 #keepalive = 60
968
969
970 # This option stands in the [Repository RemoteExample] section.
971 #
972 # Normally, OfflineIMAP will expunge deleted messages from the server.  You can
973 # disable that if you wish.  This means that OfflineIMAP will mark them deleted
974 # on the server, but not actually delete them.  You must use some other IMAP
975 # client to delete them if you use this setting; otherwise, the messages will
976 # just pile up there forever.  Therefore, this setting is definitely NOT
977 # recommended for a long term.
978 #
979 #expunge = no
980
981
982 # This option stands in the [Repository RemoteExample] section.
983 #
984 # Specify whether to process all mail folders on the server, or only
985 # those listed as "subscribed".
986 #
987 #subscribedonly = no
988
989
990 # This option stands in the [Repository RemoteExample] section.
991 #
992 # You can specify a folder translator.  This must be a eval-able.
993 #
994 # Python expression that takes a foldername arg and returns the new value. A
995 # lambda function is suggested.
996 #
997 # WARNING: you MUST construct it so that it NEVER returns the same value for two
998 # folders, UNLESS the second values are filtered out by folderfilter below.
999 # Failure to follow this rule will result in undefined behavior.
1000 #
1001 # If you enable nametrans, you will likely need to set the reversed nametrans on
1002 # the other side. See the user documentation for details and use cases. They
1003 # are also online at: http://www.offlineimap.org/doc/nametrans.html
1004 #
1005 # This example below will remove "INBOX." from the leading edge of folders
1006 # (great for Courier IMAP users).
1007 #
1008 #nametrans = lambda foldername: re.sub('^INBOX\.', '', foldername)
1009 #
1010 # Using Courier remotely and want to duplicate its mailbox naming locally?  Try
1011 # this:
1012 #
1013 #nametrans = lambda foldername: re.sub('^INBOX\.*', '.', foldername)
1014
1015
1016 # This option stands in the [Repository RemoteExample] section.
1017 #
1018 # Determines if folderfilter will be invoked on each run (dynamic folder
1019 # filtering) or filtering status will be determined at startup (default
1020 # behaviour).
1021 #
1022 #dynamic_folderfilter = False
1023
1024
1025 # This option stands in the [Repository RemoteExample] section.
1026 #
1027 # You can specify which folders to sync using the folderfilter setting. You can
1028 # provide any python function (e.g. a lambda function) which will be invoked for
1029 # each foldername. If the filter function returns True, the folder will be
1030 # synced, if it returns False, it.
1031 #
1032 # The folderfilter operates on the *UNTRANSLATED* name (before any nametrans
1033 # translation takes place).
1034 #
1035 # Example 1: synchronizing only INBOX and Sent.
1036 #
1037 #folderfilter = lambda foldername: foldername in ['INBOX', 'Sent']
1038 #
1039 # Example 2: synchronizing everything except Trash.
1040 #
1041 #folderfilter = lambda foldername: foldername not in ['Trash']
1042 #
1043 # Example 3: Using a regular expression to exclude Trash and all folders
1044 # containing the characters "Del".
1045 #
1046 #folderfilter = lambda foldername: not re.search('(^Trash$|Del)', foldername)
1047 #
1048 # If folderfilter is not specified, ALL remote folders will be synchronized.
1049 #
1050 # You can span multiple lines by indenting the others.  (Use backslashes at the
1051 # end when required by Python syntax)  For instance:
1052 #
1053 #folderfilter = lambda foldername: foldername in [
1054 #    'INBOX', 'Sent Mail',
1055 #    'Deleted Items', 'Received']
1056
1057
1058 # This option stands in the [Repository RemoteExample] section.
1059 #
1060 # You can specify folderincludes to include additional folders.  It should
1061 # return a Python list.  This might be used to include a folder that was
1062 # excluded by your folderfilter rule, to include a folder that your server does
1063 # not specify with its LIST option, or to include a folder that is outside your
1064 # basic reference.
1065 #
1066 # The 'reference' value will not be prefixed to this folder name, even if you
1067 # have specified one.  For example:
1068 #
1069 #folderincludes = ['debian.user', 'debian.personal']
1070
1071
1072 # This option stands in the [Repository RemoteExample] section.
1073 #
1074 # If you do not want to have any folders created on this repository,
1075 # set the createfolders variable to False, the default is True. Using
1076 # this feature you can e.g. disable the propagation of new folders to
1077 # the new repository.
1078 #
1079 #createfolders = True
1080
1081
1082 # This option stands in the [Repository RemoteExample] section.
1083 #
1084 # 'foldersort' determines how folders are sorted.
1085 #
1086 # This affects order of synchronization and mbnames. The expression should
1087 # return -1, 0, or 1, as the default Python cmp() does.  The two arguments, x
1088 # and y, are strings representing the names of the folders to be sorted.  The
1089 # sorting is applied *AFTER* nametrans, if any.  The default is to sort IMAP
1090 # folders alphabetically (case-insensitive). Usually, you should never have to
1091 # modify this.  To eg. reverse the sort:
1092 #
1093 #foldersort = lambda x, y: -cmp(x, y)
1094
1095
1096 # This option stands in the [Repository RemoteExample] section.
1097 #
1098 # Enable 1-way synchronization. When setting 'readonly' to True, this
1099 # repository will not be modified during synchronization. Usefull to
1100 # e.g. backup an IMAP server. The readonly setting can be applied to any
1101 # type of Repository (Maildir, Imap, etc).
1102 #
1103 #readonly = False
1104
1105
1106 [Repository GmailExample]
1107
1108 # A repository using Gmail's IMAP interface.
1109 #
1110 # Any configuration parameter of "IMAP" type repositories can be used here.
1111 # Only "remoteuser" (or "remoteusereval" ) is mandatory.  Default values for
1112 # other parameters are OK, and you should not need fiddle with those.
1113 #
1114 # The Gmail repository will use hard-coded values for "remotehost",
1115 # "remoteport", "tunnel" and "ssl".  Any attempt to set those parameters will be
1116 # silently ignored. For details, see
1117 #
1118 #  http://mail.google.com/support/bin/answer.py?answer=78799&topic=12814
1119 #
1120 # To enable GMail labels synchronisation, set the option "synclabels"
1121 # in the corresponding "Account" section.
1122 #
1123 type = Gmail
1124
1125
1126 # This option stands in the [Repository GmailExample] section.
1127 #
1128 # Specify the Gmail user name. This is the only mandatory parameter.
1129 #
1130 remoteuser = username@gmail.com
1131
1132
1133 # This option stands in the [Repository GmailExample] section.
1134 #
1135 # The trash folder name may be different from [Gmail]/Trash due to localization.
1136 # You should look for the localized names of the spam folder too: "spamfolder"
1137 # tunable will help you to override the standard name.
1138 #
1139 # For example on German Gmail, this setting should be:
1140 #
1141 #trashfolder = [Gmail]/Papierkorb