-
-
Notifications
You must be signed in to change notification settings - Fork 126
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multiple issues with admin/domains page since v2.35.3 - no longer functions correctly and produces broken config. #1513
Comments
Thanks for looking into this issue. I just cherry-picked this patch and added it to my 2.35.4 install but all of the issues I reported still exist: I've also discovered that when trying to add a new domain, the generated config file has no filename, and it only has a .json file extension. For example, if I attempt to create mailserver.co.uk domain, and I put 'mailserver.co.uk' in the 'Name' box of the form, the resultant file after saving is I will attempt to capture a debug log and mail server auth log to post here however, the debug log only reports issues with generating the new domain config when saving the settings. It doesn't show anything relating to the domain settings editor pop-up window not showing. Perhaps I should be posting separate issues for each problem? |
Here is the Snappymail debug log when trying to disable domain. When clicking the check box in the admins/domains UI, the box briefly clears and then quickly reverts back to being enabled:
|
And here is the Snappymail debug log when trying to delete the same domain. Again, the UI shows the 'Are you sure?' button when clicking the trash can but nothing happens when clicking 'Are you sure?'.
It looks like the Json queries are empty. Is something filtering them? Is the fault with my web server config or a bug in the Snappymail code? I run haproxy in front of httpd, with php-fpm 8.2 ...... |
And here are logs showing an attempt to add a new domain.
|
And finally, here is the domains directory listing showing the generated .json without
|
Something must be wrong with your server.
Here it says the change is made and the domain is disabled.
Here it does not say it is. So saving the I've changed the code a bit to return "false" when it fails |
Exactly! This is what I am reporting - the admins/domains web UI doesn't work correctly and so disabling, deleting or editing doesn't work. I'll try this change and report findings. These issues only started happening since 2.35.3 - my mail server configuration hasn't changed. I don't understand why the admins/domains settings editor window doesn't pop up when clicking one of the listed domains. |
Check your logs |
Nothing in error logs. Access logs shows Does this imply that the JSON query is not working correctly? |
That is the Apache log. Not the PHP nor SnappyMail log |
Yes. The php-fpm debug log does not show anything. The Snappymail logs are already posted in this ticket. In Snappymail config I had already set debug log = on + |
Then, when empty it could be an issue with PHP Intl extension returning incorrect value for idn_to_ascii. Just wait for next release |
Ah! I had an issue with PHP-intl on another site recently and it was due to changes in PHP. I will try running an older version of PHP to see if that works. Thanks for giving your time to help me and help troubleshoot, much appreciated. I have a little extra information - I enabled developer console in my browser and I see this when loading the domains page:
DOMPurify is part of Squire isn't it? Is the fact that Firefox can't find it important? |
Those errors are because of Firefox extensions trying to load inside SnappyMail. |
Interesting! I tried using a Firefox private browsing window that is supposed to disable all extensions yet I still get the error about purify.min.js. However, with a clean Firefox profile, that has zero extensions installed, the error doesn't appear - but.... the admin/domains page still doesn't work. I will leave you alone now and wait for the next release 🙂 Thanks again for your help [Edit] It is the Firefox Translations add-on - firefox-translations-addon @ mozilla.org |
Web browser debugger shows this JSON request and response when clicking on a domain in the list to edit it: Request: In Snappymail 2.35.2 the JSON response contains the domain's configuration settings as expected. Changing PHP version has no effect. I tried php-8.0 and php-8.1 before reverting back to php-8.2. |
The problem does indeed lie with my web server. I'd like to apologise for bombarding you with messages today and wasting your time. It has taken me all day to troubleshoot and get to the bottom of it. Your hint about PHP Intl module and I'll explain the solution in the hope that it might help other Snappymail and OpenBSD users in future: I discovered that even though the php-intl module was loaded, attempting to use the I created a small
and enabled intl error messages in my php.ini:
and the only output was the resultant error Checking file locations and OS packages relating to ICU and I discovered the My web server doesn't run with the default OpenBSD chroot so I copied that file to the relative path under my chroot and now everything works!! |
Great that you find the problem! SnappyMail does have a polyfill when php-intl is not installed. |
Version 2.35.3 and 2.35.4 have issues with the admin/domains page. Clicking already configured domains to change the domain settings does not result in the settings pop-up window appearing at all and so domain settings can not be changed.
Also, it is no longer possible to deselect or disable each domain by clearing the check mark in the box next to the domain, nor is it possible to delete the domain.
Attempting to add a new domain does result in the domain settings pop-up window appearing however, it produces a broken and non-functional configuration.
When attempting to add a new domain, after entering the correct settings and clicking the 'Test' button, the test passes as shown by the tabs turning green however, the snappymail debug log shows "Failed authentication" and my mail server log shows that during the snappymail smtp test, the authentication is attempted using only the username part of the full email address whereas it should attempt using the full email address including domain, which my mail server requires, i.e. it requires [email protected] for the auth username for example.
Version 2.35.2 does not suffer from these problems.
I'm wondering whether this might be related to recent changes for internationalisation of domain names? All my domains are .co.uk domains.
Steps to reproduce the behavior:
Expected behavior
The domain settings pop-up window should appear and produce functioning domain configuration files.
Please complete the following information:
The text was updated successfully, but these errors were encountered: