protocol-websocket 0.6.0 → 0.6.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/lib/protocol/websocket/connection.rb +5 -0
- data/lib/protocol/websocket/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 33eeff4af7898ed6affc7f2d21346353fb8b28b84ac0ce352e39a1e9d29dfe3d
|
4
|
+
data.tar.gz: 5a476f70592773a0fc2a5888f74c677a44f702689fe29444ba6076d9a6b514b0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 326edc906773bfd1afe0463a03ac24e95f1557795fbbc35a83ba1d01046db804421b37bc597bb29c624df677760b29633e4df200d4f9d95287256520a1077e54
|
7
|
+
data.tar.gz: b397680b7384cd8bfd2f361eee8641cb551f7d1d8aed3612f777e40d2df5f5267d5408a527ebbe357e9a9da6f2f1368ae10b70afc23af667269a40551d518f44
|
data/README.md
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
Provides a low-level implementation of the WebSocket protocol according to [RFC6455](https://tools.ietf.org/html/rfc6455). It only implements the latest stable version (13).
|
4
4
|
|
5
|
-
[![Build Status](https://
|
5
|
+
[![Build Status](https://travis-ci.com/socketry/protocol-websocket.svg?branch=master)](http://travis-ci.com/socketry/protocol-websocket)
|
6
6
|
|
7
7
|
## Installation
|
8
8
|
|
@@ -19,12 +19,17 @@
|
|
19
19
|
# THE SOFTWARE.
|
20
20
|
|
21
21
|
require_relative 'framer'
|
22
|
+
require 'securerandom'
|
22
23
|
|
23
24
|
module Protocol
|
24
25
|
module WebSocket
|
25
26
|
class Connection
|
26
27
|
# @option mask [String] 4-byte mask to be used for frames generated by this connection.
|
27
28
|
def initialize(framer, mask: nil)
|
29
|
+
if mask == true
|
30
|
+
mask = SecureRandom.bytes(4)
|
31
|
+
end
|
32
|
+
|
28
33
|
@framer = framer
|
29
34
|
@mask = mask
|
30
35
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: protocol-websocket
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Samuel Williams
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-06-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: protocol-http
|
@@ -140,7 +140,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
140
140
|
- !ruby/object:Gem::Version
|
141
141
|
version: '0'
|
142
142
|
requirements: []
|
143
|
-
rubygems_version: 3.0.
|
143
|
+
rubygems_version: 3.0.3
|
144
144
|
signing_key:
|
145
145
|
specification_version: 4
|
146
146
|
summary: A low level implementation of the WebSocket protocol.
|