pimalaya / himalaya

CLI to manage emails
https://pimalaya.org
MIT License
3.17k stars 95 forks source link

Older SSL/TLS versions #440

Closed jubalh closed 1 year ago

jubalh commented 1 year ago

Is there a way to configure himalaya to connect even to servers that use outdated ssl versions?

himalaya
Error: cannot connect to imap server

Caused by:
    error:1408F10B:SSL routines:ssl3_get_record:wrong version number:ssl/record/ssl3_record.c:331:
soywod commented 1 year ago

Is there a way to configure himalaya to connect even to servers that use outdated ssl versions?

No, there is no way to configure such thing. Do you know which SSL version your server uses?

jubalh commented 1 year ago

I have one instance that uses tls 1.0 AFAIK

soywod commented 1 year ago

Strange because TLS 1.0 seems to be supported by native-tls: https://github.com/sfackler/rust-native-tls/blob/774a19cecb694dc6e414c2ada9bd5f768a0b9b75/src/imp/openssl.rs#L32. Could you share your Himalaya config?

jubalh commented 1 year ago

Could you share your Himalaya config?

Quite basic, and I removed the (private) domain name:

display-name = "Test"
downloads-dir = "~/test/downloads"

[myserver]
default = true
email = "user@myserver.org"

backend = "imap"
imap-host = "imap.myserver.org"
imap-port = 143
imap-login = "user@myserver.org"
imap-passwd-cmd = "pass user@myserver.org"

sender = "smtp"
smtp-host = "smtp.myserver.org"
smtp-port = 25
smtp-login = "user@myserver.org"
smtp-passwd-cmd = "pass user@myserver.org"
jubalh commented 1 year ago

Is there anything I can do to further debug this?

soywod commented 1 year ago

Is there anything I can do to further debug this?

Did you try to use the port 993 instead of 143? Or to use STARTTLS with the option imap-starttls = true?

jubalh commented 1 year ago

I tried that and started himalaya. Now it hangs since several minutes. It can't be downloading since it didn't get my password via pass yet. And I assume there would also be a connection timeout.

soywod commented 1 year ago

I tried that and started himalaya. Now it hangs since several minutes.

So something is wrong with the config. I am a bit out of idea :/ is there any way for me to have an access so I can try to debug also?

jubalh commented 1 year ago

I will close this for now since I didn't find the time to further investigate. I hope it's okay if I comment later again.

soywod commented 1 year ago

Yes sure! Just for information: the bug trackers moves away from GitHub, you need now to send an email at soywod/pimalaya@todo.sr.ht, see https://github.com/soywod/himalaya/blob/master/CONTRIBUTING.md#contributing.