diff options
Diffstat (limited to 'selftest/target/Samba.pm')
-rw-r--r-- | selftest/target/Samba.pm | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/selftest/target/Samba.pm b/selftest/target/Samba.pm index 445cbb250d..06b6472a6c 100644 --- a/selftest/target/Samba.pm +++ b/selftest/target/Samba.pm @@ -134,4 +134,42 @@ sub mk_realms_stanza($$$$) return $realms_stanza; } +sub get_interface($) +{ + my ($netbiosname) = @_; + $netbiosname = lc($netbiosname); + + my %interfaces = (); + $interfaces{"locals3dc2"} = 2; + $interfaces{"localmember3"} = 3; + $interfaces{"localshare4"} = 4; + $interfaces{"localserver5"} = 5; + $interfaces{"localktest6"} = 6; + $interfaces{"maptoguest"} = 7; + + # 11-16 used by selftest.pl for client interfaces + + $interfaces{"localdc"} = 21; + $interfaces{"localvampiredc"} = 22; + $interfaces{"s4member"} = 23; + $interfaces{"localrpcproxy"} = 24; + $interfaces{"dc5"} = 25; + $interfaces{"dc6"} = 26; + $interfaces{"dc7"} = 27; + $interfaces{"rodc"} = 28; + $interfaces{"localadmember"} = 29; + $interfaces{"plugindc"} = 30; + $interfaces{"localsubdc"} = 31; + $interfaces{"chgdcpass"} = 32; + + # update lib/socket_wrapper/socket_wrapper.c + # #define MAX_WRAPPED_INTERFACES 32 + # if you wish to have more than 32 interfaces + + if (not defined($interfaces{$netbiosname})) { + die(); + } + + return $interfaces{$netbiosname}; +} 1; |