CVE-2022-32744 tests/krb5: Correctly handle specifying account kvno
authorJoseph Sutton <josephsutton@catalyst.net.nz>
Thu, 26 May 2022 04:34:01 +0000 (16:34 +1200)
committerJule Anger <janger@samba.org>
Sun, 24 Jul 2022 09:42:01 +0000 (11:42 +0200)
The environment variable is a string, but we expect an integer.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=15074

Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz>
Reviewed-by: Andreas Schneider <asn@samba.org>
python/samba/tests/krb5/raw_testcase.py

index a2241707d44c7505d395fe4bd480b4d85d1bfb3c..4120edf93b94e917ac48ba13268613f365ea05f1 100644 (file)
@@ -724,7 +724,7 @@ class RawKerberosTest(TestCaseInTempDir):
                                 fallback_default=False,
                                 allow_missing=kvno_allow_missing)
         if kvno is not None:
-            c.set_kvno(kvno)
+            c.set_kvno(int(kvno))
         aes256_key = self.env_get_var('AES256_KEY_HEX', prefix,
                                       fallback_default=False,
                                       allow_missing=aes256_allow_missing)