selftest:Samba4: let fl2000dc use Windows2000 supported_enctypes
authorStefan Metzmacher <metze@samba.org>
Tue, 26 Apr 2016 23:00:14 +0000 (01:00 +0200)
committerKarolin Seeger <kseeger@samba.org>
Fri, 29 Apr 2016 10:06:26 +0000 (12:06 +0200)
BUG: https://bugzilla.samba.org/show_bug.cgi?id=11849

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Günther Deschner <gd@samba.org>
(similar to commit 587b5db7979c1ca1055f5bfd81ab79606cd3c2dd)

selftest/target/Samba.pm
selftest/target/Samba4.pm

index dabe442c142d0767479d287ea7529783f23b5a2d..069b85eaeea03f4f05f48efedb851ddd416f0ce3 100644 (file)
@@ -204,6 +204,19 @@ sub mk_krb5_conf($$)
  forwardable = yes
  allow_weak_crypto = yes
 
+";
+
+        if (defined($ctx->{supported_enctypes})) {
+               print KRB5CONF "
+ default_etypes = $ctx->{supported_enctypes}
+ default_as_etypes = $ctx->{supported_enctypes}
+ default_tgs_enctypes = $ctx->{supported_enctypes}
+ default_tkt_enctypes = $ctx->{supported_enctypes}
+ permitted_enctypes = $ctx->{supported_enctypes}
+";
+       }
+
+       print KRB5CONF "
 [realms]
  $our_realms_stanza
  $other_realms_stanza
index e8d591560fdf33dfb4c19aff8e589cb7a042f7e0..48ff9b8be86a0387a24e8dba6a37af0c059dd8e3 100755 (executable)
@@ -282,6 +282,9 @@ sub provision_raw_prepare($$$$$$$$$$)
        $ctx->{swiface} = $swiface;
        $ctx->{password} = $password;
        $ctx->{kdc_ipv4} = $kdc_ipv4;
+       if ($functional_level eq "2000") {
+               $ctx->{supported_enctypes} = "arcfour-hmac-md5 des-cbc-md5 des-cbc-crc"
+       }
 
 #
 # Set smbd log level here.