From f6c53ea900e677577ae5261fbc208beefb614e75 Mon Sep 17 00:00:00 2001 From: "narrieta@microsoft" Date: Fri, 25 Oct 2024 11:22:00 -0700 Subject: [PATCH] review --- azurelinuxagent/ga/policy/policy_engine.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/azurelinuxagent/ga/policy/policy_engine.py b/azurelinuxagent/ga/policy/policy_engine.py index 5bb8a3d3aa..065589f675 100644 --- a/azurelinuxagent/ga/policy/policy_engine.py +++ b/azurelinuxagent/ga/policy/policy_engine.py @@ -147,7 +147,7 @@ def _parse_policy(policy): @staticmethod def _parse_policy_version(policy): """ - Validate and return "policyVersion" attribute. If not a string in the format "x.y.z", raise InvalidPolicyError. + Validate and return "policyVersion" attribute. If not a string in the format "major[.minor[.patch]]", raise InvalidPolicyError. If policy_version is greater than maximum supported version, raise InvalidPolicyError. """ version = _PolicyEngine._get_string(policy, attribute="policyVersion") @@ -280,8 +280,6 @@ class ExtensionPolicyEngine(_PolicyEngine): def should_allow_extension(self, extension_name): """ Return whether we should allow extension download based on policy. - extension_to_check is expected to be an Extension object. - If policy feature not enabled, return True. If allowListedExtensionsOnly=true, return true only if extension present in "extensions" allowlist. If allowListedExtensions=false, return true always. @@ -298,7 +296,6 @@ def should_allow_extension(self, extension_name): def should_enforce_signature_validation(self, extension_name): """ Return whether we should enforce signature based on policy. - If policy feature not enabled, return False. Individual policy takes precedence over global. """