Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8757491
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T14:18:52+00:00 2026-06-13T14:18:52+00:00

We are trying to read in a public key file into our Delphi application

  • 0

We are trying to read in a public key file into our Delphi application so that we can use it for encrypting some data using OpenSSL. We are stuck at trying to populate the pRSA structure in libeay32.pas.

Basically we have read the modulus and exponent out of the pke file, base 64 decoded them and stored the decoded value in a buffer of type Byte.

From what we can tell these now need to be converted into a BIGNUM structure. Libeay32 provides a function BN_bin2bn function which accepts a pointer an output a pBIGNUM.

The question is, can we pass the modulus and exponent buffers directly to BN_bin2bn or do they first need to be converted to a format compatible with the BN_bin2bn function?

We are using Delphi 2007.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T14:18:53+00:00Added an answer on June 13, 2026 at 2:18 pm

    I’ve solved this. There is no conversion required. The Modulus and Exponent can be base 64 decoded into a buffer and then passed straight into the BN_bin2bn function as is

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to use PHP and OpenSSL to encrypt some data using a public
I am trying to read data from a file and use the data for
I'm trying to encrypt some binary data in Java with a public key as
I am trying to read a config file which has some key value pairs
I'm trying to read in file content, ex : public void myMethod(){ FileInputStream fstream
I am trying to read in an XML file that I have saved to
I am trying to devise a security scheme for encrypting the application level data
When trying to read a RSA private key from a file using the method
I am trying to read from a constants file the key value pair. It
I am trying to make a program that after it generates a public/private key

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.