Fix cursive named arguments
Change I08a32215d2ff40299919f859f8d18f5400641311 intruduced named
arguments when using cursive.
However, those named arguments were incorrect. See
b2aba64263/cursive/signature_utils.py (L175-L190)
for the correct arguments.
This commit fixes those named arguments, and updates the
fake_get_verifier method to reflect the get_verifier method in the
cursive library.
Change-Id: Ic5f1fe232b0553df8806278c9fc3b3445a0f9f1a
This commit is contained in:
parent
b50cd90f65
commit
e8e0abdb1e
@ -421,9 +421,11 @@ class ImageProxy(glance.domain.proxy.Image):
|
||||
key_type = extra_props[signature_utils.KEY_TYPE]
|
||||
cert_uuid = extra_props[signature_utils.CERT_UUID]
|
||||
verifier = signature_utils.get_verifier(
|
||||
context=self.context, cert_uuid=cert_uuid,
|
||||
hash_method=hash_method, img_signature=img_signature,
|
||||
key_type=key_type
|
||||
context=self.context,
|
||||
img_signature_certificate_uuid=cert_uuid,
|
||||
img_signature_hash_method=hash_method,
|
||||
img_signature=img_signature,
|
||||
img_signature_key_type=key_type
|
||||
)
|
||||
else:
|
||||
verifier = None
|
||||
|
@ -85,8 +85,9 @@ def fake_get_size_from_backend(uri, context=None):
|
||||
return 1
|
||||
|
||||
|
||||
def fake_get_verifier(context, cert_uuid, hash_method,
|
||||
img_signature, key_type):
|
||||
def fake_get_verifier(context, img_signature_certificate_uuid,
|
||||
img_signature_hash_method, img_signature,
|
||||
img_signature_key_type):
|
||||
verifier = mock.Mock()
|
||||
if (img_signature is not None and img_signature == 'VALID'):
|
||||
verifier.verify.return_value = None
|
||||
|
Loading…
Reference in New Issue
Block a user