my dog learned polymorphism*
The moose likes Security and the fly likes Generating a selfcertificate programatically Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Security
Bookmark "Generating a selfcertificate programatically" Watch "Generating a selfcertificate programatically" New topic
Author

Generating a selfcertificate programatically

Jose Botella
Ranch Hand

Joined: Jul 03, 2001
Posts: 2120
It seems that there is no way to generate a selfcertificate via a JRE API. For instance java.security.cert.CertificateFactory needs to read an already existing certificate (encoding) from an InputStream. While CertPathBuilder requires LDAP or a Collection of certificates.

I do not want to force the users to pay to a CA, any free alternatives?
In fact, I would like the program would allow the user to generate the selfcertificates, preventing the user of knowing/managing the keytool utility.
I know they are not said to be reliable. But I think the user can phone the owner/subject of the selfcertificate to find out the "digitall firm" and check its autenticity. This is how I would like my program worked.

[ June 28, 2004: Message edited by: Jose Botella ]

[ June 28, 2004: Message edited by: Jose Botella ]
[ June 29, 2004: Message edited by: Jose Botella ]

SCJP2. Please Indent your code using UBB Code
Jose Botella
Ranch Hand

Joined: Jul 03, 2001
Posts: 2120
Hey I have found the bouncycastle.org site. Now it seems I am on the track!

Dou you think this practice is secure or unfeasible?
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Generating a selfcertificate programatically