1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-27 03:21:53 +03:00
samba-mirror/python
Alexander Bokovoy bbeef554f2 lib/crypto: implement samba.crypto Python module for RC4
Implement a small Python module that exposes arcfour_crypt_blob()
function widely used in Samba C code.

When Samba Python bindings are used to call LSA CreateTrustedDomainEx2,
there is a need to encrypt trusted credentials with RC4 cipher.

Current Samba Python code relies on Python runtime to provide RC4
cipher. However, in FIPS 140-2 mode system crypto libraries do not
provide access RC4 cipher at all. According to Microsoft dochelp team,
Windows is treating AuthenticationInformation blob encryption as 'plain
text' in terms of FIPS 140-2, thus doing application-level encryption.

Replace samba.arcfour_encrypt() implementation with a call to
samba.crypto.arcfour_crypt_blob().

Signed-off-by: Alexander Bokovoy <ab@samba.org>
Reviewed-by: Simo Sorce <idra@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>

Autobuild-User(master): Günther Deschner <gd@samba.org>
Autobuild-Date(master): Wed Mar 15 01:30:24 CET 2017 on sn-devel-144
2017-03-15 01:30:24 +01:00
..
examples python/examples/winreg: two variable name typos on a single line 2017-03-10 07:31:10 +01:00
samba lib/crypto: implement samba.crypto Python module for RC4 2017-03-15 01:30:24 +01:00
samba_external
modules.c
modules.h
py3compat.h python: Add py3compat.h 2016-12-01 05:54:21 +01:00
pyglue.c python: samba._glue: Port samba._glue module to Python 3. 2017-03-10 07:31:10 +01:00
wscript_build waf: disable-python - don't build python/ 2017-03-10 07:31:12 +01:00