soar_authentication 0.1.1 → 0.1.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: 2626831f860d04c09514a483a837c590e98b1469
4
- data.tar.gz: d495c02a807401ed4161c272d7705b7bbe6f3eb6
3
+ metadata.gz: 52544642c89e9393f15dc1e6d1886aacc9e69c25
4
+ data.tar.gz: 90d817330257fdd75467b7b71e268cad45a4e9b4
5
5
  SHA512:
6
- metadata.gz: 1b8ec5853def0a2e4f65adcd94e9f73c6f8842a281538657bc055ae49343610c2b9922159a989ea834bc284e4d595b402d95989c094a841270826974ddab288f
7
- data.tar.gz: 70a64ba7c2aaf20844409935510bb86248f901788a7151bf9e158265bac34d4133974a69e2670d2e192094f7f90a7a8536afe77c1eeed92e35b33015f9873283
6
+ metadata.gz: 9f24d4516bd60285e88a7585ae33e97cf715e2fcd80f4b16519261b920ee40660164efabff65539139d50f2a8cfa3d67ef3a3ec0866a88b4b035258fb6df8d53
7
+ data.tar.gz: b7f68c60eb44c5cfc67dc8dbb2f9981cce5f2be2be385a7830f76a8f655502f407fbab0164f32fcb19a5124043ca6d51af8ba53d75663797016da8849d47dc66
@@ -12,13 +12,16 @@ module SoarAuthentication
12
12
 
13
13
  def identifier
14
14
  return "developer" if dev_session?
15
- @request.session['user']
15
+ identifier = @request.session['user']
16
+ identifier ||= @request.env['REMOTE_USER']
17
+ identifier
16
18
  end
17
19
 
18
20
  private
19
21
 
20
22
  def session_has_user?
21
- (not @request.session['user'].nil?) and (@request.session['user'] != '')
23
+ ((not @request.session['user'].nil?) and (@request.session['user'] != '') or
24
+ (not @request.env['REMOTE_USER'].nil?) and (@request.env['REMOTE_USER'] != ''))
22
25
  end
23
26
 
24
27
  def dev_session?
@@ -1,3 +1,3 @@
1
1
  module SoarAuthentication
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: soar_authentication
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ernst Van Graan
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-07-17 00:00:00.000000000 Z
11
+ date: 2016-07-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rack