`OpenSSL::SSL::SSLError: SSL_read: unexpected eof while reading` with OpenSSL 3.x

Open
#90 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
30/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
ruby
Domain
backend, security

Research direction

Start by reproducing the failure with Ruby 3.1 and OpenSSL 3.0 while running the Excon test suite. Read the reported paths in openssl/buffering.rb and webrick/httpserver.rb and server.rb, then compare the behavior with the linked Puma and ruby/openssl discussions. Done would require an agreed compatibility fix or a documented reason the error is expected.

Written by the indexing model from the issue text.

Description

Executing excon test suite with Ruby 3.1 and OpenSSL 3.0, I observe following errors:

  Excon basics (ssl) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
[2022-02-23 03:58:50] ERROR OpenSSL::SSL::SSLError: SSL_read: unexpected eof while reading
	/usr/share/ruby/openssl/buffering.rb:80:in `sysread'
	/usr/share/ruby/openssl/buffering.rb:80:in `fill_rbuff'
	/usr/share/ruby/openssl/buffering.rb:332:in `eof?'
	/usr/share/gems/gems/webrick-1.7.0/lib/webrick/httpserver.rb:82:in `run'
	/usr/share/gems/gems/webrick-1.7.0/lib/webrick/server.rb:310:in `block in start_thread'

This reminds me issues I had with Puma. There is also more details in ruby/openssl ticket

Dominant language
Ruby
Stars
328
Forks
114
Avg merge
1h 15m
Merged PRs (30d)
1

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from ruby/webrick

All issues in ruby/webrick

Similar issues

More Ruby issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.