user: Please show me the C implementation that matches the assembly code listed below:

```asm
<do_bio_cipher>:
  endbr64
  push   %r15
  mov    %rsi,%r15
  push   %r14
  lea    D189(%rip),%r14
  push   %r13
  mov    %rdi,%r13
  push   %r12
  push   %rbp
  push   %rbx
  mov    %rdx,%rbx
  sub    $0x898,%rsp
  mov    %rdi,0x8(%rsp)
  lea    D151(%rip),%rdi
  mov    %rsi,0x10(%rsp)
  mov    $0x400,%esi
  mov    %rdx,0x18(%rsp)
  mov    %fs:0x28,%rax
  mov    %rax,0x888(%rsp)
  xor    %eax,%eax
  call   <RAND_bytes@plt>
  xor    %r9d,%r9d
  mov    $0x2f,%esi
  mov    %r14,%rdi
  mov    %eax,%r8d
  lea    D216(%rip),%rcx
  lea    D284(%rip),%rdx
  call   <test_int_gt@plt>
  test   %eax,%eax
  jne    L407
L258:
  xor    %r8d,%r8d
L136:
  mov    0x888(%rsp),%rax
  sub    %fs:0x28,%rax
  jne    L349
  add    $0x898,%rsp
  mov    %r8d,%eax
  pop    %rbx
  pop    %rbp
  pop    %r12
  pop    %r13
  pop    %r14
  pop    %r15
  ret
  nopl   0x0(%rax)
L407:
  xor    %eax,%eax
  call   <BIO_f_cipher@plt>
  mov    %eax,%edi
  call   <BIO_new@plt>
  mov    %rbx,%rcx
  mov    %r15,%rdx
  mov    %r13,%rsi
  mov    %rax,%rdi
  mov    $0x1,%r8d
  mov    %rax,%rbp
  call   <BIO_set_cipher@plt>
  xor    %ecx,%ecx
  mov    $0x36,%esi
  mov    %r14,%rdi
  test   %rax,%rax
  lea    D196(%rip),%rdx
  setne  %cl
  call   <test_true@plt>
  test   %eax,%eax
  je     L258
  mov    $0x400,%esi
  lea    D151(%rip),%rdi
  lea    0x460(%rsp),%r15
  call   <BIO_new_mem_buf@plt>
  mov    %rbp,%rdi
  mov    %eax,%esi
  call   <BIO_push@plt>
  mov    $0x420,%edx
  mov    %r15,%rsi
  mov    %rbp,%rdi
  mov    %r15,0x30(%rsp)
  call   <BIO_read@plt>
  mov    %rbp,%rdi
  mov    %eax,%ebx
  mov    %eax,0x24(%rsp)
  call   <BIO_free_all@plt>
  movslq %ebx,%rax
  cmp    $0x1,%eax
  jle    L397
  mov    %rax,0x28(%rsp)
  mov    $0x1,%r12d
  jmp    L25
  nopw   0x0(%rax,%rax,1)
L152:
  mov    $0x400,%esi
  lea    D151(%rip),%rdi
  lea    0x40(%rsp),%rbx
  call   <BIO_new_mem_buf@plt>
  mov    %rbp,%rdi
  mov    %eax,%esi
  call   <BIO_push@plt>
  xor    %esi,%esi
  mov    $0x420,%edx
  mov    %rbx,%rdi
  call   <memset@plt>
  movzbl (%r15,%r12,1),%eax
  mov    %rbx,%rsi
  mov    %rbp,%rdi
  mov    0x20(%rsp),%edx
  not    %eax
  mov    %al,0x40(%rsp,%r12,1)
  call   <BIO_read@plt>
  movzbl (%r15,%r12,1),%r9d
  mov    %r14,%rdi
  movzbl 0x40(%rsp,%r12,1),%r8d
  lea    D110(%rip),%rcx
  lea    D124(%rip),%rdx
  mov    $0x48,%esi
  mov    %eax,%r13d
  not    %r9d
  movzbl %r9b,%r9d
  call   <test_uchar_eq@plt>
  test   %eax,%eax
  je     L403
  movslq %r13d,%rsi
  mov    $0x420,%edx
  mov    %rbp,%rdi
  sub    %r13d,%edx
  add    %rbx,%rsi
  call   <BIO_read@plt>
  mov    %rbp,%rdi
  add    %eax,%r13d
  call   <BIO_free_all@plt>
  mov    0x24(%rsp),%eax
  mov    %r13d,%r9d
  mov    %rbx,%r8
  lea    D191(%rip),%rcx
  lea    D0(%rip),%rdx
  mov    $0x4f,%esi
  mov    %r14,%rdi
  push   %rax
  push   %r15
  call   <test_mem_eq@plt>
  pop    %r11
  pop    %rbp
  test   %eax,%eax
  je     L177
  add    $0x1,%r12
  cmp    0x28(%rsp),%r12
  je     L367
L25:
  xor    %eax,%eax
  mov    %r12d,0x20(%rsp)
  call   <BIO_f_cipher@plt>
  mov    %eax,%edi
  call   <BIO_new@plt>
  mov    0x18(%rsp),%rcx
  mov    0x10(%rsp),%rdx
  mov    $0x1,%r8d
  mov    0x8(%rsp),%rsi
  mov    %rax,%rdi
  mov    %rax,%rbp
  call   <BIO_set_cipher@plt>
  xor    %ecx,%ecx
  mov    $0x3f,%esi
  mov    %r14,%rdi
  test   %rax,%rax
  lea    D196(%rip),%rdx
  setne  %cl
  call   <test_true@plt>
  test   %eax,%eax
  jne    L152
  mov    0x20(%rsp),%r15d
  mov    $0x40,%esi
  mov    %r14,%rdi
  mov    %eax,0x20(%rsp)
  lea    D251(%rip),%rdx
  mov    %r15d,%ecx
  call   <test_info@plt>
  mov    0x20(%rsp),%r8d
  jmp    L136
  cs nopw 0x0(%rax,%rax,1)
L367:
  mov    0x24(%rsp),%ecx
  mov    %ecx,%eax
  shr    $0x1f,%eax
  add    %ecx,%eax
  sar    %eax
  mov    %eax,0x28(%rsp)
  cmp    $0x3,%ecx
  jle    L126
  mov    %eax,0x20(%rsp)
  mov    0x18(%rsp),%r15
  mov    $0x1,%r12d
  nopl   0x0(%rax)
L35:
  xor    %eax,%eax
  call   <BIO_f_cipher@plt>
  mov    %eax,%edi
  call   <BIO_new@plt>
  mov    0x10(%rsp),%rdx
  mov    0x8(%rsp),%rsi
  mov    %r15,%rcx
  mov    %rax,%rdi
  mov    $0x1,%r8d
  mov    %rax,%r13
  call   <BIO_set_cipher@plt>
  xor    %ecx,%ecx
  mov    $0x5a,%esi
  mov    %r14,%rdi
  test   %rax,%rax
  lea    D196(%rip),%rdx
  setne  %cl
  call   <test_true@plt>
  test   %eax,%eax
  je     L147
  mov    $0x400,%esi
  lea    D151(%rip),%rdi
  xor    %ebp,%ebp
  call   <BIO_new_mem_buf@plt>
  mov    %r13,%rdi
  mov    %eax,%esi
  call   <BIO_push@plt>
  mov    $0x420,%edx
  xor    %esi,%esi
  mov    %rbx,%rdi
  call   <memset@plt>
  jmp    L134
  xchg   %ax,%ax
L302:
  add    %eax,%ebp
L134:
  movslq %ebp,%rsi
  mov    %r12d,%edx
  mov    %r13,%rdi
  add    %rbx,%rsi
  call   <BIO_read@plt>
  test   %eax,%eax
  jne    L302
  mov    %r13,%rdi
  call   <BIO_free_all@plt>
  mov    0x24(%rsp),%eax
  mov    %ebp,%r9d
  mov    %rbx,%r8
  lea    D191(%rip),%rcx
  lea    D0(%rip),%rdx
  mov    $0x65,%esi
  mov    %r14,%rdi
  push   %rax
  push   0x38(%rsp)
  call   <test_mem_eq@plt>
  pop    %r9
  pop    %r10
  test   %eax,%eax
  je     L43
  add    $0x1,%r12d
  cmp    %r12d,0x20(%rsp)
  jg     L35
L126:
  xor    %eax,%eax
  call   <BIO_f_cipher@plt>
  mov    %eax,%edi
  call   <BIO_new@plt>
  mov    0x18(%rsp),%rcx
  mov    0x10(%rsp),%rdx
  xor    %r8d,%r8d
  mov    0x8(%rsp),%rsi
  mov    %rax,%rdi
  mov    %rax,%rbp
  call   <BIO_set_cipher@plt>
  xor    %ecx,%ecx
  mov    $0x6f,%esi
  mov    %r14,%rdi
  test   %rax,%rax
  lea    D180(%rip),%rdx
  setne  %cl
  call   <test_true@plt>
  test   %eax,%eax
  je     L258
  mov    0x24(%rsp),%r13d
  mov    0x30(%rsp),%r15
  lea    0x40(%rsp),%rbx
  mov    %r13d,%esi
  mov    %r15,%rdi
  call   <BIO_new_mem_buf@plt>
  mov    %rbp,%rdi
  mov    %eax,%esi
  call   <BIO_push@plt>
  mov    %rbp,%rdi
  call   <BIO_flush@plt>
  mov    $0x420,%edx
  xor    %esi,%esi
  mov    %rbx,%rdi
  call   <memset@plt>
  mov    $0x420,%edx
  mov    %rbx,%rsi
  mov    %rbp,%rdi
  call   <BIO_read@plt>
  mov    %rbp,%rdi
  mov    %eax,%r12d
  call   <BIO_free_all@plt>
  push   %r12
  mov    %r14,%rdi
  mov    $0x400,%r9d
  push   %rbx
  lea    D151(%rip),%r8
  lea    D0(%rip),%rcx
  mov    $0x78,%esi
  lea    D212(%rip),%rdx
  call   <test_mem_eq@plt>
  pop    %rdi
  pop    %r8
  test   %eax,%eax
  je     L258
  cmp    $0x1,%r13d
  jle    L320
  movslq %r13d,%rax
  mov    $0x1,%r13d
  mov    %rax,0x38(%rsp)
  jmp    L229
  nopl   0x0(%rax)
L375:
  mov    0x24(%rsp),%esi
  mov    %r15,%rdi
  call   <BIO_new_mem_buf@plt>
  mov    %rbp,%rdi
  mov    %eax,%esi
  call   <BIO_push@plt>
  xor    %esi,%esi
  mov    $0x420,%edx
  mov    %rbx,%rdi
  call   <memset@plt>
  movzbl (%r15,%r13,1),%eax
  mov    %rbx,%rsi
  mov    %rbp,%rdi
  mov    0x20(%rsp),%edx
  not    %eax
  mov    %al,(%rbx,%r13,1)
  call   <BIO_read@plt>
  movzbl (%r15,%r13,1),%r9d
  mov    %r14,%rdi
  movzbl (%rbx,%r13,1),%r8d
  lea    D110(%rip),%rcx
  lea    D124(%rip),%rdx
  mov    $0x87,%esi
  mov    %eax,%r12d
  not    %r9d
  movzbl %r9b,%r9d
  call   <test_uchar_eq@plt>
  test   %eax,%eax
  je     L19
  movslq %r12d,%rsi
  mov    $0x420,%edx
  mov    %rbp,%rdi
  sub    %r12d,%edx
  add    %rbx,%rsi
  call   <BIO_read@plt>
  mov    %rbp,%rdi
  add    %eax,%r12d
  call   <BIO_free_all@plt>
  push   %r12
  mov    $0x8e,%esi
  mov    %r14,%rdi
  push   %rbx
  lea    D0(%rip),%rcx
  mov    $0x400,%r9d
  lea    D151(%rip),%r8
  lea    D212(%rip),%rdx
  call   <test_mem_eq@plt>
  pop    %rcx
  pop    %rsi
  test   %eax,%eax
  je     L34
  add    $0x1,%r13
  cmp    0x38(%rsp),%r13
  je     L355
L229:
  xor    %eax,%eax
  mov    %r13d,0x20(%rsp)
  call   <BIO_f_cipher@plt>
  mov    %eax,%edi
  call   <BIO_new@plt>
  mov    0x18(%rsp),%rcx
  mov    0x10(%rsp),%rdx
  xor    %r8d,%r8d
  mov    0x8(%rsp),%rsi
  mov    %rax,%rdi
  mov    %rax,%rbp
  call   <BIO_set_cipher@plt>
  xor    %ecx,%ecx
  mov    $0x7e,%esi
  mov    %r14,%rdi
  test   %rax,%rax
  lea    D180(%rip),%rdx
  setne  %cl
  call   <test_true@plt>
  test   %eax,%eax
  jne    L375
  mov    0x20(%rsp),%r15d
  mov    $0x7f,%esi
  mov    %r14,%rdi
  mov    %eax,0x20(%rsp)
  lea    D307(%rip),%rdx
  mov    %r15d,%ecx
  call   <test_info@plt>
  mov    0x20(%rsp),%r8d
  jmp    L136
  nopl   0x0(%rax)
L403:
  mov    0x20(%rsp),%r15d
  mov    $0x49,%esi
  mov    %r14,%rdi
  mov    %eax,0x20(%rsp)
  lea    D345(%rip),%rdx
  mov    %r15d,%ecx
  call   <test_info@plt>
  mov    0x20(%rsp),%r8d
  jmp    L136
  nopw   0x0(%rax,%rax,1)
L177:
  mov    0x20(%rsp),%r15d
  mov    $0x50,%esi
  mov    %r14,%rdi
  mov    %eax,0x20(%rsp)
  lea    D172(%rip),%rdx
  mov    %r15d,%ecx
  call   <test_info@plt>
  mov    0x20(%rsp),%r8d
  jmp    L136
L147:
  mov    %r12d,%ecx
  mov    $0x5b,%esi
  mov    %r14,%rdi
  mov    %eax,0x20(%rsp)
  lea    D211(%rip),%rdx
  call   <test_info@plt>
  mov    0x20(%rsp),%r8d
  jmp    L136
L43:
  mov    %r12d,%ecx
  mov    $0x66,%esi
  mov    %r14,%rdi
  mov    %eax,0x20(%rsp)
  lea    D72(%rip),%rdx
  call   <test_info@plt>
  mov    0x20(%rsp),%r8d
  jmp    L136
L397:
  mov    0x24(%rsp),%ecx
  mov    %ecx,%eax
  shr    $0x1f,%eax
  add    %ecx,%eax
  sar    %eax
  mov    %eax,0x28(%rsp)
  jmp    L126
L355:
  cmpl   $0x3,0x24(%rsp)
  jle    L320
  mov    $0x1,%r12d
  lea    D151(%rip),%rbp
L9:
  xor    %eax,%eax
  call   <BIO_f_cipher@plt>
  mov    %eax,%edi
  call   <BIO_new@plt>
  mov    0x18(%rsp),%rcx
  mov    0x10(%rsp),%rdx
  xor    %r8d,%r8d
  mov    0x8(%rsp),%rsi
  mov    %rax,%rdi
  mov    %rax,%r15
  call   <BIO_set_cipher@plt>
  xor    %ecx,%ecx
  mov    $0x99,%esi
  mov    %r14,%rdi
  test   %rax,%rax
  lea    D180(%rip),%rdx
  setne  %cl
  call   <test_true@plt>
  test   %eax,%eax
  je     L121
  mov    0x24(%rsp),%esi
  mov    0x30(%rsp),%rdi
  xor    %r13d,%r13d
  call   <BIO_new_mem_buf@plt>
  mov    %r15,%rdi
  mov    %eax,%esi
  call   <BIO_push@plt>
  mov    $0x420,%edx
  xor    %esi,%esi
  mov    %rbx,%rdi
  call   <memset@plt>
  jmp    L54
  nopl   (%rax)
L264:
  add    %eax,%r13d
L54:
  movslq %r13d,%rsi
  mov    %r12d,%edx
  mov    %r15,%rdi
  add    %rbx,%rsi
  call   <BIO_read@plt>
  test   %eax,%eax
  jne    L264
  mov    %r15,%rdi
  call   <BIO_free_all@plt>
  push   %r13
  mov    %rbp,%r8
  mov    $0x400,%r9d
  push   %rbx
  lea    D212(%rip),%rdx
  mov    $0xa4,%esi
  mov    %r14,%rdi
  lea    D0(%rip),%rcx
  call   <test_mem_eq@plt>
  mov    %eax,%r8d
  pop    %rax
  pop    %rdx
  test   %r8d,%r8d
  je     L55
  add    $0x1,%r12d
  cmp    0x28(%rsp),%r12d
  jl     L9
L320:
  mov    $0x1,%r8d
  jmp    L136
L34:
  mov    0x20(%rsp),%r15d
  mov    $0x8f,%esi
  mov    %r14,%rdi
  mov    %eax,0x20(%rsp)
  lea    D73(%rip),%rdx
  mov    %r15d,%ecx
  call   <test_info@plt>
  mov    0x20(%rsp),%r8d
  jmp    L136
L19:
  mov    0x20(%rsp),%r15d
  mov    $0x88,%esi
  mov    %r14,%rdi
  mov    %eax,0x20(%rsp)
  lea    D76(%rip),%rdx
  mov    %r15d,%ecx
  call   <test_info@plt>
  mov    0x20(%rsp),%r8d
  jmp    L136
L349:
  call   <__stack_chk_fail@plt>
L55:
  mov    %r12d,%ecx
  mov    $0xa5,%esi
  mov    %r14,%rdi
  mov    %r8d,0x20(%rsp)
  lea    D147(%rip),%rdx
  call   <test_info@plt>
  mov    0x20(%rsp),%r8d
  jmp    L136
L121:
  mov    %r12d,%ecx
  mov    $0x9a,%esi
  mov    %r14,%rdi
  mov    %eax,0x20(%rsp)
  lea    D304(%rip),%rdx
  call   <test_info@plt>
  mov    0x20(%rsp),%r8d
  jmp    L136
```

