Sha256: 393834454c96560183b5c16fd1913485848a609d386acc85d846dbcb5db8363d

Contents?: true

Size: 378 Bytes

Versions: 7

Compression:

Stored size: 378 Bytes

Contents

require 'test/unit'

require "openid/dh"
require "openid/util"

# Diffie Hellman test case

class DiffieHellmanTestCase < Test::Unit::TestCase

  def test_dh    
    dh1 = OpenID::DiffieHellman.new
    dh2 = OpenID::DiffieHellman.new
    
    secret1 = dh1.get_shared_secret(dh2.public)
    secret2 = dh2.get_shared_secret(dh1.public)
    assert(secret1 == secret2)
  end

end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
ruby-openid-1.0.1 test/dh.rb
ruby-openid-1.1.4 test/dh.rb
ruby-openid-1.0 test/dh.rb
ruby-openid-1.1.2 test/dh.rb
ruby-openid-1.1.3 test/dh.rb
ruby-openid-1.1.1 test/dh.rb
ruby-openid-1.0.2 test/dh.rb