feat(certificates): add certificate import, export, and deletion support (server handlers, request types, and UI)
This commit is contained in:
@@ -74,3 +74,68 @@ export interface IReq_ReprovisionCertificateDomain extends plugins.typedrequestI
|
||||
message?: string;
|
||||
};
|
||||
}
|
||||
|
||||
// Delete a certificate by domain
|
||||
export interface IReq_DeleteCertificate extends plugins.typedrequestInterfaces.implementsTR<
|
||||
plugins.typedrequestInterfaces.ITypedRequest,
|
||||
IReq_DeleteCertificate
|
||||
> {
|
||||
method: 'deleteCertificate';
|
||||
request: {
|
||||
identity?: authInterfaces.IIdentity;
|
||||
domain: string;
|
||||
};
|
||||
response: {
|
||||
success: boolean;
|
||||
message?: string;
|
||||
};
|
||||
}
|
||||
|
||||
// Export a certificate as ICert JSON
|
||||
export interface IReq_ExportCertificate extends plugins.typedrequestInterfaces.implementsTR<
|
||||
plugins.typedrequestInterfaces.ITypedRequest,
|
||||
IReq_ExportCertificate
|
||||
> {
|
||||
method: 'exportCertificate';
|
||||
request: {
|
||||
identity?: authInterfaces.IIdentity;
|
||||
domain: string;
|
||||
};
|
||||
response: {
|
||||
success: boolean;
|
||||
cert?: {
|
||||
id: string;
|
||||
domainName: string;
|
||||
created: number;
|
||||
validUntil: number;
|
||||
privateKey: string;
|
||||
publicKey: string;
|
||||
csr: string;
|
||||
};
|
||||
message?: string;
|
||||
};
|
||||
}
|
||||
|
||||
// Import a certificate from ICert JSON
|
||||
export interface IReq_ImportCertificate extends plugins.typedrequestInterfaces.implementsTR<
|
||||
plugins.typedrequestInterfaces.ITypedRequest,
|
||||
IReq_ImportCertificate
|
||||
> {
|
||||
method: 'importCertificate';
|
||||
request: {
|
||||
identity?: authInterfaces.IIdentity;
|
||||
cert: {
|
||||
id: string;
|
||||
domainName: string;
|
||||
created: number;
|
||||
validUntil: number;
|
||||
privateKey: string;
|
||||
publicKey: string;
|
||||
csr: string;
|
||||
};
|
||||
};
|
||||
response: {
|
||||
success: boolean;
|
||||
message?: string;
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user