sbsm 1.4.1 → 1.4.2

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
  SHA1:
3
- metadata.gz: d647251dba775553fefe6121a9426dbb451d3cca
4
- data.tar.gz: 1f856b9d6adf4c1a7744057fe0c2dc7dfc3e711c
3
+ metadata.gz: 8b8934dcd4cdbd63fead780bf5bf87af408d43d3
4
+ data.tar.gz: 9bddb67fbce3b770fa182691a3af7a57b74afbdf
5
5
  SHA512:
6
- metadata.gz: 3143714442df1fb02afe914f21e9f6046d152e65595e6c65db919c7e4b5bcce1b7d1e0ca094d3c5db0bcbf268fcc38521cc8341eb010ba54d30a01cfa306a7c9
7
- data.tar.gz: 319e8f27fea2a105a9db1474c09bd9d3a7da3280bc5c164837ae3f8bebd453086208ac9e2a03c7dc6e78cce87096b04de779b872d28b0ad89626880e3b4a1414
6
+ metadata.gz: 70d380793a5eead1e398f0ea38a9294fc34e7a661c03004bdcb5a4dd679dedefdd32e342f5c6a2ad0f4fe6e93e7591f022d2d413b72f1db0af78b868794c0e1d
7
+ data.tar.gz: 39ee8b6ccb16477c0726a20ae817abff227540e47ac1b87366702c8d4bf5aff5bc7e2cb787ed76c82d3174fcdb1629803361bd9f3356d6082e4eb650724f070e
data/History.txt CHANGED
@@ -1,3 +1,8 @@
1
+ === 1.4.2 / 23.05.2017
2
+
3
+ * Allow overriding http_protocol via ENV variable SERVER_PORT
4
+ * Return correct http_protocol https when serving on port 443
5
+
1
6
  === 1.4.1 / 22.05.2017
2
7
 
3
8
  * Moved _async from from SessionStore back to Session class
data/lib/sbsm/session.rb CHANGED
@@ -210,6 +210,7 @@ module SBSM
210
210
  @request_method =rack_request.request_method
211
211
  @request_path = rack_request.path
212
212
  @server_name = rack_request.env['SERVER_NAME']
213
+ @server_port = rack_request.env['SERVER_PORT']
213
214
  logout unless @active_state
214
215
  validator.reset_errors() if validator && validator.respond_to?(:reset_errors)
215
216
  import_user_input(rack_request)
@@ -406,8 +407,7 @@ module SBSM
406
407
  {'Content-Type' => 'text/plain'}
407
408
  end
408
409
  def http_protocol
409
- @http_protocol ||= if(@request.respond_to?(:server_port) \
410
- && @request.server_port == 443)
410
+ @http_protocol ||= if(@server_port && @server_port == 443) || ENV['SERVER_PORT']
411
411
  'https'
412
412
  else
413
413
  'http'
data/lib/sbsm/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module SBSM
2
- VERSION = '1.4.1'
2
+ VERSION = '1.4.2'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sbsm
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.1
4
+ version: 1.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Masaomi Hatakeyama, Zeno R.R. Davatz
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-05-22 00:00:00.000000000 Z
11
+ date: 2017-05-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rack