1 # -*- coding: UTF-8 -*- |
|
2 # Copyright (c) 2007 - 2014, Pascal Volk |
|
3 # See COPYING for distribution information. |
|
4 """ |
|
5 VirtualMailManager.constants |
|
6 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|
7 |
|
8 VirtualMailManager's constants: |
|
9 * version information |
|
10 * upper and lower limits MIN_* / MAX_* |
|
11 * exit codes |
|
12 * error codes |
|
13 """ |
|
14 # version information |
|
15 |
|
16 __all__ = ['__author__', '__date__', '__version__'] |
|
17 AUTHOR = 'Pascal Volk <user+vmm@localhost.localdomain.org>' |
|
18 RELDATE = '2014-02-01' |
|
19 VERSION = '0.6.2' |
|
20 __author__ = AUTHOR |
|
21 __copyright__ = 'Copyright (c) 2007-2014 %s' % __author__ |
|
22 __date__ = RELDATE |
|
23 __version__ = VERSION |
|
24 |
|
25 |
|
26 # limits |
|
27 |
|
28 MIN_GID = 70000 |
|
29 MIN_UID = 70000 |
|
30 |
|
31 |
|
32 # exit codes |
|
33 |
|
34 EX_SUCCESS = 0 |
|
35 EX_MISSING_ARGS = 1 |
|
36 EX_UNKNOWN_COMMAND = 2 |
|
37 EX_USER_INTERRUPT = 3 |
|
38 |
|
39 |
|
40 # error codes |
|
41 |
|
42 ACCOUNT_AND_ALIAS_PRESENT = 20 |
|
43 ACCOUNT_EXISTS = 21 |
|
44 ACCOUNT_MISSING_PASSWORD = 69 |
|
45 ALIASDOMAIN_EXISTS = 23 |
|
46 ALIASDOMAIN_ISDOMAIN = 24 |
|
47 ALIASDOMAIN_NO_DOMDEST = 25 |
|
48 ALIAS_EXCEEDS_EXPANSION_LIMIT = 27 |
|
49 ALIAS_EXISTS = 28 |
|
50 ALIAS_PRESENT = 30 |
|
51 CONF_ERROR = 31 |
|
52 CONF_NOFILE = 32 |
|
53 CONF_NOPERM = 33 |
|
54 CONF_WRONGPERM = 34 |
|
55 DATABASE_ERROR = 35 |
|
56 DOMAINDIR_GROUP_MISMATCH = 36 |
|
57 DOMAIN_ALIAS_EXISTS = 37 |
|
58 DOMAIN_EXISTS = 38 |
|
59 DOMAIN_INVALID = 39 |
|
60 DOMAIN_NO_NAME = 40 |
|
61 DOMAIN_TOO_LONG = 41 |
|
62 FOUND_DOTS_IN_PATH = 42 |
|
63 INVALID_ADDRESS = 43 |
|
64 INVALID_ARGUMENT = 44 |
|
65 INVALID_MAIL_LOCATION = 70 |
|
66 INVALID_SECTION = 46 |
|
67 LOCALPART_INVALID = 47 |
|
68 LOCALPART_TOO_LONG = 48 |
|
69 MAILDIR_PERM_MISMATCH = 49 |
|
70 MAILLOCATION_INIT = 50 |
|
71 NOT_EXECUTABLE = 51 |
|
72 NO_SUCH_ACCOUNT = 52 |
|
73 NO_SUCH_ALIAS = 53 |
|
74 NO_SUCH_ALIASDOMAIN = 54 |
|
75 NO_SUCH_BINARY = 55 |
|
76 NO_SUCH_DIRECTORY = 56 |
|
77 NO_SUCH_DOMAIN = 57 |
|
78 NO_SUCH_RELOCATED = 58 |
|
79 RELOCATED_ADDR_DEST_IDENTICAL = 59 |
|
80 RELOCATED_EXISTS = 60 |
|
81 UNKNOWN_SERVICE = 65 |
|
82 VMM_ERROR = 67 |
|
83 VMM_TOO_MANY_FAILURES = 68 |
|
84 |
|
85 # address types |
|
86 |
|
87 TYPE_ACCOUNT = 0x1 |
|
88 TYPE_ALIAS = 0x2 |
|
89 TYPE_RELOCATED = 0x4 |
|