-
-
Notifications
You must be signed in to change notification settings - Fork 126
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Describe the bug
- In V1, when creating a certificate authority, there is a field called 'method' to specify a creation method - import or internal, as internal generates new crt and prv fields. When the method is 'import', a 'prv' field is not needed, and pfSense can use CA without specifying their private key.
In Certificate Authority creation #519 , you created an option to generate values for the 'crt' and 'key' fields in V2.
The functionality of importing external certificate authority without the 'prv' field is still missing in V2. - In addition, when importing an external certificate, using the 'crt' and 'prv' fields, the certificate appears to be created without an association to a CA object already existing in pfSense, even though it is issued by it.
An interesting phenomenon is that when clicking 'edit' in the web configurator on the certificate object created with V2, making no changes, and clicking 'save', the pfSense suddenly recognizes the existing CA object as the issuer of this certificate.
Can it be related to the way the certificates are sent to the API? In V1 they were sent in base64 format, in V1 they were sent in plain text. Can you explain the difference?
I will stress that I'm sending the same request to /api/v1/system/certificate, with the 'crt' and 'prv' in base64, and with the 'import' method, and the certificate was created successfully and are shown as issued by the CA object.
To Reproduce
- send POST request to /api/v2/system/certificate_authority. The 'prv' field is mandatory.
- send a POST request to /api/v2/system/certificate.
specify the 'crt' and 'prv' fields using plain text X509 certificate.
the certificate is being created, but not appears to be signed by the existing CA object.
- Package Version V1 - v1.7.6
- Package Version V2 - v2.2.2
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working