diff options
author | Noel Power <noel.power@suse.com> | 2016-09-29 16:50:58 +0100 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2016-10-03 19:49:19 +0200 |
commit | ebfe3c85d0bbdf5d5f7459ddd61e3b44c3ec2bd3 (patch) | |
tree | 3f2c141739ac03f66d8e985385e7929a83c47c92 /testprogs | |
parent | c514fb6b62a904b7aaea17a78ea05299e0f462a1 (diff) | |
download | samba-ebfe3c85d0bbdf5d5f7459ddd61e3b44c3ec2bd3.tar.gz |
Add a blackbox tests for id & getent to test domain@realm type credentials
Using domain@realm credentials has been problematic when
global conf setting "winbind use default domain" is enabled, this patch
creates a new s4member_dflt_domain environment (where
"winbind use default domain" is enabled) and runs getent & id against the
normal s4member & and new s4member_dflt_domain environments
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12298
Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Diffstat (limited to 'testprogs')
-rwxr-xr-x | testprogs/blackbox/dom_parse.sh | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/testprogs/blackbox/dom_parse.sh b/testprogs/blackbox/dom_parse.sh new file mode 100755 index 00000000000..dd14f0d7ca9 --- /dev/null +++ b/testprogs/blackbox/dom_parse.sh @@ -0,0 +1,27 @@ +#!/bin/sh +# Blackbox wrapper for nsstest +# Copyright (C) 2006-2007 Jelmer Vernooij <jelmer@samba.org> +# Copyright (C) 2006-2008 Andrew Bartlett <abartlet@samba.org> + +if [ $# -lt 2 ]; then +cat <<EOF +Usage: dom_parse.sh [id|getent] $USER +EOF +exit 1; +fi + +USER=$2 +CMD=$1 +EXTRA="" +shift 2 +failed=0 + +. `dirname $0`/subunit.sh + +if [ "$CMD" = "getent" ]; then + EXTRA="passwd" +fi + +testit "samba4.winbind.dom_name_parse.cmd.$CMD" $CMD $EXTRA $USER || failed=`expr $failed + 1` + +exit $failed |