<div dir="ltr">I have question that propably should be in new thread but it' s related with all this storing private keys in DRM. How to handle certificate renewal?<div class="gmail_extra">In renewal request for other profiles I found that the renewal request has a new public key which is diffrent, that means private key has been changed as well.</div><div class="gmail_extra">After administrator approve on renewal request, the DRM will store not valid private key. I have some ideas how to fix that, if You have any better please give me a hint.</div><div class="gmail_extra">solution A) In reneval request put generated put crmf request generated by CRMFPopClient</div><div class="gmail_extra">solution B) revoke old certificate, create new one with same key pair and subject values(except notvalidafter date) </div><div class="gmail_extra"><br></div><div class="gmail_extra">Or maybe is there option to renewal certificate without changing keys? from some reading(<a href="http://security.stackexchange.com/questions/27810/should-i-change-the-private-key-when-renewing-a-certificate">http://security.stackexchange.com/questions/27810/should-i-change-the-private-key-when-renewing-a-certificate</a>) propably SSL certificates renewals does not require that. </div><div class="gmail_extra"><br><div class="gmail_quote">2015-10-16 20:05 GMT+02:00 John Magne <span dir="ltr"><<a href="mailto:jmagne@redhat.com" target="_blank">jmagne@redhat.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">Hi:<br>
<br>
The CRMFPopClient generates the key pair on its own, it does not get it from the KRA.<br>
It uses the transport cert to essentially wrap the data for transit.<br>
<br>
And that private key gets sent to the kra.<br>
<br>
Also that line of code I believe is in some test driver program.<br>
It gets the same transport cert using some rest call.<br>
<span class="im"><br>
<br>
<br>
----- Original Message -----<br>
> From: "Marcin Mierzejewski" <<a href="mailto:marcinmierzejewski1024@gmail.com">marcinmierzejewski1024@gmail.com</a>><br>
> To: "John Magne" <<a href="mailto:jmagne@redhat.com">jmagne@redhat.com</a>><br>
> Cc: "Dave Sirrine" <<a href="mailto:dsirrine@redhat.com">dsirrine@redhat.com</a>>, <a href="mailto:pki-users@redhat.com">pki-users@redhat.com</a><br>
</span><div class=""><div class="h5">> Sent: Friday, October 16, 2015 5:03:48 AM<br>
> Subject: Re: [Pki-users] Dogtag profile for encryption certificate with storing private key in DRM/KRA<br>
><br>
> That helps a lot. It's actually working in CLI(now I'm figuring out how to<br>
> use this in application) but I don't understand one aspect of this.<br>
> CRMFPopClient generates RSA key pair and put it in crmf request. Question<br>
> is how to get keypair for client without retriving it from KRA? Could<br>
> CRMFPopClient used with existing keypair?<br>
><br>
> T<br>
> ransport.cert it is the same certicate that can be accessed with that line?<br>
<br>
<br>
><br>
> // Test 1: Get transport certificate from DRM<br>
> transportCert = systemCertClient.getTransportCert().getEncoded();<br>
><br>
><br>
><br>
> 2015-10-15 19:39 GMT+02:00 John Magne <<a href="mailto:jmagne@redhat.com">jmagne@redhat.com</a>>:<br>
><br>
> ><br>
> ><br>
> ><br>
> ><br>
> > ----- Original Message -----<br>
> > > From: "Marcin Mierzejewski" <<a href="mailto:marcinmierzejewski1024@gmail.com">marcinmierzejewski1024@gmail.com</a>><br>
> > > To: "John Magne" <<a href="mailto:jmagne@redhat.com">jmagne@redhat.com</a>><br>
> > > Cc: "Dave Sirrine" <<a href="mailto:dsirrine@redhat.com">dsirrine@redhat.com</a>>, <a href="mailto:pki-users@redhat.com">pki-users@redhat.com</a><br>
> > > Sent: Thursday, October 15, 2015 2:26:33 AM<br>
> > > Subject: Re: [Pki-users] Dogtag profile for encryption certificate with<br>
> > storing private key in DRM/KRA<br>
> > ><br>
> > > Ok, after futher reading this symmetric key is encypted with CA public<br>
> > key<br>
> > > in wrapSessionKey(...) method.<br>
> > > Question I still have is how to user in rest client?<br>
> ><br>
> ><br>
> > I believe in one of the previous emails, I put in a list of steps.<br>
> > After the request is created by CRMFPopClient, we put that blob<br>
> > in the xml file generated for the enrollment profile chosen.<br>
> ><br>
> ><br>
> > Once that xml file is filled out , that is used in issuing the proper<br>
> > "pki" cli command to do the enrollment. This is in fact hitting the rest<br>
> > servlets responsible for performing a cert enrollment.<br>
> ><br>
> > Hope this helps,<br>
> > thanks,<br>
> > jack<br>
> ><br>
> ><br>
> ><br>
> ><br>
> ><br>
> > ><br>
> > > 2015-10-15 10:59 GMT+02:00 Marcin Mierzejewski <<br>
> > > <a href="mailto:marcinmierzejewski1024@gmail.com">marcinmierzejewski1024@gmail.com</a>>:<br>
> > ><br>
> > > > Thanks fo clue. RMFPopClientTool is a cli tool. I check implementation<br>
> > and<br>
> > > > I found this method wrapPrivateKey(...).<br>
> > > > Can it be used to wrap private key which could be added to<br>
> > > > CertEnrollRequest to request certificate from my rest client?<br>
> > > > And do You have ideas how to get symmetric key for that? I think better<br>
> > > > solution would be use CA public key to encrypt it but I don't have that<br>
> > > > much knowlege in PKI and Dogtag architecture.<br>
> > > ><br>
> > > > 2015-10-14 19:25 GMT+02:00 John Magne <<a href="mailto:jmagne@redhat.com">jmagne@redhat.com</a>>:<br>
> > > ><br>
> > > >> If you see the email I sent the other day,<br>
> > > >> we make use of the CRMFPopClient tool that uses the transport key to<br>
> > wrap<br>
> > > >> the private key.<br>
> > > >><br>
> > > >><br>
> > > >><br>
> > > >> ----- Original Message -----<br>
> > > >> From: "Marcin Mierzejewski" <<a href="mailto:marcinmierzejewski1024@gmail.com">marcinmierzejewski1024@gmail.com</a>><br>
> > > >> To: "Dave Sirrine" <<a href="mailto:dsirrine@redhat.com">dsirrine@redhat.com</a>><br>
> > > >> Cc: <a href="mailto:pki-users@redhat.com">pki-users@redhat.com</a><br>
> > > >> Sent: Wednesday, October 14, 2015 2:35:00 AM<br>
> > > >> Subject: Re: [Pki-users] Dogtag profile for encryption certificate<br>
> > with<br>
> > > >> storing private key in DRM/KRA<br>
> > > >><br>
> > > >> But after this change it is not adding private key to DRM: /<br>
> > > >><br>
> > > >> 2015-10-13 19:27 GMT+02:00 Dave Sirrine < <a href="mailto:dsirrine@redhat.com">dsirrine@redhat.com</a> > :<br>
> > > >><br>
> > > >><br>
> > > >><br>
> > > >> Marcin,<br>
> > > >><br>
> > > >> Not sure what exactly you're looking for here, but the beauty of<br>
> > profiles<br>
> > > >> is you can create your own. If the ECC profile works as you would<br>
> > expect,<br>
> > > >> you can always create a copy with a new name and change the<br>
> > appropriate<br>
> > > >> lines. A quick diff of the two profiles you mention shows that<br>
> > there's not<br>
> > > >> a lot that's different between the two:<br>
> > > >><br>
> > > >> diff caEncECUserCert.cfg caEncUserCert.cfg<br>
> > > >> 1c1<br>
> > > >> < desc=This certificate profile is for enrolling user ECC encryption<br>
> > > >> certificates. It works only with latest Firefox.<br>
> > > >> ---<br>
> > > >> > desc=This certificate profile is for enrolling user encryption<br>
> > > >> certificates with option to archive keys.<br>
> > > >> 5c5<br>
> > > >> < name=Manual User Encryption ECC Certificates Enrollment<br>
> > > >> ---<br>
> > > >> > name=Manual User Encryption Certificates Enrollment<br>
> > > >> 7,8c7,10<br>
> > > >> < input.list=i1<br>
> > > >> < input.i1.class_id=encKeyGenInputImpl<br>
> > > >> ---<br>
> > > >> > input.list=i1,i2,i3<br>
> > > >> > input.i1.class_id=certReqInputImpl<br>
> > > >> > input.i2.class_id=subjectNameInputImpl<br>
> > > >> > input.i3.class_id=submitterInfoInputImpl<br>
> > > >> 31,32c33,34<br>
> > > >> < policyset.encryptionCertSet.3.constraint.params.keyType=EC<br>
> > > >> <<br>
> > > >><br>
> > policyset.encryptionCertSet.3.constraint.params.keyParameters=nistp256,nistp521<br>
> > > >> ---<br>
> > > >> > policyset.encryptionCertSet.3.constraint.params.keyType=RSA<br>
> > > >> ><br>
> > > >><br>
> > policyset.encryptionCertSet.3.constraint.params.keyParameters=1024,2048,3072,4096<br>
> > > >> 93a96<br>
> > > >> ><br>
> > > >><br>
> > > >> In theory (I have not tested this) you should be able to change the<br>
> > lines<br>
> > > >> for 'policyset.encryptionCertSet.3.constraint.params.keyType' and<br>
> > > >> 'policyset.encryptionCertSet.3.constraint.params.keyParameters' to<br>
> > match<br>
> > > >> the caEncUserCert.cfg profile and keep everything else the same. If<br>
> > you<br>
> > > >> have the KRA installed and configured to work with your CA, the<br>
> > encryption<br>
> > > >> keys should automatically be archived in the KRA.<br>
> > > >><br>
> > > >> -- Dave<br>
> > > >><br>
> > > >> On Tue, Oct 13, 2015 at 10:36 AM, Marcin Mierzejewski <<br>
> > > >> <a href="mailto:marcinmierzejewski1024@gmail.com">marcinmierzejewski1024@gmail.com</a> > wrote:<br>
> > > >><br>
> > > >><br>
> > > >><br>
> > > >> there is a caEncECUserCert that works as I expect but generates<br>
> > Eliptic<br>
> > > >> curve certificate. Is there any eqiuvalent for RSA? And next question<br>
> > is:<br>
> > > >> could I use this profile to generate enduser certificate remote by<br>
> > calling<br>
> > > >> REST service?<br>
> > > >><br>
> > > >> 2015-10-13 15:51 GMT+02:00 Marcin Mierzejewski <<br>
> > > >> <a href="mailto:marcinmierzejewski1024@gmail.com">marcinmierzejewski1024@gmail.com</a> > :<br>
> > > >><br>
> > > >><br>
> > > >><br>
> > > >> Hi All,<br>
> > > >><br>
> > > >> What I want is simple profile for requesting encryption(not sign)<br>
> > > >> personal certificate that will private key be stored in KRA/DRM. I<br>
> > check<br>
> > > >> existing profiles and found profile that name and description meet the<br>
> > > >> goals I want to achieve.<br>
> > > >><br>
> > > >> CaEncUserCert.cfg<br>
> > > >><br>
> > > >> this profile was not visible I change that. I opened this profile in<br>
> > end<br>
> > > >> user CA application<br>
> > > >><br>
> > > >><br>
> > > >> Certificate Profile - Manual User Encryption Certificates Enrollment<br>
> > > >><br>
> > > >> This certificate profile is for enrolling user encryption certificates<br>
> > > >> with option to archive keys. Certificate Request Input<br>
> > > >>         * Certificate Request Type list ( pcks10 or crmf)<br>
> > > >><br>
> > > >>         * Certificate Request (text area for request)<br>
> > > >> Subject Name<br>
> > > >> -fields with info about user(propably should be same values that were<br>
> > in<br>
> > > >> certificate request)<br>
> > > >> Requestor Information<br>
> > > >> - info about requestor<br>
> > > >><br>
> > > >> How it's possible to store private key without even sending it to CA?<br>
> > can<br>
> > > >> be private key enclosed into "Certificate Request"? If answer is no -<br>
> > as I<br>
> > > >> think why there is a "option to archieve keys"?<br>
> > > >><br>
> > > >><br>
> > > >><br>
> > > >><br>
> > > >><br>
> > > >><br>
> > > >> Marcin<br>
> > > >><br>
> > > >><br>
> > > >><br>
> > > >> _______________________________________________<br>
> > > >> Pki-users mailing list<br>
> > > >> <a href="mailto:Pki-users@redhat.com">Pki-users@redhat.com</a><br>
> > > >> <a href="https://www.redhat.com/mailman/listinfo/pki-users" rel="noreferrer" target="_blank">https://www.redhat.com/mailman/listinfo/pki-users</a><br>
> > > >><br>
> > > >><br>
> > > >><br>
> > > >> _______________________________________________<br>
> > > >> Pki-users mailing list<br>
> > > >> <a href="mailto:Pki-users@redhat.com">Pki-users@redhat.com</a><br>
> > > >> <a href="https://www.redhat.com/mailman/listinfo/pki-users" rel="noreferrer" target="_blank">https://www.redhat.com/mailman/listinfo/pki-users</a><br>
> > > >><br>
> > > ><br>
> > > ><br>
> > ><br>
> ><br>
><br>
</div></div></blockquote></div><br></div></div>