user: What is the c source code of the assembly code below?

```asm
<pkcs7_decrypt_rinfo>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  sub    $0x50,%rsp
  mov    %rdi,-0x38(%rbp)
  mov    %rsi,-0x40(%rbp)
  mov    %rdx,-0x48(%rbp)
  mov    %rcx,-0x50(%rbp)
  mov    %fs:0x28,%rax
  mov    %rax,-0x8(%rbp)
  xor    %eax,%eax
  movq   $0x0,-0x10(%rbp)
  movq   $0x0,-0x18(%rbp)
  movl   $0xffffffff,-0x24(%rbp)
  mov    -0x50(%rbp),%rax
  mov    $0x0,%esi
  mov    %rax,%rdi
  call   <EVP_PKEY_CTX_new@plt>
  mov    %rax,-0x10(%rbp)
  cmpq   $0x0,-0x10(%rbp)
  jne    L21
  mov    $0xffffffff,%eax
  jmp    L132
L21:
  mov    -0x10(%rbp),%rax
  mov    %rax,%rdi
  call   <EVP_PKEY_decrypt_init@plt>
  test   %rax,%rax
  jle    L69
  mov    D25(%rip),%rax
  mov    (%rax),%ecx
  mov    D5(%rip),%rax
  mov    (%rax),%edx
  mov    -0x48(%rbp),%rsi
  mov    -0x10(%rbp),%rax
  mov    %rsi,%r9
  mov    $0x0,%r8d
  mov    $0xffffffff,%esi
  mov    %rax,%rdi
  call   <EVP_PKEY_CTX_ctrl@plt>
  test   %rax,%rax
  jg     L59
  mov    D47(%rip),%rax
  mov    (%rax),%edx
  mov    D26(%rip),%rax
  mov    (%rax),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <PKCS7err@plt>
  jmp    L106
L59:
  mov    -0x48(%rbp),%rax
  mov    (%rax),%rax
  mov    (%rax),%esi
  mov    -0x48(%rbp),%rax
  mov    (%rax),%rax
  mov    0x4(%rax),%ecx
  lea    -0x20(%rbp),%rdx
  mov    -0x10(%rbp),%rax
  mov    %esi,%r8d
  mov    $0x0,%esi
  mov    %rax,%rdi
  call   <EVP_PKEY_decrypt@plt>
  test   %rax,%rax
  jle    L121
  mov    -0x20(%rbp),%rax
  mov    %rax,%rdi
  call   <malloc@plt>
  mov    %rax,-0x18(%rbp)
  cmpq   $0x0,-0x18(%rbp)
  jne    L40
  mov    D75(%rip),%rax
  mov    (%rax),%edx
  mov    D26(%rip),%rax
  mov    (%rax),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <PKCS7err@plt>
  jmp    L106
L40:
  mov    -0x48(%rbp),%rax
  mov    (%rax),%rax
  mov    (%rax),%edi
  mov    -0x48(%rbp),%rax
  mov    (%rax),%rax
  mov    0x4(%rax),%ecx
  lea    -0x20(%rbp),%rdx
  mov    -0x18(%rbp),%rsi
  mov    -0x10(%rbp),%rax
  mov    %edi,%r8d
  mov    %rax,%rdi
  call   <EVP_PKEY_decrypt@plt>
  test   %rax,%rax
  jg     L140
  movl   $0x0,-0x24(%rbp)
  mov    D56(%rip),%rax
  mov    (%rax),%edx
  mov    D26(%rip),%rax
  mov    (%rax),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <PKCS7err@plt>
  jmp    L106
L140:
  movl   $0x1,-0x24(%rbp)
  mov    -0x38(%rbp),%rax
  mov    (%rax),%rax
  test   %rax,%rax
  je     L56
  mov    -0x40(%rbp),%rax
  mov    (%rax),%edx
  mov    -0x38(%rbp),%rax
  mov    (%rax),%rax
  mov    %edx,%esi
  mov    %rax,%rdi
  call   <OPENSSL_cleanse@plt>
  mov    -0x38(%rbp),%rax
  mov    (%rax),%rax
  mov    %rax,%rdi
  call   <free@plt>
L56:
  mov    -0x38(%rbp),%rax
  mov    -0x18(%rbp),%rdx
  mov    %rdx,(%rax)
  mov    -0x20(%rbp),%rax
  mov    %eax,%edx
  mov    -0x40(%rbp),%rax
  mov    %edx,(%rax)
  jmp    L106
L69:
  nop
  jmp    L106
L121:
  nop
L106:
  mov    -0x10(%rbp),%rax
  mov    %rax,%rdi
  call   <EVP_PKEY_CTX_free@plt>
  cmpl   $0x0,-0x24(%rbp)
  jne    L27
  cmpq   $0x0,-0x18(%rbp)
  je     L27
  mov    -0x18(%rbp),%rax
  mov    %rax,%rdi
  call   <free@plt>
L27:
  mov    -0x24(%rbp),%eax
L132:
  mov    -0x8(%rbp),%rdx
  sub    %fs:0x28,%rdx
  je     L137
  call   <__stack_chk_fail@plt>
L137:
  leave
  ret
```

assistant: ```c
int pkcs7_decrypt_rinfo(unsigned char **pek, int *peklen, PKCS7_RECIP_INFO *ri, EVP_PKEY *pkey) {
  EVP_PKEY_CTX *pctx = NULL;
  unsigned char *ek = NULL;
  size_t eklen;
  int ret = -1;
  pctx = EVP_PKEY_CTX_new(pkey, NULL);
  if (!pctx)
    return -1;
  if (EVP_PKEY_decrypt_init(pctx) <= 0)
    goto err;
  if (EVP_PKEY_CTX_ctrl(pctx, -1, EVP_PKEY_OP_DECRYPT, EVP_PKEY_CTRL_PKCS7_DECRYPT, 0, ri) <= 0) {
    PKCS7err(PKCS7_F_PKCS7_DECRYPT_RINFO, PKCS7_R_CTRL_ERROR);
    goto err;
  }
  if (EVP_PKEY_decrypt(pctx, NULL, &eklen, ri->enc_key->data, ri->enc_key->length) <= 0)
    goto err;
  ek = malloc(eklen);
  if (ek == NULL) {
    PKCS7err(PKCS7_F_PKCS7_DECRYPT_RINFO, ERR_R_MALLOC_FAILURE);
    goto err;
  }
  if (EVP_PKEY_decrypt(pctx, ek, &eklen, ri->enc_key->data, ri->enc_key->length) <= 0) {
    ret = 0;
    PKCS7err(PKCS7_F_PKCS7_DECRYPT_RINFO, ERR_R_EVP_LIB);
    goto err;
  }
  ret = 1;
  if (*pek) {
    OPENSSL_cleanse(*pek, *peklen);
    free(*pek);
  }
  *pek = ek;
  *peklen = eklen;
err:
  EVP_PKEY_CTX_free(pctx);
  if (!ret && ek)
    free(ek);
  return ret;
}
```