websocket-client-simple 0.5.1 → 0.6.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: dacb78ebf74e2700e9a33fee5738d6887f89bc1ff75fd0462f13f7fecb6a4c29
4
- data.tar.gz: 517d19aedb9257e328ab373321bf994bec148e90993078bd1d9222d16012ddd2
3
+ metadata.gz: 2de6863ed3ec4f702c28cb4143bb949facf6fd18efda61eb236410131cb4dfa7
4
+ data.tar.gz: a5ebee3d4e74eb177ad70ea111497b2c4aa515ed6ddff523ff0840f7bd0355ac
5
5
  SHA512:
6
- metadata.gz: 60c390df8b3a65861e8fb7af48e068a8e2d1f28ae8efa5beb780f8b73d4cff844e9ae22f925f6b5c860946742cfcf91dd138c61ee3f3dd60218bec30c4a57825
7
- data.tar.gz: 3e8fccee5f323c77734272dc60bf801d8d58de0c4b53b6d6c4f7f2f6f209dde3940066323eb52bd8de76fdc217a17cb4b0c0e61d0e47f90d93a50139b9025391
6
+ metadata.gz: 25239fc6f496ff3838112f1b6360a52d6be6d651fc3354ae7e61cdae3712cfe491d870c5af6874583e42fead682420f9757dee1483391f9df31b5c25b4a921c2
7
+ data.tar.gz: 3fc6b6f1abbb20157f58a80d9fb47bb65ace236620ca786bb7eaae3fd51b134be15bd4e2b34ecbc5a7f2fa94cfd9c392b583f29bc335c359eb749bcccf607d72
data/History.txt CHANGED
@@ -1,5 +1,10 @@
1
1
  === Not yet released
2
2
 
3
+ == 0.6.0 2022-09-22
4
+
5
+ * Add option `cert_store` for passing cert store to SSLSocket context #12 by @DerekStride
6
+ * Set `OpenSSL::SSL::SSLSocket#sync_close` to `true` #12 by @DerekStride
7
+
3
8
  === 0.5.1 2022-01-01
4
9
 
5
10
  * Add `closed?` method to `WebSocket::Client::Simple` #8 by @fuyuton
data/README.md CHANGED
@@ -16,7 +16,6 @@ Installation
16
16
  Usage
17
17
  -----
18
18
  ```ruby
19
- require 'rubygems'
20
19
  require 'websocket-client-simple'
21
20
 
22
21
  ws = WebSocket::Client::Simple.connect 'ws://example.com:8888'
@@ -60,7 +59,7 @@ end
60
59
 
61
60
  Sample
62
61
  ------
63
- [websocket chat](https://github.com/shokai/websocket-client-simple/tree/master/sample)
62
+ [websocket chat](https://github.com/ruby-jp/websocket-client-simple/tree/master/sample)
64
63
 
65
64
 
66
65
  Test
@@ -23,10 +23,11 @@ module WebSocket
23
23
  ctx = OpenSSL::SSL::SSLContext.new
24
24
  ctx.ssl_version = options[:ssl_version] if options[:ssl_version]
25
25
  ctx.verify_mode = options[:verify_mode] if options[:verify_mode]
26
- cert_store = OpenSSL::X509::Store.new
26
+ cert_store = options[:cert_store] || OpenSSL::X509::Store.new
27
27
  cert_store.set_default_paths
28
28
  ctx.cert_store = cert_store
29
29
  @socket = ::OpenSSL::SSL::SSLSocket.new(@socket, ctx)
30
+ @socket.sync_close = true
30
31
  @socket.hostname = uri.host
31
32
  @socket.connect
32
33
  end
@@ -1,7 +1,7 @@
1
1
  module WebSocket
2
2
  module Client
3
3
  module Simple
4
- VERSION = "0.5.1"
4
+ VERSION = "0.6.0"
5
5
  end
6
6
  end
7
7
  end
data/sample/client.rb CHANGED
@@ -1,6 +1,5 @@
1
1
  #!/usr/bin/env ruby
2
2
  $:.unshift File.expand_path '../lib', File.dirname(__FILE__)
3
- require 'rubygems'
4
3
  require 'websocket-client-simple'
5
4
 
6
5
  puts "websocket-client-simple v#{WebSocket::Client::Simple::VERSION}"
@@ -16,7 +16,7 @@
16
16
  <ul id="chat"></ul>
17
17
  <div id="footer">
18
18
  <hr>
19
- <a href="https://github.com/shokai/websocket-client-simple">https://github.com/shokai/websocket-client-simple</a>
19
+ <a href="https://github.com/ruby-jp/websocket-client-simple">https://github.com/ruby-jp/websocket-client-simple</a>
20
20
  </div>
21
21
  </body>
22
22
  </html>
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: websocket-client-simple
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1
4
+ version: 0.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sho Hashimoto
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2022-01-01 00:00:00.000000000 Z
12
+ date: 2022-09-22 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler