[Opendnssec-develop] Only store the private key object
rickard.bellgrim at iis.se
Tue Mar 16 12:49:16 UTC 2010
We have talked about only storing the private key and not the public key on the HSM. Since you can create the public key from the private key. But I might have found a problem with this.
The specification actually says that only the CKA_MODULUS and CKA_PRIVATE_EXPONENT is required to be stored by the token. It is then up to the token if it want to store the other attributes of the private key object.
You need CKA_MODULUS and CKA_PUBLIC_EXPONENT in order to create a public key from the data in the private key. You can access these attributes if:
- The private key object is public.
- If the object is private, then the user needs to be logged in.
- And the token needs to store the attributes.
OpenDNSSEC always login into the token, so that is no problem. But the conclusion is that you cannot guarantee that the CKA_PUBLIC_EXPONENT of the private key object is available.
Is there any implementation that does not store the CKA_PUBLIC_EXPONENT?
If so, then it clearly is a need of the public key object. The key might not be generated on the same machine as it is used.
Or another solution is that the application which generates the key also writes the public key to disc and feed it to OpenDNSSEC.
More information about the Opendnssec-develop