Feature #9612

Gemify OpenSSL

Added by Zachary Scott about 1 year ago. Updated 5 months ago.

[ruby-core:61378]
Status:Open
Priority:Normal
Assignee:-

Description

Previously in #9439 we discussed removing OpenSSL from Ruby, however this wasn't the right approach.

I would like to suggest Aaron's approach from ruby-core:60075

You can see his patch here: https://github.com/tenderlove/ruby/commit/fd96a5b

As ruby-core:60063 states, we will need to modify the visibility of thread_native.h as seen here: https://github.com/ruby/ruby/blob/8cacc6459/ext/openssl/ossl.c#L469-L480


Related issues

Related to Ruby trunk - Feature #5481: Gemifying Ruby standard library Assigned 10/25/2011

Associated revisions

Revision 45944
Added by Koichi Sasada 12 months ago

  • ext/openssl/depend: remove dependency from internal headers. [Feature #9612]
  • ext/openssl/ossl.c (ossl_fips_mode_set): ditto.
  • ext/coverage/depend: ditto.
  • include/ruby/thread_native.h: added. This header file only provides wrapper functions to control native threads. These wrapper functions are used by MRI implementation.
  • vm_core.h: use include/ruby/thread_native.h.
  • thread.c: ditto.
  • thread_pthread.h: ditto.
  • thread_win32.h: ditto.
  • thread_native.h: removed.

Revision 45944
Added by Koichi Sasada 12 months ago

  • ext/openssl/depend: remove dependency from internal headers. [Feature #9612]
  • ext/openssl/ossl.c (ossl_fips_mode_set): ditto.
  • ext/coverage/depend: ditto.
  • include/ruby/thread_native.h: added. This header file only provides wrapper functions to control native threads. These wrapper functions are used by MRI implementation.
  • vm_core.h: use include/ruby/thread_native.h.
  • thread.c: ditto.
  • thread_pthread.h: ditto.
  • thread_win32.h: ditto.
  • thread_native.h: removed.

Revision 45945
Added by Nobuyoshi Nakada 12 months ago

openssl/depend: ossl.o

  • ext/openssl/depend (ossl.o): now depends on thread_native.h under $(hdrdir) instead of $(top_srcdir). [Feature #9612]

Revision 45945
Added by Nobuyoshi Nakada 12 months ago

openssl/depend: ossl.o

  • ext/openssl/depend (ossl.o): now depends on thread_native.h under $(hdrdir) instead of $(top_srcdir). [Feature #9612]

History

#1 Updated by Shyouhei Urabe about 1 year ago

:+1: Great step.

#2 Updated by Koichi Sasada 12 months ago

  • Status changed from Open to Closed
  • % Done changed from 0 to 100

Applied in changeset r45944.


  • ext/openssl/depend: remove dependency from internal headers. [Feature #9612]
  • ext/openssl/ossl.c (ossl_fips_mode_set): ditto.
  • ext/coverage/depend: ditto.
  • include/ruby/thread_native.h: added. This header file only provides wrapper functions to control native threads. These wrapper functions are used by MRI implementation.
  • vm_core.h: use include/ruby/thread_native.h.
  • thread.c: ditto.
  • thread_pthread.h: ditto.
  • thread_win32.h: ditto.
  • thread_native.h: removed.

#3 Updated by Koichi Sasada 12 months ago

  • Status changed from Closed to Open

Modified.

But current version doesn't work on 2.1.2 or before.

#4 Updated by Nobuyoshi Nakada 12 months ago

  • Status changed from Open to Closed

Applied in changeset r45945.


openssl/depend: ossl.o

  • ext/openssl/depend (ossl.o): now depends on thread_native.h under $(hdrdir) instead of $(top_srcdir). [Feature #9612]

#5 Updated by Nobuyoshi Nakada 12 months ago

  • Status changed from Closed to Open

It might be better to create a subtask?

#6 Updated by Zachary Scott 12 months ago

Awesome, thanks so much @ko1!!!

We should consider this for 2.2.0, adding a gemspec with required_ruby_version to match.

#7 Updated by Yui NARUSE 6 months ago

  • Related to Feature #5481: Gemifying Ruby standard library added

#8 Updated by Charles Nutter 5 months ago

So will this be a default gem in 2.2? Has there been enough testing?

Because many Rubyists will now start putting "openssl" in their Gemfile, I think we need to get JRuby's version of openssl released as a -java platform gem.

I've started this process locally in the jruby/openssl fork of ruby/openssl. I hope we could work from one codebase in the future.

#9 Updated by Yui NARUSE 5 months ago

  • Target version changed from current: 2.2.0 to next minor

No, 2.2 doesn't include gemifying openssl.

Also available in: Atom PDF