Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LVS Key Suggestor does not return trust anchor #60

Open
tianyuan129 opened this issue Nov 12, 2022 · 1 comment
Open

LVS Key Suggestor does not return trust anchor #60

tianyuan129 opened this issue Nov 12, 2022 · 1 comment

Comments

@tianyuan129
Copy link
Contributor

tianyuan129 commented Nov 12, 2022

The highlighted piece of code avoids returning all self-signed certificates.

# This is to avoid self-signed certificate
if (not cert.signature_info or not cert.signature_info.key_locator
        or not cert.signature_info.key_locator.name):
    continue

If trust anchor is in the keychain, the key suggestor never returns it even if it's a valid signer.

@zjkmxy
Copy link
Member

zjkmxy commented Nov 12, 2022

This is because the design and implementation of the suggest function did not consider the use by controller.
To add more context: this code is added to fix the problem that the function may return a self-signed certificate that is not the trust anchor but satisfies the trust schema's check, as we only check packet name vs cert name, but not further move to cert name vs cert's signer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants