Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
acs-authentication
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
project-open
acs-authentication
Commits
27a282c1
Commit
27a282c1
authored
Oct 24, 2018
by
adrtel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- Allowing for LDAP authentication via email, in addition to Windows username
parent
05cf0e1e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
0 deletions
+9
-0
authentication-procs.tcl
tcl/authentication-procs.tcl
+9
-0
No files found.
tcl/authentication-procs.tcl
View file @
27a282c1
...
...
@@ -221,6 +221,15 @@ ad_proc -public auth::authenticate {
set authority_id
$user
(
authority_id
)
set username
$user
(
username
)
}
else
{
# Check for email instead of username
set user_id_from_email
[
db_string email_p
"select min(party_id) from parties where lower(email) = lower(trim(:username))"
-default
""
]
if
{
""
ne
$user
_id_from_email
}
{
ns_log Notice
"auth::authenticate: found that username='
$username
' is actually a valid email for user_id=
$user
_id_from_email"
set username
[
db_string uname
"select username from users where user_id = :user_id_from_email"
]
ns_log Notice
"auth::authenticate: New username='
$username
' for user_id=
$user
_id_from_email"
}
# Default to local authority
if
{
$authority
_id eq
""
}
{
set authority_id
[
auth::authority::local
]
...
...
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