Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 447022 | Differences between
and this patch

Collapse All | Expand All

(-)samba-4.0.0/source4/heimdal_build/crypto-headers.h (+17 lines)
Lines 3-8 Link Here
3
#ifdef KRB5
3
#ifdef KRB5
4
#include <krb5-types.h>
4
#include <krb5-types.h>
5
#endif
5
#endif
6
#if 0
6
#include <hcrypto/evp.h>
7
#include <hcrypto/evp.h>
7
#include <hcrypto/des.h>
8
#include <hcrypto/des.h>
8
#include <hcrypto/md2.h>
9
#include <hcrypto/md2.h>
Lines 17-20 Link Here
17
#include <hcrypto/engine.h>
18
#include <hcrypto/engine.h>
18
#include <hcrypto/pkcs12.h>
19
#include <hcrypto/pkcs12.h>
19
#include <hcrypto/hmac.h>
20
#include <hcrypto/hmac.h>
21
#else
22
#include <openssl/evp.h>
23
#include <openssl/des.h>
24
//#include <openssl/md2.h>
25
#include <openssl/md4.h>
26
#include <openssl/md5.h>
27
#include <openssl/sha.h>
28
#include <openssl/rc4.h>
29
#include <openssl/rc2.h>
30
#include <openssl/aes.h>
31
#include <openssl/ui.h>
32
#include <openssl/rand.h>
33
#include <openssl/engine.h>
34
#include <openssl/pkcs12.h>
35
#include <openssl/hmac.h>
36
#endif
20
#endif /* __crypto_headers_h__ */
37
#endif /* __crypto_headers_h__ */
(-)samba-4.0.0/source4/heimdal_build/wscript_build (-3 / +6 lines)
Lines 941-959 if not bld.CONFIG_SET('USING_SYSTEM_COMP Link Here
941
941
942
HEIMDAL_BINARY('samba4kinit',
942
HEIMDAL_BINARY('samba4kinit',
943
    'kuser/kinit.c',
943
    'kuser/kinit.c',
944
    deps='krb5 heimntlm roken HEIMDAL_VERS hcrypto',
944
#    deps='krb5 heimntlm roken HEIMDAL_VERS hcrypto',
945
    deps='krb5 heimntlm roken HEIMDAL_VERS libcrypto',
945
    install=False
946
    install=False
946
    )
947
    )
947
948
948
HEIMDAL_BINARY('samba4kgetcred',
949
HEIMDAL_BINARY('samba4kgetcred',
949
    'kuser/kgetcred.c',
950
    'kuser/kgetcred.c',
950
    deps='krb5 heimntlm roken HEIMDAL_VERS hcrypto',
951
#    deps='krb5 heimntlm roken HEIMDAL_VERS hcrypto',
952
    deps='krb5 heimntlm roken HEIMDAL_VERS libcrypto',
951
    install=False
953
    install=False
952
    )
954
    )
953
955
954
HEIMDAL_BINARY('samba4kpasswd',
956
HEIMDAL_BINARY('samba4kpasswd',
955
    'kpasswd/kpasswd.c',
957
    'kpasswd/kpasswd.c',
956
    deps='krb5 heimntlm roken HEIMDAL_VERS hcrypto',
958
#    deps='krb5 heimntlm roken HEIMDAL_VERS hcrypto',
959
    deps='krb5 heimntlm roken HEIMDAL_VERS libcrypto',
957
    install=False
960
    install=False
958
    )
961
    )
959
962
(-)samba-4.0.0/source4/heimdal_build/wscript_configure (-7 / +19 lines)
Lines 217-233 try: Link Here
217
    check_system_heimdal_lib("hx509", "hx509_bitstring_print", "hx509.h", onlyif="roken wind")
217
    check_system_heimdal_lib("hx509", "hx509_bitstring_print", "hx509.h", onlyif="roken wind")
218
    check_system_heimdal_lib("asn1", "initialize_asn1_error_table", "asn1_err.h", onlyif="roken com_err")
218
    check_system_heimdal_lib("asn1", "initialize_asn1_error_table", "asn1_err.h", onlyif="roken com_err")
219
    check_system_heimdal_lib("heimbase", "heim_cmp", "heimbase.h", onlyif="roken")
219
    check_system_heimdal_lib("heimbase", "heim_cmp", "heimbase.h", onlyif="roken")
220
    check_system_heimdal_lib("hcrypto", "MD4_Init", "hcrypto/md4.h",
220
    #check_system_heimdal_lib("hcrypto", "MD4_Init", "hcrypto/md4.h",
221
        onlyif="asn1 roken com_err")
221
    #    onlyif="asn1 roken com_err")
222
    if conf.check_cfg(package='libcrypto',
223
#                      uselib_store='HCRYPTO',
224
                      args='--cflags --libs',
225
                      msg='Checking for crypto'):
226
        conf.SET_TARGET_TYPE('libcrypto', 'SYSLIB')
227
    
228
    conf.define('USING_SYSTEM_HCRYPTO', 1)
222
    if check_system_heimdal_lib("krb5", "krb5_anyaddr", "krb5.h",
229
    if check_system_heimdal_lib("krb5", "krb5_anyaddr", "krb5.h",
223
        onlyif="roken wind asn1 hx509 hcrypto com_err heimbase"):
230
    #    onlyif="roken wind asn1 hx509 hcrypto com_err heimbase"):
231
        onlyif="roken wind asn1 hx509 com_err heimbase"):
224
        conf.CHECK_FUNCS_IN('krb5_free_unparsed_name', 'krb5', headers="krb5.h")
232
        conf.CHECK_FUNCS_IN('krb5_free_unparsed_name', 'krb5', headers="krb5.h")
225
    check_system_heimdal_lib("gssapi", "gss_oid_to_name", "gssapi.h",
233
    check_system_heimdal_lib("gssapi", "gss_oid_to_name", "gssapi.h",
226
        onlyif="hcrypto asn1 roken krb5 com_err wind")
234
#        onlyif="hcrypto asn1 roken krb5 com_err wind")
235
        onlyif="asn1 roken krb5 com_err wind")
227
    check_system_heimdal_lib("heimntlm", "heim_ntlm_ntlmv2_key", "heimntlm.h",
236
    check_system_heimdal_lib("heimntlm", "heim_ntlm_ntlmv2_key", "heimntlm.h",
228
        onlyif="roken hcrypto krb5")
237
#        onlyif="roken hcrypto krb5")
238
        onlyif="roken krb5")
229
    if check_system_heimdal_lib("hdb", "hdb_db_dir", "krb5.h hdb.h",
239
    if check_system_heimdal_lib("hdb", "hdb_db_dir", "krb5.h hdb.h",
230
        onlyif="roken krb5 hcrypto com_err wind"):
240
#        onlyif="roken krb5 hcrypto com_err wind"):
241
        onlyif="roken krb5 com_err wind"):
231
        conf.CHECK_CODE('''
242
        conf.CHECK_CODE('''
232
            #include <hdb.h>
243
            #include <hdb.h>
233
            int main(void) { hdb_enctype2key(NULL, NULL, NULL, 0, NULL); }
244
            int main(void) { hdb_enctype2key(NULL, NULL, NULL, 0, NULL); }
Lines 239-245 try: Link Here
239
            local_include=False)
250
            local_include=False)
