omniauth-colorgy-oauth2 0.1.3 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 29913eb13a4cc3a9a9e423aa333be28283db88cd
|
4
|
+
data.tar.gz: 004dbc2e48bafc87659c3540748623e196a82b40
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 828eb9354237f9e51159877918e81e38bc9ef29fbc716ec1cee7ca7413ae3531f18518de17d872d6b51e2a1103efea67178f9380d0ff69c6287353f6e9855d97
|
7
|
+
data.tar.gz: 4118249af1893a8466763cc36630e4c52303ad019c54dc7e037b936aa1efb9e7d269901380d96d51db36258d2a6020ac6949c5d2308636fd8a39deb245c8ea48
|
@@ -58,13 +58,20 @@ module ColorgyDeviseSSOManager
|
|
58
58
|
ENV['CORE_RSA_PUBLIC_KEY'].gsub(/\\n/, "\n")
|
59
59
|
else
|
60
60
|
url = URI.parse("#{core_url}/_rsa.pub")
|
61
|
-
Net::HTTP.get(url)
|
61
|
+
respond = Net::HTTP.get(url)
|
62
|
+
if respond.code == '301'
|
63
|
+
respond = Net::HTTP.get_response(URI.parse(respond.header['location']))
|
64
|
+
else
|
65
|
+
respond
|
66
|
+
end
|
62
67
|
end
|
63
68
|
end
|
64
69
|
|
65
70
|
# Getter of the core rsa public key
|
66
71
|
def core_rsa_public_key
|
67
72
|
@@core_rsa_public_key ||= OpenSSL::PKey::RSA.new(core_rsa_public_key_string)
|
73
|
+
rescue
|
74
|
+
@@core_rsa_public_key ||= OpenSSL::PKey::RSA.new(core_rsa_public_key_string)
|
68
75
|
end
|
69
76
|
|
70
77
|
# Decode the sign-on status token (sst) string and return a hash
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: omniauth-colorgy-oauth2
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Neson
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-06-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: omniauth
|
@@ -143,3 +143,4 @@ signing_key:
|
|
143
143
|
specification_version: 4
|
144
144
|
summary: A Colorgy OAuth2 strategy and SSO client helper for OmniAuth.
|
145
145
|
test_files: []
|
146
|
+
has_rdoc:
|