// File: /workspace/github_c_makefile_star2_O1/OpenKMIP[P]libkmip/tests/tests.c
// Function: test_deep_copy_cryptographic_parameters
int
test_deep_copy_cryptographic_parameters(TestTracker *tracker)
{
    TRACK_TEST(tracker);

    CryptographicParameters *observed = NULL;

    observed = kmip_deep_copy_cryptographic_parameters(NULL, NULL);
    if(NULL != observed)
    {
        TEST_FAILED(tracker, __func__, __LINE__);
    }

    KMIP ctx = {0};
    kmip_init(&ctx, NULL, 0, KMIP_1_0);

    observed = kmip_deep_copy_cryptographic_parameters(&ctx, NULL);
    if(NULL != observed)
    {
        kmip_destroy(&ctx);
        TEST_FAILED(tracker, __func__, __LINE__);
    }

    uint8 b[4] = {0x01, 0x02, 0x03, 0x04};
    ByteString p_source = {0};
    p_source.value = b;
    p_source.size = ARRAY_LENGTH(b);

    CryptographicParameters expected = {0};
    expected.block_cipher_mode = KMIP_BLOCK_CBC;
    expected.padding_method = KMIP_PAD_PKCS5;
    expected.hashing_algorithm = KMIP_HASH_SHA1;
    expected.key_role_type = KMIP_ROLE_KEK;

    expected.digital_signature_algorithm = KMIP_DIGITAL_SHA1_WITH_RSA;
    expected.cryptographic_algorithm = KMIP_CRYPTOALG_RSA;
    expected.random_iv = KMIP_TRUE;
    expected.iv_length = 256;
    expected.tag_length = 16;
    expected.fixed_field_length = 1024;
    expected.invocation_field_length = 1024;
    expected.counter_length = 32;
    expected.initial_counter_value = 1;

    expected.salt_length = 64;
    expected.mask_generator = KMIP_MASKGEN_MGF1;
    expected.mask_generator_hashing_algorithm = KMIP_HASH_SHA1;
    expected.p_source = &p_source;
    expected.trailer_field = 32;

    observed = kmip_deep_copy_cryptographic_parameters(&ctx, &expected);
    if(NULL == observed)
    {
        kmip_destroy(&ctx);
        TEST_FAILED(tracker, __func__, __LINE__);
    }
    if(!kmip_compare_cryptographic_parameters(&expected, observed))
    {
        kmip_print_cryptographic_parameters(stderr, 1, &expected);
        kmip_print_cryptographic_parameters(stderr, 1, &expected);
        kmip_free_cryptographic_parameters(&ctx, observed);
        ctx.free_func(ctx.state, observed);
        kmip_destroy(&ctx);
        TEST_FAILED(tracker, __func__, __LINE__);
    }

    kmip_free_cryptographic_parameters(&ctx, observed);
    ctx.free_func(ctx.state, observed);
    kmip_destroy(&ctx);

    TEST_PASSED(tracker, __func__);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x910, %rsp            # imm = 0x910
movq %rdi, %rbx
incw (%rdi)
xorl %edi, %edi
xorl %esi, %esi
callq 0x15bda
testq %rax, %rax
je 0x3e91
leaq 0x2b39f(%rip), %rdi     # 0x2f222
leaq 0x2b75a(%rip), %rsi     # 0x2f5e4
movl $0x60e, %edx            # imm = 0x60E
jmp 0x3edf
leaq 0x78(%rsp), %r14
movl $0x898, %edx            # imm = 0x898
movq %r14, %rdi
xorl %esi, %esi
callq 0x10c0
movq %r14, %rdi
xorl %esi, %esi
xorl %edx, %edx
xorl %ecx, %ecx
callq 0x13747
movq %r14, %rdi
xorl %esi, %esi
callq 0x15bda
testq %rax, %rax
je 0x3f01
leaq 0x78(%rsp), %rdi
callq 0x13a23
leaq 0x2b34f(%rip), %rdi     # 0x2f222
leaq 0x2b70a(%rip), %rsi     # 0x2f5e4
movl $0x618, %edx            # imm = 0x618
xorl %eax, %eax
callq 0x1090
incw 0x2(%rbx)
movl $0x1, %ebp
movl %ebp, %eax
addq $0x910, %rsp            # imm = 0x910
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0xc(%rsp), %rax
movl $0x4030201, (%rax)      # imm = 0x4030201
xorps %xmm0, %xmm0
leaq 0x10(%rsp), %rcx
movaps %xmm0, (%rcx)
movq %rax, (%rcx)
movq $0x4, 0x8(%rcx)
leaq 0x20(%rsp), %rsi
movaps %xmm0, 0x40(%rsi)
movaps 0x2b0de(%rip), %xmm0    # 0x2f010
movaps %xmm0, (%rsi)
movaps 0x2b0e4(%rip), %xmm0    # 0x2f020
movaps %xmm0, 0x10(%rsi)
movaps 0x2b0e9(%rip), %xmm0    # 0x2f030
movaps %xmm0, 0x20(%rsi)
movaps 0x2b0ee(%rip), %xmm0    # 0x2f040
movaps %xmm0, 0x30(%rsi)
movq %rcx, 0x40(%rsi)
movl $0x20, 0x48(%rsi)
leaq 0x78(%rsp), %rdi
callq 0x15bda
testq %rax, %rax
je 0x3fce
movq %rax, %r14
leaq 0x20(%rsp), %rdi
movq %rax, %rsi
callq 0x164bf
testl %eax, %eax
je 0x3ff9
leaq 0x78(%rsp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x141d8
movq 0x890(%r15), %rdi
movq %r14, %rsi
callq *0x878(%r15)
movq %r15, %rdi
callq 0x13a23
leaq 0x2b263(%rip), %rdi     # 0x2f217
leaq 0x2b629(%rip), %rsi     # 0x2f5e4
xorl %ebp, %ebp
xorl %eax, %eax
callq 0x1090
movl $0x4, %eax
jmp 0x4074
leaq 0x78(%rsp), %rdi
callq 0x13a23
leaq 0x2b243(%rip), %rdi     # 0x2f222
leaq 0x2b5fe(%rip), %rsi     # 0x2f5e4
movl $0x63a, %edx            # imm = 0x63A
xorl %eax, %eax
callq 0x1090
movl $0x1, %ebp
jmp 0x406f
movq 0x40ff8(%rip), %r12     # 0x44ff8
movq (%r12), %rdi
movl $0x1, %ebp
leaq 0x20(%rsp), %r15
movl $0x1, %esi
movq %r15, %rdx
callq 0x2c217
movq (%r12), %rdi
movl $0x1, %esi
movq %r15, %rdx
callq 0x2c217
leaq 0x78(%rsp), %r15
movq %r15, %rdi
movq %r14, %rsi
callq 0x141d8
movq 0x890(%r15), %rdi
movq %r14, %rsi
callq *0x878(%r15)
movq %r15, %rdi
callq 0x13a23
leaq 0x2b1c6(%rip), %rdi     # 0x2f222
leaq 0x2b581(%rip), %rsi     # 0x2f5e4
movl $0x643, %edx            # imm = 0x643
xorl %eax, %eax
callq 0x1090
movl $0x2, %eax
incw (%rbx,%rax)
jmp 0x3eef