http-access2 error

N

nkb

Hi.
When I run ssl_client from http-access2's sample program, I received the
following error:

../../lib/http-access2.rb:479:in 'set_trust_ca': undefined method
'add_path' for nil:NilClass (NoMethodError) from
C:/ruby/http-access-2_0_4/samples/ssl/ssl_client.rb:19

I'm still trying out and getting used to things in Ruby, appreciate any
pointer please. Thank you.
 
N

NAKAMURA, Hiroshi

Hi, nkb,

When I run ssl_client from http-access2's sample program, I received the
following error:

../../lib/http-access2.rb:479:in 'set_trust_ca': undefined method
'add_path' for nil:NilClass (NoMethodError) from
C:/ruby/http-access-2_0_4/samples/ssl/ssl_client.rb:19

Hmm. What version of ruby are you using? It seems work on my machine
with ruby 1.8.2 (2004-09-10) [i386-cygwin]. Up to now I cannot
imagine why the above error message could be thrown...

Please type the following and let me see the output.
$ ruby -v

Regards,
// NaHi
 
N

nkb

I'm on linux with ruby 1.8.2 (2004-07-29) [i686-linux]
I think it is the latest available preview from the website. OR is there
a even more latest version I could get?

NAKAMURA, Hiroshi wrote on 2004/09/18 18:47:
Hi, nkb,

When I run ssl_client from http-access2's sample program, I received the
following error:

../../lib/http-access2.rb:479:in 'set_trust_ca': undefined method
'add_path' for nil:NilClass (NoMethodError) from
C:/ruby/http-access-2_0_4/samples/ssl/ssl_client.rb:19


Hmm. What version of ruby are you using? It seems work on my machine
with ruby 1.8.2 (2004-09-10) [i386-cygwin]. Up to now I cannot
imagine why the above error message could be thrown...

Please type the following and let me see the output.
$ ruby -v

Regards,
// NaHi
 
N

NAKAMURA, Hiroshi

Hi, nkb,

I'm on linux with ruby 1.8.2 (2004-07-29) [i686-linux]
I think it is the latest available preview from the website. OR is there
a even more latest version I could get?

Hmm. Http-access/2.0.4 should work with your ruby.

I suddenly remember one possibility. Do you have openssl installed?
Would you please try this?

$ ruby -ropenssl -e 0

And, please run ssl_client.rb with -d option.

$ ruby -d ssl_client.rb

Regards,
// NaHi
 
N

nkb

$ ruby -ropenssl -e 0

I received
ruby: No such file to load -- openssl (LoadError)
And, please run ssl_client.rb with -d option.

$ ruby -d ssl_client.rb

For this I received

Exception 'LoadError' at ../../lib/http-access2.rb:37 - No such file to
load -- openssl
../../lib/http-access2/rb:479: warning: instance variable @cert_store
not initialized
Exception 'NoMethodError' at ../../lib/http-access2.rb:479 - undefined
method 'add_path' for nil:NilClass
../../lib/http-access2.rb:479:in 'set_trust_ca': undefined method
'add_path' for nil:NilClass (NoMethodError)
from ssl_client.rb:19
Regards,
// NaHi

I went on to get openssl from ruby website. But the link doesnt seem to
be working either. Is there something wrong?
http://freesoftware.fsf.org/download/rubypki/
 
N

NAKAMURA, Hiroshi

Hi,

I received
ruby: No such file to load -- openssl (LoadError)

It's the root problem. As you assume, Ruby/OpenSSL library (called
ossl2, Ruby/OpenSSL, OpenSSL/Ruby, rubypki, or just openssl, etc, etc)
was not installed. But the reason why Ruby/OpneSSL library is not
installed is that you don't have The OpenSSL Toolkit
(http://www.openssl.org/) installed on your system.

You should install The OpenSSL Toolkit first. You may be able to
install The OpenSSL Toolkit with some package management system such
as apt, rpm or something.

Then re-install ruby again. The installer of ruby will detect The
OpenSSL Toolkit exists and will install Ruby/OpenSSL library.

Regards,
// NaHi
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,535
Members
45,007
Latest member
obedient dusk

Latest Threads

Top