Skip to content

Commit 896692d

Browse files
committed
Fixed issue with certificate requests and key types
Fixed an issue with Elliptic Curve values not being accepted by VaaS because they are in lowercase
1 parent b084d3a commit 896692d

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

vcert/connection_cloud.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -974,11 +974,11 @@ def _get_service_generated_csr_attr(self, request, zone):
974974
kt_param = {
975975
CSR_ATTR_KEY_TYPE: request.key_type.key_type.upper()
976976
}
977-
kt_option = request.key_type.key_type.lower()
978-
if kt_option == KeyType.RSA:
977+
kt_type = request.key_type.key_type.lower()
978+
if kt_type == KeyType.RSA:
979979
kt_param[CSR_ATTR_KEY_LENGTH] = request.key_type.option
980-
elif request.key_type.key_type == KeyType.ECDSA:
981-
kt_param[CSR_ATTR_KEY_CURVE] = request.key_type.option
980+
elif kt_type == KeyType.ECDSA:
981+
kt_param[CSR_ATTR_KEY_CURVE] = request.key_type.option.upper()
982982

983983
csr_attr_map[CSR_ATTR_KEY_TYPE_PARAMS] = kt_param
984984
elif ps.defaults and ps.defaults.key_pair:

0 commit comments

Comments
 (0)