Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
O
OpenLDAP
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Dragoș Haiduc
OpenLDAP
Commits
440f1355
Commit
440f1355
authored
19 years ago
by
Kurt Zeilenga
Browse files
Options
Downloads
Patches
Plain Diff
whoami test updates
parent
e36536ec
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
tests/data/test-whoami.ldif
+1
-4
1 addition, 4 deletions
tests/data/test-whoami.ldif
tests/scripts/test014-whoami
+44
-8
44 additions, 8 deletions
tests/scripts/test014-whoami
with
45 additions
and
12 deletions
tests/data/test-whoami.ldif
+
1
−
4
View file @
440f1355
...
...
@@ -262,7 +262,6 @@ authzFrom: dn.regex:^cn=Dorothy.*dc=example,dc=com$
authzFrom: dn.children:ou=Alumni Association,ou=People,dc=example
,dc=com
authzFrom: dn.subtree:ou=Groups,dc=example,dc=com
authzFrom: ldap:///dc=example,dc=com??sub?uid=fail
authzTo: dn.exact:cn=Barbara Jensen,ou=Information Technology Division,ou=Peop
le,dc=example,dc=com
authzTo: u:melliot
...
...
@@ -271,10 +270,8 @@ authzTo: group/groupOfUniqueNames/uniqueMember:cn=ITD Staff,ou=Groups,dc=examp
le,dc=com
authzTo: dn.onelevel:ou=Information Technology Division,ou=People,dc=example,dc=com
authzTo: dn.regex:^cn=Dorothy.*dc=example,dc=com$
authzTo: dn.children:ou=Alumni Association,ou=People,dc=example,d
c=com
authzTo: dn.children:ou=Alumni Association,ou=People,dc=example,dc=com
authzTo: dn.subtree:ou=Groups,dc=example,dc=com
authzTo: ldap:///dc=example,dc=com??sub?uid=fail
dn: cn=Dorothy Stevens,ou=Alumni Association,ou=People,dc=example,dc=com
objectclass: OpenLDAPperson
...
...
This diff is collapsed.
Click to expand it.
tests/scripts/test014-whoami
+
44
−
8
View file @
440f1355
...
...
@@ -227,11 +227,20 @@ $LDAPWHOAMI -h $LOCALHOST -p $PORT1 -D "$BINDDN" -w $BINDPW \
-e
\!
authzid
=
"
$AUTHZID
"
RC
=
$?
if
test
$RC
!=
1
;
then
case
$RC
in
1
)
;;
0
)
echo
"ldapwhoami should have failed (
$RC
)!"
test
$KILLSERVERS
!=
no
&&
kill
-HUP
$KILLPIDS
exit
-1
;;
*
)
echo
"ldapwhoami failed (
$RC
)!"
test
$KILLSERVERS
!=
no
&&
kill
-HUP
$KILLPIDS
exit
$RC
fi
;;
esac
BINDDN
=
"cn=Must Fail,dc=example,dc=com"
BINDPW
=
fail
...
...
@@ -241,11 +250,20 @@ $LDAPWHOAMI -h $LOCALHOST -p $PORT1 -D "$BINDDN" -w $BINDPW \
-e
\!
authzid
=
"
$AUTHZID
"
RC
=
$?
if
test
$RC
!=
1
;
then
case
$RC
in
1
)
;;
0
)
echo
"ldapwhoami should have failed (
$RC
)!"
test
$KILLSERVERS
!=
no
&&
kill
-HUP
$KILLPIDS
exit
-1
;;
*
)
echo
"ldapwhoami failed (
$RC
)!"
test
$KILLSERVERS
!=
no
&&
kill
-HUP
$KILLPIDS
exit
$RC
fi
;;
esac
# authzTo: bjorn => someone else
echo
"Testing authzTo..."
...
...
@@ -370,11 +388,20 @@ $LDAPWHOAMI -h $LOCALHOST -p $PORT1 -D "$BINDDN" -w $BINDPW \
-e
\!
authzid
=
"
$AUTHZID
"
RC
=
$?
if
test
$RC
!=
1
;
then
case
$RC
in
1
)
;;
0
)
echo
"ldapwhoami should have failed (
$RC
)!"
test
$KILLSERVERS
!=
no
&&
kill
-HUP
$KILLPIDS
exit
-1
;;
*
)
echo
"ldapwhoami failed (
$RC
)!"
test
$KILLSERVERS
!=
no
&&
kill
-HUP
$KILLPIDS
exit
$RC
fi
;;
esac
BINDDN
=
"cn=Bjorn Jensen,ou=Information Technology Division,ou=People,dc=example,dc=com"
BINDPW
=
bjorn
...
...
@@ -384,11 +411,20 @@ $LDAPWHOAMI -h $LOCALHOST -p $PORT1 -D "$BINDDN" -w $BINDPW \
-e
\!
authzid
=
"
$AUTHZID
"
RC
=
$?
if
test
$RC
!=
1
;
then
case
$RC
in
1
)
;;
0
)
echo
"ldapwhoami should have failed (
$RC
)!"
test
$KILLSERVERS
!=
no
&&
kill
-HUP
$KILLPIDS
exit
-1
;;
*
)
echo
"ldapwhoami failed (
$RC
)!"
test
$KILLSERVERS
!=
no
&&
kill
-HUP
$KILLPIDS
exit
$RC
fi
;;
esac
BINDDN
=
"cn=Bjorn Jensen,ou=Information Technology Division,ou=People,dc=example,dc=com"
BINDPW
=
bjorn
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment