2013-08-31 14:50:59 +00:00
|
|
|
#!/usr/bin/python3
|
2020-10-29 19:10:11 +00:00
|
|
|
#
|
|
|
|
# This is a command-line script for calling management APIs
|
|
|
|
# on the Mail-in-a-Box control panel backend. The script
|
|
|
|
# reads /var/lib/mailinabox/api.key for the backend's
|
|
|
|
# root API key. This file is readable only by root, so this
|
|
|
|
# tool can only be used as root.
|
2013-08-31 14:50:59 +00:00
|
|
|
|
2023-12-22 15:08:30 +00:00
|
|
|
import sys, getpass, urllib.request, urllib.error, json, csv
|
2023-12-23 13:26:32 +00:00
|
|
|
import contextlib
|
2013-08-31 14:50:59 +00:00
|
|
|
|
2014-08-08 12:31:22 +00:00
|
|
|
def mgmt(cmd, data=None, is_json=False):
|
2014-10-05 12:55:28 +00:00
|
|
|
# The base URL for the management daemon. (Listens on IPv4 only.)
|
|
|
|
mgmt_uri = 'http://127.0.0.1:10222'
|
2014-06-21 23:49:09 +00:00
|
|
|
|
|
|
|
setup_key_auth(mgmt_uri)
|
|
|
|
|
|
|
|
req = urllib.request.Request(mgmt_uri + cmd, urllib.parse.urlencode(data).encode("utf8") if data else None)
|
2014-06-03 13:24:48 +00:00
|
|
|
try:
|
|
|
|
response = urllib.request.urlopen(req)
|
|
|
|
except urllib.error.HTTPError as e:
|
2014-07-25 13:51:35 +00:00
|
|
|
if e.code == 401:
|
2023-12-23 13:26:32 +00:00
|
|
|
with contextlib.suppress(Exception):
|
2014-08-17 22:43:57 +00:00
|
|
|
print(e.read().decode("utf8"))
|
2014-07-25 13:51:35 +00:00
|
|
|
print("The management daemon refused access. The API key file may be out of sync. Try 'service mailinabox restart'.", file=sys.stderr)
|
|
|
|
elif hasattr(e, 'read'):
|
|
|
|
print(e.read().decode('utf8'), file=sys.stderr)
|
|
|
|
else:
|
|
|
|
print(e, file=sys.stderr)
|
2014-06-03 13:24:48 +00:00
|
|
|
sys.exit(1)
|
2014-08-08 12:31:22 +00:00
|
|
|
resp = response.read().decode('utf8')
|
|
|
|
if is_json: resp = json.loads(resp)
|
|
|
|
return resp
|
2013-08-31 14:50:59 +00:00
|
|
|
|
2014-06-06 21:07:30 +00:00
|
|
|
def read_password():
|
2015-03-29 16:54:37 +00:00
|
|
|
while True:
|
|
|
|
first = getpass.getpass('password: ')
|
2017-02-14 19:24:59 +00:00
|
|
|
if len(first) < 8:
|
|
|
|
print("Passwords must be at least eight characters.")
|
2015-03-30 17:59:07 +00:00
|
|
|
continue
|
2015-03-29 16:54:37 +00:00
|
|
|
second = getpass.getpass(' (again): ')
|
|
|
|
if first != second:
|
2015-03-30 17:59:07 +00:00
|
|
|
print("Passwords not the same. Try again.")
|
2015-03-29 16:54:37 +00:00
|
|
|
continue
|
|
|
|
break
|
|
|
|
return first
|
2014-06-06 21:07:30 +00:00
|
|
|
|
2014-06-21 23:49:09 +00:00
|
|
|
def setup_key_auth(mgmt_uri):
|
2023-12-23 13:07:25 +00:00
|
|
|
with open('/var/lib/mailinabox/api.key', encoding='utf-8') as f:
|
2023-01-15 13:28:43 +00:00
|
|
|
key = f.read().strip()
|
2014-06-21 23:49:09 +00:00
|
|
|
|
|
|
|
auth_handler = urllib.request.HTTPBasicAuthHandler()
|
|
|
|
auth_handler.add_password(
|
|
|
|
realm='Mail-in-a-Box Management Server',
|
|
|
|
uri=mgmt_uri,
|
|
|
|
user=key,
|
|
|
|
passwd='')
|
|
|
|
opener = urllib.request.build_opener(auth_handler)
|
|
|
|
urllib.request.install_opener(opener)
|
|
|
|
|
2013-08-31 14:50:59 +00:00
|
|
|
if len(sys.argv) < 2:
|
2020-10-29 19:10:11 +00:00
|
|
|
print("""Usage:
|
v0.51 (November 14, 2020)
Software updates:
* Upgraded Nextcloud from 17.0.6 to 20.0.1 (with Contacts from 3.3.0 to 3.4.1 and Calendar from 2.0.3 to 2.1.2)
* Upgraded Roundcube to version 1.4.9.
Mail:
* The MTA-STA max_age value was increased to the normal one week.
Control Panel:
* Two-factor authentication can now be enabled for logins to the control panel. However, keep in mind that many online services (including domain name registrars, cloud server providers, and TLS certificate providers) may allow an attacker to take over your account or issue a fraudulent TLS certificate with only access to your email address, and this new two-factor authentication does not protect access to your inbox. It therefore remains very important that user accounts with administrative email addresses have strong passwords.
* TLS certificate expiry dates are now shown in ISO8601 format for clarity.
-----BEGIN PGP SIGNATURE-----
iQFDBAABCgAtFiEEX0wOcxPM10RpOyrquSBB9MEL3YEFAl+v8k4PHGp0QG9jY2Ft
cy5pbmZvAAoJELkgQfTBC92BMYUIAJTD1iKzY1SoDNSp8JMPn2sWusOnJNrnvYEV
vsrBM4AzwJv3DIZKSkYCitbTQW2FsTcjF6Jl5PCavEmAGe55AIKAPM/52Uq6jqDE
aR8EZvI9ca1i7yR7DOHEI043QSPmp/iCFD48vvmKgN/LZy67TaHaOlGJbc3nfpk0
y7ejMpF/6RP6ik4snnRQoWTFShaOpB9WcEVnUO7CHZdWcpSCZ55c9yi6A6ExGk7e
97R5+JN1MgOdZ6rzWZuMWiz7EZ/Ew4jYLZpOwg8qJm0HNbYJ6+/xxsQBwaQzyBw3
TsTl4GmunNPfoNrmKdJeLy0sBwiVBv/rysjWjim5v8jAYBoKoUQ=
=2oRU
-----END PGP SIGNATURE-----
Merge tag 'v0.51' of https://github.com/mail-in-a-box/mailinabox
v0.51 (November 14, 2020)
Software updates:
* Upgraded Nextcloud from 17.0.6 to 20.0.1 (with Contacts from 3.3.0 to 3.4.1 and Calendar from 2.0.3 to 2.1.2)
* Upgraded Roundcube to version 1.4.9.
Mail:
* The MTA-STA max_age value was increased to the normal one week.
Control Panel:
* Two-factor authentication can now be enabled for logins to the control panel. However, keep in mind that many online services (including domain name registrars, cloud server providers, and TLS certificate providers) may allow an attacker to take over your account or issue a fraudulent TLS certificate with only access to your email address, and this new two-factor authentication does not protect access to your inbox. It therefore remains very important that user accounts with administrative email addresses have strong passwords.
* TLS certificate expiry dates are now shown in ISO8601 format for clarity.
# gpg verification failed.
# Conflicts:
# management/daemon.py
# setup/bootstrap.sh
# setup/mail-users.sh
# tools/mail.py
2020-12-03 21:21:37 +00:00
|
|
|
{cli} system default-quota [new default] (set default quota for system)
|
2020-10-29 19:41:34 +00:00
|
|
|
{cli} user (lists users)
|
2020-10-29 19:10:11 +00:00
|
|
|
{cli} user add user@domain.com [password]
|
|
|
|
{cli} user password user@domain.com [password]
|
|
|
|
{cli} user remove user@domain.com
|
|
|
|
{cli} user make-admin user@domain.com
|
v0.51 (November 14, 2020)
Software updates:
* Upgraded Nextcloud from 17.0.6 to 20.0.1 (with Contacts from 3.3.0 to 3.4.1 and Calendar from 2.0.3 to 2.1.2)
* Upgraded Roundcube to version 1.4.9.
Mail:
* The MTA-STA max_age value was increased to the normal one week.
Control Panel:
* Two-factor authentication can now be enabled for logins to the control panel. However, keep in mind that many online services (including domain name registrars, cloud server providers, and TLS certificate providers) may allow an attacker to take over your account or issue a fraudulent TLS certificate with only access to your email address, and this new two-factor authentication does not protect access to your inbox. It therefore remains very important that user accounts with administrative email addresses have strong passwords.
* TLS certificate expiry dates are now shown in ISO8601 format for clarity.
-----BEGIN PGP SIGNATURE-----
iQFDBAABCgAtFiEEX0wOcxPM10RpOyrquSBB9MEL3YEFAl+v8k4PHGp0QG9jY2Ft
cy5pbmZvAAoJELkgQfTBC92BMYUIAJTD1iKzY1SoDNSp8JMPn2sWusOnJNrnvYEV
vsrBM4AzwJv3DIZKSkYCitbTQW2FsTcjF6Jl5PCavEmAGe55AIKAPM/52Uq6jqDE
aR8EZvI9ca1i7yR7DOHEI043QSPmp/iCFD48vvmKgN/LZy67TaHaOlGJbc3nfpk0
y7ejMpF/6RP6ik4snnRQoWTFShaOpB9WcEVnUO7CHZdWcpSCZ55c9yi6A6ExGk7e
97R5+JN1MgOdZ6rzWZuMWiz7EZ/Ew4jYLZpOwg8qJm0HNbYJ6+/xxsQBwaQzyBw3
TsTl4GmunNPfoNrmKdJeLy0sBwiVBv/rysjWjim5v8jAYBoKoUQ=
=2oRU
-----END PGP SIGNATURE-----
Merge tag 'v0.51' of https://github.com/mail-in-a-box/mailinabox
v0.51 (November 14, 2020)
Software updates:
* Upgraded Nextcloud from 17.0.6 to 20.0.1 (with Contacts from 3.3.0 to 3.4.1 and Calendar from 2.0.3 to 2.1.2)
* Upgraded Roundcube to version 1.4.9.
Mail:
* The MTA-STA max_age value was increased to the normal one week.
Control Panel:
* Two-factor authentication can now be enabled for logins to the control panel. However, keep in mind that many online services (including domain name registrars, cloud server providers, and TLS certificate providers) may allow an attacker to take over your account or issue a fraudulent TLS certificate with only access to your email address, and this new two-factor authentication does not protect access to your inbox. It therefore remains very important that user accounts with administrative email addresses have strong passwords.
* TLS certificate expiry dates are now shown in ISO8601 format for clarity.
# gpg verification failed.
# Conflicts:
# management/daemon.py
# setup/bootstrap.sh
# setup/mail-users.sh
# tools/mail.py
2020-12-03 21:21:37 +00:00
|
|
|
{cli} user quota user@domain [new-quota]
|
2020-10-29 19:10:11 +00:00
|
|
|
{cli} user remove-admin user@domain.com
|
2020-10-29 19:41:34 +00:00
|
|
|
{cli} user admins (lists admins)
|
|
|
|
{cli} user mfa show user@domain.com (shows MFA devices for user, if any)
|
|
|
|
{cli} user mfa disable user@domain.com [id] (disables MFA for user)
|
|
|
|
{cli} alias (lists aliases)
|
2020-10-29 19:10:11 +00:00
|
|
|
{cli} alias add incoming.name@domain.com sent.to@other.domain.com
|
|
|
|
{cli} alias add incoming.name@domain.com 'sent.to@other.domain.com, multiple.people@other.domain.com'
|
|
|
|
{cli} alias remove incoming.name@domain.com
|
|
|
|
|
|
|
|
Removing a mail user does not delete their mail folders on disk. It only prevents IMAP/SMTP login.
|
|
|
|
""".format(
|
|
|
|
cli="management/cli.py"
|
|
|
|
))
|
2013-08-31 14:50:59 +00:00
|
|
|
|
|
|
|
elif sys.argv[1] == "user" and len(sys.argv) == 2:
|
2014-08-08 12:31:22 +00:00
|
|
|
# Dump a list of users, one per line. Mark admins with an asterisk.
|
|
|
|
users = mgmt("/mail/users?format=json", is_json=True)
|
2014-10-07 19:28:07 +00:00
|
|
|
for domain in users:
|
|
|
|
for user in domain["users"]:
|
|
|
|
if user['status'] == 'inactive': continue
|
|
|
|
print(user['email'], end='')
|
|
|
|
if "admin" in user['privileges']:
|
|
|
|
print("*", end='')
|
v0.51 (November 14, 2020)
Software updates:
* Upgraded Nextcloud from 17.0.6 to 20.0.1 (with Contacts from 3.3.0 to 3.4.1 and Calendar from 2.0.3 to 2.1.2)
* Upgraded Roundcube to version 1.4.9.
Mail:
* The MTA-STA max_age value was increased to the normal one week.
Control Panel:
* Two-factor authentication can now be enabled for logins to the control panel. However, keep in mind that many online services (including domain name registrars, cloud server providers, and TLS certificate providers) may allow an attacker to take over your account or issue a fraudulent TLS certificate with only access to your email address, and this new two-factor authentication does not protect access to your inbox. It therefore remains very important that user accounts with administrative email addresses have strong passwords.
* TLS certificate expiry dates are now shown in ISO8601 format for clarity.
-----BEGIN PGP SIGNATURE-----
iQFDBAABCgAtFiEEX0wOcxPM10RpOyrquSBB9MEL3YEFAl+v8k4PHGp0QG9jY2Ft
cy5pbmZvAAoJELkgQfTBC92BMYUIAJTD1iKzY1SoDNSp8JMPn2sWusOnJNrnvYEV
vsrBM4AzwJv3DIZKSkYCitbTQW2FsTcjF6Jl5PCavEmAGe55AIKAPM/52Uq6jqDE
aR8EZvI9ca1i7yR7DOHEI043QSPmp/iCFD48vvmKgN/LZy67TaHaOlGJbc3nfpk0
y7ejMpF/6RP6ik4snnRQoWTFShaOpB9WcEVnUO7CHZdWcpSCZ55c9yi6A6ExGk7e
97R5+JN1MgOdZ6rzWZuMWiz7EZ/Ew4jYLZpOwg8qJm0HNbYJ6+/xxsQBwaQzyBw3
TsTl4GmunNPfoNrmKdJeLy0sBwiVBv/rysjWjim5v8jAYBoKoUQ=
=2oRU
-----END PGP SIGNATURE-----
Merge tag 'v0.51' of https://github.com/mail-in-a-box/mailinabox
v0.51 (November 14, 2020)
Software updates:
* Upgraded Nextcloud from 17.0.6 to 20.0.1 (with Contacts from 3.3.0 to 3.4.1 and Calendar from 2.0.3 to 2.1.2)
* Upgraded Roundcube to version 1.4.9.
Mail:
* The MTA-STA max_age value was increased to the normal one week.
Control Panel:
* Two-factor authentication can now be enabled for logins to the control panel. However, keep in mind that many online services (including domain name registrars, cloud server providers, and TLS certificate providers) may allow an attacker to take over your account or issue a fraudulent TLS certificate with only access to your email address, and this new two-factor authentication does not protect access to your inbox. It therefore remains very important that user accounts with administrative email addresses have strong passwords.
* TLS certificate expiry dates are now shown in ISO8601 format for clarity.
# gpg verification failed.
# Conflicts:
# management/daemon.py
# setup/bootstrap.sh
# setup/mail-users.sh
# tools/mail.py
2020-12-03 21:21:37 +00:00
|
|
|
if user['quota'] == '0':
|
|
|
|
print(" unlimited", end='')
|
|
|
|
else:
|
|
|
|
print(" " + user['quota'], end='')
|
2014-10-07 19:28:07 +00:00
|
|
|
print()
|
2013-08-31 14:50:59 +00:00
|
|
|
|
2023-12-22 15:10:25 +00:00
|
|
|
elif sys.argv[1] == "user" and sys.argv[2] in {"add", "password"}:
|
2013-08-31 14:50:59 +00:00
|
|
|
if len(sys.argv) < 5:
|
2023-12-22 15:17:23 +00:00
|
|
|
email = input('email: ') if len(sys.argv) < 4 else sys.argv[3]
|
2014-06-06 21:07:30 +00:00
|
|
|
pw = read_password()
|
2013-08-31 14:50:59 +00:00
|
|
|
else:
|
|
|
|
email, pw = sys.argv[3:5]
|
|
|
|
|
|
|
|
if sys.argv[2] == "add":
|
2014-06-03 13:24:48 +00:00
|
|
|
print(mgmt("/mail/users/add", { "email": email, "password": pw }))
|
2013-08-31 14:50:59 +00:00
|
|
|
elif sys.argv[2] == "password":
|
2014-06-03 13:24:48 +00:00
|
|
|
print(mgmt("/mail/users/password", { "email": email, "password": pw }))
|
2013-08-31 14:50:59 +00:00
|
|
|
|
|
|
|
elif sys.argv[1] == "user" and sys.argv[2] == "remove" and len(sys.argv) == 4:
|
2014-06-03 13:24:48 +00:00
|
|
|
print(mgmt("/mail/users/remove", { "email": sys.argv[3] }))
|
2013-08-31 14:50:59 +00:00
|
|
|
|
2023-12-22 15:10:25 +00:00
|
|
|
elif sys.argv[1] == "user" and sys.argv[2] in {"make-admin", "remove-admin"} and len(sys.argv) == 4:
|
2023-12-22 15:17:23 +00:00
|
|
|
action = 'add' if sys.argv[2] == 'make-admin' else 'remove'
|
2014-08-08 12:31:22 +00:00
|
|
|
print(mgmt("/mail/users/privileges/" + action, { "email": sys.argv[3], "privilege": "admin" }))
|
|
|
|
|
2014-08-16 12:59:29 +00:00
|
|
|
elif sys.argv[1] == "user" and sys.argv[2] == "admins":
|
|
|
|
# Dump a list of admin users.
|
|
|
|
users = mgmt("/mail/users?format=json", is_json=True)
|
2014-10-07 19:28:07 +00:00
|
|
|
for domain in users:
|
|
|
|
for user in domain["users"]:
|
|
|
|
if "admin" in user['privileges']:
|
|
|
|
print(user['email'])
|
2014-08-16 12:59:29 +00:00
|
|
|
|
v0.51 (November 14, 2020)
Software updates:
* Upgraded Nextcloud from 17.0.6 to 20.0.1 (with Contacts from 3.3.0 to 3.4.1 and Calendar from 2.0.3 to 2.1.2)
* Upgraded Roundcube to version 1.4.9.
Mail:
* The MTA-STA max_age value was increased to the normal one week.
Control Panel:
* Two-factor authentication can now be enabled for logins to the control panel. However, keep in mind that many online services (including domain name registrars, cloud server providers, and TLS certificate providers) may allow an attacker to take over your account or issue a fraudulent TLS certificate with only access to your email address, and this new two-factor authentication does not protect access to your inbox. It therefore remains very important that user accounts with administrative email addresses have strong passwords.
* TLS certificate expiry dates are now shown in ISO8601 format for clarity.
-----BEGIN PGP SIGNATURE-----
iQFDBAABCgAtFiEEX0wOcxPM10RpOyrquSBB9MEL3YEFAl+v8k4PHGp0QG9jY2Ft
cy5pbmZvAAoJELkgQfTBC92BMYUIAJTD1iKzY1SoDNSp8JMPn2sWusOnJNrnvYEV
vsrBM4AzwJv3DIZKSkYCitbTQW2FsTcjF6Jl5PCavEmAGe55AIKAPM/52Uq6jqDE
aR8EZvI9ca1i7yR7DOHEI043QSPmp/iCFD48vvmKgN/LZy67TaHaOlGJbc3nfpk0
y7ejMpF/6RP6ik4snnRQoWTFShaOpB9WcEVnUO7CHZdWcpSCZ55c9yi6A6ExGk7e
97R5+JN1MgOdZ6rzWZuMWiz7EZ/Ew4jYLZpOwg8qJm0HNbYJ6+/xxsQBwaQzyBw3
TsTl4GmunNPfoNrmKdJeLy0sBwiVBv/rysjWjim5v8jAYBoKoUQ=
=2oRU
-----END PGP SIGNATURE-----
Merge tag 'v0.51' of https://github.com/mail-in-a-box/mailinabox
v0.51 (November 14, 2020)
Software updates:
* Upgraded Nextcloud from 17.0.6 to 20.0.1 (with Contacts from 3.3.0 to 3.4.1 and Calendar from 2.0.3 to 2.1.2)
* Upgraded Roundcube to version 1.4.9.
Mail:
* The MTA-STA max_age value was increased to the normal one week.
Control Panel:
* Two-factor authentication can now be enabled for logins to the control panel. However, keep in mind that many online services (including domain name registrars, cloud server providers, and TLS certificate providers) may allow an attacker to take over your account or issue a fraudulent TLS certificate with only access to your email address, and this new two-factor authentication does not protect access to your inbox. It therefore remains very important that user accounts with administrative email addresses have strong passwords.
* TLS certificate expiry dates are now shown in ISO8601 format for clarity.
# gpg verification failed.
# Conflicts:
# management/daemon.py
# setup/bootstrap.sh
# setup/mail-users.sh
# tools/mail.py
2020-12-03 21:21:37 +00:00
|
|
|
elif sys.argv[1] == "user" and sys.argv[2] == "quota" and len(sys.argv) == 4:
|
|
|
|
# Set a user's quota
|
|
|
|
print(mgmt("/mail/users/quota?text=1&email=%s" % sys.argv[3]))
|
|
|
|
|
|
|
|
elif sys.argv[1] == "user" and sys.argv[2] == "quota" and len(sys.argv) == 5:
|
|
|
|
# Set a user's quota
|
|
|
|
users = mgmt("/mail/users/quota", { "email": sys.argv[3], "quota": sys.argv[4] })
|
|
|
|
|
2020-10-29 19:41:34 +00:00
|
|
|
elif sys.argv[1] == "user" and len(sys.argv) == 5 and sys.argv[2:4] == ["mfa", "show"]:
|
|
|
|
# Show MFA status for a user.
|
|
|
|
status = mgmt("/mfa/status", { "user": sys.argv[4] }, is_json=True)
|
|
|
|
W = csv.writer(sys.stdout)
|
|
|
|
W.writerow(["id", "type", "label"])
|
|
|
|
for mfa in status["enabled_mfa"]:
|
|
|
|
W.writerow([mfa["id"], mfa["type"], mfa["label"]])
|
|
|
|
|
2023-12-22 15:10:25 +00:00
|
|
|
elif sys.argv[1] == "user" and len(sys.argv) in {5, 6} and sys.argv[2:4] == ["mfa", "disable"]:
|
2020-10-29 19:41:34 +00:00
|
|
|
# Disable MFA (all or a particular device) for a user.
|
|
|
|
print(mgmt("/mfa/disable", { "user": sys.argv[4], "mfa-id": sys.argv[5] if len(sys.argv) == 6 else None }))
|
|
|
|
|
2013-08-31 14:50:59 +00:00
|
|
|
elif sys.argv[1] == "alias" and len(sys.argv) == 2:
|
2014-06-03 13:24:48 +00:00
|
|
|
print(mgmt("/mail/aliases"))
|
2013-08-31 14:50:59 +00:00
|
|
|
|
|
|
|
elif sys.argv[1] == "alias" and sys.argv[2] == "add" and len(sys.argv) == 5:
|
2015-08-14 23:05:08 +00:00
|
|
|
print(mgmt("/mail/aliases/add", { "address": sys.argv[3], "forwards_to": sys.argv[4] }))
|
2013-08-31 14:50:59 +00:00
|
|
|
|
|
|
|
elif sys.argv[1] == "alias" and sys.argv[2] == "remove" and len(sys.argv) == 4:
|
2015-08-14 23:05:08 +00:00
|
|
|
print(mgmt("/mail/aliases/remove", { "address": sys.argv[3] }))
|
2013-08-31 14:50:59 +00:00
|
|
|
|
v0.51 (November 14, 2020)
Software updates:
* Upgraded Nextcloud from 17.0.6 to 20.0.1 (with Contacts from 3.3.0 to 3.4.1 and Calendar from 2.0.3 to 2.1.2)
* Upgraded Roundcube to version 1.4.9.
Mail:
* The MTA-STA max_age value was increased to the normal one week.
Control Panel:
* Two-factor authentication can now be enabled for logins to the control panel. However, keep in mind that many online services (including domain name registrars, cloud server providers, and TLS certificate providers) may allow an attacker to take over your account or issue a fraudulent TLS certificate with only access to your email address, and this new two-factor authentication does not protect access to your inbox. It therefore remains very important that user accounts with administrative email addresses have strong passwords.
* TLS certificate expiry dates are now shown in ISO8601 format for clarity.
-----BEGIN PGP SIGNATURE-----
iQFDBAABCgAtFiEEX0wOcxPM10RpOyrquSBB9MEL3YEFAl+v8k4PHGp0QG9jY2Ft
cy5pbmZvAAoJELkgQfTBC92BMYUIAJTD1iKzY1SoDNSp8JMPn2sWusOnJNrnvYEV
vsrBM4AzwJv3DIZKSkYCitbTQW2FsTcjF6Jl5PCavEmAGe55AIKAPM/52Uq6jqDE
aR8EZvI9ca1i7yR7DOHEI043QSPmp/iCFD48vvmKgN/LZy67TaHaOlGJbc3nfpk0
y7ejMpF/6RP6ik4snnRQoWTFShaOpB9WcEVnUO7CHZdWcpSCZ55c9yi6A6ExGk7e
97R5+JN1MgOdZ6rzWZuMWiz7EZ/Ew4jYLZpOwg8qJm0HNbYJ6+/xxsQBwaQzyBw3
TsTl4GmunNPfoNrmKdJeLy0sBwiVBv/rysjWjim5v8jAYBoKoUQ=
=2oRU
-----END PGP SIGNATURE-----
Merge tag 'v0.51' of https://github.com/mail-in-a-box/mailinabox
v0.51 (November 14, 2020)
Software updates:
* Upgraded Nextcloud from 17.0.6 to 20.0.1 (with Contacts from 3.3.0 to 3.4.1 and Calendar from 2.0.3 to 2.1.2)
* Upgraded Roundcube to version 1.4.9.
Mail:
* The MTA-STA max_age value was increased to the normal one week.
Control Panel:
* Two-factor authentication can now be enabled for logins to the control panel. However, keep in mind that many online services (including domain name registrars, cloud server providers, and TLS certificate providers) may allow an attacker to take over your account or issue a fraudulent TLS certificate with only access to your email address, and this new two-factor authentication does not protect access to your inbox. It therefore remains very important that user accounts with administrative email addresses have strong passwords.
* TLS certificate expiry dates are now shown in ISO8601 format for clarity.
# gpg verification failed.
# Conflicts:
# management/daemon.py
# setup/bootstrap.sh
# setup/mail-users.sh
# tools/mail.py
2020-12-03 21:21:37 +00:00
|
|
|
elif sys.argv[1] == "system" and sys.argv[2] == "default-quota" and len(sys.argv) == 3:
|
|
|
|
print(mgmt("/system/default-quota?text=1"))
|
|
|
|
|
|
|
|
elif sys.argv[1] == "system" and sys.argv[2] == "default-quota" and len(sys.argv) == 4:
|
|
|
|
print(mgmt("/system/default-quota", { "default_quota": sys.argv[3]}))
|
|
|
|
|
2013-08-31 14:50:59 +00:00
|
|
|
else:
|
|
|
|
print("Invalid command-line arguments.")
|
2014-08-10 14:10:25 +00:00
|
|
|
sys.exit(1)
|
2013-08-31 14:50:59 +00:00
|
|
|
|