# How to fix SSL wrong version number?

**URL:** https://meta.discourse.org/t/how-to-fix-ssl-wrong-version-number/385239
**Category:** Support
**Tags:** unsupported-install, onebox
**Created:** [October 10, 2025, 2:15pm UTC](https://meta.discourse.org/t/how-to-fix-ssl-wrong-version-number/385239 "2025-10-10T14:15:36Z")
**Posts on this page:** 1
**Showing post:** 1

<div class="post-metadata">

### Author: ![MoRanYue](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/moranyue/32/523065_2.png) [@MoRanYue](https://meta.discourse.org/u/MoRanYue)
#### Post date: [October 10, 2025, 2:15pm UTC](https://meta.discourse.org/t/how-to-fix-ssl-wrong-version-number/385239/1 "2025-10-10T14:15:36Z")

</div>

I found that my Discourse cannot generate OneBox for any websites except YouTube, when checking out the log, I saw this error thrown:

```plaintext
Failed to onebox https://bilibili.com SSL_connect returned=1 errno=0 peeraddr=192.168.50.1:10808 state=error: wrong version number (OpenSSL::SSL::SSLError) ["/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/excon-1.2.5/lib/excon/ssl_socket.rb:151:in 'OpenSSL::SSL::SSLSocket#connect_nonblock'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/excon-1.2.5/lib/excon/ssl_socket.rb:151:in 'Excon::SSLSocket#initialize'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/excon-1.2.5/lib/excon/connection.rb:487:in 'Class#new'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/excon-1.2.5/lib/excon/connection.rb:487:in 'Excon::Connection#socket'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/excon-1.2.5/lib/excon/connection.rb:120:in 'Excon::Connection#request_call'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/excon-1.2.5/lib/excon/middlewares/mock.rb:57:in 'Excon::Middleware::Mock#request_call'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/excon-1.2.5/lib/excon/middlewares/instrumentor.rb:34:in 'Excon::Middleware::Instrumentor#request_call'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/excon-1.2.5/lib/excon/middlewares/idempotent.rb:19:in 'Excon::Middleware::Idempotent#request_call'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/excon-1.2.5/lib/excon/middlewares/base.rb:22:in 'Excon::Middleware::Base#request_call'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/excon-1.2.5/lib/excon/middlewares/decompress.rb:14:in 'Excon::Middleware::Decompress#request_call'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/excon-1.2.5/lib/excon/middlewares/base.rb:22:in 'Excon::Middleware::Base#request_call'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/excon-1.2.5/lib/excon/connection.rb:293:in 'Excon::Connection#request'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/excon-1.2.5/lib/excon.rb:252:in 'Excon.head'", "/home/mry/discourse/lib/final_destination.rb:268:in 'Kernel#public_send'", "/home/mry/discourse/lib/final_destination.rb:268:in 'FinalDestination#resolve'", "/home/mry/discourse/lib/oneboxer.rb:497:in 'block in Oneboxer.external_onebox'", "/home/mry/discourse/lib/cache.rb:93:in 'Cache#fetch'", "/home/mry/discourse/lib/oneboxer.rb:482:in 'Oneboxer.external_onebox'", "/home/mry/discourse/lib/oneboxer.rb:285:in 'Oneboxer.onebox_raw'", "/home/mry/discourse/lib/oneboxer.rb:96:in 'Oneboxer.onebox'", "(discourse):4:in '<main>'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/irb-1.15.2/lib/irb/workspace.rb:101:in 'Kernel#eval'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/irb-1.15.2/lib/irb/workspace.rb:101:in 'IRB::WorkSpace#evaluate'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/irb-1.15.2/lib/irb/context.rb:591:in 'IRB::Context#evaluate_expression'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/irb-1.15.2/lib/irb/context.rb:557:in 'IRB::Context#evaluate'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/irb-1.15.2/lib/irb.rb:201:in 'block (2 levels) in IRB::Irb#eval_input'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/irb-1.15.2/lib/irb.rb:512:in 'IRB::Irb#signal_status'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/irb-1.15.2/lib/irb.rb:193:in 'block in IRB::Irb#eval_input'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/irb-1.15.2/lib/irb.rb:272:in 'block in IRB::Irb#each_top_level_statement'", "<internal:kernel>:168:in 'Kernel#loop'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/irb-1.15.2/lib/irb.rb:269:in 'IRB::Irb#each_top_level_statement'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/irb-1.15.2/lib/irb.rb:192:in 'IRB::Irb#eval_input'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/irb-1.15.2/lib/irb.rb:173:in 'block in IRB::Irb#run'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/irb-1.15.2/lib/irb.rb:172:in 'Kernel#catch'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/irb-1.15.2/lib/irb.rb:172:in 'IRB::Irb#run'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/railties-8.0.3/lib/rails/commands/console/irb_console.rb:113:in 'Rails::Console::IRBConsole#start'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/railties-8.0.3/lib/rails/commands/console/console_command.rb:59:in 'Rails::Console#start'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/railties-8.0.3/lib/rails/commands/console/console_command.rb:8:in 'Rails::Console.start'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/railties-8.0.3/lib/rails/commands/console/console_command.rb:87:in 'Rails::Command::ConsoleCommand#perform'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/thor-1.4.0/lib/thor/command.rb:28:in 'Thor::Command#run'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/thor-1.4.0/lib/thor/invocation.rb:127:in 'Thor::Invocation#invoke_command'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/railties-8.0.3/lib/rails/command/base.rb:178:in 'Rails::Command::Base#invoke_command'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/thor-1.4.0/lib/thor.rb:538:in 'Thor.dispatch'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/railties-8.0.3/lib/rails/command/base.rb:73:in 'Rails::Command::Base.perform'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/railties-8.0.3/lib/rails/command.rb:65:in 'block in Rails::Command.invoke'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/railties-8.0.3/lib/rails/command.rb:143:in 'Rails::Command.with_argv'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/railties-8.0.3/lib/rails/command.rb:63:in 'Rails::Command.invoke'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/railties-8.0.3/lib/rails/commands.rb:18:in '<main>'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/3.4.0/bundled_gems.rb:82:in 'Kernel.require'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/3.4.0/bundled_gems.rb:82:in 'block (2 levels) in Kernel#replace_require'", "/home/mry/.rbenv/versions/3.4.6/lib/ruby/gems/3.4.0/gems/bootsnap-1.18.6/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in 'Kernel#require'", "bin/rails:18:in '<main>'"]

```

Tested `Oneboxer.onebox('https://bilibili.com')` invocation in `rails c`, then getting the same error.

I do not know why and feel puzzled now, because Discourse can process OAuth and AI request and other HTTP requests with no errors, it only happened to OneBox, but YouTube OneBox can be normally generated.

It was using a proxy server now and I am sure that this is not proxy’s problem, `curl`, `wget` and `httpx` module in Python could fetch response successfully, but `excon` in Ruby gave me `SSL: wrong version number`, what should I do to fix it?

I used `3.0.13` release of OpenSSL, which was published in Jan. 2024, when compiling the Ruby interpreter, is that version too old?

---

_[View the full topic](https://meta.discourse.org/t/how-to-fix-ssl-wrong-version-number/385239)._
