Re: RSA private key file created with Windows10

2022-10-05 Thread Tomas Mraz
On Wed, 2022-10-05 at 16:35 +0900, Imazu Setsuo wrote: > Thank you immediately answer. > > PKCS8, PEM, and RFC4716 formats were created and tested with the ssh- > keygen command. > > PKCS8 and PEM formatting was successful. > > RFC4716 is the default on Windows10, and PEM is the default on > Cen

Re: RSA private key file created with Windows10

2022-10-05 Thread Imazu Setsuo
Thank you immediately answer. PKCS8, PEM, and RFC4716 formats were created and tested with the ssh-keygen command. PKCS8 and PEM formatting was successful. RFC4716 is the default on Windows10, and PEM is the default on CentOS7. Does OpenSSL have any plans to support RFC4716 format in the futu

Re: RSA private key file created with Windows10

2022-10-04 Thread Tomas Mraz
Hello, most probably the key is stored in the OpenSSH private key format. You'll need to use ssh-keygen -p -m PKCS8 to convert the key into a format that OpenSSL can read. Tomas Mraz, OpenSSL On Wed, 2022-10-05 at 15:00 +0900, Imazu Setsuo wrote: > Hello. > > When I read the RSA private key file

Re: RSA signed ECDSA certificate still uses ECDSA for authentication

2022-08-26 Thread Viktor Dukhovni
On Fri, Aug 26, 2022 at 01:28:21PM -0700, radiatejava wrote: > >> and then the same ECDSA key verified by the CA to sign a hash over the > >> transcript of the handshake itself > > Which part of the TLS handshake you are talking about? Are you talking > about the three messages from the client to

Re: RSA signed ECDSA certificate still uses ECDSA for authentication

2022-08-26 Thread radiatejava
>> and then the same ECDSA key verified by the CA to sign a hash over the >> transcript of the handshake itself Which part of the TLS handshake you are talking about? Are you talking about the three messages from the client to server messages that are - ClientKeyExchange, ChangeCipherSpec, ClientF

Re: RSA signed ECDSA certificate still uses ECDSA for authentication

2022-08-26 Thread Nicola Tuveri
I'll give it a try. The Certification Authority (CA) that released the certificate has an RSA key. That was used to generate the signature in the cert, that tells users that the CA verified the Certificate Subject identity and that they hold the secret key associated with the Subject's Public Key.

Re: RSA test vectors, etc.

2022-04-27 Thread William Roberts
On Wed, Apr 27, 2022 at 11:46 AM Philip Prindeville wrote: > > Oh, forgot one other issue: > > I also need to pick apart the RSA keys into their constituent exponents, > modulus, etc. as BN's that I can then compare to bit-strings. > > With the old RSA_* routines this was trivial. How does one d

Re: RSA test vectors, etc.

2022-04-27 Thread Philip Prindeville
Oh, forgot one other issue: I also need to pick apart the RSA keys into their constituent exponents, modulus, etc. as BN's that I can then compare to bit-strings. With the old RSA_* routines this was trivial. How does one do this with the EVP_PKEY_* interface so that it works with 1.1.x and 3.

Re: RSA and DES encryption and decryption with C++ on Windows

2022-04-11 Thread Dr Paul Dale
aster/demos/encrypt Matthias *From:*openssl-users *On Behalf Of *John Alway *Sent:* Monday, April 11, 2022 7:06 PM *Cc:* openssl-users@openssl.org *Subject:* Re: RSA and DES encryption and decryption with C++ on Windows Pauli, Thanks for the link, but apparently that code requires havi

RE: RSA and DES encryption and decryption with C++ on Windows

2022-04-11 Thread Dr. Matthias St. Pierre
@openssl.org Subject: Re: RSA and DES encryption and decryption with C++ on Windows Pauli, Thanks for the link, but apparently that code requires having an account to view it. However, I've passed the information from this thread onto the guy I'm working with and he's going to ree

Re: RSA and DES encryption and decryption with C++ on Windows

2022-04-11 Thread John Alway
Pauli, Thanks for the link, but apparently that code requires having an account to view it. However, I've passed the information from this thread onto the guy I'm working with and he's going to reevaluate what he wants to do. Regards, ...John

Re: RSA and DES encryption and decryption with C++ on Windows

2022-04-10 Thread Dr Paul Dale
Have a look in the demos/encrypt folder: https://github.openssl.org/openssl/openssl/tree/master/demos/encrypt There has been an amount of effort put into updating these for 3.0 & later.  There is more to do. Pauli On 10/4/22 23:50, Kenneth Goldman wrote: Anyway, I'm trying to encrypt/decr

Re: RSA and DES encryption and decryption with C++ on Windows

2022-04-10 Thread John Alway
Thank you and Kenneth for your replies. I was given this task by someone with all of these specifics, including the site to download the library. Most of the terminology about encryption I'm not familiar with, but I'm learning. I've passed both of your posts and the wisdom in them on to him to

