user: Translate the below assembly code into C programming language:

```asm
<SSL_CTX_use_RSAPrivateKey_file>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  push   %rbx
  sub    $0x48,%rsp
  mov    %rdi,-0x38(%rbp)
  mov    %rsi,-0x40(%rbp)
  mov    %edx,-0x44(%rbp)
  movl   $0x0,-0x24(%rbp)
  movq   $0x0,-0x20(%rbp)
  mov    $0x0,%eax
  call   <BIO_s_file@plt>
  mov    %eax,%edi
  call   <BIO_new@plt>
  mov    %rax,-0x18(%rbp)
  cmpq   $0x0,-0x18(%rbp)
  jne    L8
  mov    D21(%rip),%rax
  mov    (%rax),%edx
  mov    D12(%rip),%rax
  mov    (%rax),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <ERR_raise@plt>
  jmp    L47
L8:
  mov    -0x40(%rbp),%rdx
  mov    -0x18(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <BIO_read_filename@plt>
  test   %rax,%rax
  jg     L15
  mov    D18(%rip),%rax
  mov    (%rax),%edx
  mov    D12(%rip),%rax
  mov    (%rax),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <ERR_raise@plt>
  jmp    L47
L15:
  mov    D22(%rip),%rax
  mov    (%rax),%eax
  cmp    %eax,-0x44(%rbp)
  jne    L108
  mov    D13(%rip),%rax
  mov    (%rax),%eax
  mov    %eax,-0x28(%rbp)
  mov    -0x18(%rbp),%rax
  mov    $0x0,%esi
  mov    %rax,%rdi
  call   <d2i_RSAPrivateKey_bio@plt>
  mov    %rax,-0x20(%rbp)
  jmp    L22
L108:
  mov    D43(%rip),%rax
  mov    (%rax),%eax
  cmp    %eax,-0x44(%rbp)
  jne    L98
  mov    D65(%rip),%rax
  mov    (%rax),%eax
  mov    %eax,-0x28(%rbp)
  mov    -0x38(%rbp),%rax
  mov    %rax,%rdi
  call   <SSL_CTX_get_default_passwd_cb_userdata@plt>
  mov    %eax,%ebx
  mov    -0x38(%rbp),%rax
  mov    %rax,%rdi
  call   <SSL_CTX_get_default_passwd_cb@plt>
  mov    %eax,%edx
  mov    -0x18(%rbp),%rax
  mov    %ebx,%ecx
  mov    $0x0,%esi
  mov    %rax,%rdi
  call   <PEM_read_bio_RSAPrivateKey@plt>
  mov    %rax,-0x20(%rbp)
  jmp    L22
L98:
  mov    D88(%rip),%rax
  mov    (%rax),%edx
  mov    D12(%rip),%rax
  mov    (%rax),%eax
  mov    %edx,%esi
  mov    %eax,%edi
  call   <ERR_raise@plt>
  jmp    L47
L22:
  cmpq   $0x0,-0x20(%rbp)
  jne    L23
  mov    D12(%rip),%rax
  mov    (%rax),%eax
  mov    -0x28(%rbp),%edx
  mov    %edx,%esi
  mov    %eax,%edi
  call   <ERR_raise@plt>
  jmp    L47
L23:
  mov    -0x20(%rbp),%rdx
  mov    -0x38(%rbp),%rax
  mov    %rdx,%rsi
  mov    %rax,%rdi
  call   <SSL_CTX_use_RSAPrivateKey@plt>
  mov    %eax,-0x24(%rbp)
  mov    -0x20(%rbp),%rax
  mov    %rax,%rdi
  call   <RSA_free@plt>
L47:
  mov    -0x18(%rbp),%rax
  mov    %rax,%rdi
  call   <BIO_free@plt>
  mov    -0x24(%rbp),%eax
  mov    -0x8(%rbp),%rbx
  leave
  ret
```

assistant: ```c
int SSL_CTX_use_RSAPrivateKey_file(SSL_CTX *ctx, const char *file, int type) {
  int j, ret = 0;
  BIO *in;
  RSA *rsa = NULL;
  in = BIO_new(BIO_s_file());
  if (in == NULL) {
    ERR_raise(ERR_LIB_SSL, ERR_R_BUF_LIB);
    goto end;
  }
  if (BIO_read_filename(in, file) <= 0) {
    ERR_raise(ERR_LIB_SSL, ERR_R_SYS_LIB);
    goto end;
  }
  if (type == SSL_FILETYPE_ASN1) {
    j = ERR_R_ASN1_LIB;
    rsa = d2i_RSAPrivateKey_bio(in, NULL);
  } else if (type == SSL_FILETYPE_PEM) {
    j = ERR_R_PEM_LIB;
    rsa = PEM_read_bio_RSAPrivateKey(in, NULL, SSL_CTX_get_default_passwd_cb(ctx), SSL_CTX_get_default_passwd_cb_userdata(ctx));
  } else {
    ERR_raise(ERR_LIB_SSL, SSL_R_BAD_SSL_FILETYPE);
    goto end;
  }
  if (rsa == NULL) {
    ERR_raise(ERR_LIB_SSL, j);
    goto end;
  }
  ret = SSL_CTX_use_RSAPrivateKey(ctx, rsa);
  RSA_free(rsa);
end:
  BIO_free(in);
  return ret;
}
```