Commit f573e286 authored by Léo-Paul Géneau's avatar Léo-Paul Géneau 👾

libnetworkcache: make verification method public

Move `_verifySignatureInCertificateList` to a public method
parent 2a079ea3
Pipeline #18709 passed with stage
in 0 seconds
......@@ -421,7 +421,7 @@ class NetworkcacheClient(object):
raise NetworkcacheException('Failed to parse json response (%r)' % data)
if filter:
return (data for data in data_list
if self._verifySignatureInCertificateList(*data))
if self.verifySignatureInCertificateList(*data))
return data_list
def _getSignatureString(self, content):
......@@ -433,7 +433,7 @@ class NetworkcacheClient(object):
return ''
return b64encode(crypto.sign(k, content, 'sha1')).decode()
def _verifySignatureInCertificateList(self, content, signature_string):
def verifySignatureInCertificateList(self, content, signature_string):
"""
Returns true if it can find any valid certificate or false if it does not
find any.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment