Repository navigation
Read AYON_CA_FILE and use the same CA in generativeCorePost - #62
Open
MustafaJafar wants to merge 1 commit into
Open
MustafaJafar wants to merge 1 commit into
MustafaJafar wants to merge 1 commit into
Conversation
- The constructor now checks AYON_CA_FILE first (the variable ayon-python-api and the AYON launcher read), then AYON_SSL_CERT_PATH, then the existing setSSL() lookup. A variable that points at something that is not a file is reported and skipped instead of being handed to httplib. - generativeCorePost creates its own httplib::Client per call, which did not inherit the CA of the main client. It now applies m_caCertPath, so a self-signed AYON server is trusted on that path too. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
The CA lookup only knew
AYON_SSL_CERT_PATH, whileayon-python-apiand the AYON launcher readAYON_CA_FILE. With a self-signed server (for example a localayon-dockerbehind Caddy), the resolver fell back toSSL_CERT_FILE, which the launcher sets to certifi, and failed withFailed to connect to the Ayon server.Also,
generativeCorePostbuilds its ownhttplib::Clientper call, and a new client does not inherit the CA of the main client.Changelog
AYON_CA_FILEfirst, thenAYON_SSL_CERT_PATH, then the existingsetSSL()lookup.AYON_SSL_CERT_PATHkeeps working.generativeCorePostappliesm_caCertPath(already recorded by every lookup branch) to its client and enables server certificate verification when the server URL is https.Testing:
manual Testing notes:
I believe it resolves down to:
AYON_CA_FILEset to a valid file: usedAYON_CA_FILEset to a missing path,AYON_SSL_CERT_PATHvalid: warning, falls back toAYON_SSL_CERT_PATHsetSSL())