docker-spotweb icon indicating copy to clipboard operation
docker-spotweb copied to clipboard

SSL operation failed with code 1

Open Smiggel opened this issue 3 years ago • 15 comments

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

Smiggel avatar Dec 01 '21 18:12 Smiggel

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

jgeusebroek avatar Dec 01 '21 19:12 jgeusebroek

Eweka and SSL works for me

image

proddy avatar Dec 01 '21 19:12 proddy

And if you disable verify name; does it work?

jgeusebroek avatar Dec 01 '21 19:12 jgeusebroek

And if you disable verify name; does it work?

yes

proddy avatar Dec 01 '21 20:12 proddy

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

jgeusebroek avatar Dec 01 '21 20:12 jgeusebroek

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 .

Smiggel avatar Dec 02 '21 16:12 Smiggel

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

jgeusebroek avatar Dec 02 '21 17:12 jgeusebroek

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.

Smiggel avatar Dec 02 '21 18:12 Smiggel

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

jgeusebroek avatar Dec 02 '21 18:12 jgeusebroek

Thanks anyway for the help. :-)

Smiggel avatar Dec 02 '21 18:12 Smiggel

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?

Smiggel avatar Dec 03 '21 17:12 Smiggel

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

jgeusebroek avatar Dec 03 '21 20:12 jgeusebroek

yup, for years now

proddy avatar Dec 03 '21 21:12 proddy

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)

nomnomnomhb avatar Aug 26 '22 17:08 nomnomnomhb

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!

Smiggel avatar Aug 27 '22 06:08 Smiggel