<?xml version="1.0" encoding="UTF-8"?>
<page>
  <created-at type="datetime">2009-03-24T22:44:14Z</created-at>
  <description></description>
  <id type="integer">1136</id>
  <name>JRuby_Builtin_OpenSSL</name>
  <number type="integer">1</number>
  <person-id type="integer">5242</person-id>
  <text>JRuby historically has not shipped with a fully functional openssl module due to cryptographic export restrictions. However, in order to support Rails 2.0 out of the box, we implemented a limited subset of openssl that implements &lt;tt&gt;OpenSSL::HMAC&lt;/tt&gt; and &lt;tt&gt;OpenSSL::Digest&lt;/tt&gt;.

However, this breaks programs that use &lt;tt&gt;require 'openssl'&lt;/tt&gt; as a test for whether openssl is available or not. [http://dev.ctor.org/soap4r Soap4r] is one such program. In order to support this behavior, simply add

    require 'jruby/openssl/gem_only'

at the start of your program, and requiring openssl will revert to raising a load error.

See also [http://jira.codehaus.org/browse/JRUBY-1808 JRUBY-1808] for a discussion on this feature. 
</text>
  <text-as-html>&lt;p&gt;JRuby historically has not shipped with a fully functional openssl module due to cryptographic export restrictions. However, in order to support Rails 2.0 out of the box, we implemented a limited subset of openssl that implements &lt;tt&gt;OpenSSL::HMAC&lt;/tt&gt; and &lt;tt&gt;OpenSSL::Digest&lt;/tt&gt;.

&lt;/p&gt;&lt;p&gt;However, this breaks programs that use &lt;tt&gt;require 'openssl'&lt;/tt&gt; as a test for whether openssl is available or not. &lt;a class='external' href=&quot;http://dev.ctor.org/soap4r&quot;&gt;Soap4r&lt;/a&gt; is one such program. In order to support this behavior, simply add

&lt;/p&gt;&lt;pre&gt;    require 'jruby/openssl/gem_only'
&lt;/pre&gt;&lt;p&gt;
at the start of your program, and requiring openssl will revert to raising a load error.

&lt;/p&gt;&lt;p&gt;See also &lt;a class='external' href=&quot;http://jira.codehaus.org/browse/JRUBY-1808&quot;&gt;JRUBY-1808&lt;/a&gt; for a discussion on this feature. 
&lt;/p&gt;</text-as-html>
  <updated-at type="datetime">2009-03-24T22:44:14Z</updated-at>
  <wiki-id type="integer">320</wiki-id>
</page>
