Skip to main content
Version: 2.1.26

2.1.29

Four fixes, one of which deleted mail. Update.

Fixed​

  • Deleting one domain deleted every mailbox the account had, on every domain. The routine that removes a domain's mail is given the domain and never uses it: it reads the account's mailbox list — which is one file covering every domain the account owns — and deletes all of it. Removing one domain from an account with three took the other two domains' mail with it, and the panel reported the deletion as successful.

    The mail itself survived by accident. Mailbox deletion removed /var/mail/<domain>/<user>, which is where the container layout kept mail; natively Dovecot keeps it one directory deeper. So every mailbox deletion this product has done has left the mail on disk — a fault of its own, fixed here, and the only reason this one was recoverable. Both had to be fixed together: the wrong path was the safety net under the wrong list.

    If you have deleted a domain from an account that owns others, check your mailboxes. The maildirs are still under /var/mail/vhosts/; a mailbox can be recreated at the same address and its mail is there.

  • Document Root opened the wrong directory. Clicking it answered "Directory does not exist" and dropped you at the top of your files. The link was built by removing /var/www/html from the front of the document root — the container layout — so on a native server nothing was removed and the path was resolved underneath the account's home a second time. The FTP accounts table had the same line and is fixed with it.

  • An address could not be allocated to a reseller. It answered "No such account", and had never worked: a reseller is a panel login, not a hosting account, so the check for one looked in a directory a reseller has never had.

  • The IP address list in an account's settings was empty, and offered addresses that were in use when it was not. It was built from the accounts that already hold a dedicated address — empty on a server where none does, and a list of other people's addresses where some do. It now offers what is free, plus whatever the account already holds.

Notes​

Nothing to migrate. The update replaces scripts and binaries; no configuration, schema or service changes.

On the mailbox one. It was found from a live server rather than from the code: two mailboxes present in a backup at 03:32 were absent from the account file at 12:22, with their maildirs untouched on disk. The fix is covered by a test that runs the real routine out of the real script with the deletion command stubbed, and it was checked by removing the fix again and watching the test fail on exactly the mailboxes that should not have been touched.

Was this helpful?