Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5_fork
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Eteri
erp5_fork
Commits
b9ab4468
Commit
b9ab4468
authored
Jul 27, 2011
by
Ivan Tyagov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Extend API of ILoginAccountProvider to allow to take actions whenever a
password expire occurs.
parent
85278bdd
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
0 deletions
+13
-0
product/ERP5/interfaces/login_account_provider.py
product/ERP5/interfaces/login_account_provider.py
+5
-0
product/ERP5/mixin/login_account_provider.py
product/ERP5/mixin/login_account_provider.py
+8
-0
No files found.
product/ERP5/interfaces/login_account_provider.py
View file @
b9ab4468
...
@@ -39,6 +39,11 @@ class ILoginAccountProvider(Interface):
...
@@ -39,6 +39,11 @@ class ILoginAccountProvider(Interface):
"""
"""
Notify an authentication failure.
Notify an authentication failure.
"""
"""
def
notifyPasswordExpire
(
**
kw
):
"""
Notify a password expire event.
"""
def
isLoginBlocked
(
**
kw
):
def
isLoginBlocked
(
**
kw
):
"""
"""
...
...
product/ERP5/mixin/login_account_provider.py
View file @
b9ab4468
...
@@ -47,6 +47,14 @@ class LoginAccountProviderMixin:
...
@@ -47,6 +47,14 @@ class LoginAccountProviderMixin:
method
=
self
.
_getTypeBasedMethod
(
'notifyLoginFailure'
)
method
=
self
.
_getTypeBasedMethod
(
'notifyLoginFailure'
)
return
method
(
**
kw
)
return
method
(
**
kw
)
security
.
declareProtected
(
Permissions
.
SetOwnPassword
,
'notifyPasswordExpire'
)
def
notifyPasswordExpire
(
self
,
**
kw
):
"""
Notify a password expire event.
"""
method
=
self
.
_getTypeBasedMethod
(
'notifyPasswordExpire'
)
return
method
(
**
kw
)
security
.
declareProtected
(
Permissions
.
SetOwnPassword
,
'isLoginBlocked'
)
security
.
declareProtected
(
Permissions
.
SetOwnPassword
,
'isLoginBlocked'
)
def
isLoginBlocked
(
self
,
**
kw
):
def
isLoginBlocked
(
self
,
**
kw
):
"""
"""
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment