2008/6/4 darren <[EMAIL PROTECTED]>:

>
>
> 2008/6/4 Lucas Nussbaum <[EMAIL PROTECTED]>:
>
> On 01/06/08 at 23:40 +0800, darren wrote:
>> > Package: libopenssl-ruby1.8
>> > Version: 1.8.6.114-2
>> > Severity: normal
>> >
>> > I tried to connect to gtalk using xmpp4r,but failed,I tried to track
>> > down the problem,later found that it may be caused by this ruby libray.
>> > a simple test code to verify:
>> >
>> > ----------------
>> > require 'openssl'
>> > require 'socket'
>> >
>> >
>> > socket = TCPSocket.new("talk.google.com", 5223)
>> >
>> > ctx = OpenSSL::SSL::SSLContext.new('TLSv1')
>> >
>> > sslsocket = OpenSSL::SSL::SSLSocket.new(socket, ctx)
>> >
>> > begin
>> >   puts "Start connect"
>> >     sslsocket.connect
>> > rescue OpenSSL::SSL::SSLError => ssle
>> >     puts "------------------#{ssle.message}---------------"
>> > end
>> >
>> > puts "finished"
>> > -----------------
>> >
>> > It failed,but gave no reason,because ssle.message was empty.
>> > same code runs fine on a lenny machine.
>>
>> Hi darren,
>>
>> Can you still reproduce this? It works fine here. Maybe it was fixed on
>> Google's side?
>
> Thanks for you response
> Problem exists on my Debian Sid,But I tried it on a windows box with ruby
> 1.8.6,everything just goes fine,and xmpp4r works just fine too.
> So I suspect it to be a Linux or rather Debian related bug.I have also
> downloads ruby source code and compile myself,still the problem exists.
>

sorry,I have forgotten to mention that I have upgrade ruby version to 1.8.7
in unstable, running the above code gives the message now,it is :
   SSL_connect SYSCALL returned=5 errno=0 state=SSLv3 read server hello A
I have googled around the error message for a long time ,just don't know how
to figure out what does the error code above means.

>
>
>> Lucas
>>
>
>

Reply via email to