sashoalm
sashoalm

Reputation: 79527

Generate self-signed SSL certificate using Qt

Is it possible for a Qt program to generate a self-signed SSL certificate and private key, i.e. the cacert.pem and privkey.pem files, using only Qt functions?

The program would be running on a Symbian phone (it's an FTPS server), so openssl command-line tools would not be available.

Upvotes: 3

Views: 3019

Answers (3)

Juan Gonzalez Burgos
Juan Gonzalez Burgos

Reputation: 982

Apperently there are some Qt classes that do this, starting from Qt version 5.14:

https://doc.qt.io/qt-5/qopcuax509certificatesigningrequest.html#createSelfSignedCertificate

Upvotes: 3

Richard Moore
Richard Moore

Reputation: 441

I've written an addon to Qt that will allow you to do this with a nice Qt-style API. It can be obtained here https://gitorious.org/qt-certificate-addon/ and the docs are online at http://xmelegance.org/devel/qt-certificate-addon/ it includes a couple of examples that should get you started.

Upvotes: 3

sashoalm
sashoalm

Reputation: 79527

It seems there are no classes that do this in Qt, so it is impossible to do with only Qt functions currently.

Upvotes: 1

Related Questions