tool_calls: name: unpack_data
arguments: label: D189
type_guessed: string
name: unpack_data
arguments: label: D216
type_guessed: string
name: unpack_data
arguments: label: D284
type_guessed: string
name: unpack_data
arguments: label: D196
type_guessed: string
name: unpack_data
arguments: label: D110
type_guessed: string
name: unpack_data
arguments: label: D124
type_guessed: string
name: unpack_data
arguments: label: D191
type_guessed: string
name: unpack_data
arguments: label: D0
type_guessed: string
name: unpack_data
arguments: label: D251
type_guessed: string
name: unpack_data
arguments: label: D180
type_guessed: string
name: unpack_data
arguments: label: D212
type_guessed: string
name: unpack_data
arguments: label: D307
type_guessed: string
name: unpack_data
arguments: label: D345
type_guessed: string
name: unpack_data
arguments: label: D172
type_guessed: string
name: unpack_data
arguments: label: D211
type_guessed: string
name: unpack_data
arguments: label: D72
type_guessed: string
name: unpack_data
arguments: label: D73
type_guessed: string
name: unpack_data
arguments: label: D76
type_guessed: string
name: unpack_data
arguments: label: D147
type_guessed: string
name: unpack_data
arguments: label: D304
type_guessed: string

tool: D189: /scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c

