utep_sso 0.0.1 → 0.0.2

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: 02a0e482c6cfceb8553f0187ffe93a69363210eb
4
- data.tar.gz: b0c1209fb357a25d0a869b46b0372c408b4bdb60
3
+ metadata.gz: d794d674afd4ef31f64eb15a558a28499c178e11
4
+ data.tar.gz: 6e4714a156ced0844268429c3985a5131bba093a
5
5
  SHA512:
6
- metadata.gz: 153607159c46af42f4c0ce217797444f3f9e7f82c4f8ac7bded17348521a59e3251e5c6927caf3cb1e66c4072a9342add88a5143477665f23715451c4762cfcc
7
- data.tar.gz: 8a6259ccc516b9ddccc333ebf09d2727007385fc903c3a643041fbe6ba0c55e1154f4ed784c4ed24463bf884c4e00466b94224b427a1f5cbd4456efeb82a1f89
6
+ metadata.gz: 0719a894c877bedca9c7fb7af01a8d041e0c223a838c50c8c55c5216e79e4ebf73da57ed1764aafa73885cfa0275afc55b283bee789c20019684198bf6eae7aa
7
+ data.tar.gz: 0722926593918c6cb6668a85be774618f9f76ee7bea21f35cbc22f45065e99aff474a66bfe480b9c6b1d1f919a6c5c1f158bc131b0437540c83baf6ed7d20414
data/.gitignore CHANGED
@@ -11,4 +11,5 @@
11
11
  *.so
12
12
  *.o
13
13
  *.a
14
+ .DS_Store
14
15
  mkmf.log
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # UTEP SingleSignOn for Ruby
2
2
 
3
- TODO: Write a gem description
3
+ Authenticate users using UTEP's SingleSignOn
4
4
 
5
5
  ## Installation
6
6
 
@@ -12,7 +12,7 @@ gem 'utep_sso'
12
12
 
13
13
  And then execute:
14
14
 
15
- $ bundle
15
+ $ bundle install
16
16
 
17
17
  Or install it yourself as:
18
18
 
@@ -20,11 +20,33 @@ Or install it yourself as:
20
20
 
21
21
  ## Usage
22
22
 
23
- TODO: Write usage instructions here
23
+ ```ruby
24
+
25
+ require 'utep_sso'
26
+
27
+
28
+ # Check if a user is signed in
29
+ UTEPSSO.authenticated?(cookies[:UTEP_SE], cookies[:UTEP_SA])
30
+
31
+ # Authenticate a user using UTEP cookies (will return nil values in the hash for invalid cookies)
32
+ UTEPSSO.authenticate(cookies[:UTEP_SE], cookies[:UTEP_SA])
33
+ # => {:user_name, :full_name, :email_address, :authenticated, :role_value, :external_user, :@xmlns}
34
+
35
+ # roles are returned as a binary
36
+ # 000010 = faculty
37
+ # 000100 = staff
38
+ # 010000 = student
39
+
40
+ # 010110 = user that is a student, faculty and staff
41
+
42
+ # Deauthenticate a user
43
+ UTEPSSO.deauthenticate(cookies[:UTEP_SE], cookies[:UTEP_SA])
44
+
45
+ ```
24
46
 
25
47
  ## Contributing
26
48
 
27
- 1. Fork it ( https://github.com/[my-github-username]/utep_sso/fork )
49
+ 1. Fork it ( https://github.com/awernick/utep_sso/fork )
28
50
  2. Create your feature branch (`git checkout -b my-new-feature`)
29
51
  3. Commit your changes (`git commit -am 'Add some feature'`)
30
52
  4. Push to the branch (`git push origin my-new-feature`)
@@ -1,3 +1,3 @@
1
1
  module UTEPSSO
2
- VERSION = "0.0.1"
2
+ VERSION = "0.0.2"
3
3
  end
@@ -10,7 +10,7 @@ Gem::Specification.new do |spec|
10
10
  spec.email = ["alan.wernik@gmail.com"]
11
11
  spec.summary = %q{UTEP SingleSignOn Authentication for Ruby}
12
12
  spec.description = %q{Fetch user information using UTEP's Single Sign On service}
13
- spec.homepage = ""
13
+ spec.homepage = "https://github.com/awernick/utep_sso"
14
14
  spec.license = "MIT"
15
15
 
16
16
  spec.files = `git ls-files -z`.split("\x0")
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: utep_sso
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alan Wernick
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-12-15 00:00:00.000000000 Z
11
+ date: 2014-12-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -68,7 +68,7 @@ files:
68
68
  - lib/utep_sso.rb
69
69
  - lib/utep_sso/version.rb
70
70
  - utep_sso.gemspec
71
- homepage: ''
71
+ homepage: https://github.com/awernick/utep_sso
72
72
  licenses:
73
73
  - MIT
74
74
  metadata: {}