-
Notifications
You must be signed in to change notification settings - Fork 1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Loading the CA trusted store certificate into Feast to verify t…
…he public certificate. (#4852) * Initial Draft version to load the CA trusted store code. Signed-off-by: lrangine <[email protected]> * Initial Draft version to load the CA trusted store code. Signed-off-by: lrangine <[email protected]> * Fixing the lint error. Signed-off-by: lrangine <[email protected]> * Trying to fix the online store test cases. Signed-off-by: lrangine <[email protected]> * Formatted the python to fix lint errors. Signed-off-by: lrangine <[email protected]> * Fixing the unit test cases. Signed-off-by: lrangine <[email protected]> * Fixing the unit test cases. Signed-off-by: lrangine <[email protected]> * removing unnecessary cli args. Signed-off-by: lrangine <[email protected]> * Now configuring the SSL ca store configurations on the feast client side rather than on the server side. And also fixing the integration tests. Signed-off-by: lrangine <[email protected]> * Renamed the remote registry is_tls_mode variable to is_tls. Changed the offline store TLS setting decision from cert to scheme. Signed-off-by: lrangine <[email protected]> * Adding the existing trust store certificates to the newly created trust store. Signed-off-by: lrangine <[email protected]> * Clearing the existing trust store configuration to see if it fixes the PR integration failures. Signed-off-by: lrangine <[email protected]> * Clearing the existing trust store configuration to see if it fixes the PR integration failures. Signed-off-by: lrangine <[email protected]> * Clearing the existing trust store configuration to see if it fixes the PR integration failures. Signed-off-by: lrangine <[email protected]> * combining the default system ca store with the custom one to fix the integration tests. Signed-off-by: lrangine <[email protected]> * Final clean up and adding documentation. Signed-off-by: lrangine <[email protected]> * Incorporating the code review comments from Francisco. Signed-off-by: lrangine <[email protected]> --------- Signed-off-by: lrangine <[email protected]>
- Loading branch information
1 parent
739eaa7
commit 132ce2a
Showing
13 changed files
with
320 additions
and
115 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import logging | ||
import os | ||
|
||
logger = logging.getLogger(__name__) | ||
logger.setLevel(logging.INFO) | ||
|
||
|
||
def configure_ca_trust_store_env_variables(): | ||
""" | ||
configures the environment variable so that other libraries or servers refer to the TLS ca file path. | ||
:param ca_file_path: | ||
:return: | ||
""" | ||
if ( | ||
"FEAST_CA_CERT_FILE_PATH" in os.environ | ||
and os.environ["FEAST_CA_CERT_FILE_PATH"] | ||
): | ||
logger.info( | ||
f"Feast CA Cert file path found in environment variable FEAST_CA_CERT_FILE_PATH={os.environ['FEAST_CA_CERT_FILE_PATH']}. Going to refer this path." | ||
) | ||
os.environ["SSL_CERT_FILE"] = os.environ["FEAST_CA_CERT_FILE_PATH"] | ||
os.environ["REQUESTS_CA_BUNDLE"] = os.environ["FEAST_CA_CERT_FILE_PATH"] |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.