mirror of
https://github.com/samba-team/samba.git
synced 2025-01-06 13:18:07 +03:00
3542483de3
This lets us access single-DES from Python. This function is used in a following commit for encrypting an NT hash to obtain the verifier for a SAMR password change. BUG: https://bugzilla.samba.org/show_bug.cgi?id=14611 Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz> Reviewed-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> (cherry picked from commitb27a67af02
) [jsutton@samba.org Fixed wscript conflict introduced by commit61aeb77407
]
55 lines
1.7 KiB
Python
55 lines
1.7 KiB
Python
#!/usr/bin/env python
|
|
|
|
extra_deps = ''
|
|
|
|
if (bld.CONFIG_SET("HAVE_AESNI_INTEL") and
|
|
not bld.CONFIG_SET('HAVE_GNUTLS_AES_CMAC')):
|
|
extra_deps += ' aesni-intel'
|
|
|
|
bld.SAMBA_SUBSYSTEM('GNUTLS_HELPERS',
|
|
source='''
|
|
gnutls_error.c
|
|
gnutls_arcfour_confounded_md5.c
|
|
gnutls_weak_crypto.c
|
|
''',
|
|
deps='gnutls samba-errors');
|
|
|
|
bld.SAMBA_SUBSYSTEM('LIBCRYPTO_AES',
|
|
source='aes.c rijndael-alg-fst.c',
|
|
deps='talloc',
|
|
enabled=not bld.CONFIG_SET('HAVE_GNUTLS_AES_CMAC'))
|
|
|
|
bld.SAMBA_SUBSYSTEM('LIBCRYPTO_AES_CMAC',
|
|
source='aes_cmac_128.c',
|
|
deps='talloc',
|
|
enabled=not bld.CONFIG_SET('HAVE_GNUTLS_AES_CMAC'))
|
|
|
|
bld.SAMBA_SUBSYSTEM('LIBCRYPTO',
|
|
source='''
|
|
md4.c
|
|
''',
|
|
deps='''
|
|
talloc
|
|
LIBCRYPTO_AES
|
|
LIBCRYPTO_AES_CMAC
|
|
''' + extra_deps)
|
|
|
|
bld.SAMBA_SUBSYSTEM('TORTURE_LIBCRYPTO_AES_CMAC',
|
|
source='aes_cmac_128_test.c',
|
|
autoproto='aes_cmac_test_proto.h',
|
|
deps='talloc',
|
|
enabled=not bld.CONFIG_SET('HAVE_GNUTLS_AES_CMAC'))
|
|
|
|
bld.SAMBA_SUBSYSTEM('TORTURE_LIBCRYPTO',
|
|
source='md4test.c',
|
|
autoproto='test_proto.h',
|
|
deps='''
|
|
LIBCRYPTO
|
|
TORTURE_LIBCRYPTO_AES_CMAC
|
|
''')
|
|
|
|
bld.SAMBA_PYTHON('python_crypto',
|
|
source='py_crypto.c',
|
|
deps='gnutls talloc LIBCLI_AUTH',
|
|
realname='samba/crypto.so')
|