# Jerry Murdock <jmurdock@itraktech.com>
#
# Version history:
+# 2010-08-27 Hank Hampel <hh@nr-city.net>
+# Add Kerberos to NTLM conversion of credentials (-K)
+#
# 2005-12-26 Guido Serassio <guido.serassio@acmeconsulting.it>
# Add '-d' command line debugging option
#
-d Write debug info to stderr.
-h Print the help.
+ -K downgrade Kerberos credentials to NTLM.
=head1 CONFIGURATION
#
sub check {
local($user, $group) = @_;
+ if ($opt{K} && ($user =~ m/\@/)) {
+ @tmpuser = split(/\@/, $user);
+ $user = "$tmpuser[1]\\$tmpuser[0]";
+ }
$groupSID = `wbinfo -n "$group" | cut -d" " -f1`;
chop $groupSID;
$groupGID = `wbinfo -Y "$groupSID"`;
sub init()
{
use Getopt::Std;
- my $opt_string = 'hd';
+ my $opt_string = 'hdK';
getopts( "$opt_string", \%opt ) or usage();
usage() if $opt{h};
}
print "Usage: ext_wbinfo_group_acl -dh\n";
print "\t-d enable debugging\n";
print "\t-h print the help\n";
+ print "\t-K downgrade Kerberos credentials to NTLM.\n";
exit;
}