<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[wolfSSL - Embedded SSL Library — [SOLVED] RSA PUBLIC KEY OPERATIONS]]></title>
		<link>https://www.wolfssl.com/forums/topic376-solved-rsa-public-key-operations.html</link>
		<atom:link href="https://www.wolfssl.com/forums/feed-rss-topic376.xml" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in [SOLVED] RSA PUBLIC KEY OPERATIONS.]]></description>
		<lastBuildDate>Tue, 22 Mar 2016 21:55:33 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: [SOLVED] RSA PUBLIC KEY OPERATIONS]]></title>
			<link>https://www.wolfssl.com/forums/post2452.html#p2452</link>
			<description><![CDATA[<p>Hi Frank,</p><p>Am going through forum posts looking for RSA OAEP, to announce that we added RSA OAEP in the recent wolfSSL release version 3.9.0. Example code using it can be found in the function rsa_test() located in the file wolfcrypt/test/test.c.</p><p>Regards,<br />Jacob</p>]]></description>
			<author><![CDATA[null@example.com (Jacob)]]></author>
			<pubDate>Tue, 22 Mar 2016 21:55:33 +0000</pubDate>
			<guid>https://www.wolfssl.com/forums/post2452.html#p2452</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] RSA PUBLIC KEY OPERATIONS]]></title>
			<link>https://www.wolfssl.com/forums/post1105.html#p1105</link>
			<description><![CDATA[<p>Hi Frank,</p><div class="quotebox"><blockquote><p>I could use RsaPublicEncrypt() but I have no means of using RSA_PKCS1_OAEP_PADDING padding.</p></blockquote></div><p>Correct, for the RsaPublicEncrypt() function, wolfSSL currently uses PKCS #1 v1.5 padding from RFC 2313 (<a href="http://tools.ietf.org/html/rfc2313">http://tools.ietf.org/html/rfc2313</a>).&nbsp; We haven&#039;t added support for RSA-OAEP padding as of this point.&nbsp; Do you need OAEP padding or are you able to use RsaPublicEncrypt() with PKCS #1 v1.5 padding?</p><div class="quotebox"><blockquote><p>he compatibility layer of the ssl portion is almost a 100% job done. really excellent.<br />But when it comes to the area of crypto, there is really a lot of work to be done.</p></blockquote></div><p>Traditionally we have offered the OpenSSL compatibility layer for those people porting applications from OpenSSL over to wolfSSL - allowing them to keep many of the same functions in their application code.&nbsp; The compatibility layer contains about 300 of the most commonly used OpenSSL functions.&nbsp; As there are over 4,000 OpenSSL functions, this layer does slowly grow as additional projects use it while porting over from OpenSSL to wolfSSL.</p><p>Best Regards,<br />Chris</p>]]></description>
			<author><![CDATA[null@example.com (chrisc)]]></author>
			<pubDate>Tue, 21 May 2013 21:27:00 +0000</pubDate>
			<guid>https://www.wolfssl.com/forums/post1105.html#p1105</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] RSA PUBLIC KEY OPERATIONS]]></title>
			<link>https://www.wolfssl.com/forums/post1098.html#p1098</link>
			<description><![CDATA[<div class="quotebox"><cite>chrisc wrote:</cite><blockquote><p>Hi Frank,</p><p>What&#039;s your overall gaol that you are trying to accomplish in your application regarding RSA keys?&nbsp; There may be an easier way to accomplish it using the wolfSSL API.</p></blockquote></div><p>I&#039;m porting my code from openssl to wolfSSL due to the bloated size of openssl static library.<br />The application is heavily dependent on multiple ciphers.</p><p>In this case i will first use&nbsp; wolfSSL_KeyPemToDer() to convert the key to der format, then use RsaPublicKeyDecode() to convert it into a rsa key.</p><div class="quotebox"><blockquote><p>If wolfSSL is compiled with key generation (--enable-keygen or define WOLFSSL_KEY_GEN), wolfSSL provides the RsaKeyToDer() function which will convert an internal RsaKey to a DER-encoded buffer.&nbsp; Is this similar to what you are looking for?</p></blockquote></div><p>Great, that is exactly what i need.</p><p>There is a new issue that i discovered today.<br />wolfSSL_RSA_public_encrypt() is actually not implemented. The implementation simply void the parameters and return a failure code.<br />I could use RsaPublicEncrypt() but I have no means of using RSA_PKCS1_OAEP_PADDING padding.</p><p>Do you have any suggest on this for me?</p><p>Thank you alot for your time.</p><p>The compatibility layer of the ssl portion is almost a 100% job done. really excellent.<br />But when it comes to the area of crypto, there is really a lot of work to be done.</p>]]></description>
			<author><![CDATA[null@example.com (Frank Young)]]></author>
			<pubDate>Tue, 21 May 2013 05:14:09 +0000</pubDate>
			<guid>https://www.wolfssl.com/forums/post1098.html#p1098</guid>
		</item>
		<item>
			<title><![CDATA[Re: [SOLVED] RSA PUBLIC KEY OPERATIONS]]></title>
			<link>https://www.wolfssl.com/forums/post1096.html#p1096</link>
			<description><![CDATA[<p>Hi Frank,</p><p>What&#039;s your overall goal that you are trying to accomplish in your application regarding RSA keys?&nbsp; There may be an easier way to accomplish it using the wolfSSL API.</p><div class="quotebox"><blockquote><p>What should be the format of the key supplied to RsaPublicKeyDecode()? PEM or DER ?</p></blockquote></div><p>The input key to RsaPublicKeyDecode() needs to be in DER format, correct.&nbsp; wolfSSL embedded SSL does provide a function called CyaSSL_KeyPemToDer() to convert a PEM-encoded key to DER format.&nbsp; You can also use the OpenSSL command line tool to easily convert a PEM-encoded RSA key to DER format.&nbsp; You would do something similar to:</p><div class="codebox"><pre><code>openssl rsa -inform PEM -in mykey.pem -outform DER -out mykey.der</code></pre></div><div class="quotebox"><blockquote><p>I am also of the impression that RsaPublicKeyDecode() in wolfSSL can be be a replacement for PEM_read_bio_RSAPublicKey() or d2i_RSAPublicKey() in openssl without any issues since wolfSSL provides openssl compatibility layer for only private key rsa private key operations</p></blockquote></div><p>RsaPublicKeyDecode() decodes a public RSA key from DER format into an internal RsaKey structure.</p><div class="quotebox"><blockquote><p>I couldn&#039;t find any function in wolfSSL for encoding public keys.</p></blockquote></div><p>If wolfSSL is compiled with key generation (--enable-keygen or define WOLFSSL_KEY_GEN), wolfSSL provides the RsaKeyToDer() function which will convert an internal RsaKey to a DER-encoded buffer.&nbsp; Is this similar to what you are looking for?</p><p>Best Regards,<br />Chris</p>]]></description>
			<author><![CDATA[null@example.com (chrisc)]]></author>
			<pubDate>Mon, 20 May 2013 17:48:09 +0000</pubDate>
			<guid>https://www.wolfssl.com/forums/post1096.html#p1096</guid>
		</item>
		<item>
			<title><![CDATA[[SOLVED] RSA PUBLIC KEY OPERATIONS]]></title>
			<link>https://www.wolfssl.com/forums/post1090.html#p1090</link>
			<description><![CDATA[<p>What should be the format of the key supplied to RsaPublicKeyDecode()? PEM or DER ?<br />I think it should be PEM but according to section 10.5.1 of <a href="http://yassl.com/yaSSL/Docs-cyassl-manual-10-ctaocrypt-usage-reference.html">http://yassl.com/yaSSL/Docs-cyassl-manu … rence.html</a> , it seems it should be .der since it includes a comment refering to &quot;RsaPublicKey.der&quot;. Does that means a PEM key has to be first base64 decoded?</p><p>DECODING PUBLIC KEY<br />--------------<br />I am also of the impression that RsaPublicKeyDecode() in wolfSSL embedded SSL can be be a replacement for PEM_read_bio_RSAPublicKey() or d2i_RSAPublicKey() in openssl without any issues since wolfSSL provides openssl compatibility layer for only private key rsa private key operations </p><p>ENCODING PUBLIC KEY<br />-----------------------------<br />I couldn&#039;t find any function in wolfSSL for encoding public keys. <br />Is there any wolfSSL alternative for openssl i2d_RSAPublicKey()</p>]]></description>
			<author><![CDATA[null@example.com (Frank Young)]]></author>
			<pubDate>Sun, 19 May 2013 22:07:05 +0000</pubDate>
			<guid>https://www.wolfssl.com/forums/post1090.html#p1090</guid>
		</item>
	</channel>
</rss>
