role_based_authorization 0.1.16 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- data/MIT-LICENSE +1 -1
- data/README.rdoc +2 -2
- data/VERSION +1 -1
- data/lib/role_based_authorization/role_based_authorization.rb +1 -1
- data/role_based_authorization.gemspec +19 -27
- metadata +20 -20
- data/.gitignore +0 -2
data/MIT-LICENSE
CHANGED
data/README.rdoc
CHANGED
@@ -8,7 +8,7 @@ Installation:
|
|
8
8
|
* install the role_based_authorization by issuing:
|
9
9
|
gem install role_based_authorization
|
10
10
|
or by adding
|
11
|
-
|
11
|
+
config.gem "role_based_authorization"
|
12
12
|
to your rails config file and then running 'rake gems:install'
|
13
13
|
|
14
14
|
|
@@ -102,7 +102,7 @@ This works also if you use resource paths as in:
|
|
102
102
|
|
103
103
|
== Logging
|
104
104
|
|
105
|
-
The authorization system logs each access attempt to
|
105
|
+
The authorization system logs each access attempt to #{Rails.root}/log/authorization.log. If the log level is high enough, you will also view an explanation of what is happening and why.
|
106
106
|
|
107
107
|
|
108
108
|
== Examples
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.
|
1
|
+
0.2.0
|
@@ -2,7 +2,7 @@
|
|
2
2
|
module RoleBasedAuthorization
|
3
3
|
# AuthorizationLogger instance that is used throughout the plugin for logging
|
4
4
|
# events.
|
5
|
-
AUTHORIZATION_LOGGER = AuthorizationLogger.new(File.join(
|
5
|
+
AUTHORIZATION_LOGGER = AuthorizationLogger.new(File.join(Rails.root,'log','authorization.log'))
|
6
6
|
|
7
7
|
# Fires when the module is included into the controllers. It adds all class methods
|
8
8
|
# defined in the ClassAdditions sub-module and the authorize_action? and if_authorized?
|
@@ -1,53 +1,45 @@
|
|
1
1
|
# Generated by jeweler
|
2
2
|
# DO NOT EDIT THIS FILE DIRECTLY
|
3
|
-
# Instead, edit Jeweler::Tasks in
|
3
|
+
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
4
4
|
# -*- encoding: utf-8 -*-
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{role_based_authorization}
|
8
|
-
s.version = "0.
|
8
|
+
s.version = "0.2.0"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Roberto Esposito"]
|
12
|
-
s.date = %q{
|
12
|
+
s.date = %q{2011-11-25}
|
13
13
|
s.description = %q{Provides a simple DSL for specifying the authorization logic of your application. Install the gem, add a role attribute to your user model and your almost ready to go.}
|
14
14
|
s.email = %q{boborbt@gmail.com}
|
15
15
|
s.extra_rdoc_files = [
|
16
16
|
"README.rdoc"
|
17
17
|
]
|
18
18
|
s.files = [
|
19
|
-
"
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
"test/test_helper.rb"
|
19
|
+
"MIT-LICENSE",
|
20
|
+
"README.rdoc",
|
21
|
+
"Rakefile",
|
22
|
+
"VERSION",
|
23
|
+
"lib/role_based_authorization.rb",
|
24
|
+
"lib/role_based_authorization/authorization_logger.rb",
|
25
|
+
"lib/role_based_authorization/class_additions.rb",
|
26
|
+
"lib/role_based_authorization/role_based_authorization.rb",
|
27
|
+
"lib/role_based_authorization/rule.rb",
|
28
|
+
"rails/init.rb",
|
29
|
+
"role_based_authorization.gemspec",
|
30
|
+
"test/authorization_logger_test.rb",
|
31
|
+
"test/role_based_authorization_test.rb",
|
32
|
+
"test/test_helper.rb"
|
34
33
|
]
|
35
34
|
s.homepage = %q{http://github.com/boborbt/role_based_authorization}
|
36
|
-
s.rdoc_options = ["--charset=UTF-8"]
|
37
35
|
s.require_paths = ["lib"]
|
38
|
-
s.rubygems_version = %q{1.
|
36
|
+
s.rubygems_version = %q{1.5.0}
|
39
37
|
s.summary = %q{Basic authorization module for rails}
|
40
|
-
s.test_files = [
|
41
|
-
"test/authorization_logger_test.rb",
|
42
|
-
"test/role_based_authorization_test.rb",
|
43
|
-
"test/test_helper.rb"
|
44
|
-
]
|
45
38
|
|
46
39
|
if s.respond_to? :specification_version then
|
47
|
-
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
48
40
|
s.specification_version = 3
|
49
41
|
|
50
|
-
if Gem::Version.new(Gem::
|
42
|
+
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
51
43
|
s.add_runtime_dependency(%q<rails>, [">= 2.2"])
|
52
44
|
s.add_runtime_dependency(%q<mocha>, [">= 0"])
|
53
45
|
else
|
metadata
CHANGED
@@ -1,7 +1,8 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: role_based_authorization
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
|
4
|
+
prerelease:
|
5
|
+
version: 0.2.0
|
5
6
|
platform: ruby
|
6
7
|
authors:
|
7
8
|
- Roberto Esposito
|
@@ -9,29 +10,31 @@ autorequire:
|
|
9
10
|
bindir: bin
|
10
11
|
cert_chain: []
|
11
12
|
|
12
|
-
date:
|
13
|
+
date: 2011-11-25 00:00:00 +01:00
|
13
14
|
default_executable:
|
14
15
|
dependencies:
|
15
16
|
- !ruby/object:Gem::Dependency
|
16
17
|
name: rails
|
17
|
-
|
18
|
-
|
19
|
-
|
18
|
+
prerelease: false
|
19
|
+
requirement: &id001 !ruby/object:Gem::Requirement
|
20
|
+
none: false
|
20
21
|
requirements:
|
21
22
|
- - ">="
|
22
23
|
- !ruby/object:Gem::Version
|
23
24
|
version: "2.2"
|
24
|
-
|
25
|
+
type: :runtime
|
26
|
+
version_requirements: *id001
|
25
27
|
- !ruby/object:Gem::Dependency
|
26
28
|
name: mocha
|
27
|
-
|
28
|
-
|
29
|
-
|
29
|
+
prerelease: false
|
30
|
+
requirement: &id002 !ruby/object:Gem::Requirement
|
31
|
+
none: false
|
30
32
|
requirements:
|
31
33
|
- - ">="
|
32
34
|
- !ruby/object:Gem::Version
|
33
35
|
version: "0"
|
34
|
-
|
36
|
+
type: :runtime
|
37
|
+
version_requirements: *id002
|
35
38
|
description: Provides a simple DSL for specifying the authorization logic of your application. Install the gem, add a role attribute to your user model and your almost ready to go.
|
36
39
|
email: boborbt@gmail.com
|
37
40
|
executables: []
|
@@ -41,7 +44,6 @@ extensions: []
|
|
41
44
|
extra_rdoc_files:
|
42
45
|
- README.rdoc
|
43
46
|
files:
|
44
|
-
- .gitignore
|
45
47
|
- MIT-LICENSE
|
46
48
|
- README.rdoc
|
47
49
|
- Rakefile
|
@@ -61,30 +63,28 @@ homepage: http://github.com/boborbt/role_based_authorization
|
|
61
63
|
licenses: []
|
62
64
|
|
63
65
|
post_install_message:
|
64
|
-
rdoc_options:
|
65
|
-
|
66
|
+
rdoc_options: []
|
67
|
+
|
66
68
|
require_paths:
|
67
69
|
- lib
|
68
70
|
required_ruby_version: !ruby/object:Gem::Requirement
|
71
|
+
none: false
|
69
72
|
requirements:
|
70
73
|
- - ">="
|
71
74
|
- !ruby/object:Gem::Version
|
72
75
|
version: "0"
|
73
|
-
version:
|
74
76
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
77
|
+
none: false
|
75
78
|
requirements:
|
76
79
|
- - ">="
|
77
80
|
- !ruby/object:Gem::Version
|
78
81
|
version: "0"
|
79
|
-
version:
|
80
82
|
requirements: []
|
81
83
|
|
82
84
|
rubyforge_project:
|
83
|
-
rubygems_version: 1.
|
85
|
+
rubygems_version: 1.5.0
|
84
86
|
signing_key:
|
85
87
|
specification_version: 3
|
86
88
|
summary: Basic authorization module for rails
|
87
|
-
test_files:
|
88
|
-
|
89
|
-
- test/role_based_authorization_test.rb
|
90
|
-
- test/test_helper.rb
|
89
|
+
test_files: []
|
90
|
+
|
data/.gitignore
DELETED