Forum: Ruby on Rails uninitialized constant OpenSSL::Digest::SHA1

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
F0699bc4e920a0cea55b958d204b0a4b?d=identicon&s=25 Slain Wilde (slain)
on 2006-04-12 18:34
I just updated my ruby from 1.8.2 to the Windows Installer 184-16 RC1,
and now when I try to start Webrick I get the following:

c:/program
files/dev/ruby/lib/ruby/site_ruby/1.8/rubygems/security.rb:18:
uninitialized constant OpenSSL::Digest::SHA1 (NameError)
	from c:/program files/dev/ruby/lib/ruby/site_ruby/1.8/rubygems.rb:397
	from c:/program files/dev/ruby/lib/ruby/site_ruby/1.8/ubygems.rb:4


From security.rb:
    if Gem.ssl_available?
      PKEY_RSA = OpenSSL::PKey::RSA
(18)      DIGEST_SHA1 = OpenSSL::Digest::SHA1



Any ideas?
F0699bc4e920a0cea55b958d204b0a4b?d=identicon&s=25 Slain Wilde (slain)
on 2006-04-12 19:42
So I started from a fresh directory and that bug went away, but now
Webbrick says Booting then just exits without any message...
3718fdad9a141493fa921c71fae6d89f?d=identicon&s=25 Stuart Johnson (srjweb)
on 2006-04-20 11:19
slain wilde wrote:
> So I started from a fresh directory and that bug went away, but now
> Webbrick says Booting then just exits without any message...

Hi Slain,

don't know if this will fix your problem, but I got a similar error
after updating to 184-16 RC1 in order to install Mongrel.

What worked for me (from a bug report on Rubyforge at
http://rubyforge.org/tracker/index.php?func=detail...)
was

"
adding :
--begin code--
  require 'openssl/digest'
--end code--
to gem_openssl.rb after line 28 (require 'openssl')
"

hope this helps

Stuart
F0699bc4e920a0cea55b958d204b0a4b?d=identicon&s=25 Slain Wilde (slain)
on 2006-04-20 17:06
Yea, I got it to work (SHA1) by installing ruby to a fresh(empty)
directory.  My webrick not starting problem was because I needed to
upgrade engines for 1.1 or it silently killed webrick.

Thanks tho.
This topic is locked and can not be replied to.