tool: D216: 0

tool: D284: RAND_bytes(inp, DATA_SIZE)

tool: D196: BIO_set_cipher(b, cipher, key, iv, ENCRYPT)

tool: D110: (unsigned char)~ref[i]

tool: D124: out[i]

tool: D191: ref

tool: D0: out

tool: D251: Split encrypt failed @ operation %d

tool: D180: BIO_set_cipher(b, cipher, key, iv, DECRYPT)

tool: D212: inp

tool: D307: Split decrypt failed @ operation %d

tool: D345: Encrypt overstep check failed @ operation %d

tool: D172: Encrypt compare failed @ operation %d

tool: D211: Small chunk encrypt failed @ operation %d

tool: D72: Small chunk encrypt compare failed @ operation %d

tool: D73: Decrypt compare failed @ operation %d

tool: D76: Decrypt overstep check failed @ operation %d

tool: D147: Small chunk decrypt compare failed @ operation %d

tool: D304: Small chunk decrypt failed @ operation %d

assistant: ```c
int do_bio_cipher(const EVP_CIPHER *cipher, const unsigned char *key, const unsigned char *iv) {
  BIO *b;
  static unsigned char inp[(1024 + 32)] = {0};
  unsigned char out[(1024 + 32)], ref[(1024 + 32)];
  int i, lref, len;
  if (!test_int_gt("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 47, "RAND_bytes(inp, DATA_SIZE)", "0", RAND_bytes(inp, 1024), 0))
    return 0;
  b = BIO_new(BIO_f_cipher());
  if (!test_true("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 54, "BIO_set_cipher(b, cipher, key, iv, ENCRYPT)", (BIO_set_cipher(b, cipher, key, iv, 1)) != 0))
    return 0;
  BIO_push(b, BIO_new_mem_buf(inp, 1024));
  lref = BIO_read(b, ref, sizeof(ref));
  BIO_free_all(b);
  for (i = 1; i < lref; i++) {
    b = BIO_new(BIO_f_cipher());
    if (!test_true("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 63, "BIO_set_cipher(b, cipher, key, iv, ENCRYPT)", (BIO_set_cipher(b, cipher, key, iv, 1)) != 0)) {
      test_info("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 64, "Split encrypt failed @ operation %d", i);
      return 0;
    }
    BIO_push(b, BIO_new_mem_buf(inp, 1024));
    memset(out, 0, sizeof(out));
    out[i] = ~ref[i];
    len = BIO_read(b, out, i);
    if (!test_uchar_eq("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 72, "out[i]", "(unsigned char)~ref[i]", out[i], (unsigned char)~ref[i])) {
      test_info("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 73, "Encrypt overstep check failed @ operation %d", i);
      return 0;
    }
    len += BIO_read(b, out + len, sizeof(out) - len);
    BIO_free_all(b);
    if (!test_mem_eq("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 79, "out", "ref", out, len, ref, lref)) {
      test_info("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 80, "Encrypt compare failed @ operation %d", i);
      return 0;
    }
  }
  for (i = 1; i < lref / 2; i++) {
    int delta;
    b = BIO_new(BIO_f_cipher());
    if (!test_true("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 90, "BIO_set_cipher(b, cipher, key, iv, ENCRYPT)", (BIO_set_cipher(b, cipher, key, iv, 1)) != 0)) {
      test_info("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 91, "Small chunk encrypt failed @ operation %d", i);
      return 0;
    }
    BIO_push(b, BIO_new_mem_buf(inp, 1024));
    memset(out, 0, sizeof(out));
    for (len = 0; (delta = BIO_read(b, out + len, i));) {
      len += delta;
    }
    BIO_free_all(b);
    if (!test_mem_eq("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 101, "out", "ref", out, len, ref, lref)) {
      test_info("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 102, "Small chunk encrypt compare failed @ operation %d", i);
      return 0;
    }
  }
  b = BIO_new(BIO_f_cipher());
  if (!test_true("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 111, "BIO_set_cipher(b, cipher, key, iv, DECRYPT)", (BIO_set_cipher(b, cipher, key, iv, 0)) != 0))
    return 0;
  BIO_push(b, BIO_new_mem_buf(ref, lref));
  (void)BIO_flush(b);
  memset(out, 0, sizeof(out));
  len = BIO_read(b, out, sizeof(out));
  BIO_free_all(b);
  if (!test_mem_eq("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 120, "inp", "out", inp, 1024, out, len))
    return 0;
  for (i = 1; i < lref; i++) {
    b = BIO_new(BIO_f_cipher());
    if (!test_true("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 126, "BIO_set_cipher(b, cipher, key, iv, DECRYPT)", (BIO_set_cipher(b, cipher, key, iv, 0)) != 0)) {
      test_info("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 127, "Split decrypt failed @ operation %d", i);
      return 0;
    }
    BIO_push(b, BIO_new_mem_buf(ref, lref));
    memset(out, 0, sizeof(out));
    out[i] = ~ref[i];
    len = BIO_read(b, out, i);
    if (!test_uchar_eq("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 135, "out[i]", "(unsigned char)~ref[i]", out[i], (unsigned char)~ref[i])) {
      test_info("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 136, "Decrypt overstep check failed @ operation %d", i);
      return 0;
    }
    len += BIO_read(b, out + len, sizeof(out) - len);
    BIO_free_all(b);
    if (!test_mem_eq("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 142, "inp", "out", inp, 1024, out, len)) {
      test_info("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 143, "Decrypt compare failed @ operation %d", i);
      return 0;
    }
  }
  for (i = 1; i < lref / 2; i++) {
    int delta;
    b = BIO_new(BIO_f_cipher());
    if (!test_true("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 153, "BIO_set_cipher(b, cipher, key, iv, DECRYPT)", (BIO_set_cipher(b, cipher, key, iv, 0)) != 0)) {
      test_info("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 154, "Small chunk decrypt failed @ operation %d", i);
      return 0;
    }
    BIO_push(b, BIO_new_mem_buf(ref, lref));
    memset(out, 0, sizeof(out));
    for (len = 0; (delta = BIO_read(b, out + len, i));) {
      len += delta;
    }
    BIO_free_all(b);
    if (!test_mem_eq("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 164, "inp", "out", inp, 1024, out, len)) {
      test_info("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/artclarke/humble-video/refs/heads/master/humble-video-captive/src/main/gnu/openssl/csrc/test/bio_enc_test.c", 165, "Small chunk decrypt compare failed @ operation %d", i);
      return 0;
    }
  }
  return 1;
}
```