omniauth-rlauth 0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +4 -0
- data/Gemfile +3 -0
- data/Gemfile.lock +38 -0
- data/README +1 -0
- data/lib/omniauth-rlauth.rb +2 -0
- data/lib/omniauth/rlauth.rb +2 -0
- data/lib/omniauth/rlauth/version.rb +5 -0
- data/lib/omniauth/strategies/rlauth.rb +30 -0
- data/omniauth-rlauth.gemspec +18 -0
- metadata +67 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 5433be5546fcce774d4b018cd453f49d3c78017b
|
4
|
+
data.tar.gz: 296830f0a9176031b7ace55db72f45abf83cabec
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 9dfb37d162687f6a29c4be2d925c3f76b41e9efca85cf8455c67d16b8b698deee5fd6faa41e819631723a820e72b99f8b64146733bf63a39e1fb1cf403923cbf
|
7
|
+
data.tar.gz: 0ae10d75ba91a1e8ae101c9a478d69e80de5dfe8c961b37364359d40583135c34a964c07e4c994e798a8771d153979d5c3d5968b0b4197d6bf0438a3b625a1d9
|
data/.gitignore
ADDED
data/Gemfile
ADDED
data/Gemfile.lock
ADDED
@@ -0,0 +1,38 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
omniauth-rlauth (0.1)
|
5
|
+
omniauth-oauth2 (~> 1.3.0)
|
6
|
+
|
7
|
+
GEM
|
8
|
+
remote: https://rubygems.org/
|
9
|
+
specs:
|
10
|
+
faraday (0.9.1)
|
11
|
+
multipart-post (>= 1.2, < 3)
|
12
|
+
hashie (3.4.2)
|
13
|
+
jwt (1.5.0)
|
14
|
+
multi_json (1.11.1)
|
15
|
+
multi_xml (0.5.5)
|
16
|
+
multipart-post (2.0.0)
|
17
|
+
oauth2 (1.0.0)
|
18
|
+
faraday (>= 0.8, < 0.10)
|
19
|
+
jwt (~> 1.0)
|
20
|
+
multi_json (~> 1.3)
|
21
|
+
multi_xml (~> 0.5)
|
22
|
+
rack (~> 1.2)
|
23
|
+
omniauth (1.2.2)
|
24
|
+
hashie (>= 1.2, < 4)
|
25
|
+
rack (~> 1.0)
|
26
|
+
omniauth-oauth2 (1.3.0)
|
27
|
+
oauth2 (~> 1.0)
|
28
|
+
omniauth (~> 1.2)
|
29
|
+
rack (1.6.1)
|
30
|
+
|
31
|
+
PLATFORMS
|
32
|
+
ruby
|
33
|
+
|
34
|
+
DEPENDENCIES
|
35
|
+
omniauth-rlauth!
|
36
|
+
|
37
|
+
BUNDLED WITH
|
38
|
+
1.10.3
|
data/README
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
omniauth-rlauth - An OmniAuth OAuth2 strategy for RLAuth
|
@@ -0,0 +1,30 @@
|
|
1
|
+
require 'omniauth-oauth2'
|
2
|
+
|
3
|
+
module OmniAuth
|
4
|
+
module Strategies
|
5
|
+
class RLAuth < OmniAuth::Strategies::OAuth2
|
6
|
+
option :name, "rlauth"
|
7
|
+
|
8
|
+
option :client_options, {:site => "https://rlauth.deira.phitherek.me"}
|
9
|
+
|
10
|
+
uid { raw_info['user']['id'] }
|
11
|
+
|
12
|
+
info do
|
13
|
+
{
|
14
|
+
:callsign => raw_info['user']['callsign'],
|
15
|
+
:email => raw_info['user']['email']
|
16
|
+
}
|
17
|
+
end
|
18
|
+
|
19
|
+
extra do
|
20
|
+
{
|
21
|
+
'raw_info' => raw_info
|
22
|
+
}
|
23
|
+
end
|
24
|
+
|
25
|
+
def raw_info
|
26
|
+
@raw_info ||= access_token.get('/api/user_data').parsed
|
27
|
+
end
|
28
|
+
end
|
29
|
+
end
|
30
|
+
end
|
@@ -0,0 +1,18 @@
|
|
1
|
+
$LOAD_PATH.push File.expand_path('../lib', __FILE__)
|
2
|
+
require 'omniauth/rlauth/version'
|
3
|
+
|
4
|
+
Gem::Specification.new do |s|
|
5
|
+
s.name = 'omniauth-rlauth'
|
6
|
+
s.version = OmniAuth::RLAuth::VERSION
|
7
|
+
s.author = 'Phitherek_'
|
8
|
+
s.email = %w(phitherek@gmail.com)
|
9
|
+
s.summary = 'An OmniAuth OAuth2 strategy for RLAuth'
|
10
|
+
s.description = s.summary
|
11
|
+
s.homepage = 'https://github.com/Phitherek/omniauth-rlauth'
|
12
|
+
s.licenses = ['MIT']
|
13
|
+
|
14
|
+
s.files = `git ls-files`.split("\n")
|
15
|
+
s.require_paths = ['lib']
|
16
|
+
|
17
|
+
s.add_runtime_dependency 'omniauth-oauth2', '~> 1.3'
|
18
|
+
end
|
metadata
ADDED
@@ -0,0 +1,67 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: omniauth-rlauth
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: '0.1'
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Phitherek_
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2015-06-12 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: omniauth-oauth2
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '1.3'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '1.3'
|
27
|
+
description: An OmniAuth OAuth2 strategy for RLAuth
|
28
|
+
email:
|
29
|
+
- phitherek@gmail.com
|
30
|
+
executables: []
|
31
|
+
extensions: []
|
32
|
+
extra_rdoc_files: []
|
33
|
+
files:
|
34
|
+
- ".gitignore"
|
35
|
+
- Gemfile
|
36
|
+
- Gemfile.lock
|
37
|
+
- README
|
38
|
+
- lib/omniauth-rlauth.rb
|
39
|
+
- lib/omniauth/rlauth.rb
|
40
|
+
- lib/omniauth/rlauth/version.rb
|
41
|
+
- lib/omniauth/strategies/rlauth.rb
|
42
|
+
- omniauth-rlauth.gemspec
|
43
|
+
homepage: https://github.com/Phitherek/omniauth-rlauth
|
44
|
+
licenses:
|
45
|
+
- MIT
|
46
|
+
metadata: {}
|
47
|
+
post_install_message:
|
48
|
+
rdoc_options: []
|
49
|
+
require_paths:
|
50
|
+
- lib
|
51
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
52
|
+
requirements:
|
53
|
+
- - ">="
|
54
|
+
- !ruby/object:Gem::Version
|
55
|
+
version: '0'
|
56
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
57
|
+
requirements:
|
58
|
+
- - ">="
|
59
|
+
- !ruby/object:Gem::Version
|
60
|
+
version: '0'
|
61
|
+
requirements: []
|
62
|
+
rubyforge_project:
|
63
|
+
rubygems_version: 2.4.6
|
64
|
+
signing_key:
|
65
|
+
specification_version: 4
|
66
|
+
summary: An OmniAuth OAuth2 strategy for RLAuth
|
67
|
+
test_files: []
|