<div dir="auto"><span style="font-family:sans-serif;font-size:12.8px">Well, they just don't have their individual type either: they are just</span><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">`EVP_PKEY`s, with `EVP_PKEY` being the top level API in libcrypto for</span><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">public key cryptography.</span><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">The difference with `RSA_KEY`, `DSA_KEY`, `EC_KEY` (that can be</span><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">encapsulated in a generic `EVP_PKEY` object) is that Ed* keys don't</span><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">share a common module (apart from reusing common functions for parts</span><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">of the ASN1 encoding/decoding).</span><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">RSA, DSA and EC in libcrypto are submodules on their own, with a</span><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">dedicated `{RSA,DSA,EC}_*` API, in part for legacy reasons. By the</span><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">time X25519, Ed25519 and *448 were added, the new direction in the</span><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">project was to minimise the size of the public API and recommend the</span><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">use of the unified EVP API, so it did not make any sense to have a</span><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">separate submodule with its own data types and API.</span><br style="font-family:sans-serif;font-size:12.8px"><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">This is of course to the best of my knowledge and mostly based on</span><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">guesses, as I was not actively contributing to the project while some</span><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">of these decisions were made, and I don't have the same insight on the</span><br style="font-family:sans-serif;font-size:12.8px"><span style="font-family:sans-serif;font-size:12.8px">history of the design of the library as other project members.</span><div dir="auto"><span style="font-family:sans-serif;font-size:12.8px"><br></span></div><div dir="auto"><span style="font-family:sans-serif;font-size:12.8px">BR, </span></div><div dir="auto"><span style="font-family:sans-serif;font-size:12.8px"><br></span></div><div dir="auto"><span style="font-family:sans-serif;font-size:12.8px">Nicola </span></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, Mar 16, 2019, 17:00 Sam Roberts <<a href="mailto:vieuxtech@gmail.com">vieuxtech@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">That helps a lot, I can see why they are different enough from EC key<br>
types to be distinct.<br>
<br>
It still leaves me wondering whe two edwards curves have key types<br>
distinct from each other? Why aren't they both EVP_PKEY_ED? (or<br>
something of the like)<br>
<br>
Cheers,<br>
Sam<br>
</blockquote></div>