240
251
241
    check_system_heimdal_lib("kdc", "kdc_log", "kdc.h",
252
    check_system_heimdal_lib("kdc", "kdc_log", "kdc.h",
242
        onlyif="roken krb5 hdb asn1 heimntlm hcrypto com_err wind heimbase")
253
#        onlyif="roken krb5 hdb asn1 heimntlm hcrypto com_err wind heimbase")
254
        onlyif="roken krb5 hdb asn1 heimntlm com_err wind heimbase")
243
finally:
255
finally:
244
    conf.env.CCDEFINES = CCDEFINES
256
    conf.env.CCDEFINES = CCDEFINES
245
257
(-)samba-4.0.0/source4/rpc_server/backupkey/dcesrv_backupkey.c (-2 / +10 lines)
Lines 31-39 Link Here
31
#include "system/network.h"
31
#include "system/network.h"
32
#include <com_err.h>
32
#include <com_err.h>
33
#include <hx509.h>
33
#include <hx509.h>
34
#if 0
34
#include <hcrypto/rsa.h>
35
#include <hcrypto/rsa.h>
35
#include <hcrypto/bn.h>
36
#include <hcrypto/bn.h>
36
#include <hcrypto/sha.h>
37
#include <hcrypto/sha.h>
38
#else
39
#include <openssl/rsa.h>
40
#include <openssl/bn.h>
41
#include <openssl/sha.h>
42
#endif
37
#include <der.h>
43
#include <der.h>
38
#include "../lib/tsocket/tsocket.h"
44
#include "../lib/tsocket/tsocket.h"
39
#include "../libcli/security/security.h"
45
#include "../libcli/security/security.h"
Lines 454-460 static WERROR get_and_verify_access_chec Link Here
454
	if (version == 2) {
460
	if (version == 2) {
455
		uint32_t hash_size = 20;
461
		uint32_t hash_size = 20;
456
		uint8_t hash[hash_size];
462
		uint8_t hash[hash_size];
457
		struct sha sctx;
463
		//struct sha sctx;
464
		SHA_CTX sctx;
458
		struct bkrp_access_check_v2 uncrypted_accesscheckv2;
465
		struct bkrp_access_check_v2 uncrypted_accesscheckv2;
459
466
460
		ndr_err = ndr_pull_struct_blob(&blob_us, sub_ctx, &uncrypted_accesscheckv2,
467
		ndr_err = ndr_pull_struct_blob(&blob_us, sub_ctx, &uncrypted_accesscheckv2,
Lines 493-499 static WERROR get_and_verify_access_chec Link Here
493
	if (version == 3) {
500
	if (version == 3) {
494
		uint32_t hash_size = 64;
501
		uint32_t hash_size = 64;
495
		uint8_t hash[hash_size];
502
		uint8_t hash[hash_size];
496
		struct hc_sha512state sctx;
503
		//struct hc_sha512state sctx;
504
		SHA512_CTX sctx;
497
		struct bkrp_access_check_v3 uncrypted_accesscheckv3;
505
		struct bkrp_access_check_v3 uncrypted_accesscheckv3;
498
506
499
		ndr_err = ndr_pull_struct_blob(&blob_us, sub_ctx, &uncrypted_accesscheckv3,
507
		ndr_err = ndr_pull_struct_blob(&blob_us, sub_ctx, &uncrypted_accesscheckv3,
(-)samba-4.0.0/source4/rpc_server/wscript_build (-1 / +2 lines)
Lines 114-120 bld.SAMBA_MODULE('dcerpc_backupkey', Link Here
114
	autoproto='backupkey/proto.h',
114
	autoproto='backupkey/proto.h',
115
	subsystem='dcerpc_server',
115
	subsystem='dcerpc_server',
116
	init_function='dcerpc_server_backupkey_init',
116
	init_function='dcerpc_server_backupkey_init',
117
	deps='samdb DCERPC_COMMON NDR_BACKUPKEY RPC_NDR_BACKUPKEY krb5 hx509 hcrypto'
117
#	deps='samdb DCERPC_COMMON NDR_BACKUPKEY RPC_NDR_BACKUPKEY krb5 hx509 hcrypto'
118
	deps='samdb DCERPC_COMMON NDR_BACKUPKEY RPC_NDR_BACKUPKEY krb5 hx509 libcrypto'
118
	)
119
	)
119
120
120
121
(-)samba-4.0.0/source4/torture/rpc/backupkey.c (-2 / +8 lines)
Lines 26-32 Link Here
26
#include "torture/rpc/torture_rpc.h"
26
#include "torture/rpc/torture_rpc.h"
27
#include "lib/cmdline/popt_common.h"
27
#include "lib/cmdline/popt_common.h"
28
#include <com_err.h>
28
#include <com_err.h>
29
#if 0
29
#include <hcrypto/sha.h>
30
#include <hcrypto/sha.h>
31
#else
32
#include <openssl/sha.h>
33
#endif
30
#include <system/network.h>
34
#include <system/network.h>
31
#include <hx509.h>
35
#include <hx509.h>
32
#include <der.h>
36
#include <der.h>
Lines 255-261 static DATA_BLOB *create_access_check(st Link Here
255
259
256
	if (version == 2) {
260
	if (version == 2) {
257
		struct bkrp_access_check_v2 access_struct;
261
		struct bkrp_access_check_v2 access_struct;
258
		struct sha sctx;
262
		//struct sha sctx;
263
		SHA_CTX sctx;
259
		uint8_t nonce[32];
264
		uint8_t nonce[32];
260
265
261
		ZERO_STRUCT(access_struct);
266
		ZERO_STRUCT(access_struct);
Lines 290-296 static DATA_BLOB *create_access_check(st Link Here
290
295
291
	if (version == 3) {
296
	if (version == 3) {
292
		struct bkrp_access_check_v3 access_struct;
297
		struct bkrp_access_check_v3 access_struct;
293
		struct hc_sha512state sctx;
298
		//struct hc_sha512state sctx;
299
		SHA512_CTX sctx;
294
		uint8_t nonce[32];
300
		uint8_t nonce[32];
295
301
296
		ZERO_STRUCT(access_struct);
302
		ZERO_STRUCT(access_struct);

Return to bug 447022