jgeusebroek / docker-spotweb

A docker image running ubuntu/20.04 Linux and Spotweb
47 stars 27 forks source link

SSL operation failed with code 1 #43

Open Smiggel opened 2 years ago

Smiggel commented 2 years ago

Having trouble connection to Eweka using SSL. I can not retrieve spots and see this output in the terminal:

PHP Warning: stream_socket_client(): SSL operation failed with code 1. OpenSSL Error messages: error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed in /var/www/spotweb/vendor/spotweb/nntp/src/Protocol/Client.php on line 729

jgeusebroek commented 2 years ago

That's weird. What hostname are you using? The docker images uses the latest CA root certificates.

proddy commented 2 years ago

Eweka and SSL works for me

image

jgeusebroek commented 2 years ago

And if you disable verify name; does it work?

proddy commented 2 years ago

And if you disable verify name; does it work?

yes

jgeusebroek commented 2 years ago

Thanks it was meant for @Smiggel . I should have been more clear :)

Smiggel commented 2 years ago

Whoops. Sorry for the late reply. I did not get any notifications. :-)

I tried it again today. I run this docker container on OpenMediaVault 6 (beta). I have no issues with other container running.

Removing Spot information which is beyond retention period,, done Last retrieve at Thu 01 Jan 1970 01:00:00 AM CET Retrieving new Spots from server news.eweka.nl... PHP Warning: stream_socket_client(): SSL operation failed with code 1. OpenSSL Error messages: error:1416F086:SSL routines:tls_process_server_certificate:certificate verify failed in /var/www/spotweb/vendor/spotweb/nntp/src/Protocol/Client.php on line 729 PHP Warning: stream_socket_client(): Failed to enable crypto in /var/www/spotweb/vendor/spotweb/nntp/src/Protocol/Client.php on line 729 PHP Warning: stream_socket_client(): Unable to connect to ssl://news.eweka.nl:563 (Unknown error) in /var/www/spotweb/vendor/spotweb/nntp/src/Protocol/Client.php on line 729 SpotWeb v0.68.33.34 on PHP v8.0.13 crashed

Fatal error occured while connecting to the newsserver: (-1) Error while connecting to server (server did not respond) [response: ""] [response: ""]

0 /var/www/spotweb/lib/services/Nntp/Services_Nntp_Engine.php(143): Services_Nntp_Engine->connect()

1 /var/www/spotweb/lib/services/Retriever/Services_Retriever_Base.php(118): Services_Nntp_Engine->selectGroup()

2 /var/www/spotweb/lib/services/Retriever/Services_Retriever_Base.php(298): Services_Retriever_Base->connect()

3 /var/www/spotweb/retrieve.php(142): Services_Retriever_Base->perform()

4 {main}

Finished retrieving spots

Schermafbeelding 2021-12-02 om 17 19 19

.

jgeusebroek commented 2 years ago

Interesting. Is the date and time on your server set correctly? It probably is, but let's rule it out.

Smiggel commented 2 years ago

Yes, the date and time are correct.

I think perhaps my underlaying OS is perhaps the problem. I run Raspberry Pi OS Bullseye. On top of that I run OpenMediaVault 6.

Just now I removed everything related to spotweb. Did a new install in docker, with a stack. I ran the install.php script. When I verify my usenet connecting, I get a blank screen. When I skip the verification, I can continue. However, when I reach the last step, I get a blank again. dbsettings.inc.php is also not created on my disk. Manually creating the dbsettings.inc.php file works and can connect Spotweb.

jgeusebroek commented 2 years ago

The underlying OS "shouldn't" have an impact on the docker container. I unfortunately don't have any ideas left.

Smiggel commented 2 years ago

Thanks anyway for the help. :-)

Smiggel commented 2 years ago

Issue is closed, but I just want to let you know, the issue seems somewhere in your image. I switched to erikdevries/rpi-spotweb docker image and SSL connection works there.

Is perhaps your docker image not ment for a Raspberry Pi?

jgeusebroek commented 2 years ago

Thanks for letting me know. @proddy are you using my latest image to connect to Eweka?

proddy commented 2 years ago

yup, for years now

nomnomnomhb commented 2 years ago

I was encountering the same issue today with a fresh deployment on Raspberry Pi OS (Latest updated OS, Docker latest). Fixed by updating all packages inside the spotweb docker container ... This updated a ton of packages but not the OpenSSL package (I tried solely this package first, but remained the same version). Might help someone!

docker exec spotweb apt-get update docker exec spotweb apt-get upgrade -y

(With "spotweb" in the commands as name of your container)

Smiggel commented 2 years ago

I was encountering the same issue today with a fresh deployment on Raspberry Pi OS (Latest updated OS, Docker latest). Fixed by updating all packages inside the spotweb docker container ... This updated a ton of packages but not the OpenSSL package (I tried solely this package first, but remained the same version). Might help someone!

docker exec spotweb apt-get update docker exec spotweb apt-get upgrade -y

(With "spotweb" in the commands as name of your container)

Yes, that’s it! I just now tried it and ask works again! Thank you!