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
e294b0dd
Commit
e294b0dd
authored
Sep 13, 2011
by
Frank Bergmann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- LDAP Import:
Fixed import
parent
fad2b0d8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
83 additions
and
0 deletions
+83
-0
sync-procs.tcl
tcl/sync-procs.tcl
+83
-0
No files found.
tcl/sync-procs.tcl
View file @
e294b0dd
...
...
@@ -11,6 +11,7 @@ namespace eval auth::sync {}
namespace
eval auth::sync::job
{}
namespace
eval auth::sync::get_doc
{}
namespace
eval auth::sync::get_doc::http
{}
namespace
eval auth::sync::get_doc::ldap
{}
namespace
eval auth::sync::get_doc::file
{}
namespace
eval auth::sync::entry
{}
namespace
eval auth::sync::process_doc
{}
...
...
@@ -565,6 +566,7 @@ ad_proc -private auth::sync::GetDocument {
}
{
Wrapper for the GetDocument operation of the auth_sync_retrieve service contract.
}
{
ns_log Notice
"auth::sync::GetDocument: authoriy_id=
$authority
_id"
set impl_id
[
auth::authority::get_element -authority_id
$authority
_id -element
"get_doc_impl_id"
]
if
{
$impl
_id eq
""
}
{
...
...
@@ -577,12 +579,19 @@ ad_proc -private auth::sync::GetDocument {
-authority_id
$authority
_id
\
-impl_id
$impl
_id
]
ns_log Notice
"auth::sync::GetDocument: before acs_sc::invoke -contract auth_sync_retrieve -impl_id
$impl
_id -operation GetDocument -call_args
$parameters
"
return
[
acs_sc::invoke
\
-error
\
-contract
"auth_sync_retrieve"
\
-impl_id
$impl
_id
\
-operation GetDocument
\
-call_args
[
list
$parameters
]]
ad_return_complaint 1
"1 - auth::sync::GetDocument: impl_id=
$impl
_id, parameters=
$parameters
"
}
ad_proc -private auth::sync::ProcessDocument
{
...
...
@@ -712,6 +721,7 @@ ad_proc -private auth::sync::get_doc::http::GetDocument {
}
{
Retrieve the document by HTTP
}
{
ns_log Notice
"auth::sync::get_doc::http::GetDocument: parameters=
$parameters
"
array set result
{
doc_status failed_to_conntect
doc_message
{}
...
...
@@ -745,6 +755,79 @@ ad_proc -private auth::sync::get_doc::http::GetDocument {
#####
#
# auth::sync::get_doc::ldap namespace
#
#####
ad_proc -private auth::sync::get_doc::ldap::register_impl
{}
{
Register this implementation
}
{
set spec
{
contract_name
"auth_sync_retrieve"
owner
"acs-authentication"
name
"LDAPGet"
pretty_name
"LDAP GET"
aliases
{
GetDocument auth::sync::get_doc::ldap::GetDocument
GetParameters auth::sync::get_doc::ldap::GetParameters
}
}
return
[
acs_sc::impl::new_from_spec -spec
$spec
]
}
ad_proc -private auth::sync::get_doc::ldap::unregister_impl
{}
{
Unregister this implementation
}
{
acs_sc::impl::delete -contract_name
"auth_sync_retrieve"
-impl_name
"LDAPGet"
}
ad_proc -private auth::sync::get_doc::ldap::GetParameters
{}
{
Parameters for LDAP GetDocument implementation.
}
{
return
{}
}
ad_proc -private auth::sync::get_doc::ldap::GetDocument
{
parameters
}
{
Retrieve the document by LDAP
}
{
ns_log Notice
"auth::sync::get_doc::ldap::GetDocument: parameters=
$parameters
"
array set result
{
doc_status failed_to_conntect
doc_message
{}
document
{}
snapshot_p f
}
array set param
$parameters
# Check 4 call levels upwards for an authority_id
upvar 3 authority_id authority_id
if
{
!
[
info
exists authority_id
]}
{
set authority_id
""
}
if
{
""
==
$authority
_id
}
{
ad_return_complaint 1
"Internal Error:<br>auth::sync::get_doc::ldap::GetDocument didn't find a valid authority_id.<br> "
ad_script_abort
}
set result
(
document
)
"!!!"
set result
(
doc_status
)
"ok"
return
[
array
get result
]
}
#####
#
# auth::sync::get_doc::file namespace
...
...
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