Use key_type column for cert get/rotate/reissue/display

Added unit tests
This commit is contained in:
sayali
2020-09-23 15:16:19 -07:00
parent 12af0ecb45
commit cd13832377
6 changed files with 20 additions and 2 deletions

View File

@ -251,10 +251,13 @@ angular.module('lemur')
$scope.certificate.csr = null; // should not clone CSR in case other settings are changed in clone
$scope.certificate.validityStart = null;
$scope.certificate.validityEnd = null;
$scope.certificate.keyType = 'RSA2048'; // default algo to show during clone
$scope.certificate.description = 'Cloning from cert ID ' + editId;
$scope.certificate.replacedBy = []; // should not clone 'replaced by' info
$scope.certificate.removeReplaces(); // should not clone 'replacement cert' info
if(!$scope.certificate.keyType) {
$scope.certificate.keyType = 'RSA2048'; // default algo to show during clone if backend did not return algo
}
CertificateService.getDefaults($scope.certificate);
});

View File

@ -111,6 +111,8 @@
<div class="list-group-item">
<dt>Key Length</dt>
<dd>{{ certificate.bits }}</dd>
<dt>Key Type</dt>
<dd>{{ certificate.keyType }}</dd>
<dt>Signing Algorithm</dt>
<dd>{{ certificate.signingAlgorithm }}</dd>
</div>