afterlogic / webmail-lite-8

Open-source webmail script for existing IMAP server
https://afterlogic.org/webmail-lite-8
GNU Affero General Public License v3.0
335 stars 71 forks source link

plain login #93

Closed touringo closed 1 year ago

touringo commented 1 year ago

Hi, I am evaluating WebMail lite for embedding on a intranet website, I've set Dovecot to accept plain login. With another webclient and with Thunderbird too I've been able to logon but no way to make it happen in WebMail lite. I suspect there is plain login disabled somewhere: is there a setting to tweak in order to make it work?

afterlogic-support commented 1 year ago

Do you get IMAP authentication error in debug logs of WebMail? If yes, can you share the relevant part of the logs?

touringo commented 1 year ago

Hi, this is debug log: [15:03:53.68][b55e8ecb]
[15:03:53.68][b55e8ecb] ===== API: StandardLoginFormWebclient::Login [15:03:53.68][b55e8ecb] Event: 0 > login-failed [15:03:53.68][b55e8ecb] Aurora\System\Exceptions\ApiException: ApiException in /var/www/html/unidoc.next/webmail/modules/Core/Module.php:2198 Stack trace:

0 [internal function]: Aurora\Modules\Core\Module->SetAuthDataAndGetAuthToken()

1 /var/www/html/unidoc.next/webmail/system/Module/AbstractModule.php(836): call_user_func_array()

2 /var/www/html/unidoc.next/webmail/system/Module/Decorator.php(55): Aurora\System\Module\AbstractModule->CallMethod()

3 /var/www/html/unidoc.next/webmail/modules/Core/Module.php(2278): Aurora\System\Module\Decorator->__call()

4 [internal function]: Aurora\Modules\Core\Module->Login()

5 /var/www/html/unidoc.next/webmail/system/Module/AbstractModule.php(836): call_user_func_array()

6 /var/www/html/unidoc.next/webmail/system/Module/Decorator.php(55): Aurora\System\Module\AbstractModule->CallMethod()

7 /var/www/html/unidoc.next/webmail/modules/StandardLoginFormWebclient/Module.php(47): Aurora\System\Module\Decorator->__call()

8 [internal function]: Aurora\Modules\StandardLoginFormWebclient\Module->Login()

9 /var/www/html/unidoc.next/webmail/system/Module/AbstractModule.php(836): call_user_func_array()

10 /var/www/html/unidoc.next/webmail/modules/Core/Module.php(685): Aurora\System\Module\AbstractModule->CallMethod()

11 [internal function]: Aurora\Modules\Core\Module->EntryApi()

12 /var/www/html/unidoc.next/webmail/system/Router.php(111): call_user_func_array()

13 /var/www/html/unidoc.next/webmail/system/Module/Manager.php(639): Aurora\System\Router->route()

14 /var/www/html/unidoc.next/webmail/system/Application.php(141): Aurora\System\Module\Manager->RunEntry()

15 /var/www/html/unidoc.next/webmail/system/Application.php(110): Aurora\System\Application->Route()

16 /var/www/html/unidoc.next/webmail/index.php(21): Aurora\System\Application::Start()

17 {main}

[15:03:53.68][b55e8ecb] @Time: 0.0122 [15:03:53.68][b55e8ecb] @TimeApiInit: 0.0053 [15:03:53.68][b55e8ecb] INFO[MEMORY]: Memory peak usage: 4MB [15:03:53.68][b55e8ecb] INFO[TIME]: Time delta: 1669820633.6868 [15:03:53.83][4217e85c]
[15:03:53.83][4217e85c] ===== API: LogsViewerWebclient::GetLogFilesData [15:03:53.83][4217e85c] @Time: 0.0006 [15:03:53.83][4217e85c] @TimeApiInit: 0.0051 [15:03:53.83][4217e85c] INFO[MEMORY]: Memory peak usage: 2MB [15:03:53.83][4217e85c] INFO[TIME]: Time delta: 1669820633.8325 [15:03:57.01][cdfb2672]
[15:03:57.01][cdfb2672] ===== API: LogsViewerWebclient::GetLog

afterlogic-support commented 1 year ago

Thanks. However, that's not exactly what I asked. Do the logs not contain communication with IMAP server at all? If so, that isn't related to mailserver authentication mode and has something to do with how webmail is configured, there can be various potential reasons - mail server added incorrectly in adminpanel, attempting to log into an account specifying just the username rather than full email address, and so on. One more thing that comes to mind is CSRF protection, you can try turning it off and see if that helps.

touringo commented 1 year ago

I've got a couple of rows from dovecot server, if can help:

Nov 30 14:15:11 9mx dovecot: imap-login: Login: user=macho@tablet.local, method=PLAIN, rip=10.116.205.84, lip=10.116.204.112, mpid=2842, session= Nov 30 14:15:11 9mx dovecot: imap(macho@tablet.local)<2842>: Disconnected: Logged out in=89 out=1097 deleted=0 expunged=0 trashed=0 hdr_count=0 hdr_bytes=0 body_count=0 body_bytes=0

notice: tablet.local is a domain used in my intranet

touringo commented 1 year ago

Just for info, here is mailserver configuration screenshot. I hope it's visible, just pasted it. immagine

touringo commented 1 year ago

Hi, you were right: after deleting a recreating mail server I've able to make customer logon. Thanks.