RE: RSA and DES encryption and decryption with C++ on Windows

2022-04-10 Thread Michael Wojcik
> From: openssl-users On Behalf Of John > Alway > Sent: Saturday, 9 April, 2022 19:45 > From this site https://slproweb.com/products/Win32OpenSSL.html >  I downloaded " Win32 OpenSSL v3.0.2" MSI  Well, I suppose that's one option. Personally I would not use a build from some random website; I'

RE: RSA and DES encryption and decryption with C++ on Windows

2022-04-10 Thread Kenneth Goldman
Anyway, I'm trying to encrypt/decrypt using RSA and DES schemes. I've tried some of the older code examples I could find, but some of the functions weren't recognized by my header files. [kgold] You cannot encrypt long streams with RSA. DES is deprecated. Can anyone help me with this? I want

Re: RSA provider use example

2021-09-27 Thread Matt Caswell
On 24/09/2021 16:51, Antonio Santagiuliana wrote: Thank you for your reply. I'm still a bit confused though. In /providers/implementations/asymcipher/rsa_enc.c I find function rsa_decrypt() that calls RSA_private_decrypt(prsactx->rsa) I haven't found other implementation of this RSA_private_de

Re: RSA provider use example

2021-09-24 Thread Antonio Santagiuliana
Thank you for your reply. I'm still a bit confused though. In /providers/implementations/asymcipher/rsa_enc.c I find function rsa_decrypt() that calls RSA_private_decrypt(prsactx->rsa) I haven't found other implementation of this RSA_private_decrypt() apart from the one in crypto/RSA/rsa_crypt.c ,

Re: RSA provider use example

2021-09-24 Thread Matt Caswell
On 24/09/2021 14:49, Antonio Santagiuliana wrote: Hello , thank you all for the replies. Very useful. I have seen in Openssl/crypto/RSA/rsa_local.h the definition of rsa_st has a pointer to RSA_METHOD and I can't see this filled in in any of the examples' set up or initializations, where is

Re: RSA provider use example

2021-09-24 Thread Antonio Santagiuliana
Hello , thank you all for the replies. Very useful. I have seen in Openssl/crypto/RSA/rsa_local.h the definition of rsa_st has a pointer to RSA_METHOD and I can't see this filled in in any of the examples' set up or initializations, where is it filled in for the default provider , for the RSA algor

Re: RSA provider use example

2021-09-24 Thread Matt Caswell
On 24/09/2021 12:17, Dr Paul Dale wrote: What about: apps/rsa.c, apps/rsautl.c and apps/genrsa.c 3.0 doesn't use the RSA structure in the non-deprecated public API. You probably want the EVP_PKEY_fromdata call. An example of building an RSA key from its constituent parts is available on th

Re: RSA provider use example

2021-09-24 Thread Dr Paul Dale
On 24/9/21 9:15 pm, Angus Robertson - Magenta Systems Ltd wrote: I've been wondering if this is more efficient than getting the parameters one at a time using multiple EVP_PKEY_get_xx_param which also calls EVP_PKEY_get_params. I'd be surprised if there was a lot of difference. If I had to g

Re: RSA provider use example

2021-09-24 Thread Matt Caswell
On 24/09/2021 11:55, Antonio Santagiuliana wrote: Hello Is there any app or command in the current Openssl master repository that initialises and uses the new RSA provider? I would like to see how the RSA* context parameter is filled in and used, but I can't find an example using the RSA pro

Re: RSA provider use example

2021-09-24 Thread Dr Paul Dale
What about: apps/rsa.c, apps/rsautl.c and apps/genrsa.c 3.0 doesn't use the RSA structure in the non-deprecated public API. You probably want the EVP_PKEY_fromdata call. Pauli On 24/9/21 8:55 pm, Antonio Santagiuliana wrote: Hello Is there any app or command in the current Openssl master rep

Re: RSA provider use example

2021-09-24 Thread Angus Robertson - Magenta Systems Ltd
> I would like to see how the RSA* context parameter is filled in > and used, but I can't find an example using the RSA provider. This is an example I just created by building a OSSL_PARAM array with OSSL_PARAM_construct_xx and calling EVP_PKEY_get_params. I've been wondering if this is more e

Re: RSA private key DER decode fails without CRT components

2021-08-31 Thread Brahmaji K
Hi, I could see this with openssl version 1.1.1d. Sure I'll update. On Tue, Aug 31, 2021 at 1:34 PM Dmitry Belyavsky wrote: > Hello, > > First, may I ask you which version of OpenSSL do you use? > Secondly, could you please report the issue via GitHub to make sure that > it will not be lost? >

Re: RSA private key DER decode fails without CRT components

2021-08-31 Thread Dmitry Belyavsky
Hello, First, may I ask you which version of OpenSSL do you use? Secondly, could you please report the issue via GitHub to make sure that it will not be lost? On Tue, Aug 31, 2021 at 10:01 AM Brahmaji K wrote: > Hi Team, > > I'm trying to decode the RSA private key which was DER encoded earlier

