devise_pam_authenticatable2 6.1.0 → 6.1.1
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/VERSION +1 -1
- data/devise_pam_authenticatable2.gemspec +2 -2
- data/lib/devise_pam_authenticatable/model.rb +2 -2
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: f55e4967e974aa8516eb7b204f8c407a9d5b7989e3227103d0463e1b2055f58e
|
|
4
|
+
data.tar.gz: b079c8ac2d4f75a84f3422464f50f318dbf3049214b075c999158804c3acffcf
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 4ae221343f7f695c24ea84bd29b5df81a757a2127d28342a9f3f54472bdf18d3a2415bceb5a5a8b37b9786ce35d1716a8b6f481e5f299ac482da075178ad0b2c
|
|
7
|
+
data.tar.gz: 9d7a541ebd10f391a423f2124a23869eadb41f4bae46aa0a633badb97671c953e5d862fc90c91f117d161c36b1bf05c016f93f097a6656ca1e08b1fcd405f9ba
|
data/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
6.1.
|
|
1
|
+
6.1.1
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
# DO NOT EDIT THIS FILE DIRECTLY
|
|
3
3
|
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
|
4
4
|
# -*- encoding: utf-8 -*-
|
|
5
|
-
# stub: devise_pam_authenticatable2 6.1.
|
|
5
|
+
# stub: devise_pam_authenticatable2 6.1.1 ruby lib
|
|
6
6
|
|
|
7
7
|
Gem::Specification.new do |s|
|
|
8
8
|
s.name = "devise_pam_authenticatable2".freeze
|
|
9
|
-
s.version = "6.1.
|
|
9
|
+
s.version = "6.1.1"
|
|
10
10
|
|
|
11
11
|
s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version=
|
|
12
12
|
s.require_paths = ["lib".freeze]
|
|
@@ -62,7 +62,7 @@ module Devise
|
|
|
62
62
|
module ClassMethods
|
|
63
63
|
Devise::Models.config(self, :pam_service, :pam_suffix)
|
|
64
64
|
|
|
65
|
-
def
|
|
65
|
+
def pam_get_user(attributes = {})
|
|
66
66
|
if ::Devise.usernamefield && attributes[:username]
|
|
67
67
|
resource = find_by(::Devise.usernamefield => attributes[:username])
|
|
68
68
|
|
|
@@ -94,7 +94,7 @@ module Devise
|
|
|
94
94
|
def authenticate_with_pam(attributes = {})
|
|
95
95
|
return nil unless attributes[:password]
|
|
96
96
|
|
|
97
|
-
return nil unless (resource =
|
|
97
|
+
return nil unless (resource = pam_get_user(attributes))
|
|
98
98
|
|
|
99
99
|
# potential conflict detected
|
|
100
100
|
resource = resource.pam_conflict(attributes) if resource.pam_conflict?
|