cypht-org / cypht

Cypht: Lightweight Open Source webmail aggregator [PHP, JS]. Supports IMAP/SMTP, JMAP and soon EWS
http://cypht.org
GNU Lesser General Public License v2.1
1.01k stars 163 forks source link

Sieve - can't make it work #1153

Open europacafe opened 3 months ago

europacafe commented 3 months ago

💬 Question

Mail server: stalwart + snappymail webmail ---> tls sieve work (mail.mydomain.com, ssl/tls, 4190) Cypht 2.1.0 + stalwart --> tls sieve setting does not work, can't save server config

When opening a mail content, it always reports "Sieve: invalid config host for ....my mailbox name.." cypht_sieve_invalid_config

On stalwart mail server, below is the sieve config stalwart_sieve_tls_config

On snappymail webmail, the sieive config works snappymail_sieve_config

On cypht env file, below is the config: cypht_sieve_env_config

When I tried to enable sieve on one of my IMAP accounts as below, after saving the config, the screen froze for over 10 secs and came back with an offline label and it didn't save. image I'm not sure what I did wrong. (I enable sieve on Settings/Site/Enable sieve filter)

josaphatim commented 3 months ago

@europacafe thank you for reporting this. What if you remove the protocol in sieve host input mail.brhofen.com:4190 ?

europacafe commented 3 months ago

I did try that too. Not working as well.

marclaporte commented 3 months ago

Please try Cypht master

europacafe commented 3 months ago

How? (with docker compose)

marclaporte commented 3 months ago

How? (with docker compose)

@jonocodes This is not yet coded, right?

marclaporte commented 3 months ago

Please try this: https://github.com/cypht-org/cypht/pull/1135/files (just manually modify the file)

Here is an known issue: https://github.com/cypht-org/cypht/issues/931

europacafe commented 3 months ago

just manually modified it to $server = Hm_IMAP_List::get($imap_server_id, true);, restarted cypht container, rechecked the change was still there same behavior for both tls://mail.mydomain.com:4190 and mail.mydomain.com:4190

Shadow243 commented 3 months ago

@europacafe have you checked that the server firewall gives access to 4190 on your server ?

you can use this command to check if sieve is enabled:

openssl s_client -connect mail.mydomain.com:4190 --starttls sieve
europacafe commented 3 months ago

I did open 4190 port on my pfSense. Here is the test result image

As mentioned earlier, my snappymail webmail can connect to sieve.

jonocodes commented 3 months ago

Yes, I would think you could use the docker compose setup to test this. Also check the cypht service logs to see if there are any errors.

europacafe commented 3 months ago

Yes, I would think you could use the docker compose setup to test this. Also check the cypht service logs to see if there are any errors.

My cypht is always running as a container, and the suggested openssl test was carried out inside cypht container.

europacafe commented 3 months ago

With docker image v2.2.0, this is still an issue

jonocodes commented 3 months ago

Do we know that this works as expected when not using docker (using php locally without any container)?

Shadow243 commented 3 months ago

Do we know that this works as expected when not using docker (using php locally without any container)?

Yes we were able to connect not using docker, I'm going to try this one with the same server that worked but using docker instead.

marclaporte commented 2 months ago

Is still an issue with Cypht 2.4.0? https://hub.docker.com/r/cypht/cypht

europacafe commented 2 months ago

Yes.

Shadow243 commented 2 months ago

Will be solved here https://github.com/cypht-org/cypht/pull/1199

Shadow243 commented 1 month ago

@europacafe please confirm on your side.

europacafe commented 1 month ago

With cypht 2.4.0 docker container, it is still not working at all, with Stalwart mail server.

Fyi. With snappymail web client, Sieve works only with ssltls, but not starttls. They are working on the issue.

Shadow243 commented 1 month ago

With cypht 2.4.0 docker container

2.4.0 is not yet compatible; it will work with the master branch. Full compatibility will come with version 2.5.0, not 2.4.0.

europacafe commented 1 month ago

Great. I may build it from the master and try it. Will feedback later.

cptsanifair commented 4 weeks ago

@europacafe u can try to connect with this tool https://github.com/thsmi/sieve to test the connection and sieve.