Re: RSA-OAEP Certificate

2021-01-21 Thread Richard Levitte
On Wed, 20 Jan 2021 02:24:24 +0100, Viktor Dukhovni wrote: > > On Tue, Jan 19, 2021 at 06:26:23PM -0500, Russ Housley wrote: > > > I am looking a test certificate that contains an RSA-OAEP subject > > public key (OID = id-RSAES-OAEP from RFC 4055) and is signed with > > RSA-PSS (OID = id-RSASSA-P

Re: RSA-OAEP Certificate

2021-01-19 Thread Viktor Dukhovni
On Tue, Jan 19, 2021 at 06:26:23PM -0500, Russ Housley wrote: > I am looking a test certificate that contains an RSA-OAEP subject > public key (OID = id-RSAES-OAEP from RFC 4055) and is signed with > RSA-PSS (OID = id-RSASSA-PSS also from RFC 4055). I have not ben able > to find a way to generate

Re: "rsa->meth->rsa_sign" method in Openssl 1.1.1g

2020-07-22 Thread Matt Caswell
On 21/07/2020 20:19, prudvi raj wrote: > > While upgrading to openssl 1.1.1 from 1.0.2k . > I came across this code snippet : >     if (rsa->flags & RSA_FLAG_SIGN_VER) >         return rsa->meth->rsa_sign (type, m, lLen, sigret, siglen, rsa); > > From Docs : > Enhance RSA_METHOD structure. Now

Re: RSA-PSS - Backwards compatability - EVP_PKEY_get0_RSA

2020-02-10 Thread Matt Caswell
On 07/02/2020 18:14, Pedro Lopes wrote: > Hello, > > I'm assigning the RSA key as EVP_PKEY_RSA_PSS: > RSA* key; > EVP_PKEY_assign(*outKey, EVP_PKEY_RSA_PSS, key); > > As is known EVP_PKEY_get0_RSA was recently updated to also accepts > EVP_PKEY_RSA_PSS and return the rsa value. > > I'd like t

Re: RSA digital signature verification failure with openssl 1.1.0j

2019-07-16 Thread Ying
I found that if the signing and verification are all done by command line or all done by API, the verification will pass. But if cross, then failed. Any default configuration are different? -- Sent from: http://openssl.6102.n7.nabble.com/OpenSSL-User-f3.html

Re: RSA PSS RSAE Cert Generation

2019-06-14 Thread Matt Caswell
On 14/06/2019 13:28, Raja Ashok wrote: > Hi All, > > For using with TLS1.3, I am able to generate rsa_pss_pss cert (Both Public key > and Signature of RSA_PSS OID) with the below script. > > https://github.com/raja-ashok/sample_certificates/blob/master/RSA_PSS_PSS_Certs/gen_rsa_cert.sh > > Ca

RE: RSA public and private key encrypt with fips issue

2019-06-12 Thread Yi tiger
Hi guys, I then build the same source code on my Linux box (CentOS 7.1 3.10.0-299.el7.x86_64) it work fine. The environment is windows 10 with VS 2017, the sample app is configured for 32-bit. Can anyone help? Thanks very much. Sent from Mail f

Re: RSA Private key extract using Heartbleed

2014-04-15 Thread Luis Rocha
Ok, sorry about the spam the keys have a different header and googling it arround found that: "BEGIN RSA PRIVATE KEY is PKCS#1 and is just an RSA key. It is essentially just the key object from PKCS#8, but without the version or algorithm identifier in front. BEGIN PRIVATE KEY is PKCS#8 and

Re: RSA and plausible deniability

2013-12-12 Thread Adnan RIHAN
[Corrected, sorry for not finished previous mail] Hello all ! I would like to know if RSA allows plausible deniability ? I'm on a crypto app, and the RSA_private_* functions seem to return < 0 if error. I want to implement plausible deniability, deciphering with a wrong key would work but show

Re: RSA encryption/decryption with OpenSSL.

2013-08-22 Thread Dave Thompson
> From: owner-openssl-us...@openssl.org On Behalf Of mycompuser > Sent: Wednesday, 21 August, 2013 01:35 > Thanks for the reply. > I do have access to the server code but cannot change it's > implementation to > suite my requirement as the server is serving other clients in other > platforms as

RE: RSA

2013-08-22 Thread Dave Thompson
>From: owner-openssl-us...@openssl.org On Behalf Of Matt McPhee >Sent: Wednesday, 21 August, 2013 07:17 >I am new to OpenSSL and have a private RSA key and am trying to >read a encrypted message that looks to be in base64 format but >I'm not to sure. When i do [rsautl] i get [PKCS1 padding error

RE: Re: RSA encryption/decryption with OpenSSL.

2013-08-21 Thread mycompuser
Hi Dave, Thanks for the reply. I do have access to the server code but cannot change it's implementation to suite my requirement as the server is serving other clients in other platforms as well. Below is the java code to encrypt an AES symmetric key with the public key it recieves from the clie

Re: RSA encryption/decryption with OpenSSL.

2013-08-21 Thread mycompuser
Hi, Thanks for the reply. "That's because it's not a raw public key; it's a base64 encoded structure containing the key parts. It's a lot more than just stripping the header and footer." I was not aware of this. But I think my requirement is to send the public key in Base64 encoded structur

RE: Re: RSA encryption/decryption with OpenSSL.

2013-08-20 Thread Dave Thompson
> From: owner-openssl-us...@openssl.org On Behalf Of Ken Goldman > Sent: Tuesday, 20 August, 2013 08:08 > On 8/19/2013 3:15 PM, mycompuser wrote: > > But the only > > problem that I currently face is that the key pair > generated by OpenSSL has > > headers and footers of the form -BEGIN RSA P

Re: RSA encryption/decryption with OpenSSL.

2013-08-20 Thread Ken Goldman
On 8/19/2013 3:15 PM, mycompuser wrote: But the only problem that I currently face is that the key pair generated by OpenSSL has headers and footers of the form -BEGIN RSA PUBLIC KEY- -END RSA PUBLIC KEY- for public key likewise there is similar header and footer for private key a

RE: RSA encryption and Decryption code in C language

2013-07-02 Thread yamini
Hello Enrico, Thanks for the code! It really helped. Regards, yamini. -- View this message in context: http://openssl.6102.n7.nabble.com/RSA-encryption-and-Decryption-code-in-C-language-tp45588p45759.html Sent from the OpenSSL - User mailing list archive at Nabble.com. ___

Re: RSA encryption and Decryption code in C language

2013-06-18 Thread Ken Goldman
You cannot generate a private key from a public key. Typically, the receiver generates the key pair and sends the public key to the sender. The sender encrypts with the public key. The receiver decrypts with the private key. A typical format for sending a public key across a channel is an X

Re: RSA encryption and Decryption code in C language

2013-06-18 Thread Hemayamini Kurra
Hello Michel, Thanks for the link. I have the following code. int main() { RSA *key; unsigned char input_ptext[] = "58FD6F1C310FC9D0194FB8B0E99070A6CBA3473BFE69F953E60E99070A6CBA3473BFE69F953E0E99070A6CBA3473BFE69F953E0E99070A6CBAE"; unsigned char ctext[256]; unsigned char ptext[256];

RE: RSA encryption and Decryption code in C language

2013-06-18 Thread enrico d'urso
Hi, I'm implementing a software very similar to yours. This is a small function that I used to generate private and public key: #include int main() { char * file_pem = "key_priv"; char * file_pem_pub = "key_pub"; FILE * fp; int bits = 1024; unsigned long exp = RSA_F4; RS

Re: RSA encryption and Decryption code in C language

2013-06-18 Thread Matt Caswell
On 18 June 2013 09:43, Michel wrote: > Hi Yamini, > > I would suggest looking at the 'EVP Envelope' API : > https://www.openssl.org/docs/crypto/EVP_SealInit.html > Also see: http://wiki.openssl.org/index.php/EVP_Asymmetric_Encryption_and_Decryption_of_an_Envelope Matt __

Re: RSA encryption and Decryption code in C language

2013-06-18 Thread Michel
Hi Yamini, I would suggest looking at the 'EVP Envelope' API : https://www.openssl.org/docs/crypto/EVP_SealInit.html Le 17/06/2013 19:26, yamini a écrit : Hello, I am implementing the DES algorithm between my client and server systems for encryption. The DES key is transmitted in encrypted fo

Re: RSA blinding active by default?

2013-05-10 Thread schulwitz
The answer to your question is yes, RSA blinding is turned on by default. To verify that blinding is turned on by default, run this test: Run the following code after calling RSA_blinding_off(*RSA). Then, comment out RSA_blinding_off() and run it again. The output from this test verifies that RS

Re: rsa private key formats

2012-12-21 Thread Jakob Bohm
On 12/20/2012 6:58 PM, Pavol Supa wrote: Hi all, I wonder if there is some format directly supported by openssl, suitable for storing RSA key pair in the following way: - RSA private key (d,p,q,...) encrypted with passhphrase - RSA public key (n,e) unencrypted, so I can load public key without

Re: RSA public key in x509 format

2012-11-03 Thread Taraniteja Vishwanatha
Thanks Dave. Will give a shot using PEM_write_bio_RSAPUBKEY. On Fri, Nov 2, 2012 at 7:12 PM, Dave Thompson wrote: > >From: owner-openssl-us...@openssl.org On Behalf Of Taraniteja Vishwanatha > >Sent: Friday, 02 November, 2012 18:29 > > Answering only -users, this is not a -dev question. > > >I w

RE: RSA public key in x509 format

2012-11-02 Thread Dave Thompson
>From: owner-openssl-us...@openssl.org On Behalf Of Taraniteja Vishwanatha >Sent: Friday, 02 November, 2012 18:29 Answering only -users, this is not a -dev question. >I want to generate a RSA key pair in x509 format and pem encoded >( BEGIN PUBLIC KEY .END PUBLIC KEY). >Can anyone give m

Re: RSA quintuple vs. xmldsig mismatch

2012-10-30 Thread Miroslav Mikluš
+1 Thanks, M. On 30. 10. 2012 15:36, Jakob Bohm wrote: (continuing TOFU posting to match the OP) A private/public RSA key pair in (n,e)+(n,d) format can be converted to (n,p,q,e,d,d%(p-1),d%(q-1), (1/q)%p) form by using well known mathematical steps that are fairly cheap. A private RSA key in

Re: RSA quintuple vs. xmldsig mismatch

2012-10-30 Thread Jakob Bohm
(continuing TOFU posting to match the OP) A private/public RSA key pair in (n,e)+(n,d) format can be converted to (n,p,q,e,d,d%(p-1),d%(q-1), (1/q)%p) form by using well known mathematical steps that are fairly cheap. A private RSA key in (n,d) format with no information on e cannot be converte

Re: RSA quintuple vs. xmldsig mismatch

2012-10-30 Thread Miroslav Mikluš
I'm afraid RSAKeyValue may represent both public, or private key, but that's not the point. The RFC itself defines 2 forms of representation of private key, but openssl works only with the second one, the encryption works fine when I pushed zeroes to the RSA structure, but I didn't find any ex

Re: RSA quintuple vs. xmldsig mismatch

2012-10-29 Thread Wim Lewis
On 29 Oct 2012, at 8:44 AM, Miroslav Mikluš wrote: > The xmldsig (http://www.w3.org/TR/xmldsig-core/#sec-RSAKeyValue) > use the first form of RSA representation with respect to the : > http://tools.ietf.org/html/rfc3447#section-3.2 The RSAKeyValue element contains a public key, but the quintuple

Re: RSA OAEP with sha256

2012-08-16 Thread Mounir IDRASSI
Hi Martin, In OpenSSL implementation of OAEP, MGF1 is hardcoded with SHA-1 (look at the end of the file rsa_oaep.c). Moreover, the function RSA_padding_add_PKCS1_OAEP is using explicitly SHA-1 as the unique possible hash. That's why your results are incorrect. Personally, I overcame these li

Re: RSA OAEP with sha256

2012-08-16 Thread Dr. Stephen Henson
On Thu, Aug 16, 2012, Martin Kaiser wrote: > Dear all, > > I'd like to encrypt some bytes using RSA OAEP with MGF1. Both OAEP and > MGF1 should use sha256 instead of the default sha1. > > Does openssl support this at all? I tried something along the lines of > >size_t outlen; >int ret;

RE: RSA PRIVATE KEY, CERTIFICATE REQUEST, and CERTIFICATE

2012-07-30 Thread Rita Rex Smith
-openssl-us...@openssl.org] On Behalf Of Saurabh Pandya Sent: Saturday, July 28, 2012 9:34 AM To: openssl-users@openssl.org Subject: Re: RSA PRIVATE KEY, CERTIFICATE REQUEST, and CERTIFICATE On 7/28/12, Rita Rex Smith wrote: > I am just getting started trying to figure out how to set up an

Re: RSA PRIVATE KEY, CERTIFICATE REQUEST, and CERTIFICATE

2012-07-28 Thread Saurabh Pandya
On 7/28/12, Rita Rex Smith wrote: > I am just getting started trying to figure out how to set up an SSL > certificate and key with PayPal to use for encrypted payments on my > website. > I am totally confused as to what I need to upload to them and how to figure > out if it is correct or not. > >

Re: RSA Cipher using openssl

2011-10-21 Thread trilok nuwal
Please reply me too, I don't have openssl-users subscription. I want to create a crypto objects using RSA keys so that I can get cipher > update and final kind of behavior. > I have written this code and it works fine on one machine. > > > #include > #include > > #include > #include > #includ

RE: RSA publlic/private key returnig to calling function

2011-08-11 Thread Dave Thompson
> From: owner-openssl-us...@openssl.org On Behalf Of krishnamurthy santhanam > Sent: Tuesday, 09 August, 2011 16:23 > Thanks a lot for your detailed explanation. GT.M supports ASCII format > also. i believe converting base64 is better way instead of ASCII. There are no standard

Re: RSA publlic/private key returnig to calling function

2011-08-09 Thread krishnamurthy santhanam
Hi Dave, Thanks a lot for your detailed explanation. GT.M supports ASCII format also. i believe converting base64 is better way instead of ASCII. I had changed as per your suggestion and code worked for me. additionally i had tested the Decode also, now everything is fine. can you please verify t

RE: RSA publlic/private key returnig to calling function

2011-08-08 Thread Dave Thompson
> From: owner-openssl-us...@openssl.org On Behalf Of krishnamurthy santhanam > Sent: Saturday, 06 August, 2011 15:13 > Thanks for your suggestion. Let me explain in what i am doing. > I have GT.M(MUMPS) calls to C language(external calls) routines that > has to generate RSA key

Re: RSA publlic/private key returnig to calling function

2011-08-06 Thread krishnamurthy santhanam
Hi Dave, Thanks for your suggestion. Let me explain in what i am doing. I have GT.M(MUMPS) calls to C language(external calls) routines that has to generate RSA key pairs and send it to the GT.M(same server). DO &security.rsakey(char *pubkey,char *privatekey) GT.M stores the key pairs in databas

RE: RSA publlic/private key returnig to calling function

2011-08-05 Thread Dave Thompson
> From: owner-openssl-us...@openssl.org On Behalf Of krishnamurthy santhanam > Sent: Friday, 05 August, 2011 08:09 > I have to write back rsa public/private key to calling function, > i have tried below program using i2d_RSAPrivatekey(). > My application will not accept R

RE: RSA key

2011-04-14 Thread Dave Thompson
> From: owner-openssl-us...@openssl.org On Behalf Of David Schwartz > Sent: Wednesday, 13 April, 2011 18:55 > On 4/13/2011 2:35 AM, pattabi raman wrote: > > > *1. If I can't use sprintf then how can I copy the enrypted > message to a > > character buffer. Bcoz so far I am sending the request to

Re: RSA key

2011-04-13 Thread David Schwartz
On 4/13/2011 2:35 AM, pattabi raman wrote: *1. If I can't use sprintf then how can I copy the enrypted message to a character buffer. Bcoz so far I am sending the request to middleware in Char Buffer using TCP /IP socket. How can I able to achieve now.* ** If you don't know how to copy bytes o

Re: RSA key

2011-04-13 Thread pattabi raman
Hi Dave, Thanks for your reply. *1. If I can't use sprintf then how can I copy the enrypted message to a character buffer. Bcoz so far I am sending the request to middleware in Char Buffer using TCP /IP socket. How can I able to achieve now.* ** *2. Actually I am using 2048 bit public key. So wha

Re: RSA key

2011-04-12 Thread David Schwartz
On 4/11/2011 6:36 PM, Adrian D. Sacrez wrote: > I'm fairly new to OpenSSL. How do I convert the rsa generated > ry rsa_keygen_ex() into a public and private key? > Is there a way to do that? I assume you mean RSA_generate_key_ex. It already is. The purpose of this function is to generate a new

RE: RSA key

2011-04-11 Thread Adrian D. Sacrez
esday, April 12, 2011 7:19 AM To: openssl-users@openssl.org Subject: RE: RSA key On Mon, 2011-04-11 at 17:53 -0400, Dave Thompson wrote: > > From: owner-openssl-us...@openssl.org On Behalf Of pattabi raman > > Sent: Sunday, 10 April, 2011 08:14 > > > I am using the

RE: RSA key

2011-04-11 Thread Ruden Estolonio
On Mon, 2011-04-11 at 17:53 -0400, Dave Thompson wrote: > > From: owner-openssl-us...@openssl.org On Behalf Of pattabi raman > > Sent: Sunday, 10 April, 2011 08:14 > > > I am using the below code snippet and am able to do the encytption. > > > But I need to convert the enc

RE: RSA key

2011-04-11 Thread Dave Thompson
> From: owner-openssl-us...@openssl.org On Behalf Of pattabi raman > Sent: Sunday, 10 April, 2011 08:14 > I am using the below code snippet and am able to do the encytption. > But I need to convert the encrypted format to Binary format inorder > to pass the encr

RE: RSA key

2011-04-11 Thread Adrian D. Sacrez
Thanks for the reply. How do I transfer or copy the keyfile generated by RSA_keygen_ex()? From: owner-openssl-us...@openssl.org [mailto:owner-openssl-us...@openssl.org] On Behalf Of pattabi raman Sent: Sunday, April 10, 2011 8:14 PM To: openssl-users@openssl.org Subject: Re: RSA key Hi, I am

Re: RSA key

2011-04-11 Thread pattabi raman
Hi, > I am using the below code to do the encytption of the publickey and it > works fine. > > But I need to convert the encrypted format to Binary format inorder to pass > the encrypted key to a different system. > pls suggest how to do the same ??? How can I convert the encrypted message to

Re: RSA key

2011-04-10 Thread pattabi raman
Hi, I am using the below code snippet and am able to do the encytption. But I need to convert the encrypted format to Binary format inorder to pass the encrypted key to a different system. Any one pls suggest how to do the same ??? *Code snippet :* ** *void** EncrCardPin(char *pin,char** *encpi

Re: RSA implementaion in C using openssl

2011-03-06 Thread Jeffrey Walton
On Sun, Mar 6, 2011 at 5:23 AM, pattabi raman wrote: > > Hi , > >  I need to implement the entire RSA logic in C program to encrypt the > customer key for one of our application functionality. > > I am bit confused on RSA API, which gives me struggle like Which method to > call / order of the meth

Re: RSA implementaion in C using openssl

2011-03-06 Thread pattabi raman
Hi , I need to implement the entire RSA logic in C program to encrypt the customer key for one of our application functionality. I am bit confused on RSA API, which gives me struggle like Which method to call / order of the methods to be executed etc... Pls guide me. Thanks, Pattabi/

Re: RSA implementaion in C using openssl

2011-03-06 Thread Jeffrey Walton
On Sun, Mar 6, 2011 at 4:51 AM, pattabi raman wrote: > Hi, > > I have to implement the RSA algorithm in our solaris10 ( which has openssl > already) using C programming. > > Anyone please forward any doc / sample code / Weblink anything would be a > great help me. c = m^e mod n m = c^d mod n 'Raw

Re: RSA Private Key Format Different in FIPS Mode

2011-02-28 Thread Dr. Stephen Henson
On Mon, Feb 28, 2011, Yolanda Liu (liuyu) wrote: > Hi, > > > > I manually ran "openssl genrsa -out key.rsa 2048" in FIPS on and off > mode, the generated private keys are in different format. > > > > In FIPS off mode: > > -BEGIN RSA PRIVATE KEY- > > MIIEpAIBAAKCAQEAwhVeHVTVFcr

RE: RSA public/private keys only work when created programatically.

2011-02-18 Thread Dave Thompson
> From: owner-openssl-us...@openssl.org On Behalf Of David Henry > Sent: Friday, 18 February, 2011 11:51 > Solved. Thanks, Mounir. Changing my PEM_read_bio_RSA_PublicKey() > to PEM_read_bio_RSA_PUBKEY() did the trick. I don't understand why > there are two of these, but I'm new

Re: RSA public/private keys only work when created programatically.

2011-02-18 Thread David Henry
Solved. Thanks, Mounir. Changing my PEM_read_bio_RSA_PublicKey() to PEM_read_bio_RSA_PUBKEY() did the trick. I don't understand why there are two of these, but I'm new to OpenSSL, so I won't complain about that which I don't sufficiently understand. Dave On Fri, Feb 18, 2011 at 10:15 AM, David He

Re: RSA public/private keys only work when created programatically.

2011-02-18 Thread David Henry
Thanks for the response, but adding the -pubout switch did not change anything. Actually, I had already been using it, but forgot to type it in my email. Just to make sure though, I recreated the keys and tried again with: > openssl genrsa -out rsaprivatekey.pem 2048 > openssl rsa -in rsaprivateke

Re: RSA public/private keys only work when created programatically.

2011-02-17 Thread Mounir IDRASSI
Hi, Your command line that create the public key is missing the -pubout switch that tells the rsa utility to output a public key. So, this command should look like : openssl rsa -in rsaprivatekey.pem -out rsapublickey.pem -pubout . Without it, it will just output the private key as is. More

Re: RSA-PSS

2010-10-28 Thread Dr. Stephen Henson
On Thu, Oct 28, 2010, Bram Cymet wrote: > Hi, > > I would like to add rsa-pss support to my application and I have a few > questions: > > RSA-PSS support exists in the current stable code base correct? > OpenSSL 0.9.8 has padding support and a rather crude EVP support: primarily so PSS could be

RE: rsa key format

2010-09-23 Thread Dave Thompson
> From: owner-openssl-us...@openssl.org On Behalf Of Panikulam Vivek > Sent: Thursday, 23 September, 2010 10:53 > I have generated a private key using the below command and > want to extract the public key in a format that is compatible > with sites using Java. >

RE: RSA key generation and writing int to text file.

2010-09-07 Thread Dave Thompson
> From: owner-openssl-us...@openssl.org On Behalf Of krishnamurthy santhanam > Sent: Monday, 06 September, 2010 12:40 > I need to write [RSA] public and private key into text file > ...is it possible using BN? Yes, but for supported formats you don't need to; see reply

Re: RSA-PSS

2010-05-19 Thread Dr. Stephen Henson
On Wed, May 19, 2010, Martin Kaiser wrote: > Hello Bram, > > Thus wrote Bram Cymet (bcy...@cbnco.com): > > > I have been able to use RSA-PSS to sign some data with OpenSSL. I am > > wondering if OpenSSL supports creating certs where the signature > > algorithm uses RSA-PSS. In other words, when

Re: RSA-PSS

2010-05-19 Thread Martin Kaiser
Hello Bram, Thus wrote Bram Cymet (bcy...@cbnco.com): > I have been able to use RSA-PSS to sign some data with OpenSSL. I am > wondering if OpenSSL supports creating certs where the signature > algorithm uses RSA-PSS. In other words, when viewing the properties of > the cert you would get: > Sig

Re: RSA vs. RSA_METHOD

2009-12-02 Thread Dr. Stephen Henson
On Wed, Dec 02, 2009, Scott Neugroschl wrote: > Am I correct in assuming that an RSA structure is contains the encryption > "context" for a particular instance of RSA, whereas RSA_METHOD contains the > functions that the RSA instance will use? > The RSA structure contains the actual key to use w

Re: RSA algorithm with big endian environment

2009-10-15 Thread Dr. Stephen Henson
On Fri, Oct 16, 2009, Victor B. Wagner wrote: > On 2009.10.15 at 16:37:39 +0200, Alessandro Borga wrote: > > Do you use native build or cross-compiling? > If cross-compiling with GNU toolchain, that you have just to specify > --cross-compile-prefix (or it is just --cross-compile for recent CVS)

Re: RSA algorithm with big endian environment

2009-10-15 Thread Pandit Panburana
OpenSSL works fine on MIPS. MIPS is a big endian CPU. -Pandit From: Alessandro Borga To: openssl-users@openssl.org Sent: Thu, October 15, 2009 10:37:39 AM Subject: RSA algorithm with big endian environment Well I must use RSA encrypt/decprypt functions in

Re: RSA algorithm with big endian environment

2009-10-15 Thread Victor B. Wagner
On 2009.10.15 at 16:37:39 +0200, Alessandro Borga wrote: >Well > >I must use RSA encrypt/decprypt functions in a target using Arm cpu. > >Other rsa source code doesn*t work right because target environment use >big endian memory allocation for int and long > >Can openSLL cry

Re: RSA algorithm with big endian environment

2009-10-15 Thread Dan_Mitton
Alex, We use OpenSSL on Sun Solaris SPARC architecture, which is big endian. Never had a problem. No clue about how to compile/link on your ARM cpu though. Dan Please respond to openssl-users@openssl.org Sent by:owner-openssl-us...@openssl.org To: cc: (bcc: Dan Mitton/YD/R

Re: RSA algorithm with big endian environment

2009-10-15 Thread Alessandro Borga
Thanks for your replay - Original Message - From: dan_mit...@ymp.gov To: openssl-users@openssl.org Cc: al...@libero.it Sent: Thursday, October 15, 2009 5:07 PM Subject: Re: RSA algorithm with big endian environment Alex, We use OpenSSL on Sun Solaris SPARC

Re: RSA algorithm with big endian environment

2009-10-15 Thread John R Pierce
Bruce Stephens wrote: OpenSSL works fine on 32 bit SPARC. (As far as I'm aware, anyway. I don't recall seeing any problems.) its bundled with Solaris 10 as both 32bit and 64bit sparc binaries Also works on IBM Power architecture with AIX, this is also a 'big endian' 32/64bit architec

Re: RSA algorithm with big endian environment

2009-10-15 Thread Bruce Stephens
"Alessandro Borga" writes: > I must use RSA encrypt/decprypt functions in a target using Arm cpu. > > Other rsa source code doesn’t work right because target environment use big > endian memory allocation for int and long Really? SPARC (32bit) is big-endian, and really quite common (less thoug

Re: RSA algorithm with big endian environment

2009-10-15 Thread Jeffrey Walton
Hi Alessandro, > Other rsa source code doesn’t work right because target environment > use big endian memory allocation for int and long I don't believe this is characteristic of many libraries, such as Peter Guttman's Cryptlib or Wei Dai's Crypto++. Jeff On Thu, Oct 15, 2009 at 10:37 AM, Alessa

Re: RSA OAEP encrypt with a label

2009-09-11 Thread Einar Thorsrud
Thank you Martin. I have tried using the function, however using the code I have pasted below I get the error "Error = oaep decoding error" when trying to unpadd to retrieve the original data. For simplicity the code I have added here does not encrypt/decrypt, but only attempts to pad and unpadd.

Re: RSA OAEP encrypt with a label

2009-09-10 Thread Martin Kaiser
Hello, On Thu, Sep 10, 2009 at 08:34:56AM +0200, Einar Thorsrud wrote: > > I do not find any possibility to add the label to the > > RSA_public_encrypt() function, but it could perhaps be achieved > > otherwise? > > Could the label perhaps be related to the *p parameter in > > int RSA_padding_a

Re: RSA OAEP encrypt with a label

2009-09-09 Thread Einar Thorsrud
on., 09.09.2009 kl. 10.25 +0200, skrev Einar Thorsrud: > I do not find any possibility to add the label to the > RSA_public_encrypt() function, but it could perhaps be achieved > otherwise? Could the label perhaps be related to the *p parameter in int RSA_padding_add_PKCS1_OAEP(unsigned char *to,

  1   2   3   4   5   >