challah 1.2.2 → 1.2.3
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 +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/challah/techniques.rb +14 -1
- data/lib/challah/version.rb +1 -1
- metadata +19 -19
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3fc288912d32ece6053aef90ffcb92c9f6a04a57
|
4
|
+
data.tar.gz: 53b0167831cf7f74216322f8f9023ba7a2639a46
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c0bcc82983190ba7a070f660fe9fd86c52d06260a0913e53b85db0b1d81f9618f56c1e9b0ac1c045da42e6c77c6f5a30250e6c9fc90b4ca147da21a37a6a9d8e
|
7
|
+
data.tar.gz: 4cf8c0944320bb1a03afed22145ca8ff2fa2c7eeb39ac9fed259f0bbc4881c461a4949caa45b6de0e9d38cf88844bf7e85fa64568ffaec0825a73cabd1f3db32
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,7 @@
|
|
1
|
+
## Chalah 1.2.3
|
2
|
+
|
3
|
+
* Allow default techniques to be removed in the host app. [PR #9](https://github.com/jdtornow/challah/pull/9) @philtr
|
4
|
+
|
1
5
|
## Challah 1.2.2
|
2
6
|
|
3
7
|
* Bug fix for “A copy of User has been removed from the module tree but is still active!” error in Rails development mode. Fix was to not cache the `User` model reference from within the engine.
|
data/lib/challah/techniques.rb
CHANGED
@@ -44,6 +44,14 @@ module Challah
|
|
44
44
|
# Challah.register_technique(:shared_password, SharedPasswordTechnique)
|
45
45
|
#
|
46
46
|
# The first parameter is just a key for that technique, the second p param is the class name to use.
|
47
|
+
#
|
48
|
+
# You can remove an existing technique by calling +remove_technique+:
|
49
|
+
#
|
50
|
+
# Challah.remove_technique(:shared_password)
|
51
|
+
#
|
52
|
+
# This is useful for removing the techniques included by default +PasswordTechnique+ and
|
53
|
+
# +ApiKeyTechnique+.
|
54
|
+
#
|
47
55
|
module Techniques
|
48
56
|
# Register a new technique class. Pass in a name as an identifier, and the class to use
|
49
57
|
# when attempting to authenticate.
|
@@ -51,9 +59,14 @@ module Challah
|
|
51
59
|
@techniques[name] = klass
|
52
60
|
end
|
53
61
|
|
62
|
+
# Remove an existing technique class. Pass in the identifier used in +register_techinque+
|
63
|
+
def remove_technique(name)
|
64
|
+
@techniques.delete(name)
|
65
|
+
end
|
66
|
+
|
54
67
|
# Get the list of all techniques that have been registered.
|
55
68
|
def techniques
|
56
69
|
@techniques.dup
|
57
70
|
end
|
58
71
|
end
|
59
|
-
end
|
72
|
+
end
|
data/lib/challah/version.rb
CHANGED
metadata
CHANGED
@@ -1,69 +1,69 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: challah
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- John Tornow
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-09-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: highline
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- -
|
17
|
+
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '0'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- -
|
24
|
+
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: rails
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- - ~>
|
31
|
+
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: '4'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- - ~>
|
38
|
+
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '4'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: rake
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- -
|
45
|
+
- - ">="
|
46
46
|
- !ruby/object:Gem::Version
|
47
47
|
version: '0.9'
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- -
|
52
|
+
- - ">="
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '0.9'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: bcrypt-ruby
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
|
-
- - ~>
|
59
|
+
- - "~>"
|
60
60
|
- !ruby/object:Gem::Version
|
61
61
|
version: '3.0'
|
62
62
|
type: :runtime
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
|
-
- - ~>
|
66
|
+
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: '3.0'
|
69
69
|
description: A simple gem for authorization and session management in Rails.
|
@@ -73,6 +73,8 @@ executables: []
|
|
73
73
|
extensions: []
|
74
74
|
extra_rdoc_files: []
|
75
75
|
files:
|
76
|
+
- CHANGELOG.md
|
77
|
+
- README.md
|
76
78
|
- app/controllers/sessions_controller.rb
|
77
79
|
- app/models/authorization.rb
|
78
80
|
- app/models/user.rb
|
@@ -81,11 +83,12 @@ files:
|
|
81
83
|
- config/locales/en.yml
|
82
84
|
- db/migrate/20120127150433_create_users.rb
|
83
85
|
- db/migrate/20121116210759_create_authorizations.rb
|
86
|
+
- lib/challah.rb
|
84
87
|
- lib/challah/active_record_extensions.rb
|
85
88
|
- lib/challah/audit.rb
|
89
|
+
- lib/challah/authenticators.rb
|
86
90
|
- lib/challah/authenticators/api_key.rb
|
87
91
|
- lib/challah/authenticators/password.rb
|
88
|
-
- lib/challah/authenticators.rb
|
89
92
|
- lib/challah/concerns/authorizeable.rb
|
90
93
|
- lib/challah/concerns/user/attributeable.rb
|
91
94
|
- lib/challah/concerns/user/authenticateable.rb
|
@@ -100,26 +103,23 @@ files:
|
|
100
103
|
- lib/challah/encrypter.rb
|
101
104
|
- lib/challah/engine.rb
|
102
105
|
- lib/challah/plugins.rb
|
103
|
-
- lib/challah/providers/password_provider.rb
|
104
106
|
- lib/challah/providers.rb
|
107
|
+
- lib/challah/providers/password_provider.rb
|
105
108
|
- lib/challah/random.rb
|
106
109
|
- lib/challah/routes.rb
|
107
110
|
- lib/challah/session.rb
|
108
111
|
- lib/challah/signup.rb
|
109
112
|
- lib/challah/simple_cookie_store.rb
|
113
|
+
- lib/challah/techniques.rb
|
110
114
|
- lib/challah/techniques/api_key_technique.rb
|
111
115
|
- lib/challah/techniques/password_technique.rb
|
112
|
-
- lib/challah/techniques.rb
|
113
116
|
- lib/challah/test.rb
|
114
117
|
- lib/challah/validators/email_validator.rb
|
115
118
|
- lib/challah/validators/password_validator.rb
|
116
119
|
- lib/challah/version.rb
|
117
|
-
- lib/challah.rb
|
118
120
|
- lib/tasks/crud.rake
|
119
121
|
- lib/tasks/setup.rake
|
120
122
|
- lib/tasks/unpack.rake
|
121
|
-
- README.md
|
122
|
-
- CHANGELOG.md
|
123
123
|
homepage: http://github.com/jdtornow/challah
|
124
124
|
licenses:
|
125
125
|
- MIT
|
@@ -130,17 +130,17 @@ require_paths:
|
|
130
130
|
- lib
|
131
131
|
required_ruby_version: !ruby/object:Gem::Requirement
|
132
132
|
requirements:
|
133
|
-
- -
|
133
|
+
- - ">="
|
134
134
|
- !ruby/object:Gem::Version
|
135
135
|
version: 1.9.2
|
136
136
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
137
137
|
requirements:
|
138
|
-
- -
|
138
|
+
- - ">="
|
139
139
|
- !ruby/object:Gem::Version
|
140
140
|
version: '0'
|
141
141
|
requirements: []
|
142
142
|
rubyforge_project:
|
143
|
-
rubygems_version: 2.
|
143
|
+
rubygems_version: 2.2.2
|
144
144
|
signing_key:
|
145
145
|
specification_version: 4
|
146
146
|
summary: Rails 4 authentication and sessions
|