diff --git a/.codecov.yml b/.codecov.yml index 6b8f4ad1869..9b70b5793cb 100644 --- a/.codecov.yml +++ b/.codecov.yml @@ -15,20 +15,23 @@ coverage: only_pulls: true project: azure: - paths: "tools/c7n_azure" + paths: ["tools/c7n_azure"] threshold: "1%" gcp: - paths: "tools/c7n_gcp" + paths: ["tools/c7n_gcp"] threshold: "1%" mailer: - paths: "tools/c7n_mailer" + paths: ["tools/c7n_mailer"] threshold: "3%" k8s: - paths: "tools/c7n_kube" + paths: ["tools/c7n_kube"] threshold: "1%" tf: - paths: "tools/c7n_terraform" + paths: ["tools/c7n_terraform"] threshold: "1%" + shiftleft: + paths: ["tools/c7n_left"] + threshold: "3%" # aws is weaved throughout core atm can't easily call it out separately custodian: # one of the tests is slightly variable coverage due to concurrency (0.01) diff --git a/.github/workflows/ci-main.yml b/.github/workflows/ci-main.yml index 318a43a3a96..9904b4f1c02 100644 --- a/.github/workflows/ci-main.yml +++ b/.github/workflows/ci-main.yml @@ -22,10 +22,13 @@ jobs: - name: Install Linter run: | python -m pip install --upgrade pip - pip install flake8==4.0.1 + pip install flake8 black - name: Lint Check run: | make lint + - name: Format Check + run: | + black --check tools/c7n_left Analyzer: runs-on: ubuntu-latest @@ -75,8 +78,7 @@ jobs: - name: Bootstrap poetry shell: bash run: | - curl -sL https://raw.githubusercontent.com/python-poetry/poetry/master/install-poetry.py \ - | python - -y --version $POETRY_VERSION + curl -sSL https://raw.githubusercontent.com/python-poetry/install.python-poetry.org/6161821b1d39fa30f92a677bba51abfc471f8aee/install-poetry.py | python3 - --version $POETRY_VERSION -y - name: Set up cache uses: actions/cache@v2 @@ -128,7 +130,7 @@ jobs: - name: Test shell: bash env: - COV_RUN: ${{ contains(matrix.python-version, '3.8') && contains(matrix.os, 'ubuntu') }} + COV_RUN: ${{ contains(matrix.python-version, '3.10') && contains(matrix.os, 'ubuntu') }} run: | if [[ "$COV_RUN" == "true" ]] then @@ -136,7 +138,9 @@ jobs: . test.env && poetry run pytest -n auto tests tools \ --cov c7n --cov tools/c7n_azure/c7n_azure \ --cov tools/c7n_gcp/c7n_gcp --cov tools/c7n_kube/c7n_kube \ - --cov tools/c7n_mailer/c7n_mailer --cov tools/c7n_tencentcloud/c7n_tencentcloud + --cov tools/c7n_tencentcloud/c7n_tencentcloud \ + --cov tools/c7n_left/c7n_left \ + --cov tools/c7n_mailer/c7n_mailer poetry run coverage xml else . test.env && poetry run pytest -n auto tests tools @@ -144,7 +148,7 @@ jobs: - name: Upload Code Coverage uses: codecov/codecov-action@v2 - if: contains(matrix.python-version, '3.8') && contains(matrix.os, 'ubuntu') + if: contains(matrix.python-version, '3.10') && contains(matrix.os, 'ubuntu') with: files: ./coverage.xml name: codecov diff --git a/Makefile b/Makefile index 22930601243..baf83707eb1 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,18 @@ SELF_MAKE := $(lastword $(MAKEFILE_LIST)) PKG_REPO = testpypi -PKG_SET = tools/c7n_gcp tools/c7n_kube tools/c7n_openstack tools/c7n_mailer tools/c7n_logexporter tools/c7n_policystream tools/c7n_trailcreator tools/c7n_org tools/c7n_sphinxext tools/c7n_terraform tools/c7n_awscc tools/c7n_tencentcloud tools/c7n_azure +PKG_SET := tools/c7n_gcp tools/c7n_kube tools/c7n_openstack tools/c7n_mailer tools/c7n_logexporter tools/c7n_policystream tools/c7n_trailcreator tools/c7n_org tools/c7n_sphinxext tools/c7n_terraform tools/c7n_awscc tools/c7n_tencentcloud tools/c7n_azure + +PLATFORM_ARCH := $(shell python3 -c "import platform; print(platform.machine())") +PLATFORM_OS := $(shell python3 -c "import platform; print(platform.system())") +PY_VERSION := $(shell python3 -c "import sys; print('%s.%s' % (sys.version_info.major, sys.version_info.minor))") + + +ifneq "$(findstring $(PLATFORM_OS), Linux Darwin)" "" + ifneq "$(findstring $(PY_VERSION), 3.10)" "" + PKG_SET := tools/c7n_left $(PKG_SET) + endif +endif + install: python3 -m venv . diff --git a/c7n/loader.py b/c7n/loader.py index 4cc018bdc17..67aad510132 100644 --- a/c7n/loader.py +++ b/c7n/loader.py @@ -185,8 +185,9 @@ def _validate(data): log.error("Configuration invalid: {}".format(data)) log.error("%s" % e) errors.append(e) - load_resources(structure.get_resource_types(data)) - schm = schema.generate() + rtypes = structure.get_resource_types(data) + load_resources(rtypes) + schm = schema.generate(rtypes) errors += schema.validate(data, schm) return errors diff --git a/c7n/policy.py b/c7n/policy.py index f075dc0c16e..52e11fcb7e6 100644 --- a/c7n/policy.py +++ b/c7n/policy.py @@ -24,6 +24,7 @@ from c7n import deprecated, utils from c7n.version import version from c7n.query import RetryPageIterator +from c7n.varfmt import VarFormat log = logging.getLogger('c7n.policy') @@ -1132,7 +1133,9 @@ def resource_type(self) -> str: @property def provider_name(self) -> str: - if '.' in self.resource_type: + if isinstance(self.resource_type, list): + provider_name, _ = self.resource_type[0].split('.', 1) + elif '.' in self.resource_type: provider_name, resource_type = self.resource_type.split('.', 1) else: provider_name = 'aws' @@ -1243,7 +1246,9 @@ def expand_variables(self, variables): Updates the policy data in-place. """ # format string values returns a copy - updated = utils.format_string_values(self.data, **variables) + var_fmt = VarFormat() + updated = utils.format_string_values( + self.data, formatter=var_fmt.format, **variables) # Several keys should only be expanded at runtime, perserve them. if 'member-role' in updated.get('mode', {}): diff --git a/c7n/provider.py b/c7n/provider.py index f3e883deed5..102ec16c563 100644 --- a/c7n/provider.py +++ b/c7n/provider.py @@ -69,7 +69,10 @@ def import_resource_classes(resource_map, resource_types): if r not in resource_map: not_found.add(r) continue - rmodule, rclass = resource_map[r].rsplit('.', 1) + provider_value = resource_map[r] + if isinstance(provider_value, type): + continue + rmodule, rclass = provider_value.rsplit('.', 1) rmods.add(rmodule) for rmodule in rmods: @@ -78,6 +81,10 @@ def import_resource_classes(resource_map, resource_types): for rtype in resource_types: if rtype in not_found: continue + provider_value = resource_map[rtype] + if isinstance(provider_value, type): + found.append(provider_value) + continue rmodule, rclass = resource_map[rtype].rsplit('.', 1) r = getattr(mod_map[rmodule], rclass, None) if r is None: @@ -102,6 +109,8 @@ def resources(cloud_provider=None): def get_resource_class(resource_type): + if isinstance(resource_type, list): + resource_type = resource_type[0] if '.' in resource_type: provider_name, resource = resource_type.split('.', 1) else: diff --git a/c7n/resources/__init__.py b/c7n/resources/__init__.py index 7900052e0b1..9ffcd734100 100644 --- a/c7n/resources/__init__.py +++ b/c7n/resources/__init__.py @@ -28,16 +28,16 @@ def load_resources(resource_types=('*',)): return missing -def should_load_provider(name, provider_types): +def should_load_provider(name, provider_types, no_wild=False): global LOADED if (name not in LOADED and - ('*' in provider_types or - name in provider_types)): + (('*' in provider_types and not no_wild) + or name in provider_types)): return True return False -PROVIDER_NAMES = ('aws', 'azure', 'gcp', 'k8s', 'openstack', 'awscc', 'tencentcloud') +PROVIDER_NAMES = ('aws', 'azure', 'gcp', 'k8s', 'openstack', 'awscc', 'tencentcloud', 'terraform') def load_available(resources=True): @@ -93,6 +93,10 @@ def load_providers(provider_types): from c7n_tencentcloud.entry import initialize_tencentcloud initialize_tencentcloud() + if should_load_provider('terraform', provider_types, no_wild=True): + from c7n_left.entry import initialize_iac + initialize_iac() + if should_load_provider('c7n', provider_types): from c7n import data # noqa diff --git a/c7n/resources/appelb.py b/c7n/resources/appelb.py index 86d44427ff0..a310e05cfdf 100644 --- a/c7n/resources/appelb.py +++ b/c7n/resources/appelb.py @@ -5,6 +5,7 @@ """ import json import logging +import re from collections import defaultdict from c7n.actions import ActionRegistry, BaseAction, ModifyVpcSecurityGroupsAction @@ -255,6 +256,10 @@ def process(self, resources, event=None): class WafV2Enabled(Filter): """Filter Application LoadBalancer by wafv2 web-acl + Supports regex expression for web-acl. + Firewall Manager pushed WebACL's name varies by account and region. + Regex expression can support both local and Firewall Managed WebACL. + :example: .. code-block:: yaml @@ -266,21 +271,35 @@ class WafV2Enabled(Filter): - type: wafv2-enabled state: false web-acl: testv2 + + - name: filter-wafv2-elb-regex + resource: app-elb + filters: + - type: wafv2-enabled + state: false + web-acl: .*FMManagedWebACLV2-?FMS-.* """ schema = type_schema( 'wafv2-enabled', **{ 'web-acl': {'type': 'string'}, 'state': {'type': 'boolean'}}) - permissions = ('wafv2:ListResourcesForWebACL', 'wafv2:ListWebACLs') + retry = staticmethod(get_retry(( + 'ThrottlingException', + 'RequestLimitExceeded', + 'Throttled', + 'ThrottledException', + 'Throttling', + 'Client.RequestLimitExceeded'))) + # TODO verify name uniqueness within region/account # TODO consider associated resource fetch in augment def process(self, resources, event=None): client = local_session(self.manager.session_factory).client('wafv2') - target_acl = self.data.get('web-acl') + target_acl = self.data.get('web-acl', '') state = self.data.get('state', False) name_arn_map = {} @@ -290,35 +309,36 @@ def process(self, resources, event=None): for w in wafs: if 'c7n:AssociatedResources' not in w: - arns = client.list_resources_for_web_acl( - WebACLArn=w['ARN']).get('ResourceArns', []) + arns = self.retry( + client.list_resources_for_web_acl, + WebACLArn=w.get('ARN', ''), + ResourceType='APPLICATION_LOAD_BALANCER').get('ResourceArns', []) w['c7n:AssociatedResources'] = arns name_arn_map[w['Name']] = w['ARN'] for r in w['c7n:AssociatedResources']: resource_map[r] = w['ARN'] - target_acl_id = name_arn_map.get(target_acl, target_acl) + target_acl_ids = [v for k, v in name_arn_map.items() if + re.match(target_acl, k)] + arn_key = self.manager.resource_type.id state_map = {} for r in resources: arn = r[arn_key] - if arn in resource_map: - # NLB & GLB doesn't support WAF. So, skip such resources - if r['Type'] == 'application': - r['c7n_webacl'] = resource_map[arn] - if not target_acl: - state_map[arn] = True - continue - r_acl = resource_map[arn] - if r_acl == target_acl_id: - state_map[arn] = True - continue - state_map[arn] = False - else: - # NLB & GLB doesn't support WAF. So, skip such resources - if r['Type'] == 'application': - state_map[arn] = False - return [r for r in resources if r[arn_key] in state_map and state_map[r[arn_key]] == state] + # NLB & GLB doesn't support WAF. So, skip such resources + if r['Type'] != 'application': + continue + if arn not in resource_map: + state_map[arn] = False + continue + if not target_acl: + state_map[arn] = True + continue + if resource_map[arn] in target_acl_ids: + state_map[arn] = True + continue + state_map[arn] = False + return [r for r in resources if state_map[r[arn_key]] == state] @AppELB.action_registry.register('set-waf') @@ -403,6 +423,8 @@ def process(self, resources): class SetWafV2(BaseAction): """Enable wafv2 protection on Application LoadBalancer. + Supports regex expression for web-acl + :example: .. code-block:: yaml @@ -427,16 +449,37 @@ class SetWafV2(BaseAction): actions: - type: set-wafv2 state: true - web-acl: testv2 + + policies: + - name: set-wafv2-for-elb-regex + resource: app-elb + filters: + - type: wafv2-enabled + state: false + web-acl: .*FMManagedWebACLV2-?FMS-.* + actions: + - type: set-wafv2 + state: true + web-acl: FMManagedWebACLV2-?FMS-TestWebACL """ - permissions = ('wafv2:AssociateWebACL', 'wafv2:ListWebACLs') + permissions = ('wafv2:AssociateWebACL', + 'wafv2:DisassociateWebACL', + 'wafv2:ListWebACLs') schema = type_schema( - 'set-wafv2', required=['web-acl'], **{ + 'set-wafv2', **{ 'web-acl': {'type': 'string'}, 'state': {'type': 'boolean'}}) + retry = staticmethod(get_retry(( + 'ThrottlingException', + 'RequestLimitExceeded', + 'Throttled', + 'ThrottledException', + 'Throttling', + 'Client.RequestLimitExceeded'))) + def validate(self): found = False for f in self.manager.iter_filters(): @@ -453,12 +496,17 @@ def validate(self): def process(self, resources): wafs = self.manager.get_resource_manager('wafv2').resources(augment=False) name_id_map = {w['Name']: w['ARN'] for w in wafs} - target_acl = self.data.get('web-acl') - target_acl_id = name_id_map.get(target_acl, target_acl) state = self.data.get('state', True) - if state and target_acl_id not in name_id_map.values(): - raise ValueError("invalid web acl: %s" % (target_acl_id)) + target_acl_id = '' + if state: + target_acl = self.data.get('web-acl', '') + target_acl_ids = [v for k, v in name_id_map.items() if + re.match(target_acl, k)] + if len(target_acl_ids) != 1: + raise ValueError(f'{target_acl} matching to none or ' + f'multiple webacls') + target_acl_id = target_acl_ids[0] client = local_session( self.manager.session_factory).client('wafv2') @@ -469,11 +517,12 @@ def process(self, resources): # TODO investigate limits on waf association. for r in resources: if state: - client.associate_web_acl( - WebACLArn=target_acl_id, ResourceArn=r[arn_key]) + self.retry(client.associate_web_acl, + WebACLArn=target_acl_id, + ResourceArn=r[arn_key]) else: - client.disassociate_web_acl( - WebACLArn=target_acl_id, ResourceArn=r[arn_key]) + self.retry(client.disassociate_web_acl, + ResourceArn=r[arn_key]) @AppELB.action_registry.register('set-s3-logging') diff --git a/c7n/resources/cloudfront.py b/c7n/resources/cloudfront.py index 6fc20607ade..5e7276261b1 100644 --- a/c7n/resources/cloudfront.py +++ b/c7n/resources/cloudfront.py @@ -181,6 +181,13 @@ class IsWafV2Enabled(Filter): - type: wafv2-enabled state: false web-acl: testv2 + + - name: filter-distribution-wafv2-regex + resource: distribution + filters: + - type: wafv2-enabled + state: false + web-acl: .*FMManagedWebACLV2-?FMS-.* """ schema = type_schema( @@ -194,24 +201,24 @@ def process(self, resources, event=None): query = {'Scope': 'CLOUDFRONT'} wafs = self.manager.get_resource_manager('wafv2').resources(query, augment=False) waf_name_id_map = {w['Name']: w['ARN'] for w in wafs} + + target_acl = self.data.get('web-acl', '') state = self.data.get('state', False) - target_acl = self.data.get('web-acl') - target_acl_id = waf_name_id_map.get(target_acl, target_acl) + target_acl_ids = [v for k, v in waf_name_id_map.items() if + re.match(target_acl, k)] results = [] for r in resources: r_web_acl_id = r.get('WebACLId') if state: - if target_acl_id is None and r_web_acl_id \ - and r_web_acl_id in waf_name_id_map.values(): + if not target_acl and r_web_acl_id: results.append(r) - elif target_acl_id and r_web_acl_id == target_acl_id: + elif target_acl and r_web_acl_id in target_acl_ids: results.append(r) else: - if target_acl_id is None and (not r_web_acl_id or r_web_acl_id and - r_web_acl_id not in waf_name_id_map.values()): + if not target_acl and not r_web_acl_id: results.append(r) - elif target_acl_id and r_web_acl_id != target_acl_id: + elif target_acl and r_web_acl_id not in target_acl_ids: results.append(r) return results @@ -510,10 +517,21 @@ class SetWafv2(BaseAction): force: true web-acl: test + policies: + - name: set-wafv2-for-cloudfront-regex + resource: distribution + filters: + - type: wafv2-enabled + state: false + web-acl: .*FMManagedWebACLV2-?FMS-.* + actions: + - type: set-wafv2 + state: true + web-acl: FMManagedWebACLV2-?FMS-TestWebACL """ permissions = ('cloudfront:UpdateDistribution', 'wafv2:ListWebACLs') schema = type_schema( - 'set-wafv2', required=['web-acl'], **{ + 'set-wafv2', **{ 'web-acl': {'type': 'string'}, 'force': {'type': 'boolean'}, 'state': {'type': 'boolean'}}) @@ -524,10 +542,17 @@ def process(self, resources): query = {'Scope': 'CLOUDFRONT'} wafs = self.manager.get_resource_manager('wafv2').resources(query, augment=False) waf_name_id_map = {w['Name']: w['ARN'] for w in wafs} - target_acl = self.data.get('web-acl') - target_acl_id = waf_name_id_map.get(target_acl, target_acl) - if target_acl_id not in waf_name_id_map.values(): - raise ValueError("invalid web acl: %s" % (target_acl_id)) + state = self.data.get('state', True) + + target_acl_id = '' + if state: + target_acl = self.data.get('web-acl', '') + target_acl_ids = [v for k, v in waf_name_id_map.items() if + re.match(target_acl, k)] + if len(target_acl_ids) != 1: + raise ValueError(f'{target_acl} matching to none or ' + f'multiple webacls') + target_acl_id = target_acl_ids[0] client = local_session(self.manager.session_factory).client('cloudfront') force = self.data.get('force', False) diff --git a/c7n/resources/elasticsearch.py b/c7n/resources/elasticsearch.py index 52eb5f4c2bb..56ecc7a821d 100644 --- a/c7n/resources/elasticsearch.py +++ b/c7n/resources/elasticsearch.py @@ -3,7 +3,7 @@ import jmespath import json -from c7n.actions import Action, ModifyVpcSecurityGroupsAction, RemovePolicyBase +from c7n.actions import Action, BaseAction, ModifyVpcSecurityGroupsAction, RemovePolicyBase from c7n.filters import MetricsFilter, CrossAccountAccessFilter, ValueFilter from c7n.exceptions import PolicyValidationError from c7n.filters.vpc import SecurityGroupFilter, SubnetFilter, VpcFilter, Filter @@ -224,6 +224,75 @@ def get_std_format_args(self, domain): } +@ElasticSearchDomain.filter_registry.register('source-ip') +class SourceIP(Filter): + """ValueFilter-based filter for verifying allowed source ips in + an ElasticSearch domain's access policy. Useful for checking to see if + an ElasticSearch domain allows traffic from non approved IP addresses/CIDRs. + + :example: + Find ElasticSearch domains that allow traffic from IP addresses + not in the approved list (string matching) + .. code-block: yaml + + - type: source-ip + op: not-in + value: ["103.15.250.0/24", "173.240.160.0/21", "206.108.40.0/21"] + + Same as above but using cidr matching instead of string matching + .. code-block: yaml + - type: source-ip + op: not-in + value_type: cidr + value: ["103.15.250.0/24", "173.240.160.0/21", "206.108.40.0/21"] + """ + schema = type_schema('source-ip', rinherit=ValueFilter.schema) + permissions = ("es:DescribeElasticsearchDomainConfig",) + annotation = 'c7n:MatchedSourceIps' + + def __call__(self, resource): + es_access_policy = resource.get('AccessPolicies') + matched = [] + source_ips = self.get_source_ip_perms(json.loads(es_access_policy)) + if not self.data.get('key'): + self.data['key'] = 'SourceIp' + vf = ValueFilter(self.data, self.manager) + vf.annotate = False + for source_ip in source_ips: + found = vf(source_ip) + if found: + matched.append(source_ip) + + if matched: + resource[self.annotation] = matched + return True + return False + + def get_source_ip_perms(self, es_access_policy): + """Get SourceIps from the original access policy + """ + ip_perms = [] + stmts = es_access_policy.get('Statement', []) + for stmt in stmts: + source_ips = self.source_ips_from_stmt(stmt) + if not source_ips: + continue + ip_perms.extend([{'SourceIp': ip} for ip in source_ips]) + return ip_perms + + @classmethod + def source_ips_from_stmt(cls, stmt): + source_ips = [] + if stmt.get('Effect', '') == 'Allow': + ips = stmt.get('Condition', {}).get('IpAddress', {}).get('aws:SourceIp', []) + if len(ips) > 0: + if isinstance(ips, list): + source_ips.extend(ips) + else: + source_ips.append(ips) + return source_ips + + @ElasticSearchDomain.action_registry.register('remove-statements') class RemovePolicyStatement(RemovePolicyBase): """ @@ -426,6 +495,86 @@ class ElasticSearchMarkForOp(TagDelayedAction): """ +@ElasticSearchDomain.action_registry.register('remove-matched-source-ips') +class RemoveMatchedSourceIps(BaseAction): + """Action to remove matched source ips from a Access Policy. This action + needs to be used in conjunction with the source-ip filter. It can be used + for removing non-approved IP addresses from the the access policy of a + ElasticSearch domain. + + :example: + .. code-block:: yaml + policies: + - name: es-access-revoke + resource: elasticsearch + filters: + - type: source-ip + value_type: cidr + op: not-in + value_from: + url: s3://my-bucket/allowed_cidrs.csv + actions: + - type: remove-matched-source-ips + """ + + schema = type_schema('remove-matched-source-ips') + permissions = ('es:UpdateElasticsearchDomainConfig',) + + def validate(self): + for f in self.manager.iter_filters(): + if isinstance(f, SourceIP): + return self + + raise PolicyValidationError( + '`remove-matched-source-ips` can only be used in conjunction with ' + '`source-ip` filter on %s' % (self.manager.data,)) + + def process(self, resources): + client = local_session(self.manager.session_factory).client('es') + + for r in resources: + domain_name = r.get('DomainName', '') + # ES Access policy is defined as json string + accpol = json.loads(r.get('AccessPolicies', '')) + good_cidrs = [] + bad_ips = [] + + matched_key = SourceIP.annotation + for matched_perm in r.get(matched_key, []): + bad_ips.append(matched_perm.get('SourceIp')) + + if not bad_ips: + self.log.info('no matched IPs, no update needed') + return + + update_needed = False + for stmt in accpol.get('Statement', []): + source_ips = SourceIP.source_ips_from_stmt(stmt) + if not source_ips: + continue + + update_needed = True + good_ips = list(set(source_ips) - set(bad_ips)) + stmt['Condition']['IpAddress']['aws:SourceIp'] = good_ips + + if update_needed: + ap = self.update_accpol(client, domain_name, accpol, good_cidrs) + self.log.info('updated AccessPolicy: {}'.format(json.dumps(ap))) + + def update_accpol(self, client, domain_name, accpol, good_cidrs): + """Update access policy to only have good ip addresses + """ + for i, cidr in enumerate(good_cidrs): + if 'Condition' not in accpol.get('Statement', [])[i] or \ + accpol.get('Statement', [])[i].get('Effect', '') != 'Allow': + continue + accpol['Statement'][i]['Condition']['IpAddress']['aws:SourceIp'] = cidr + resp = client.update_elasticsearch_domain_config( + DomainName=domain_name, + AccessPolicies=json.dumps(accpol)) + return json.loads(resp.get('DomainConfig', {}).get('AccessPolicies', {}).get('Options', '')) + + @resources.register('elasticsearch-reserved') class ReservedInstances(QueryResourceManager): diff --git a/c7n/resources/resource_map.py b/c7n/resources/resource_map.py index 40f16e9ab28..18fd9a417ca 100644 --- a/c7n/resources/resource_map.py +++ b/c7n/resources/resource_map.py @@ -20,6 +20,7 @@ "aws.cache-snapshot": "c7n.resources.elasticache.ElastiCacheSnapshot", "aws.cache-subnet-group": "c7n.resources.elasticache.ElastiCacheSubnetGroup", "aws.catalog-portfolio": "c7n.resources.servicecatalog.CatalogPortfolio", + "aws.catalog-product": "c7n.resources.servicecatalog.CatalogProduct", "aws.cfn": "c7n.resources.cfn.CloudFormation", "aws.cloud-directory": "c7n.resources.directory.CloudDirectory", "aws.cloudhsm-cluster": "c7n.resources.hsm.CloudHSMCluster", diff --git a/c7n/resources/s3.py b/c7n/resources/s3.py index 553481a09e1..492bd5cb93b 100644 --- a/c7n/resources/s3.py +++ b/c7n/resources/s3.py @@ -111,6 +111,8 @@ def load_resource(self, item): resource.pop('Owner', None) for k, null_value in S3_CONFIG_SUPPLEMENT_NULL_MAP.items(): + if k not in cfg: + continue if cfg.get(k) == null_value: continue method = getattr(self, "handle_%s" % k, None) diff --git a/c7n/resources/servicecatalog.py b/c7n/resources/servicecatalog.py index 6ef545c28c5..9405d115581 100644 --- a/c7n/resources/servicecatalog.py +++ b/c7n/resources/servicecatalog.py @@ -169,3 +169,19 @@ def process(self, portfolios): client = local_session(self.manager.session_factory).client('servicecatalog') for p in portfolios: self.delete_shared_accounts(client, p) + + +@resources.register('catalog-product') +class CatalogProduct(QueryResourceManager): + + class resource_type(TypeInfo): + service = 'servicecatalog' + arn_type = 'catalog-product' + enum_spec = ('search_products_as_admin', 'ProductViewDetails[].ProductViewSummary', None) + detail_spec = ('describe_product_as_admin', 'Id', 'ProductId', None) + id = 'ProductId' + name = 'Name' + arn = 'ProductARN' + date = 'CreatedTime' + universal_taggable = object() + cfn_type = 'AWS::ServiceCatalog::CloudFormationProduct' diff --git a/c7n/resources/sqs.py b/c7n/resources/sqs.py index eb180ddf035..d628c661db3 100644 --- a/c7n/resources/sqs.py +++ b/c7n/resources/sqs.py @@ -3,6 +3,7 @@ from botocore.exceptions import ClientError import json +import re from c7n.actions import RemovePolicyBase, ModifyPolicyBase from c7n.filters import CrossAccountAccessFilter, MetricsFilter @@ -32,6 +33,7 @@ def _augment(r): QueueUrl=r, AttributeNames=['All'])['Attributes'] queue['QueueUrl'] = r + queue['QueueName'] = queue['QueueArn'].rsplit(':', 1)[-1] except ClientError as e: if e.response['Error']['Code'] == 'AWS.SimpleQueueService.NonExistentQueue': return @@ -331,6 +333,9 @@ def process_queue(self, client, queue): class SetEncryption(BaseAction): """Action to set encryption key on SQS queue + you can also optionally set data key 'reuse-period', or use with + the service managed encryption by not specifying a key. + :example: .. code-block:: yaml @@ -346,26 +351,48 @@ class SetEncryption(BaseAction): """ schema = type_schema( 'set-encryption', - key={'type': 'string'}, required=('key',)) + **{ + "enabled": {'type': 'boolean'}, + "reuse-period": {'type': 'integer', 'minimum': 60, 'maximum': 86400}, + "key": {'type': 'string'}} + ) permissions = ('sqs:SetQueueAttributes',) + uuid_regex = re.compile('[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}') def process(self, queues): - # get KeyId - key = "alias/" + self.data.get('key') - session = local_session(self.manager.session_factory) - key_id = session.client( - 'kms').describe_key(KeyId=key)['KeyMetadata']['KeyId'] + # compatibility, if key is given and not arn/key id/ or prefixed with + # alias, add alias to it. + key = self.data.get('key', None) + if (key + and not key.startswith('alias') + and not key.startswith('arn:') + and not self.uuid_regex.search(key)): + key = "alias/" + key + client = self.manager.get_client() + reuse_period = self.data.get('reuse-period', 300) + params = {} + if not self.data.get('enabled', True): + params['SqsManagedSseEnabled'] = 'false' + params['KmsMasterKeyId'] = '' + elif self.data.get('enable', True) and not key: + params['SqsManagedSseEnabled'] = 'true' + params['KmsMasterKeyId'] = '' + elif self.data.get('enable', True) and key: + params['SqsManagedSseEnabled'] = 'false' + params['KmsMasterKeyId'] = key + params['KmsDataKeyReusePeriodSeconds'] = str(reuse_period) + for q in queues: - self.process_queue(client, q, key_id) + self.process_queue(client, q, params) - def process_queue(self, client, queue, key_id): + def process_queue(self, client, queue, params): try: client.set_queue_attributes( QueueUrl=queue['QueueUrl'], - Attributes={'KmsMasterKeyId': key_id} + Attributes=params ) except (client.exceptions.QueueDoesNotExist,) as e: self.log.exception( diff --git a/c7n/schema.py b/c7n/schema.py index f71f3b9ec48..831ba644126 100644 --- a/c7n/schema.py +++ b/c7n/schema.py @@ -248,8 +248,9 @@ def generate(resource_types=()): 'tz': {'type': 'string'}, 'start': {'format': 'date-time'}, 'end': {'format': 'date-time'}, - - 'resource': {'type': 'string'}, + 'resource': {'oneOf': [ + {'type': 'string'}, + {'type': 'array', 'items': {'type': 'string'}}]}, 'max-resources': {'anyOf': [ {'type': 'integer', 'minimum': 1}, {'$ref': '#/definitions/max-resources-properties'} diff --git a/c7n/structure.py b/c7n/structure.py index d6dc6a5b9b2..f75e90c4b7c 100644 --- a/c7n/structure.py +++ b/c7n/structure.py @@ -81,11 +81,20 @@ def validate_policy(self, p): 'policy:%s action must be a mapping/dict found:%s' % ( p.get('name', 'unknown'), type(a).__name__))) + if isinstance(p.get('resource', ''), list): + if len({pr.split('.')[0] for pr in p['resource']}) > 1: + raise PolicyValidationError(( + "policy:%s multi resource is only allowed with a single provider" % ( + p.get('name', 'unknown')))) + def get_resource_types(self, data): resources = set() for p in data.get('policies', []): rtype = p['resource'] - if '.' not in rtype: + if isinstance(rtype, list): + resources.update(rtype) + continue + elif '.' not in rtype: rtype = 'aws.%s' % rtype resources.add(rtype) return resources diff --git a/c7n/utils.py b/c7n/utils.py index 61343038869..6ace9ad9fe5 100644 --- a/c7n/utils.py +++ b/c7n/utils.py @@ -471,7 +471,7 @@ def backoff_delays(start, stop, factor=2.0, jitter=False): def parse_cidr(value): """Process cidr ranges.""" - if isinstance(value, list): + if isinstance(value, list) or isinstance(value, set): return IPv4List([parse_cidr(item) for item in value]) klass = IPv4Network if '/' not in value: @@ -577,7 +577,7 @@ def set_value_from_jmespath(source, expression, value, is_first=True): source[current_key] = value -def format_string_values(obj, err_fallback=(IndexError, KeyError), *args, **kwargs): +def format_string_values(obj, err_fallback=(IndexError, KeyError), formatter=None, *args, **kwargs): """ Format all string values in an object. Return the updated object @@ -585,16 +585,19 @@ def format_string_values(obj, err_fallback=(IndexError, KeyError), *args, **kwar if isinstance(obj, dict): new = {} for key in obj.keys(): - new[key] = format_string_values(obj[key], *args, **kwargs) + new[key] = format_string_values(obj[key], formatter=formatter, *args, **kwargs) return new elif isinstance(obj, list): new = [] for item in obj: - new.append(format_string_values(item, *args, **kwargs)) + new.append(format_string_values(item, formatter=formatter, *args, **kwargs)) return new elif isinstance(obj, str): try: - return obj.format(*args, **kwargs) + if formatter: + return formatter(obj, *args, **kwargs) + else: + return obj.format(*args, **kwargs) except err_fallback: return obj else: diff --git a/c7n/varfmt.py b/c7n/varfmt.py new file mode 100644 index 00000000000..bcf3c7c1b5a --- /dev/null +++ b/c7n/varfmt.py @@ -0,0 +1,98 @@ +from string import Formatter + + +class VarFormat(Formatter): + """Behaves exactly like the stdlib formatter, with one additional behavior. + + when a string has no format_spec and only contains a single expression, + retain the type of the source object. + + inspired by https://pypyr.io/docs/substitutions/format-string/ + """ + + def _vformat( + self, format_string, args, kwargs, used_args, recursion_depth, auto_arg_index=0 + ): + # This is mostly verbatim from stdlib format.Formatter._vformat + # https://github.com/python/cpython/blob/main/Lib/string.py + # + # we have to copy alot of std logic to override the str cast + + if recursion_depth < 0: + raise ValueError('Max string recursion exceeded') + result = [] + for literal_text, field_name, format_spec, conversion in self.parse( + format_string + ): + + # output the literal text + if literal_text: + result.append((literal_text, True, None)) + + # if there's a field, output it + if field_name is not None: + # this is some markup, find the object and do + # the formatting + + # handle arg indexing when empty field_names are given. + if field_name == '': + if auto_arg_index is False: + raise ValueError( + 'cannot switch from manual field ' + 'specification to automatic field ' + 'numbering' + ) + field_name = str(auto_arg_index) + auto_arg_index += 1 + elif field_name.isdigit(): + if auto_arg_index: + raise ValueError( + 'cannot switch from manual field ' + 'specification to automatic field ' + 'numbering' + ) + # disable auto arg incrementing, if it gets + # used later on, then an exception will be raised + auto_arg_index = False + + # given the field_name, find the object it references + # and the argument it came from + obj, arg_used = self.get_field(field_name, args, kwargs) + used_args.add(arg_used) + + # do any conversion on the resulting object + obj = self.convert_field(obj, conversion) + + # expand the format spec, if needed + format_spec, auto_arg_index = self._vformat( + format_spec, + args, + kwargs, + used_args, + recursion_depth - 1, + auto_arg_index=auto_arg_index, + ) + + # defer format + result.append((obj, False, format_spec)) + + # if input is a single expression (ie. '{expr}' don't cast + # source to string. + if len(result) == 1: + obj, is_literal, format_spec = result[0] + if is_literal: + return obj, auto_arg_index + if format_spec: + return self.format_field(obj, format_spec), auto_arg_index + else: + return obj, auto_arg_index + else: + return ( + ''.join( + [ + obj if is_literal else self.format_field(obj, format_spec) + for obj, is_literal, format_spec in result + ] + ), + auto_arg_index, + ) diff --git a/docker/c7n b/docker/c7n index 2725335ad2c..4107737d396 100644 --- a/docker/c7n +++ b/docker/c7n @@ -30,9 +30,11 @@ ADD tools/c7n_kube /src/tools/c7n_kube RUN rm -R tools/c7n_kube/tests ADD tools/c7n_openstack /src/tools/c7n_openstack RUN rm -R tools/c7n_openstack/tests +ADD tools/c7n_tencentcloud /src/tools/c7n_tencentcloud +RUN rm -R tools/c7n_tencentcloud/tests # Install requested providers -ARG providers="gcp kube openstack azure" +ARG providers="gcp kube openstack tencentcloud azure" RUN . /usr/local/bin/activate && \ for pkg in $providers; do cd tools/c7n_$pkg && \ poetry install && cd ../../; done diff --git a/docker/c7n-distroless b/docker/c7n-distroless index e10a71eeda2..a27edbf0c4c 100644 --- a/docker/c7n-distroless +++ b/docker/c7n-distroless @@ -30,9 +30,11 @@ ADD tools/c7n_kube /src/tools/c7n_kube RUN rm -R tools/c7n_kube/tests ADD tools/c7n_openstack /src/tools/c7n_openstack RUN rm -R tools/c7n_openstack/tests +ADD tools/c7n_tencentcloud /src/tools/c7n_tencentcloud +RUN rm -R tools/c7n_tencentcloud/tests # Install requested providers -ARG providers="gcp kube openstack azure" +ARG providers="gcp kube openstack tencentcloud azure" RUN . /usr/local/bin/activate && \ for pkg in $providers; do cd tools/c7n_$pkg && \ poetry install && cd ../../; done diff --git a/docker/c7n-org b/docker/c7n-org index 46ccb1f3cb3..ff1f4fe4274 100644 --- a/docker/c7n-org +++ b/docker/c7n-org @@ -30,9 +30,11 @@ ADD tools/c7n_kube /src/tools/c7n_kube RUN rm -R tools/c7n_kube/tests ADD tools/c7n_openstack /src/tools/c7n_openstack RUN rm -R tools/c7n_openstack/tests +ADD tools/c7n_tencentcloud /src/tools/c7n_tencentcloud +RUN rm -R tools/c7n_tencentcloud/tests # Install requested providers -ARG providers="gcp kube openstack azure" +ARG providers="gcp kube openstack tencentcloud azure" RUN . /usr/local/bin/activate && \ for pkg in $providers; do cd tools/c7n_$pkg && \ poetry install && cd ../../; done diff --git a/docker/c7n-org-distroless b/docker/c7n-org-distroless index 38a64cdfda6..6abf0f786a0 100644 --- a/docker/c7n-org-distroless +++ b/docker/c7n-org-distroless @@ -30,9 +30,11 @@ ADD tools/c7n_kube /src/tools/c7n_kube RUN rm -R tools/c7n_kube/tests ADD tools/c7n_openstack /src/tools/c7n_openstack RUN rm -R tools/c7n_openstack/tests +ADD tools/c7n_tencentcloud /src/tools/c7n_tencentcloud +RUN rm -R tools/c7n_tencentcloud/tests # Install requested providers -ARG providers="gcp kube openstack azure" +ARG providers="gcp kube openstack tencentcloud azure" RUN . /usr/local/bin/activate && \ for pkg in $providers; do cd tools/c7n_$pkg && \ poetry install && cd ../../; done diff --git a/docker/mailer b/docker/mailer index 91d430036d1..f7f5ae4cad5 100644 --- a/docker/mailer +++ b/docker/mailer @@ -30,9 +30,11 @@ ADD tools/c7n_kube /src/tools/c7n_kube RUN rm -R tools/c7n_kube/tests ADD tools/c7n_openstack /src/tools/c7n_openstack RUN rm -R tools/c7n_openstack/tests +ADD tools/c7n_tencentcloud /src/tools/c7n_tencentcloud +RUN rm -R tools/c7n_tencentcloud/tests # Install requested providers -ARG providers="gcp kube openstack azure" +ARG providers="gcp kube openstack tencentcloud azure" RUN . /usr/local/bin/activate && \ for pkg in $providers; do cd tools/c7n_$pkg && \ poetry install && cd ../../; done diff --git a/docker/mailer-distroless b/docker/mailer-distroless index 902c543e51a..303717dbc7d 100644 --- a/docker/mailer-distroless +++ b/docker/mailer-distroless @@ -30,9 +30,11 @@ ADD tools/c7n_kube /src/tools/c7n_kube RUN rm -R tools/c7n_kube/tests ADD tools/c7n_openstack /src/tools/c7n_openstack RUN rm -R tools/c7n_openstack/tests +ADD tools/c7n_tencentcloud /src/tools/c7n_tencentcloud +RUN rm -R tools/c7n_tencentcloud/tests # Install requested providers -ARG providers="gcp kube openstack azure" +ARG providers="gcp kube openstack tencentcloud azure" RUN . /usr/local/bin/activate && \ for pkg in $providers; do cd tools/c7n_$pkg && \ poetry install && cd ../../; done diff --git a/docker/policystream b/docker/policystream index 6ca3d36e892..9f56f26f18c 100644 --- a/docker/policystream +++ b/docker/policystream @@ -30,9 +30,11 @@ ADD tools/c7n_kube /src/tools/c7n_kube RUN rm -R tools/c7n_kube/tests ADD tools/c7n_openstack /src/tools/c7n_openstack RUN rm -R tools/c7n_openstack/tests +ADD tools/c7n_tencentcloud /src/tools/c7n_tencentcloud +RUN rm -R tools/c7n_tencentcloud/tests # Install requested providers -ARG providers="gcp kube openstack azure" +ARG providers="gcp kube openstack tencentcloud azure" RUN . /usr/local/bin/activate && \ for pkg in $providers; do cd tools/c7n_$pkg && \ poetry install && cd ../../; done diff --git a/docker/policystream-distroless b/docker/policystream-distroless index c666a55abd8..6813857b99d 100644 --- a/docker/policystream-distroless +++ b/docker/policystream-distroless @@ -30,9 +30,11 @@ ADD tools/c7n_kube /src/tools/c7n_kube RUN rm -R tools/c7n_kube/tests ADD tools/c7n_openstack /src/tools/c7n_openstack RUN rm -R tools/c7n_openstack/tests +ADD tools/c7n_tencentcloud /src/tools/c7n_tencentcloud +RUN rm -R tools/c7n_tencentcloud/tests # Install requested providers -ARG providers="gcp kube openstack azure" +ARG providers="gcp kube openstack tencentcloud azure" RUN . /usr/local/bin/activate && \ for pkg in $providers; do cd tools/c7n_$pkg && \ poetry install && cd ../../; done diff --git a/docs/Makefile.sphinx b/docs/Makefile.sphinx index 70b1bf142bd..88dbfec717f 100644 --- a/docs/Makefile.sphinx +++ b/docs/Makefile.sphinx @@ -83,7 +83,7 @@ html: cp -p tools/omnissm/assets/omnissm.svg $(SRCDIR)/tools/assets/omnissm.svg cp -p tools/c7n_salactus/README.md $(SRCDIR)/tools/c7n-salactus.md cp -p tools/c7n_logexporter/README.md $(SRCDIR)/tools/c7n-logexporter.md - + cp -p tools/c7n_left/README.md $(SRCDIR)/tools/c7n-left.md mkdir -p $(SRCDIR)/aws/resources c7n-sphinxext --provider aws --output-dir $(SRCDIR)/aws/resources --group-by=resource_type.service mkdir -p $(SRCDIR)/awscc/resources diff --git a/poetry.lock b/poetry.lock index 37aef8ae288..cf425e5450f 100644 --- a/poetry.lock +++ b/poetry.lock @@ -64,14 +64,14 @@ dev = ["Sphinx (==4.3.2)", "black (==22.3.0)", "build (==0.8.0)", "flake8 (==4.0 [[package]] name = "boto3" -version = "1.24.79" +version = "1.24.87" description = "The AWS SDK for Python" category = "main" optional = false python-versions = ">= 3.7" [package.dependencies] -botocore = ">=1.27.79,<1.28.0" +botocore = ">=1.27.87,<1.28.0" jmespath = ">=0.7.1,<2.0.0" s3transfer = ">=0.6.0,<0.7.0" @@ -80,7 +80,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "botocore" -version = "1.27.79" +version = "1.27.87" description = "Low-level, data-driven core of boto 3." category = "main" optional = false @@ -96,7 +96,7 @@ crt = ["awscrt (==0.14.0)"] [[package]] name = "certifi" -version = "2022.9.14" +version = "2022.9.24" description = "Python package for providing Mozilla's CA Bundle." category = "main" optional = false @@ -146,7 +146,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" [[package]] name = "coverage" -version = "6.4.4" +version = "6.5.0" description = "Code coverage measurement for Python" category = "dev" optional = false @@ -268,7 +268,7 @@ python-versions = ">=3.5" [[package]] name = "importlib-metadata" -version = "4.12.0" +version = "4.13.0" description = "Read metadata from Python packages" category = "main" optional = false @@ -279,9 +279,9 @@ typing-extensions = {version = ">=3.6.4", markers = "python_version < \"3.8\""} zipp = ">=0.5" [package.extras] -docs = ["jaraco.packaging (>=9)", "rst.linker (>=1.9)", "sphinx"] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)"] perf = ["ipython"] -testing = ["flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] +testing = ["flake8 (<5)", "flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] [[package]] name = "importlib-resources" @@ -308,7 +308,7 @@ python-versions = "*" [[package]] name = "jaraco.classes" -version = "3.2.2" +version = "3.2.3" description = "Utility functions for Python class constructs" category = "dev" optional = false @@ -318,8 +318,8 @@ python-versions = ">=3.7" more-itertools = "*" [package.extras] -docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] -testing = ["pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)"] +testing = ["flake8 (<5)", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [[package]] name = "jeepney" @@ -721,7 +721,7 @@ python-versions = ">=3.6" [[package]] name = "readme-renderer" -version = "37.1" +version = "37.2" description = "readme_renderer is a library for rendering \"readme\" descriptions for Warehouse" category = "dev" optional = false @@ -979,16 +979,16 @@ bleach = [ {file = "bleach-5.0.1.tar.gz", hash = "sha256:0d03255c47eb9bd2f26aa9bb7f2107732e7e8fe195ca2f64709fcf3b0a4a085c"}, ] boto3 = [ - {file = "boto3-1.24.79-py3-none-any.whl", hash = "sha256:c05f82633b086a7aa6dba9edec56ba8137835d6eb2bfca98bedb32d93eb657a9"}, - {file = "boto3-1.24.79.tar.gz", hash = "sha256:973a23d629a7aed77a662fcd55505c210bc48642cddfc64a1a9f3dbd18468d19"}, + {file = "boto3-1.24.87-py3-none-any.whl", hash = "sha256:bcc579e801774cb2c7dda87ff985feda1ae7e10591d11ef37526363139138bd4"}, + {file = "boto3-1.24.87.tar.gz", hash = "sha256:3dd7ed74d1d29dd8094a078be86ed61c45de6638fe18856f7a1ff9282b4d929e"}, ] botocore = [ - {file = "botocore-1.27.79-py3-none-any.whl", hash = "sha256:10be90eb6ece83fc915b1bb15d2561a0ecefd33a7c1612a8f78da006f99d58f0"}, - {file = "botocore-1.27.79.tar.gz", hash = "sha256:1187a685f0205b8acdde873fc3b081b036bed9104c91e9702b176e7b76ea63d0"}, + {file = "botocore-1.27.87-py3-none-any.whl", hash = "sha256:c4cbd22056ace4c7aa99e62e8ae629865ab80cc8bbf7c6d68ccf0f768f0034b6"}, + {file = "botocore-1.27.87.tar.gz", hash = "sha256:216de9751116d0d1cc3901e26d95a5c9a30ecb6973ae6147af1cf504858d845a"}, ] certifi = [ - {file = "certifi-2022.9.14-py3-none-any.whl", hash = "sha256:e232343de1ab72c2aa521b625c80f699e356830fd0e2c620b465b304b17b0516"}, - {file = "certifi-2022.9.14.tar.gz", hash = "sha256:36973885b9542e6bd01dea287b2b4b3b21236307c56324fcc3f1160f2d655ed5"}, + {file = "certifi-2022.9.24-py3-none-any.whl", hash = "sha256:90c1a32f1d68f940488354e36370f6cca89f0f106db09518524c88d6ed83f382"}, + {file = "certifi-2022.9.24.tar.gz", hash = "sha256:0d9c601124e5a6ba9712dbc60d9c53c21e34f5f641fe83002317394311bdce14"}, ] cffi = [ {file = "cffi-1.15.1-cp27-cp27m-macosx_10_9_x86_64.whl", hash = "sha256:a66d3508133af6e8548451b25058d5812812ec3798c886bf38ed24a98216fab2"}, @@ -1069,56 +1069,56 @@ colorama = [ {file = "colorama-0.4.5.tar.gz", hash = "sha256:e6c6b4334fc50988a639d9b98aa429a0b57da6e17b9a44f0451f930b6967b7a4"}, ] coverage = [ - {file = "coverage-6.4.4-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:e7b4da9bafad21ea45a714d3ea6f3e1679099e420c8741c74905b92ee9bfa7cc"}, - {file = "coverage-6.4.4-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:fde17bc42e0716c94bf19d92e4c9f5a00c5feb401f5bc01101fdf2a8b7cacf60"}, - {file = "coverage-6.4.4-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:cdbb0d89923c80dbd435b9cf8bba0ff55585a3cdb28cbec65f376c041472c60d"}, - {file = "coverage-6.4.4-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:67f9346aeebea54e845d29b487eb38ec95f2ecf3558a3cffb26ee3f0dcc3e760"}, - {file = "coverage-6.4.4-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:42c499c14efd858b98c4e03595bf914089b98400d30789511577aa44607a1b74"}, - {file = "coverage-6.4.4-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:c35cca192ba700979d20ac43024a82b9b32a60da2f983bec6c0f5b84aead635c"}, - {file = "coverage-6.4.4-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:9cc4f107009bca5a81caef2fca843dbec4215c05e917a59dec0c8db5cff1d2aa"}, - {file = "coverage-6.4.4-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:5f444627b3664b80d078c05fe6a850dd711beeb90d26731f11d492dcbadb6973"}, - {file = "coverage-6.4.4-cp310-cp310-win32.whl", hash = "sha256:66e6df3ac4659a435677d8cd40e8eb1ac7219345d27c41145991ee9bf4b806a0"}, - {file = "coverage-6.4.4-cp310-cp310-win_amd64.whl", hash = "sha256:35ef1f8d8a7a275aa7410d2f2c60fa6443f4a64fae9be671ec0696a68525b875"}, - {file = "coverage-6.4.4-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:c1328d0c2f194ffda30a45f11058c02410e679456276bfa0bbe0b0ee87225fac"}, - {file = "coverage-6.4.4-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:61b993f3998ee384935ee423c3d40894e93277f12482f6e777642a0141f55782"}, - {file = "coverage-6.4.4-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:d5dd4b8e9cd0deb60e6fcc7b0647cbc1da6c33b9e786f9c79721fd303994832f"}, - {file = "coverage-6.4.4-cp311-cp311-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7026f5afe0d1a933685d8f2169d7c2d2e624f6255fb584ca99ccca8c0e966fd7"}, - {file = "coverage-6.4.4-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:9c7b9b498eb0c0d48b4c2abc0e10c2d78912203f972e0e63e3c9dc21f15abdaa"}, - {file = "coverage-6.4.4-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:ee2b2fb6eb4ace35805f434e0f6409444e1466a47f620d1d5763a22600f0f892"}, - {file = "coverage-6.4.4-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:ab066f5ab67059d1f1000b5e1aa8bbd75b6ed1fc0014559aea41a9eb66fc2ce0"}, - {file = "coverage-6.4.4-cp311-cp311-win32.whl", hash = "sha256:9d6e1f3185cbfd3d91ac77ea065d85d5215d3dfa45b191d14ddfcd952fa53796"}, - {file = "coverage-6.4.4-cp311-cp311-win_amd64.whl", hash = "sha256:e3d3c4cc38b2882f9a15bafd30aec079582b819bec1b8afdbde8f7797008108a"}, - {file = "coverage-6.4.4-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:a095aa0a996ea08b10580908e88fbaf81ecf798e923bbe64fb98d1807db3d68a"}, - {file = "coverage-6.4.4-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:ef6f44409ab02e202b31a05dd6666797f9de2aa2b4b3534e9d450e42dea5e817"}, - {file = "coverage-6.4.4-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:4b7101938584d67e6f45f0015b60e24a95bf8dea19836b1709a80342e01b472f"}, - {file = "coverage-6.4.4-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:14a32ec68d721c3d714d9b105c7acf8e0f8a4f4734c811eda75ff3718570b5e3"}, - {file = "coverage-6.4.4-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:6a864733b22d3081749450466ac80698fe39c91cb6849b2ef8752fd7482011f3"}, - {file = "coverage-6.4.4-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:08002f9251f51afdcc5e3adf5d5d66bb490ae893d9e21359b085f0e03390a820"}, - {file = "coverage-6.4.4-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:a3b2752de32c455f2521a51bd3ffb53c5b3ae92736afde67ce83477f5c1dd928"}, - {file = "coverage-6.4.4-cp37-cp37m-win32.whl", hash = "sha256:f855b39e4f75abd0dfbcf74a82e84ae3fc260d523fcb3532786bcbbcb158322c"}, - {file = "coverage-6.4.4-cp37-cp37m-win_amd64.whl", hash = "sha256:ee6ae6bbcac0786807295e9687169fba80cb0617852b2fa118a99667e8e6815d"}, - {file = "coverage-6.4.4-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:564cd0f5b5470094df06fab676c6d77547abfdcb09b6c29c8a97c41ad03b103c"}, - {file = "coverage-6.4.4-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:cbbb0e4cd8ddcd5ef47641cfac97d8473ab6b132dd9a46bacb18872828031685"}, - {file = "coverage-6.4.4-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6113e4df2fa73b80f77663445be6d567913fb3b82a86ceb64e44ae0e4b695de1"}, - {file = "coverage-6.4.4-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:8d032bfc562a52318ae05047a6eb801ff31ccee172dc0d2504614e911d8fa83e"}, - {file = "coverage-6.4.4-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:e431e305a1f3126477abe9a184624a85308da8edf8486a863601d58419d26ffa"}, - {file = "coverage-6.4.4-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:cf2afe83a53f77aec067033199797832617890e15bed42f4a1a93ea24794ae3e"}, - {file = "coverage-6.4.4-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:783bc7c4ee524039ca13b6d9b4186a67f8e63d91342c713e88c1865a38d0892a"}, - {file = "coverage-6.4.4-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:ff934ced84054b9018665ca3967fc48e1ac99e811f6cc99ea65978e1d384454b"}, - {file = "coverage-6.4.4-cp38-cp38-win32.whl", hash = "sha256:e1fabd473566fce2cf18ea41171d92814e4ef1495e04471786cbc943b89a3781"}, - {file = "coverage-6.4.4-cp38-cp38-win_amd64.whl", hash = "sha256:4179502f210ebed3ccfe2f78bf8e2d59e50b297b598b100d6c6e3341053066a2"}, - {file = "coverage-6.4.4-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:98c0b9e9b572893cdb0a00e66cf961a238f8d870d4e1dc8e679eb8bdc2eb1b86"}, - {file = "coverage-6.4.4-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:fc600f6ec19b273da1d85817eda339fb46ce9eef3e89f220055d8696e0a06908"}, - {file = "coverage-6.4.4-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7a98d6bf6d4ca5c07a600c7b4e0c5350cd483c85c736c522b786be90ea5bac4f"}, - {file = "coverage-6.4.4-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:01778769097dbd705a24e221f42be885c544bb91251747a8a3efdec6eb4788f2"}, - {file = "coverage-6.4.4-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:dfa0b97eb904255e2ab24166071b27408f1f69c8fbda58e9c0972804851e0558"}, - {file = "coverage-6.4.4-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:fcbe3d9a53e013f8ab88734d7e517eb2cd06b7e689bedf22c0eb68db5e4a0a19"}, - {file = "coverage-6.4.4-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:15e38d853ee224e92ccc9a851457fb1e1f12d7a5df5ae44544ce7863691c7a0d"}, - {file = "coverage-6.4.4-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:6913dddee2deff8ab2512639c5168c3e80b3ebb0f818fed22048ee46f735351a"}, - {file = "coverage-6.4.4-cp39-cp39-win32.whl", hash = "sha256:354df19fefd03b9a13132fa6643527ef7905712109d9c1c1903f2133d3a4e145"}, - {file = "coverage-6.4.4-cp39-cp39-win_amd64.whl", hash = "sha256:1238b08f3576201ebf41f7c20bf59baa0d05da941b123c6656e42cdb668e9827"}, - {file = "coverage-6.4.4-pp36.pp37.pp38-none-any.whl", hash = "sha256:f67cf9f406cf0d2f08a3515ce2db5b82625a7257f88aad87904674def6ddaec1"}, - {file = "coverage-6.4.4.tar.gz", hash = "sha256:e16c45b726acb780e1e6f88b286d3c10b3914ab03438f32117c4aa52d7f30d58"}, + {file = "coverage-6.5.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:ef8674b0ee8cc11e2d574e3e2998aea5df5ab242e012286824ea3c6970580e53"}, + {file = "coverage-6.5.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:784f53ebc9f3fd0e2a3f6a78b2be1bd1f5575d7863e10c6e12504f240fd06660"}, + {file = "coverage-6.5.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b4a5be1748d538a710f87542f22c2cad22f80545a847ad91ce45e77417293eb4"}, + {file = "coverage-6.5.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:83516205e254a0cb77d2d7bb3632ee019d93d9f4005de31dca0a8c3667d5bc04"}, + {file = "coverage-6.5.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:af4fffaffc4067232253715065e30c5a7ec6faac36f8fc8d6f64263b15f74db0"}, + {file = "coverage-6.5.0-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:97117225cdd992a9c2a5515db1f66b59db634f59d0679ca1fa3fe8da32749cae"}, + {file = "coverage-6.5.0-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:a1170fa54185845505fbfa672f1c1ab175446c887cce8212c44149581cf2d466"}, + {file = "coverage-6.5.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:11b990d520ea75e7ee8dcab5bc908072aaada194a794db9f6d7d5cfd19661e5a"}, + {file = "coverage-6.5.0-cp310-cp310-win32.whl", hash = "sha256:5dbec3b9095749390c09ab7c89d314727f18800060d8d24e87f01fb9cfb40b32"}, + {file = "coverage-6.5.0-cp310-cp310-win_amd64.whl", hash = "sha256:59f53f1dc5b656cafb1badd0feb428c1e7bc19b867479ff72f7a9dd9b479f10e"}, + {file = "coverage-6.5.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:4a5375e28c5191ac38cca59b38edd33ef4cc914732c916f2929029b4bfb50795"}, + {file = "coverage-6.5.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c4ed2820d919351f4167e52425e096af41bfabacb1857186c1ea32ff9983ed75"}, + {file = "coverage-6.5.0-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:33a7da4376d5977fbf0a8ed91c4dffaaa8dbf0ddbf4c8eea500a2486d8bc4d7b"}, + {file = "coverage-6.5.0-cp311-cp311-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a8fb6cf131ac4070c9c5a3e21de0f7dc5a0fbe8bc77c9456ced896c12fcdad91"}, + {file = "coverage-6.5.0-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:a6b7d95969b8845250586f269e81e5dfdd8ff828ddeb8567a4a2eaa7313460c4"}, + {file = "coverage-6.5.0-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:1ef221513e6f68b69ee9e159506d583d31aa3567e0ae84eaad9d6ec1107dddaa"}, + {file = "coverage-6.5.0-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:cca4435eebea7962a52bdb216dec27215d0df64cf27fc1dd538415f5d2b9da6b"}, + {file = "coverage-6.5.0-cp311-cp311-win32.whl", hash = "sha256:98e8a10b7a314f454d9eff4216a9a94d143a7ee65018dd12442e898ee2310578"}, + {file = "coverage-6.5.0-cp311-cp311-win_amd64.whl", hash = "sha256:bc8ef5e043a2af066fa8cbfc6e708d58017024dc4345a1f9757b329a249f041b"}, + {file = "coverage-6.5.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:4433b90fae13f86fafff0b326453dd42fc9a639a0d9e4eec4d366436d1a41b6d"}, + {file = "coverage-6.5.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f4f05d88d9a80ad3cac6244d36dd89a3c00abc16371769f1340101d3cb899fc3"}, + {file = "coverage-6.5.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:94e2565443291bd778421856bc975d351738963071e9b8839ca1fc08b42d4bef"}, + {file = "coverage-6.5.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:027018943386e7b942fa832372ebc120155fd970837489896099f5cfa2890f79"}, + {file = "coverage-6.5.0-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:255758a1e3b61db372ec2736c8e2a1fdfaf563977eedbdf131de003ca5779b7d"}, + {file = "coverage-6.5.0-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:851cf4ff24062c6aec510a454b2584f6e998cada52d4cb58c5e233d07172e50c"}, + {file = "coverage-6.5.0-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:12adf310e4aafddc58afdb04d686795f33f4d7a6fa67a7a9d4ce7d6ae24d949f"}, + {file = "coverage-6.5.0-cp37-cp37m-win32.whl", hash = "sha256:b5604380f3415ba69de87a289a2b56687faa4fe04dbee0754bfcae433489316b"}, + {file = "coverage-6.5.0-cp37-cp37m-win_amd64.whl", hash = "sha256:4a8dbc1f0fbb2ae3de73eb0bdbb914180c7abfbf258e90b311dcd4f585d44bd2"}, + {file = "coverage-6.5.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:d900bb429fdfd7f511f868cedd03a6bbb142f3f9118c09b99ef8dc9bf9643c3c"}, + {file = "coverage-6.5.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:2198ea6fc548de52adc826f62cb18554caedfb1d26548c1b7c88d8f7faa8f6ba"}, + {file = "coverage-6.5.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6c4459b3de97b75e3bd6b7d4b7f0db13f17f504f3d13e2a7c623786289dd670e"}, + {file = "coverage-6.5.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:20c8ac5386253717e5ccc827caad43ed66fea0efe255727b1053a8154d952398"}, + {file = "coverage-6.5.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6b07130585d54fe8dff3d97b93b0e20290de974dc8177c320aeaf23459219c0b"}, + {file = "coverage-6.5.0-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:dbdb91cd8c048c2b09eb17713b0c12a54fbd587d79adcebad543bc0cd9a3410b"}, + {file = "coverage-6.5.0-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:de3001a203182842a4630e7b8d1a2c7c07ec1b45d3084a83d5d227a3806f530f"}, + {file = "coverage-6.5.0-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:e07f4a4a9b41583d6eabec04f8b68076ab3cd44c20bd29332c6572dda36f372e"}, + {file = "coverage-6.5.0-cp38-cp38-win32.whl", hash = "sha256:6d4817234349a80dbf03640cec6109cd90cba068330703fa65ddf56b60223a6d"}, + {file = "coverage-6.5.0-cp38-cp38-win_amd64.whl", hash = "sha256:7ccf362abd726b0410bf8911c31fbf97f09f8f1061f8c1cf03dfc4b6372848f6"}, + {file = "coverage-6.5.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:633713d70ad6bfc49b34ead4060531658dc6dfc9b3eb7d8a716d5873377ab745"}, + {file = "coverage-6.5.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:95203854f974e07af96358c0b261f1048d8e1083f2de9b1c565e1be4a3a48cfc"}, + {file = "coverage-6.5.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b9023e237f4c02ff739581ef35969c3739445fb059b060ca51771e69101efffe"}, + {file = "coverage-6.5.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:265de0fa6778d07de30bcf4d9dc471c3dc4314a23a3c6603d356a3c9abc2dfcf"}, + {file = "coverage-6.5.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8f830ed581b45b82451a40faabb89c84e1a998124ee4212d440e9c6cf70083e5"}, + {file = "coverage-6.5.0-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:7b6be138d61e458e18d8e6ddcddd36dd96215edfe5f1168de0b1b32635839b62"}, + {file = "coverage-6.5.0-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:42eafe6778551cf006a7c43153af1211c3aaab658d4d66fa5fcc021613d02518"}, + {file = "coverage-6.5.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:723e8130d4ecc8f56e9a611e73b31219595baa3bb252d539206f7bbbab6ffc1f"}, + {file = "coverage-6.5.0-cp39-cp39-win32.whl", hash = "sha256:d9ecf0829c6a62b9b573c7bb6d4dcd6ba8b6f80be9ba4fc7ed50bf4ac9aecd72"}, + {file = "coverage-6.5.0-cp39-cp39-win_amd64.whl", hash = "sha256:fc2af30ed0d5ae0b1abdb4ebdce598eafd5b35397d4d75deb341a614d333d987"}, + {file = "coverage-6.5.0-pp36.pp37.pp38-none-any.whl", hash = "sha256:1431986dac3923c5945271f169f59c45b8802a114c8f548d611f2015133df77a"}, + {file = "coverage-6.5.0.tar.gz", hash = "sha256:f642e90754ee3e06b0e7e51bce3379590e76b7f76b708e1a71ff043f87025c84"}, ] cryptography = [ {file = "cryptography-38.0.1-cp36-abi3-macosx_10_10_universal2.whl", hash = "sha256:10d1f29d6292fc95acb597bacefd5b9e812099d75a6469004fd38ba5471a977f"}, @@ -1177,8 +1177,8 @@ idna = [ {file = "idna-3.4.tar.gz", hash = "sha256:814f528e8dead7d329833b91c5faa87d60bf71824cd12a7530b5526063d02cb4"}, ] importlib-metadata = [ - {file = "importlib_metadata-4.12.0-py3-none-any.whl", hash = "sha256:7401a975809ea1fdc658c3aa4f78cc2195a0e019c5cbc4c06122884e9ae80c23"}, - {file = "importlib_metadata-4.12.0.tar.gz", hash = "sha256:637245b8bab2b6502fcbc752cc4b7a6f6243bb02b31c5c26156ad103d3d45670"}, + {file = "importlib_metadata-4.13.0-py3-none-any.whl", hash = "sha256:8a8a81bcf996e74fee46f0d16bd3eaa382a7eb20fd82445c3ad11f4090334116"}, + {file = "importlib_metadata-4.13.0.tar.gz", hash = "sha256:dd0173e8f150d6815e098fd354f6414b0f079af4644ddfe90c71e2fc6174346d"}, ] importlib-resources = [ {file = "importlib_resources-5.9.0-py3-none-any.whl", hash = "sha256:f78a8df21a79bcc30cfd400bdc38f314333de7c0fb619763f6b9dabab8268bb7"}, @@ -1189,8 +1189,8 @@ iniconfig = [ {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, ] "jaraco.classes" = [ - {file = "jaraco.classes-3.2.2-py3-none-any.whl", hash = "sha256:e6ef6fd3fcf4579a7a019d87d1e56a883f4e4c35cfe925f86731abc58804e647"}, - {file = "jaraco.classes-3.2.2.tar.gz", hash = "sha256:6745f113b0b588239ceb49532aa09c3ebb947433ce311ef2f8e3ad64ebb74594"}, + {file = "jaraco.classes-3.2.3-py3-none-any.whl", hash = "sha256:2353de3288bc6b82120752201c6b1c1a14b058267fa424ed5ce5984e3b922158"}, + {file = "jaraco.classes-3.2.3.tar.gz", hash = "sha256:89559fa5c1d3c34eff6f631ad80bb21f378dbcbb35dd161fd2c6b93f5be2f98a"}, ] jeepney = [ {file = "jeepney-0.8.0-py3-none-any.whl", hash = "sha256:c0a454ad016ca575060802ee4d590dd912e35c122fa04e70306de3d076cce755"}, @@ -1488,8 +1488,8 @@ PyYAML = [ {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, ] readme-renderer = [ - {file = "readme_renderer-37.1-py3-none-any.whl", hash = "sha256:16c914ca7731fd062a316a2a8e5434a175ee34661a608af771a60c881f528a34"}, - {file = "readme_renderer-37.1.tar.gz", hash = "sha256:96768c069729f69176f514477e57f2f8cd543fbb2cd7bad372976249fa509a0c"}, + {file = "readme_renderer-37.2-py3-none-any.whl", hash = "sha256:d3f06a69e8c40fca9ab3174eca48f96d9771eddb43517b17d96583418427b106"}, + {file = "readme_renderer-37.2.tar.gz", hash = "sha256:e8ad25293c98f781dbc2c5a36a309929390009f902f99e1798c761aaf04a7923"}, ] requests = [ {file = "requests-2.28.1-py3-none-any.whl", hash = "sha256:8fefa2a1a1365bf5520aac41836fbee479da67864514bdb821f31ce07ce65349"}, @@ -1517,7 +1517,6 @@ six = [ ] tabulate = [ {file = "tabulate-0.8.10-py3-none-any.whl", hash = "sha256:0ba055423dbaa164b9e456abe7920c5e8ed33fcc16f6d1b2f2d152c8e1e8b4fc"}, - {file = "tabulate-0.8.10-py3.8.egg", hash = "sha256:436f1c768b424654fce8597290d2764def1eea6a77cfa5c33be00b1bc0f4f63d"}, {file = "tabulate-0.8.10.tar.gz", hash = "sha256:6c57f3f3dd7ac2782770155f3adb2db0b1a269637e42f27599925e64b114f519"}, ] termcolor = [ diff --git a/pyproject.toml b/pyproject.toml index 1df99a6f115..19bd6cb4a41 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,3 +56,11 @@ pytest-recording = "^0.12.1" [tool.black] skip-string-normalization = true + + +[tool.pytest.ini_options] +junit_family = "xunit2" +addopts = "--tb=native" +markers = ["functional", "skiplive"] +python_files = "test_*.py" +norecursedirs = ["data", "cassettes", "templates", "terraform"] diff --git a/requirements.txt b/requirements.txt index bbc138c54cf..78b24bdbb79 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,76 +1,77 @@ -argcomplete==2.0.0; python_version >= "3.6" -attrs==22.1.0; python_version >= "3.7" and python_version < "4.0" -aws-xray-sdk==2.10.0 -bleach==5.0.1; python_version >= "3.7" -boto3==1.24.77; python_version >= "3.7" -botocore==1.27.77; python_version >= "3.7" -certifi==2022.9.14; python_version >= "3.7" and python_version < "4" -cffi==1.15.1; sys_platform == "linux" and python_version >= "3.7" -charset-normalizer==2.1.1; python_version >= "3.7" and python_version < "4" and python_full_version >= "3.6.0" -click==8.1.3; python_version >= "3.7" -colorama==0.4.5; python_version >= "3.7" and python_full_version < "3.0.0" and sys_platform == "win32" and platform_system == "Windows" and python_version < "4.0" or sys_platform == "win32" and python_version >= "3.7" and python_full_version >= "3.5.0" and platform_system == "Windows" and python_version < "4.0" -coverage==6.4.4; python_version >= "3.7" -cryptography==38.0.1; sys_platform == "linux" and python_version >= "3.7" -docutils==0.17.1; (python_version >= "2.7" and python_full_version < "3.0.0") or (python_full_version >= "3.5.0") -execnet==1.9.0; python_version >= "3.6" and python_full_version < "3.0.0" and python_version < "4.0" or python_full_version >= "3.5.0" and python_version >= "3.6" and python_version < "4.0" -flake8==3.9.2; (python_version >= "2.7" and python_full_version < "3.0.0") or (python_full_version >= "3.5.0") -freezegun==1.2.2; python_version >= "3.6" -idna==3.4; python_version >= "3.7" and python_version < "4" -importlib-metadata==4.12.0; python_version >= "3.7" -importlib-resources==5.9.0; python_version < "3.9" and python_version >= "3.7" -iniconfig==1.1.1; python_version >= "3.7" and python_version < "4.0" -jaraco.classes==3.2.2; python_version >= "3.7" -jeepney==0.8.0; sys_platform == "linux" and python_version >= "3.7" -jmespath==1.0.1; python_version >= "3.7" and python_version < "4.0" -jsonpatch==1.32; (python_version >= "2.7" and python_full_version < "3.0.0") or (python_full_version >= "3.5.0") -jsonpointer==2.3; python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" -jsonschema==4.16.0; python_version >= "3.7" -keyring==23.9.3; python_version >= "3.7" -mccabe==0.6.1; python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" -mock==4.0.3; python_version >= "3.6" -more-itertools==8.14.0; python_version >= "3.7" -multidict==6.0.2; python_version >= "3.7" -packaging==21.3; python_version >= "3.7" and python_version < "4.0" -pkginfo==1.8.3; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6" -pkgutil-resolve-name==1.3.10; python_version < "3.9" and python_version >= "3.7" -placebo==0.9.0 -pluggy==1.0.0; python_version >= "3.7" and python_version < "4.0" -portalocker==2.5.1; python_version >= "3.6" and python_version < "4.0" -psutil==5.9.2; (python_version >= "2.7" and python_full_version < "3.0.0") or (python_full_version >= "3.4.0") -py==1.11.0; python_version >= "3.7" and python_full_version < "3.0.0" and python_version < "4.0" or python_full_version >= "3.5.0" and python_version >= "3.7" and python_version < "4.0" -pycodestyle==2.7.0; python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" -pycparser==2.21; python_version >= "3.7" and python_full_version < "3.0.0" and sys_platform == "linux" or sys_platform == "linux" and python_version >= "3.7" and python_full_version >= "3.4.0" -pyflakes==2.3.1; python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" -pygments==2.13.0; python_version >= "3.7" -pyparsing==3.0.9; python_full_version >= "3.6.8" and python_version >= "3.7" -pyrsistent==0.18.1; python_version >= "3.7" -pytest-cov==3.0.0; python_version >= "3.6" -pytest-forked==1.4.0; python_version >= "3.6" and python_version < "4.0" -pytest-recording==0.12.1; python_version >= "3.5" -pytest-sugar==0.9.5 -pytest-terraform==0.6.4; python_version >= "3.6" and python_version < "4.0" -pytest-xdist==2.5.0; python_version >= "3.6" -pytest==7.1.3; python_version >= "3.7" -python-dateutil==2.8.2; (python_version >= "2.7" and python_full_version < "3.0.0") or (python_full_version >= "3.3.0") -pywin32-ctypes==0.2.0; sys_platform == "win32" and python_version >= "3.7" -pywin32==304; python_version >= "3.6" and python_version < "4.0" and platform_system == "Windows" -pyyaml==6.0; python_version >= "3.6" -readme-renderer==37.1; python_version >= "3.7" -requests-toolbelt==0.9.1; python_version >= "3.6" -requests==2.28.1; python_version >= "3.7" and python_version < "4" -rfc3986==2.0.0; python_version >= "3.7" -s3transfer==0.6.0; python_version >= "3.7" -secretstorage==3.3.3; sys_platform == "linux" and python_version >= "3.7" -six==1.16.0; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.3.0" and python_version >= "3.7" -tabulate==0.8.10; (python_version >= "2.7" and python_full_version < "3.0.0") or (python_full_version >= "3.5.0") -termcolor==2.0.1; python_version >= "3.7" -tomli==2.0.1; python_full_version <= "3.11.0a6" and python_version >= "3.7" and python_version < "4.0" -tqdm==4.64.1; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.6" -twine==3.8.0; python_version >= "3.6" -typing-extensions==4.3.0; python_version == "3.7" and (python_version >= "3.7" and python_full_version < "3.0.0" and python_version < "3.8" or python_full_version >= "3.5.0" and python_version < "3.8" and python_version >= "3.7") -urllib3==1.26.12; python_version >= "3.7" and python_full_version < "3.0.0" and python_version < "4" or python_full_version >= "3.6.0" and python_version < "4" and python_version >= "3.7" -vcrpy==4.2.1; python_version >= "3.7" -webencodings==0.5.1; python_version >= "3.7" -wrapt==1.14.1; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" and python_version >= "3.7" -yarl==1.8.1; python_version >= "3.7" -zipp==3.8.1; python_version == "3.7" and (python_version >= "3.7" and python_full_version < "3.0.0" and python_version < "3.8" or python_full_version >= "3.5.0" and python_version < "3.8" and python_version >= "3.7") +argcomplete==2.0.0 ; python_version >= "3.7" and python_version < "4.0" +attrs==22.1.0 ; python_version >= "3.7" and python_version < "4.0" +aws-xray-sdk==2.10.0 ; python_version >= "3.7" and python_version < "4.0" +bleach==5.0.1 ; python_version >= "3.7" and python_version < "4.0" +boto3==1.24.87 ; python_version >= "3.7" and python_version < "4.0" +botocore==1.27.87 ; python_version >= "3.7" and python_version < "4.0" +certifi==2022.9.24 ; python_version >= "3.7" and python_version < "4" +cffi==1.15.1 ; python_version >= "3.7" and python_version < "4.0" and sys_platform == "linux" +charset-normalizer==2.1.1 ; python_version >= "3.7" and python_version < "4" +click==8.1.3 ; python_version >= "3.7" and python_version < "4.0" +colorama==0.4.5 ; python_version >= "3.7" and python_version < "4.0" +coverage==6.5.0 ; python_version >= "3.7" and python_version < "4.0" +coverage[toml]==6.5.0 ; python_version >= "3.7" and python_version < "4.0" +cryptography==38.0.1 ; python_version >= "3.7" and python_version < "4.0" and sys_platform == "linux" +docutils==0.17.1 ; python_version >= "3.7" and python_version < "4.0" +execnet==1.9.0 ; python_version >= "3.7" and python_version < "4.0" +flake8==3.9.2 ; python_version >= "3.7" and python_version < "4.0" +freezegun==1.2.2 ; python_version >= "3.7" and python_version < "4.0" +idna==3.4 ; python_version >= "3.7" and python_version < "4.0" +importlib-metadata==4.13.0 ; python_version >= "3.7" and python_version < "4.0" +importlib-resources==5.9.0 ; python_version >= "3.7" and python_version < "3.9" +iniconfig==1.1.1 ; python_version >= "3.7" and python_version < "4.0" +jaraco-classes==3.2.3 ; python_version >= "3.7" and python_version < "4.0" +jeepney==0.8.0 ; python_version >= "3.7" and python_version < "4.0" and sys_platform == "linux" +jmespath==1.0.1 ; python_version >= "3.7" and python_version < "4.0" +jsonpatch==1.32 ; python_version >= "3.7" and python_version < "4.0" +jsonpointer==2.3 ; python_version >= "3.7" and python_version < "4.0" +jsonschema==4.16.0 ; python_version >= "3.7" and python_version < "4.0" +keyring==23.9.3 ; python_version >= "3.7" and python_version < "4.0" +mccabe==0.6.1 ; python_version >= "3.7" and python_version < "4.0" +mock==4.0.3 ; python_version >= "3.7" and python_version < "4.0" +more-itertools==8.14.0 ; python_version >= "3.7" and python_version < "4.0" +multidict==6.0.2 ; python_version >= "3.7" and python_version < "4.0" +packaging==21.3 ; python_version >= "3.7" and python_version < "4.0" +pkginfo==1.8.3 ; python_version >= "3.7" and python_version < "4.0" +pkgutil-resolve-name==1.3.10 ; python_version >= "3.7" and python_version < "3.9" +placebo==0.9.0 ; python_version >= "3.7" and python_version < "4.0" +pluggy==1.0.0 ; python_version >= "3.7" and python_version < "4.0" +portalocker==2.5.1 ; python_version >= "3.7" and python_version < "4.0" +psutil==5.9.2 ; python_version >= "3.7" and python_version < "4.0" +py==1.11.0 ; python_version >= "3.7" and python_version < "4.0" +pycodestyle==2.7.0 ; python_version >= "3.7" and python_version < "4.0" +pycparser==2.21 ; python_version >= "3.7" and python_version < "4.0" and sys_platform == "linux" +pyflakes==2.3.1 ; python_version >= "3.7" and python_version < "4.0" +pygments==2.13.0 ; python_version >= "3.7" and python_version < "4.0" +pyparsing==3.0.9 ; python_version >= "3.7" and python_version < "4.0" +pyrsistent==0.18.1 ; python_version >= "3.7" and python_version < "4.0" +pytest-cov==3.0.0 ; python_version >= "3.7" and python_version < "4.0" +pytest-forked==1.4.0 ; python_version >= "3.7" and python_version < "4.0" +pytest-recording==0.12.1 ; python_version >= "3.7" and python_version < "4.0" +pytest-sugar==0.9.5 ; python_version >= "3.7" and python_version < "4.0" +pytest-terraform==0.6.4 ; python_version >= "3.7" and python_version < "4.0" +pytest-xdist==2.5.0 ; python_version >= "3.7" and python_version < "4.0" +pytest==7.1.3 ; python_version >= "3.7" and python_version < "4.0" +python-dateutil==2.8.2 ; python_version >= "3.7" and python_version < "4.0" +pywin32-ctypes==0.2.0 ; python_version >= "3.7" and python_version < "4.0" and sys_platform == "win32" +pywin32==304 ; python_version >= "3.7" and python_version < "4.0" and platform_system == "Windows" +pyyaml==6.0 ; python_version >= "3.7" and python_version < "4.0" +readme-renderer==37.2 ; python_version >= "3.7" and python_version < "4.0" +requests-toolbelt==0.9.1 ; python_version >= "3.7" and python_version < "4.0" +requests==2.28.1 ; python_version >= "3.7" and python_version < "4" +rfc3986==2.0.0 ; python_version >= "3.7" and python_version < "4.0" +s3transfer==0.6.0 ; python_version >= "3.7" and python_version < "4.0" +secretstorage==3.3.3 ; python_version >= "3.7" and python_version < "4.0" and sys_platform == "linux" +six==1.16.0 ; python_version >= "3.7" and python_version < "4.0" +tabulate==0.8.10 ; python_version >= "3.7" and python_version < "4.0" +termcolor==2.0.1 ; python_version >= "3.7" and python_version < "4.0" +tomli==2.0.1 ; python_version >= "3.7" and python_version < "4.0" +tqdm==4.64.1 ; python_version >= "3.7" and python_version < "4.0" +twine==3.8.0 ; python_version >= "3.7" and python_version < "4.0" +typing-extensions==4.3.0 ; python_version >= "3.7" and python_version < "3.8" +urllib3==1.26.12 ; python_version >= "3.7" and python_version < "4" +vcrpy==4.2.1 ; python_version >= "3.7" and python_version < "4.0" +webencodings==0.5.1 ; python_version >= "3.7" and python_version < "4.0" +wrapt==1.14.1 ; python_version >= "3.7" and python_version < "4.0" +yarl==1.8.1 ; python_version >= "3.7" and python_version < "4.0" +zipp==3.8.1 ; python_version >= "3.7" and python_version < "4.0" diff --git a/setup.py b/setup.py index a807dd701d3..ca7ca2a46b5 100644 --- a/setup.py +++ b/setup.py @@ -40,10 +40,13 @@ 'long_description': 'Cloud Custodian\n=================\n\n

Cloud Custodian Logo

\n\n---\n\n[![](https://badges.gitter.im/cloud-custodian/cloud-custodian.svg)](https://gitter.im/cloud-custodian/cloud-custodian?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)\n[![CI](https://github.com/cloud-custodian/cloud-custodian/workflows/CI/badge.svg?event=push)](https://github.com/cloud-custodian/cloud-custodian/actions?query=workflow%3ACI+branch%3Amaster+event%3Apush)\n[![](https://dev.azure.com/cloud-custodian/cloud-custodian/_apis/build/status/Custodian%20-%20CI?branchName=master)](https://dev.azure.com/cloud-custodian/cloud-custodian/_build)\n[![](https://img.shields.io/badge/license-Apache%202-blue.svg)](https://www.apache.org/licenses/LICENSE-2.0)\n[![](https://codecov.io/gh/cloud-custodian/cloud-custodian/branch/master/graph/badge.svg)](https://codecov.io/gh/cloud-custodian/cloud-custodian)\n[![](https://requires.io/github/cloud-custodian/cloud-custodian/requirements.svg?branch=master)](https://requires.io/github/cloud-custodian/cloud-custodian/requirements/?branch=master)\n[![CII Best Practices](https://bestpractices.coreinfrastructure.org/projects/3402/badge)](https://bestpractices.coreinfrastructure.org/projects/3402)\n\nCloud Custodian is a rules engine for managing public cloud accounts and\nresources. It allows users to define policies to enable a well managed\ncloud infrastructure, that\\\'s both secure and cost optimized. It\nconsolidates many of the adhoc scripts organizations have into a\nlightweight and flexible tool, with unified metrics and reporting.\n\nCustodian can be used to manage AWS, Azure, and GCP environments by\nensuring real time compliance to security policies (like encryption and\naccess requirements), tag policies, and cost management via garbage\ncollection of unused resources and off-hours resource management.\n\nCustodian policies are written in simple YAML configuration files that\nenable users to specify policies on a resource type (EC2, ASG, Redshift,\nCosmosDB, PubSub Topic) and are constructed from a vocabulary of filters\nand actions.\n\nIt integrates with the cloud native serverless capabilities of each\nprovider to provide for real time enforcement of policies with builtin\nprovisioning. Or it can be run as a simple cron job on a server to\nexecute against large existing fleets.\n\nCloud Custodian is a CNCF Sandbox project, lead by a community of hundreds\nof contributors.\n\nFeatures\n--------\n\n- Comprehensive support for public cloud services and resources with a\n rich library of actions and filters to build policies with.\n- Supports arbitrary filtering on resources with nested boolean\n conditions.\n- Dry run any policy to see what it would do.\n- Automatically provisions serverless functions and event sources (\n AWS CloudWatchEvents, AWS Config Rules, Azure EventGrid, GCP\n AuditLog & Pub/Sub, etc)\n- Cloud provider native metrics outputs on resources that matched a\n policy\n- Structured outputs into cloud native object storage of which\n resources matched a policy.\n- Intelligent cache usage to minimize api calls.\n- Supports multi-account/subscription/project usage.\n- Battle-tested - in production on some very large cloud environments.\n\nLinks\n-----\n\n- [Homepage](http://cloudcustodian.io)\n- [Docs](http://cloudcustodian.io/docs/index.html)\n- [Project Roadmap](https://github.com/orgs/cloud-custodian/projects/1)\n- [Developer Install](https://cloudcustodian.io/docs/developer/installing.html)\n- [Presentations](https://www.google.com/search?q=cloud+custodian&source=lnms&tbm=vid)\n\nQuick Install\n-------------\n\n```shell\n$ python3 -m venv custodian\n$ source custodian/bin/activate\n(custodian) $ pip install c7n\n```\n\n\nUsage\n-----\n\nThe first step to using Cloud Custodian is writing a YAML file\ncontaining the policies that you want to run. Each policy specifies\nthe resource type that the policy will run on, a set of filters which\ncontrol resources will be affected by this policy, actions which the policy\nwith take on the matched resources, and a mode which controls which\nhow the policy will execute.\n\nThe best getting started guides are the cloud provider specific tutorials.\n\n - [AWS Getting Started](https://cloudcustodian.io/docs/aws/gettingstarted.html)\n - [Azure Getting Started](https://cloudcustodian.io/docs/azure/gettingstarted.html)\n - [GCP Getting Started](https://cloudcustodian.io/docs/gcp/gettingstarted.html)\n\nAs a quick walk through, below are some sample policies for AWS resources.\n\n 1. will enforce that no S3 buckets have cross-account access enabled.\n 1. will terminate any newly launched EC2 instance that do not have an encrypted EBS volume.\n 1. will tag any EC2 instance that does not have the follow tags\n "Environment", "AppId", and either "OwnerContact" or "DeptID" to\n be stopped in four days.\n\n```yaml\npolicies:\n - name: s3-cross-account\n description: |\n Checks S3 for buckets with cross-account access and\n removes the cross-account access.\n resource: aws.s3\n region: us-east-1\n filters:\n - type: cross-account\n actions:\n - type: remove-statements\n statement_ids: matched\n\n - name: ec2-require-non-public-and-encrypted-volumes\n resource: aws.ec2\n description: |\n Provision a lambda and cloud watch event target\n that looks at all new instances and terminates those with\n unencrypted volumes.\n mode:\n type: cloudtrail\n role: CloudCustodian-QuickStart\n events:\n - RunInstances\n filters:\n - type: ebs\n key: Encrypted\n value: false\n actions:\n - terminate\n\n - name: tag-compliance\n resource: aws.ec2\n description: |\n Schedule a resource that does not meet tag compliance policies to be stopped in four days. Note a separate policy using the`marked-for-op` filter is required to actually stop the instances after four days.\n filters:\n - State.Name: running\n - "tag:Environment": absent\n - "tag:AppId": absent\n - or:\n - "tag:OwnerContact": absent\n - "tag:DeptID": absent\n actions:\n - type: mark-for-op\n op: stop\n days: 4\n```\n\nYou can validate, test, and run Cloud Custodian with the example policy with these commands:\n\n```shell\n# Validate the configuration (note this happens by default on run)\n$ custodian validate policy.yml\n\n# Dryrun on the policies (no actions executed) to see what resources\n# match each policy.\n$ custodian run --dryrun -s out policy.yml\n\n# Run the policy\n$ custodian run -s out policy.yml\n```\n\nYou can run Cloud Custodian via Docker as well:\n\n```shell\n# Download the image\n$ docker pull cloudcustodian/c7n\n$ mkdir output\n\n# Run the policy\n#\n# This will run the policy using only the environment variables for authentication\n$ docker run -it \\\n -v $(pwd)/output:/home/custodian/output \\\n -v $(pwd)/policy.yml:/home/custodian/policy.yml \\\n --env-file <(env | grep "^AWS\\|^AZURE\\|^GOOGLE") \\\n cloudcustodian/c7n run -v -s /home/custodian/output /home/custodian/policy.yml\n\n# Run the policy (using AWS\'s generated credentials from STS)\n#\n# NOTE: We mount the ``.aws/credentials`` and ``.aws/config`` directories to\n# the docker container to support authentication to AWS using the same credentials\n# credentials that are available to the local user if authenticating with STS.\n\n$ docker run -it \\\n -v $(pwd)/output:/home/custodian/output \\\n -v $(pwd)/policy.yml:/home/custodian/policy.yml \\\n -v $(cd ~ && pwd)/.aws/credentials:/home/custodian/.aws/credentials \\\n -v $(cd ~ && pwd)/.aws/config:/home/custodian/.aws/config \\\n --env-file <(env | grep "^AWS") \\\n cloudcustodian/c7n run -v -s /home/custodian/output /home/custodian/policy.yml\n```\n\nThe [custodian cask\ntool](https://cloudcustodian.io/docs/tools/cask.html) is a go binary\nthat provides a transparent front end to docker that mirors the regular\ncustodian cli, but automatically takes care of mounting volumes.\n\nConsult the documentation for additional information, or reach out on gitter.\n\nCloud Provider Specific Help\n----------------------------\n\nFor specific instructions for AWS, Azure, and GCP, visit the relevant getting started page.\n\n- [AWS](https://cloudcustodian.io/docs/aws/gettingstarted.html)\n- [Azure](https://cloudcustodian.io/docs/azure/gettingstarted.html)\n- [GCP](https://cloudcustodian.io/docs/gcp/gettingstarted.html)\n\nGet Involved\n------------\n\n- [GitHub](https://github.com/cloud-custodian/cloud-custodian) - (This page)\n- [Slack](https://communityinviter.com/apps/cloud-custodian/c7n-chat) - Real time chat if you\'re looking for help or interested in contributing to Custodian! \n - [Gitter](https://gitter.im/cloud-custodian/cloud-custodian) - (Older real time chat, we\'re likely migrating away from this)\n- [Mailing List](https://groups.google.com/forum/#!forum/cloud-custodian) - Our project mailing list, subscribe here for important project announcements, feel free to ask questions\n- [Reddit](https://reddit.com/r/cloudcustodian) - Our subreddit\n- [StackOverflow](https://stackoverflow.com/questions/tagged/cloudcustodian) - Q&A site for developers, we keep an eye on the `cloudcustodian` tag\n- [YouTube Channel](https://www.youtube.com/channel/UCdeXCdFLluylWnFfS0-jbDA/) - We\'re working on adding tutorials and other useful information, as well as meeting videos\n\nCommunity Resources\n-------------------\n\nWe have a regular community meeting that is open to all users and developers of every skill level.\nJoining the [mailing list](https://groups.google.com/forum/#!forum/cloud-custodian) will automatically send you a meeting invite. \nSee the notes below for more technical information on joining the meeting. \n\n- [Community Meeting Videos](https://www.youtube.com/watch?v=qy250y0UT-4&list=PLJ2Un8H_N5uBeAAWK95SnWvm_AuNJ8q2x)\n- [Community Meeting Notes Archive](https://github.com/orgs/cloud-custodian/discussions/categories/announcements)\n- [Upcoming Community Events](https://cloudcustodian.io/events/)\n- [Cloud Custodian Annual Report 2021](https://github.com/cncf/toc/blob/main/reviews/2021-cloud-custodian-annual.md) - Annual health check provided to the CNCF outlining the health of the project\n\n\nAdditional Tools\n----------------\n\nThe Custodian project also develops and maintains a suite of additional\ntools here\n:\n\n- [**_Org_:**](https://cloudcustodian.io/docs/tools/c7n-org.html) Multi-account policy execution.\n\n- [**_PolicyStream_:**](https://cloudcustodian.io/docs/tools/c7n-policystream.html) Git history as stream of logical policy changes.\n\n- [**_Salactus_:**](https://cloudcustodian.io/docs/tools/c7n-salactus.html) Scale out s3 scanning.\n\n- [**_Mailer_:**](https://cloudcustodian.io/docs/tools/c7n-mailer.html) A reference implementation of sending messages to users to notify them.\n\n- [**_Trail Creator_:**](https://cloudcustodian.io/docs/tools/c7n-trailcreator.html) Retroactive tagging of resources creators from CloudTrail\n\n- **_TrailDB_:** Cloudtrail indexing and time series generation for dashboarding.\n\n- [**_LogExporter_:**](https://cloudcustodian.io/docs/tools/c7n-logexporter.html) Cloud watch log exporting to s3\n\n- [**_Cask_:**](https://cloudcustodian.io/docs/tools/cask.html) Easy custodian exec via docker\n\n- [**_Guardian_:**](https://cloudcustodian.io/docs/tools/c7n-guardian.html) Automated multi-account Guard Duty setup\n\n- [**_Omni SSM_:**](https://cloudcustodian.io/docs/tools/omnissm.html) EC2 Systems Manager Automation\n\n- [**_Mugc_:**](https://github.com/cloud-custodian/cloud-custodian/tree/master/tools/ops#mugc) A utility used to clean up Cloud Custodian Lambda policies that are deployed in an AWS environment.\n\nContributing\n------------\n\nSee \n\nSecurity\n--------\n\nIf you\'ve found a security related issue, a vulnerability, or a\npotential vulnerability in Cloud Custodian please let the Cloud\n[Custodian Security Team](mailto:security@cloudcustodian.io) know with\nthe details of the vulnerability. We\'ll send a confirmation email to\nacknowledge your report, and we\'ll send an additional email when we\'ve\nidentified the issue positively or negatively.\n\nCode of Conduct\n---------------\n\nThis project adheres to the [CNCF Code of Conduct](https://github.com/cncf/foundation/blob/master/code-of-conduct.md)\n\nBy participating, you are expected to honor this code.\n\n', 'long_description_content_type': 'text/markdown', 'author': 'Cloud Custodian Project', - 'author_email': None, - 'maintainer': None, - 'maintainer_email': None, - 'url': 'https://cloudcustodian.io', + 'author_email': 'cloud-custodian@googlegroups.com', + 'project_urls': { + 'Homepage': 'https://cloudcustodian.io', + 'Documentation': 'https://cloudcustodian.io/docs/', + 'Source': 'https://github.com/cloud-custodian/cloud-custodian', + 'Issue Tracker': 'https://github.com/cloud-custodian/cloud-custodian/issues', + }, 'packages': packages, 'package_data': package_data, 'install_requires': install_requires, diff --git a/tests/data/config/s3-from-rule-sans-accelerator.json b/tests/data/config/s3-from-rule-sans-accelerator.json new file mode 100644 index 00000000000..17bf22528eb --- /dev/null +++ b/tests/data/config/s3-from-rule-sans-accelerator.json @@ -0,0 +1 @@ +{"invokingEvent": "{\"configurationItemDiff\":null,\"configurationItem\":{\"relatedEvents\":[\"99f04786-16e3-4f91-98a7-b7d710fe1e3b\"],\"relationships\":[],\"configuration\":{\"name\":\"c7n-fire-logs\",\"owner\":{\"displayName\":\"mandeep.bal\",\"id\":\"e7c8bb65a5fc49cf906715eae09de9e4bb7861a96361ba79b833aa45f6833b15\"},\"creationDate\":\"2017-09-15T02:05:40.000Z\"},\"supplementaryConfiguration\":{\"AccessControlList\":\"{\\\"grantSet\\\":null,\\\"grantList\\\":[{\\\"grantee\\\":{\\\"id\\\":\\\"e7c8bb65a5fc49cf906715eae09de9e4bb7861a96361ba79b833aa45f6833b15\\\",\\\"displayName\\\":\\\"mandeep.bal\\\"},\\\"permission\\\":\\\"FullControl\\\"}],\\\"owner\\\":{\\\"displayName\\\":\\\"mandeep.bal\\\",\\\"id\\\":\\\"e7c8bb65a5fc49cf906715eae09de9e4bb7861a96361ba79b833aa45f6833b15\\\"},\\\"isRequesterCharged\\\":false}\",\"BucketLoggingConfiguration\":{\"destinationBucketName\":null,\"logFilePrefix\":null},\"BucketNotificationConfiguration\":{\"configurations\":{}},\"BucketPolicy\":{\"policyText\":null},\"BucketVersioningConfiguration\":{\"status\":\"Off\",\"isMfaDeleteEnabled\":null},\"IsRequesterPaysEnabled\":false},\"tags\":{},\"configurationItemVersion\":\"1.2\",\"configurationItemCaptureTime\":\"2017-09-15T02:08:26.719Z\",\"configurationStateId\":1505441306719,\"awsAccountId\":\"644160558196\",\"configurationItemStatus\":\"ResourceDiscovered\",\"resourceType\":\"AWS::S3::Bucket\",\"resourceId\":\"c7n-fire-logs\",\"resourceName\":\"c7n-fire-logs\",\"ARN\":\"arn:aws:s3:::c7n-fire-logs\",\"awsRegion\":\"us-east-1\",\"availabilityZone\":\"Regional\",\"configurationStateMd5Hash\":\"6d3815aa37dbbd79e55abc72a11fb298\",\"resourceCreationTime\":\"2017-09-15T02:05:40.000Z\"},\"notificationCreationTime\":\"2017-10-30T08:54:48.029Z\",\"messageType\":\"ConfigurationItemChangeNotification\",\"recordVersion\":\"1.2\"}"} diff --git a/tests/data/cwe/event-cloud-trail-update-distribution.json b/tests/data/cwe/event-cloud-trail-update-distribution.json new file mode 100644 index 00000000000..61be5514c43 --- /dev/null +++ b/tests/data/cwe/event-cloud-trail-update-distribution.json @@ -0,0 +1,264 @@ +{ + "version": "0", + "id": "93a7a030-e28a-6aa0-a35c-7bdbca54b7f6", + "detail-type": "AWS API Call via CloudTrail", + "source": "aws.cloudfront", + "account": "012345678912", + "time": "2022-07-13T18:09:19Z", + "region": "us-east-1", + "resources": [], + "detail": { + "eventVersion": "1.08", + "userIdentity": { + "type": "AssumedRole", + "principalId": "AROAVD4IK2M7GWZXER5DZ:HarishAchappa", + "arn": "arn:aws:sts::012345678912:assumed-role/c7nbot/HarishAchappa", + "accountId": "012345678912", + "accessKeyId": "ASIAVD4IK2M7C6RULHH3", + "sessionContext": { + "sessionIssuer": { + "type": "Role", + "principalId": "AROAVD4IK2M7GWZXER5DZ", + "arn": "arn:aws:iam::012345678912:role/c7nbot", + "accountId": "012345678912", + "userName": "c7nbot" + }, + "webIdFederationData": {}, + "attributes": { + "creationDate": "2022-07-13T17:55:21Z", + "mfaAuthenticated": "false" + } + } + }, + "eventTime": "2022-07-13T18:09:19Z", + "eventSource": "cloudfront.amazonaws.com", + "eventName": "UpdateDistribution", + "awsRegion": "us-east-1", + "sourceIPAddress": "AWS Internal", + "userAgent": "AWS Internal", + "requestParameters": { + "id": "E53370FUHBNLK", + "distributionConfig": { + "origins": { + "quantity": 1, + "items": [ + { + "connectionAttempts": 3, + "customHeaders": { + "items": [], + "quantity": 0 + }, + "domainName": "c7n-activeresponse-test-to-be-deleted.s3.us-east-1.amazonaws.com", + "connectionTimeout": 10, + "s3OriginConfig": { + "originAccessIdentity": "" + }, + "originShield": { + "enabled": false + }, + "originPath": "", + "id": "c7n-activeresponse-test-to-be-deleted.s3.us-east-1.amazonaws.com" + } + ] + }, + "aliases": { + "items": [], + "quantity": 0 + }, + "defaultCacheBehavior": { + "functionAssociations": { + "quantity": 0, + "items": [] + }, + "lambdaFunctionAssociations": { + "items": [], + "quantity": 0 + }, + "fieldLevelEncryptionId": "", + "trustedSigners": { + "items": [], + "enabled": false, + "quantity": 0 + }, + "trustedKeyGroups": { + "enabled": false, + "quantity": 0, + "items": [] + }, + "cachePolicyId": "658327ea-f89d-4fab-a63d-7e88639e58f6", + "allowedMethods": { + "items": [ + "GET", + "HEAD" + ], + "quantity": 2, + "cachedMethods": { + "items": [ + "GET", + "HEAD" + ], + "quantity": 2 + } + }, + "smoothStreaming": false, + "targetOriginId": "c7n-activeresponse-test-to-be-deleted.s3.us-east-1.amazonaws.com", + "viewerProtocolPolicy": "allow-all", + "compress": true + }, + "callerReference": "9c8970c1-b26e-4131-b3cf-985880574e96", + "webACLId": "arn:aws:wafv2:us-east-1:012345678912:regional/webacl/FMManagedWebACLV2-FMS-TEST-1656966584517/96494e83-ee49-4505-9f68-9103c6cd9406", + "defaultRootObject": "", + "enabled": true, + "httpVersion": "http2", + "comment": "HIDDEN_DUE_TO_SECURITY_REASONS", + "logging": { + "includeCookies": false, + "prefix": "", + "bucket": "", + "enabled": false + }, + "isIPV6Enabled": true, + "viewerCertificate": { + "cloudFrontDefaultCertificate": true, + "minimumProtocolVersion": "TLSv1" + }, + "priceClass": "PriceClass_All", + "originGroups": { + "quantity": 0, + "items": [] + } + } + }, + "responseElements": { + "location": "https://cloudfront.amazonaws.com/2020-05-31/distribution/E53370FUHBNLK", + "eTag": "E3DFGD1PHNLYY3", + "distribution": { + "aRN": "arn:aws:cloudfront::012345678912:distribution/E53370FUHBNLK", + "id": "E53370FUHBNLK", + "lastModifiedTime": "Jul 13, 2022 6:09:18 PM", + "activeTrustedSigners": { + "quantity": 0, + "enabled": false + }, + "domainName": "d1bftvz1j2jyjs.cloudfront.net", + "activeTrustedKeyGroups": { + "quantity": 0, + "enabled": false + }, + "inProgressInvalidationBatches": 0, + "status": "InProgress", + "distributionConfig": { + "origins": { + "quantity": 1, + "items": [ + { + "connectionAttempts": 3, + "customHeaders": { + "quantity": 0 + }, + "oacSigningBehavior": "never", + "domainName": "c7n-activeresponse-test-to-be-deleted.s3.us-east-1.amazonaws.com", + "connectionTimeout": 10, + "s3OriginConfig": { + "originAccessIdentity": "" + }, + "originShield": { + "enabled": false + }, + "originAccessControlId": "", + "originPath": "", + "id": "c7n-activeresponse-test-to-be-deleted.s3.us-east-1.amazonaws.com" + } + ] + }, + "aliases": { + "quantity": 0 + }, + "defaultCacheBehavior": { + "functionAssociations": { + "quantity": 0 + }, + "lambdaFunctionAssociations": { + "quantity": 0 + }, + "fieldLevelEncryptionId": "", + "trustedSigners": { + "enabled": false, + "quantity": 0 + }, + "trustedKeyGroups": { + "enabled": false, + "quantity": 0 + }, + "cachePolicyId": "658327ea-f89d-4fab-a63d-7e88639e58f6", + "allowedMethods": { + "items": [ + "HEAD", + "GET" + ], + "quantity": 2, + "cachedMethods": { + "items": [ + "HEAD", + "GET" + ], + "quantity": 2 + } + }, + "smoothStreaming": false, + "targetOriginId": "c7n-activeresponse-test-to-be-deleted.s3.us-east-1.amazonaws.com", + "viewerProtocolPolicy": "allow-all", + "compress": true + }, + "callerReference": "9c8970c1-b26e-4131-b3cf-985880574e96", + "staging": false, + "webACLId": "arn:aws:wafv2:us-east-1:012345678912:regional/webacl/FMManagedWebACLV2-FMS-TEST-1656966584517/96494e83-ee49-4505-9f68-9103c6cd9406", + "defaultRootObject": "", + "customErrorResponses": { + "quantity": 0 + }, + "enabled": true, + "cacheBehaviors": { + "quantity": 0 + }, + "continuousDeploymentPolicyId": "", + "httpVersion": "http2", + "comment": "HIDDEN_DUE_TO_SECURITY_REASONS", + "restrictions": { + "geoRestriction": { + "restrictionType": "none", + "quantity": 0 + } + }, + "logging": { + "includeCookies": false, + "prefix": "", + "bucket": "", + "enabled": false + }, + "isIPV6Enabled": true, + "viewerCertificate": { + "cloudFrontDefaultCertificate": true, + "certificateSource": "cloudfront", + "sSLSupportMethod": "vip", + "minimumProtocolVersion": "TLSv1" + }, + "priceClass": "PriceClass_All", + "originGroups": { + "quantity": 0 + } + } + } + }, + "requestID": "5e3a89ec-4fb3-4407-a7a1-26e52122ca46", + "eventID": "a1474634-7457-45e1-bc0f-d47e7ad72f79", + "readOnly": false, + "eventType": "AwsApiCall", + "apiVersion": "2020_05_31", + "managementEvent": true, + "recipientAccountId": "012345678912", + "eventCategory": "Management", + "sessionCredentialFromConsole": "true" + }, + "debug": true +} \ No newline at end of file diff --git a/tests/data/placebo/test_appelb_wafv2_regex/elasticloadbalancing.DescribeLoadBalancers_1.json b/tests/data/placebo/test_appelb_wafv2_regex/elasticloadbalancing.DescribeLoadBalancers_1.json new file mode 100644 index 00000000000..5fdaa0d6c17 --- /dev/null +++ b/tests/data/placebo/test_appelb_wafv2_regex/elasticloadbalancing.DescribeLoadBalancers_1.json @@ -0,0 +1,37 @@ +{ + "status_code": 200, + "data": { + "LoadBalancers": [ + { + "LoadBalancerArn": "arn:aws:elasticloadbalancing:us-east-1:123456789123:loadbalancer/app/test/433ae0ba96204181", + "DNSName": "test-1231241576.us-east-1.elb.amazonaws.com", + "CanonicalHostedZoneId": "Z35SXDOTRQ7X7K", + "CreatedTime": "2020-04-15T02:00:16.010000+00:00", + "LoadBalancerName": "test", + "Scheme": "internet-facing", + "VpcId": "vpc-d2d616b5", + "State": { + "Code": "active" + }, + "Type": "application", + "AvailabilityZones": [ + { + "ZoneName": "us-east-1a", + "SubnetId": "subnet-914763e7", + "LoadBalancerAddresses": [] + }, + { + "ZoneName": "us-east-1b", + "SubnetId": "subnet-efbcccb7", + "LoadBalancerAddresses": [] + } + ], + "SecurityGroups": [ + "sg-6c7fa917" + ], + "IpAddressType": "ipv4" + } + ], + "ResponseMetadata": {} + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_appelb_wafv2_regex/elasticloadbalancing.DescribeTags_1.json b/tests/data/placebo/test_appelb_wafv2_regex/elasticloadbalancing.DescribeTags_1.json new file mode 100644 index 00000000000..bea217322a2 --- /dev/null +++ b/tests/data/placebo/test_appelb_wafv2_regex/elasticloadbalancing.DescribeTags_1.json @@ -0,0 +1,12 @@ +{ + "status_code": 200, + "data": { + "TagDescriptions": [ + { + "ResourceArn": "arn:aws:elasticloadbalancing:us-east-1:123456789123:loadbalancer/app/test/433ae0ba96204181", + "Tags": [] + } + ], + "ResponseMetadata": {} + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_appelb_wafv2_regex/elasticloadbalancing.DescribeTags_2.json b/tests/data/placebo/test_appelb_wafv2_regex/elasticloadbalancing.DescribeTags_2.json new file mode 100644 index 00000000000..bea217322a2 --- /dev/null +++ b/tests/data/placebo/test_appelb_wafv2_regex/elasticloadbalancing.DescribeTags_2.json @@ -0,0 +1,12 @@ +{ + "status_code": 200, + "data": { + "TagDescriptions": [ + { + "ResourceArn": "arn:aws:elasticloadbalancing:us-east-1:123456789123:loadbalancer/app/test/433ae0ba96204181", + "Tags": [] + } + ], + "ResponseMetadata": {} + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_appelb_wafv2_regex/wafv2.AssociateWebACL_1.json b/tests/data/placebo/test_appelb_wafv2_regex/wafv2.AssociateWebACL_1.json new file mode 100644 index 00000000000..5b2170a073c --- /dev/null +++ b/tests/data/placebo/test_appelb_wafv2_regex/wafv2.AssociateWebACL_1.json @@ -0,0 +1,6 @@ +{ + "status_code": 200, + "data": { + "ResponseMetadata": {} + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_appelb_wafv2_regex/wafv2.DisassociateWebACL_1.json b/tests/data/placebo/test_appelb_wafv2_regex/wafv2.DisassociateWebACL_1.json new file mode 100644 index 00000000000..5b2170a073c --- /dev/null +++ b/tests/data/placebo/test_appelb_wafv2_regex/wafv2.DisassociateWebACL_1.json @@ -0,0 +1,6 @@ +{ + "status_code": 200, + "data": { + "ResponseMetadata": {} + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_appelb_wafv2_regex/wafv2.ListResourcesForWebACL_1.json b/tests/data/placebo/test_appelb_wafv2_regex/wafv2.ListResourcesForWebACL_1.json new file mode 100644 index 00000000000..7053058a495 --- /dev/null +++ b/tests/data/placebo/test_appelb_wafv2_regex/wafv2.ListResourcesForWebACL_1.json @@ -0,0 +1,9 @@ +{ + "status_code": 200, + "data": { + "ResourceArns": [ + "arn:aws:elasticloadbalancing:us-east-1:123456789123:loadbalancer/app/test/433ae0ba96204181" + ], + "ResponseMetadata": {} + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_appelb_wafv2_regex/wafv2.ListWebACLs_1.json b/tests/data/placebo/test_appelb_wafv2_regex/wafv2.ListWebACLs_1.json new file mode 100644 index 00000000000..3e8d0608b51 --- /dev/null +++ b/tests/data/placebo/test_appelb_wafv2_regex/wafv2.ListWebACLs_1.json @@ -0,0 +1,14 @@ +{ + "status_code": 200, + "data": { + "NextMarker": "791f9fc9-16bb-4d32-8f6a-b55e9b6f11c8", + "WebACLs": [ + { + "Id": "96494e83-ee49-4505-9f68-9103c6cd9406", + "Name": "FMManagedWebACLV2-FMS-TEST-1656966584517", + "ARN": "arn:aws:wafv2:us-east-1:671470938745:regional/webacl/FMManagedWebACLV2-FMS-TEST-1656966584517/96494e83-ee49-4505-9f68-9103c6cd9406" + } + ], + "ResponseMetadata": {} + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/elasticloadbalancing.DescribeLoadBalancers_1.json b/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/elasticloadbalancing.DescribeLoadBalancers_1.json new file mode 100644 index 00000000000..5fdaa0d6c17 --- /dev/null +++ b/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/elasticloadbalancing.DescribeLoadBalancers_1.json @@ -0,0 +1,37 @@ +{ + "status_code": 200, + "data": { + "LoadBalancers": [ + { + "LoadBalancerArn": "arn:aws:elasticloadbalancing:us-east-1:123456789123:loadbalancer/app/test/433ae0ba96204181", + "DNSName": "test-1231241576.us-east-1.elb.amazonaws.com", + "CanonicalHostedZoneId": "Z35SXDOTRQ7X7K", + "CreatedTime": "2020-04-15T02:00:16.010000+00:00", + "LoadBalancerName": "test", + "Scheme": "internet-facing", + "VpcId": "vpc-d2d616b5", + "State": { + "Code": "active" + }, + "Type": "application", + "AvailabilityZones": [ + { + "ZoneName": "us-east-1a", + "SubnetId": "subnet-914763e7", + "LoadBalancerAddresses": [] + }, + { + "ZoneName": "us-east-1b", + "SubnetId": "subnet-efbcccb7", + "LoadBalancerAddresses": [] + } + ], + "SecurityGroups": [ + "sg-6c7fa917" + ], + "IpAddressType": "ipv4" + } + ], + "ResponseMetadata": {} + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/elasticloadbalancing.DescribeTags_1.json b/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/elasticloadbalancing.DescribeTags_1.json new file mode 100644 index 00000000000..bea217322a2 --- /dev/null +++ b/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/elasticloadbalancing.DescribeTags_1.json @@ -0,0 +1,12 @@ +{ + "status_code": 200, + "data": { + "TagDescriptions": [ + { + "ResourceArn": "arn:aws:elasticloadbalancing:us-east-1:123456789123:loadbalancer/app/test/433ae0ba96204181", + "Tags": [] + } + ], + "ResponseMetadata": {} + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/elasticloadbalancing.DescribeTags_2.json b/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/elasticloadbalancing.DescribeTags_2.json new file mode 100644 index 00000000000..bea217322a2 --- /dev/null +++ b/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/elasticloadbalancing.DescribeTags_2.json @@ -0,0 +1,12 @@ +{ + "status_code": 200, + "data": { + "TagDescriptions": [ + { + "ResourceArn": "arn:aws:elasticloadbalancing:us-east-1:123456789123:loadbalancer/app/test/433ae0ba96204181", + "Tags": [] + } + ], + "ResponseMetadata": {} + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/wafv2.AssociateWebACL_1.json b/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/wafv2.AssociateWebACL_1.json new file mode 100644 index 00000000000..5b2170a073c --- /dev/null +++ b/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/wafv2.AssociateWebACL_1.json @@ -0,0 +1,6 @@ +{ + "status_code": 200, + "data": { + "ResponseMetadata": {} + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/wafv2.ListResourcesForWebACL_1.json b/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/wafv2.ListResourcesForWebACL_1.json new file mode 100644 index 00000000000..7053058a495 --- /dev/null +++ b/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/wafv2.ListResourcesForWebACL_1.json @@ -0,0 +1,9 @@ +{ + "status_code": 200, + "data": { + "ResourceArns": [ + "arn:aws:elasticloadbalancing:us-east-1:123456789123:loadbalancer/app/test/433ae0ba96204181" + ], + "ResponseMetadata": {} + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/wafv2.ListWebACLs_1.json b/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/wafv2.ListWebACLs_1.json new file mode 100644 index 00000000000..00d578445b8 --- /dev/null +++ b/tests/data/placebo/test_appelb_wafv2_regex_multiple_webacl_match/wafv2.ListWebACLs_1.json @@ -0,0 +1,19 @@ +{ + "status_code": 200, + "data": { + "NextMarker": "791f9fc9-16bb-4d32-8f6a-b55e9b6f11c8", + "WebACLs": [ + { + "Id": "96494e83-ee49-4505-9f68-9103c6cd9406", + "Name": "FMManagedWebACLV2-FMS-TEST-1656966584517", + "ARN": "arn:aws:wafv2:us-east-1:123456789123:regional/webacl/FMManagedWebACLV2-FMS-TEST-1656966584517/96494e83-ee49-4505-9f68-9103c6cd9406" + }, + { + "Id": "3c5f3db9-04c1-47f4-a6ab-23b70a3a8509", + "Name": "FMManagedWebACLV2-FMS-TEST2-1656966576062", + "ARN": "arn:aws:wafv2:us-east-1:123456789123:regional/webacl/FMManagedWebACLV2-FMS-TEST2-1656966576062/3c5f3db9-04c1-47f4-a6ab-23b70a3a8509" + } + ], + "ResponseMetadata": {} + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_catalog_product_resource/servicecatalog.DescribeProductAsAdmin_1.json b/tests/data/placebo/test_catalog_product_resource/servicecatalog.DescribeProductAsAdmin_1.json new file mode 100644 index 00000000000..2d149f8ffee --- /dev/null +++ b/tests/data/placebo/test_catalog_product_resource/servicecatalog.DescribeProductAsAdmin_1.json @@ -0,0 +1,63 @@ +{ + "status_code": 200, + "data": { + "ProductViewDetail": { + "ProductViewSummary": { + "Id": "testview-ipzsltwzr26dq", + "ProductId": "test-6orqs3iobd7om", + "Name": "testProduct", + "Owner": "testOwner", + "ShortDescription": "test-product", + "Type": "CLOUD_FORMATION_TEMPLATE", + "Distributor": "xyz", + "HasDefaultPath": true, + "SupportEmail": "xyz@test.com", + "SupportDescription": "", + "SupportUrl": "" + }, + "Status": "AVAILABLE", + "ProductARN": "arn:aws:catalog:us-east-2:123456789012:product/test-6orqs3iobd7om", + "CreatedTime": { + "__class__": "datetime", + "year": 2019, + "month": 1, + "day": 17, + "hour": 6, + "minute": 1, + "second": 58, + "microsecond": 667000 + } + }, + "ProvisioningArtifactSummaries": [ + { + "Id": "pa-wxfliske47cp2", + "CreatedTime": { + "__class__": "datetime", + "year": 2019, + "month": 1, + "day": 17, + "hour": 6, + "minute": 1, + "second": 58, + "microsecond": 667000 + }, + "ProvisioningArtifactMetadata": { + "SourceProvisioningArtifactId": "pa-wxfliske47cp2" + } + } + ], + "Tags": [ + { + "Key": "Name", + "Value": "testProduct" + } + ], + "TagOptions": [], + "Budgets": [ + { + "BudgetName": "testBudget" + } + ], + "ResponseMetadata": {} + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_catalog_product_resource/servicecatalog.SearchProductsAsAdmin_1.json b/tests/data/placebo/test_catalog_product_resource/servicecatalog.SearchProductsAsAdmin_1.json new file mode 100644 index 00000000000..3f7798c467a --- /dev/null +++ b/tests/data/placebo/test_catalog_product_resource/servicecatalog.SearchProductsAsAdmin_1.json @@ -0,0 +1,35 @@ +{ + "status_code": 200, + "data": { + "ProductViewDetails": [ + { + "ProductViewSummary": { + "Id": "testview-ipzsltwzr26dq", + "ProductId": "test-6orqs3iobd7om", + "Name": "testProduct", + "Owner": "testOwner", + "ShortDescription": "test-product", + "Type": "CLOUD_FORMATION_TEMPLATE", + "Distributor": "xyz", + "HasDefaultPath": true, + "SupportEmail": "xyz@test.com", + "SupportDescription": "", + "SupportUrl": "" + }, + "Status": "AVAILABLE", + "ProductARN": "arn:aws:catalog:us-east-2:123456789012:product/test-6orqs3iobd7om", + "CreatedTime": { + "__class__": "datetime", + "year": 2019, + "month": 1, + "day": 17, + "hour": 6, + "minute": 1, + "second": 58, + "microsecond": 667000 + } + } + ], + "ResponseMetadata": {} + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_distribution_wafv2_regex/cloudfront.GetDistributionConfig_1.json b/tests/data/placebo/test_distribution_wafv2_regex/cloudfront.GetDistributionConfig_1.json new file mode 100644 index 00000000000..a9285791104 --- /dev/null +++ b/tests/data/placebo/test_distribution_wafv2_regex/cloudfront.GetDistributionConfig_1.json @@ -0,0 +1,113 @@ +{ + "status_code": 200, + "data": { + "ETag": "EIZMGDN1LXJRI", + "DistributionConfig": { + "Comment": "", + "CacheBehaviors": { + "Quantity": 0 + }, + "IsIPV6Enabled": true, + "Logging": { + "Bucket": "", + "Prefix": "", + "Enabled": false, + "IncludeCookies": false + }, + "WebACLId": "arn:aws:wafv2:us-east-1:012345678912:regional/webacl/FMManagedWebACLV2-FMS-TEST-1656966584517/96494e83-ee49-4505-9f68-9103c6cd9406", + "Origins": { + "Items": [ + { + "S3OriginConfig": { + "OriginAccessIdentity": "" + }, + "OriginPath": "", + "CustomHeaders": { + "Quantity": 0 + }, + "Id": "S3-sns-notify-test", + "DomainName": "sns-notify-test.s3.amazonaws.com" + } + ], + "Quantity": 1 + }, + "DefaultRootObject": "", + "PriceClass": "PriceClass_All", + "Enabled": true, + "DefaultCacheBehavior": { + "TrustedSigners": { + "Enabled": false, + "Quantity": 0 + }, + "LambdaFunctionAssociations": { + "Quantity": 0 + }, + "TargetOriginId": "S3-sns-notify-test", + "ViewerProtocolPolicy": "allow-all", + "ForwardedValues": { + "Headers": { + "Quantity": 0 + }, + "Cookies": { + "Forward": "none" + }, + "QueryStringCacheKeys": { + "Quantity": 0 + }, + "QueryString": false + }, + "MaxTTL": 31536000, + "SmoothStreaming": false, + "DefaultTTL": 86400, + "AllowedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "CachedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "Quantity": 2 + }, + "Quantity": 2 + }, + "MinTTL": 0, + "Compress": false + }, + "CallerReference": "1499952607732", + "ViewerCertificate": { + "CloudFrontDefaultCertificate": true, + "MinimumProtocolVersion": "TLSv1", + "CertificateSource": "cloudfront" + }, + "CustomErrorResponses": { + "Quantity": 0 + }, + "HttpVersion": "http2", + "Restrictions": { + "GeoRestriction": { + "RestrictionType": "none", + "Quantity": 0 + } + }, + "Aliases": { + "Quantity": 0 + } + }, + "ResponseMetadata": { + "RetryAttempts": 0, + "HTTPStatusCode": 200, + "RequestId": "0755e5c5-a9c9-11e7-82fd-ed12cccaa8d8", + "HTTPHeaders": { + "x-amzn-requestid": "0755e5c5-a9c9-11e7-82fd-ed12cccaa8d8", + "content-length": "2180", + "vary": "Accept-Encoding", + "etag": "EIZMGDN1LXJRI", + "date": "Thu, 05 Oct 2017 12:30:53 GMT", + "content-type": "text/xml" + } + } + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_distribution_wafv2_regex/cloudfront.ListDistributions_1.json b/tests/data/placebo/test_distribution_wafv2_regex/cloudfront.ListDistributions_1.json new file mode 100644 index 00000000000..e5cb49b02ec --- /dev/null +++ b/tests/data/placebo/test_distribution_wafv2_regex/cloudfront.ListDistributions_1.json @@ -0,0 +1,281 @@ +{ + "status_code": 200, + "data": { + "DistributionList": { + "Marker": "", + "Items": [ + { + "Status": "Deployed", + "CacheBehaviors": { + "Quantity": 0 + }, + "Restrictions": { + "GeoRestriction": { + "RestrictionType": "none", + "Quantity": 0 + } + }, + "Origins": { + "Items": [ + { + "S3OriginConfig": { + "OriginAccessIdentity": "" + }, + "OriginPath": "", + "CustomHeaders": { + "Quantity": 0 + }, + "Id": "S3-sns-notify-test", + "DomainName": "sns-notify-test.s3.amazonaws.com" + } + ], + "Quantity": 1 + }, + "DomainName": "d3naej5h8q7gej.cloudfront.net", + "WebACLId": "arn:aws:wafv2:us-east-1:012345678912:regional/webacl/FMManagedWebACLV2-FMS-TEST-1656966584517/96494e83-ee49-4505-9f68-9103c6cd9406", + "PriceClass": "PriceClass_All", + "Enabled": true, + "DefaultCacheBehavior": { + "TrustedSigners": { + "Enabled": false, + "Quantity": 0 + }, + "LambdaFunctionAssociations": { + "Quantity": 0 + }, + "TargetOriginId": "S3-sns-notify-test", + "ViewerProtocolPolicy": "allow-all", + "ForwardedValues": { + "Headers": { + "Quantity": 0 + }, + "Cookies": { + "Forward": "none" + }, + "QueryStringCacheKeys": { + "Quantity": 0 + }, + "QueryString": false + }, + "MaxTTL": 31536000, + "SmoothStreaming": false, + "DefaultTTL": 86400, + "AllowedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "CachedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "Quantity": 2 + }, + "Quantity": 2 + }, + "MinTTL": 0, + "Compress": false + }, + "IsIPV6Enabled": true, + "Comment": "", + "ViewerCertificate": { + "CloudFrontDefaultCertificate": true, + "MinimumProtocolVersion": "TLSv1", + "CertificateSource": "cloudfront" + }, + "CustomErrorResponses": { + "Quantity": 0 + }, + "LastModifiedTime": { + "hour": 13, + "__class__": "datetime", + "month": 7, + "second": 8, + "microsecond": 399000, + "year": 2017, + "day": 13, + "minute": 30 + }, + "HttpVersion": "HTTP2", + "Id": "E53370FUHBNLK", + "ARN": "arn:aws:cloudfront::012345678912:distribution/E53370FUHBNLK", + "Aliases": { + "Quantity": 0 + } + }, + { + "Status": "Deployed", + "CacheBehaviors": { + "Items": [ + { + "TrustedSigners": { + "Enabled": false, + "Quantity": 0 + }, + "LambdaFunctionAssociations": { + "Quantity": 0 + }, + "TargetOriginId": "Custom-google.com", + "ViewerProtocolPolicy": "allow-all", + "ForwardedValues": { + "Headers": { + "Quantity": 0 + }, + "Cookies": { + "Forward": "none" + }, + "QueryStringCacheKeys": { + "Quantity": 0 + }, + "QueryString": false + }, + "MaxTTL": 31536000, + "PathPattern": "sadf", + "SmoothStreaming": false, + "DefaultTTL": 86400, + "AllowedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "CachedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "Quantity": 2 + }, + "Quantity": 2 + }, + "MinTTL": 0, + "Compress": false + } + ], + "Quantity": 1 + }, + "Restrictions": { + "GeoRestriction": { + "RestrictionType": "none", + "Quantity": 0 + } + }, + "Origins": { + "Items": [ + { + "OriginPath": "", + "CustomOriginConfig": { + "OriginSslProtocols": { + "Items": [ + "TLSv1.1", + "TLSv1.2" + ], + "Quantity": 2 + }, + "OriginProtocolPolicy": "http-only", + "OriginReadTimeout": 30, + "HTTPPort": 80, + "HTTPSPort": 443, + "OriginKeepaliveTimeout": 5 + }, + "CustomHeaders": { + "Quantity": 0 + }, + "Id": "Custom-google.com", + "DomainName": "google.com" + } + ], + "Quantity": 1 + }, + "DomainName": "d34vi31c0msjue.cloudfront.net", + "WebACLId": "", + "PriceClass": "PriceClass_All", + "Enabled": true, + "DefaultCacheBehavior": { + "TrustedSigners": { + "Enabled": false, + "Quantity": 0 + }, + "LambdaFunctionAssociations": { + "Quantity": 0 + }, + "TargetOriginId": "Custom-google.com", + "ViewerProtocolPolicy": "https-only", + "ForwardedValues": { + "Headers": { + "Quantity": 0 + }, + "Cookies": { + "Forward": "none" + }, + "QueryStringCacheKeys": { + "Quantity": 0 + }, + "QueryString": false + }, + "MaxTTL": 31536000, + "SmoothStreaming": false, + "DefaultTTL": 86400, + "AllowedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "CachedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "Quantity": 2 + }, + "Quantity": 2 + }, + "MinTTL": 0, + "Compress": false + }, + "IsIPV6Enabled": true, + "Comment": "", + "ViewerCertificate": { + "CloudFrontDefaultCertificate": true, + "MinimumProtocolVersion": "TLSv1", + "CertificateSource": "cloudfront" + }, + "CustomErrorResponses": { + "Quantity": 0 + }, + "LastModifiedTime": { + "hour": 18, + "__class__": "datetime", + "month": 9, + "second": 38, + "microsecond": 66000, + "year": 2017, + "day": 21, + "minute": 13 + }, + "HttpVersion": "HTTP2", + "Id": "EX42KVJ3ATGH", + "ARN": "arn:aws:cloudfront::012345678912:distribution/EX42KVJ3ATGH", + "Aliases": { + "Quantity": 0 + } + } + ], + "IsTruncated": false, + "MaxItems": 100, + "Quantity": 2 + }, + "ResponseMetadata": { + "RetryAttempts": 0, + "HTTPStatusCode": 200, + "RequestId": "05a7e864-a9c9-11e7-b379-c16d51d99c4d", + "HTTPHeaders": { + "x-amzn-requestid": "05a7e864-a9c9-11e7-b379-c16d51d99c4d", + "vary": "Accept-Encoding", + "content-length": "5686", + "content-type": "text/xml", + "date": "Thu, 05 Oct 2017 12:30:50 GMT" + } + } + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_distribution_wafv2_regex/cloudfront.UpdateDistribution_1.json b/tests/data/placebo/test_distribution_wafv2_regex/cloudfront.UpdateDistribution_1.json new file mode 100644 index 00000000000..50ce38791c9 --- /dev/null +++ b/tests/data/placebo/test_distribution_wafv2_regex/cloudfront.UpdateDistribution_1.json @@ -0,0 +1,134 @@ +{ + "status_code": 200, + "data": { + "Distribution": { + "Status": "InProgress", + "DomainName": "d3naej5h8q7gej.cloudfront.net", + "InProgressInvalidationBatches": 0, + "DistributionConfig": { + "Comment": "", + "CacheBehaviors": { + "Quantity": 0 + }, + "IsIPV6Enabled": true, + "Logging": { + "Bucket": "", + "Prefix": "", + "Enabled": false, + "IncludeCookies": false + }, + "WebACLId": "arn:aws:wafv2:us-east-1:012345678912:regional/webacl/FMManagedWebACLV2-FMS-TEST-1656966584517/96494e83-ee49-4505-9f68-9103c6cd9406", + "Origins": { + "Items": [ + { + "S3OriginConfig": { + "OriginAccessIdentity": "" + }, + "OriginPath": "", + "CustomHeaders": { + "Quantity": 0 + }, + "Id": "S3-sns-notify-test", + "DomainName": "sns-notify-test.s3.amazonaws.com" + } + ], + "Quantity": 1 + }, + "DefaultRootObject": "", + "PriceClass": "PriceClass_All", + "Enabled": true, + "DefaultCacheBehavior": { + "TrustedSigners": { + "Enabled": false, + "Quantity": 0 + }, + "LambdaFunctionAssociations": { + "Quantity": 0 + }, + "TargetOriginId": "S3-sns-notify-test", + "ViewerProtocolPolicy": "allow-all", + "ForwardedValues": { + "Headers": { + "Quantity": 0 + }, + "Cookies": { + "Forward": "none" + }, + "QueryStringCacheKeys": { + "Quantity": 0 + }, + "QueryString": false + }, + "MaxTTL": 31536000, + "SmoothStreaming": false, + "DefaultTTL": 86400, + "AllowedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "CachedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "Quantity": 2 + }, + "Quantity": 2 + }, + "MinTTL": 0, + "Compress": false + }, + "CallerReference": "1499952607732", + "ViewerCertificate": { + "CloudFrontDefaultCertificate": true, + "MinimumProtocolVersion": "TLSv1", + "CertificateSource": "cloudfront" + }, + "CustomErrorResponses": { + "Quantity": 0 + }, + "HttpVersion": "http2", + "Restrictions": { + "GeoRestriction": { + "RestrictionType": "none", + "Quantity": 0 + } + }, + "Aliases": { + "Quantity": 0 + } + }, + "ActiveTrustedSigners": { + "Enabled": false, + "Quantity": 0 + }, + "LastModifiedTime": { + "hour": 12, + "__class__": "datetime", + "month": 10, + "second": 53, + "microsecond": 843000, + "year": 2017, + "day": 5, + "minute": 30 + }, + "Id": "E53370FUHBNLK", + "ARN": "arn:aws:cloudfront::012345678912:distribution/E53370FUHBNLK" + }, + "ETag": "E12XBCJWKPGMKF", + "ResponseMetadata": { + "RetryAttempts": 0, + "HTTPStatusCode": 200, + "RequestId": "0772e3a8-a9c9-11e7-82fd-ed12cccaa8d8", + "HTTPHeaders": { + "x-amzn-requestid": "0772e3a8-a9c9-11e7-82fd-ed12cccaa8d8", + "content-length": "2634", + "vary": "Accept-Encoding", + "etag": "E12XBCJWKPGMKF", + "date": "Thu, 05 Oct 2017 12:30:53 GMT", + "content-type": "text/xml" + } + } + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_distribution_wafv2_regex/tagging.GetResources_1.json b/tests/data/placebo/test_distribution_wafv2_regex/tagging.GetResources_1.json new file mode 100644 index 00000000000..0388c0b6b72 --- /dev/null +++ b/tests/data/placebo/test_distribution_wafv2_regex/tagging.GetResources_1.json @@ -0,0 +1,18 @@ +{ + "status_code": 200, + "data": { + "PaginationToken": "", + "ResourceTagMappingList": [], + "ResponseMetadata": { + "RetryAttempts": 0, + "HTTPStatusCode": 200, + "RequestId": "05d75c18-a9c9-11e7-a028-2f7bd19c01f1", + "HTTPHeaders": { + "x-amzn-requestid": "05d75c18-a9c9-11e7-a028-2f7bd19c01f1", + "date": "Thu, 05 Oct 2017 12:30:50 GMT", + "content-length": "50", + "content-type": "application/x-amz-json-1.1" + } + } + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_distribution_wafv2_regex/tagging.GetResources_2.json b/tests/data/placebo/test_distribution_wafv2_regex/tagging.GetResources_2.json new file mode 100644 index 00000000000..b0588275990 --- /dev/null +++ b/tests/data/placebo/test_distribution_wafv2_regex/tagging.GetResources_2.json @@ -0,0 +1,18 @@ +{ + "status_code": 200, + "data": { + "PaginationToken": "", + "ResourceTagMappingList": [], + "ResponseMetadata": { + "RetryAttempts": 0, + "HTTPStatusCode": 200, + "RequestId": "08a6d06e-a9c9-11e7-bbe7-91ba2b470183", + "HTTPHeaders": { + "x-amzn-requestid": "08a6d06e-a9c9-11e7-bbe7-91ba2b470183", + "date": "Thu, 05 Oct 2017 12:30:55 GMT", + "content-length": "50", + "content-type": "application/x-amz-json-1.1" + } + } + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_distribution_wafv2_regex/wafv2.GetWebACL_1.json b/tests/data/placebo/test_distribution_wafv2_regex/wafv2.GetWebACL_1.json new file mode 100644 index 00000000000..2ea5437b62b --- /dev/null +++ b/tests/data/placebo/test_distribution_wafv2_regex/wafv2.GetWebACL_1.json @@ -0,0 +1,27 @@ +{ + "status_code": 200, + "data": { + "WebACL": { + "DefaultAction": { + "Type": "BLOCK" + }, + "Rules": [], + "MetricName": "test2", + "Id": "96494e83-ee49-4505-9f68-9103c6cd9406", + "Name": "FMManagedWebACLV2-FMS-TEST-1656966584517", + "ARN": "arn:aws:wafv2:us-east-1:012345678912:regional/webacl/FMManagedWebACLV2-FMS-TEST-1656966584517/96494e83-ee49-4505-9f68-9103c6cd9406", + "Description": "FMManagedWebACLV2-FMS-TEST-1656966584517" + }, + "ResponseMetadata": { + "RetryAttempts": 0, + "HTTPStatusCode": 200, + "RequestId": "0631b12c-a9c9-11e7-b1a6-170ff8aa22cc", + "HTTPHeaders": { + "x-amzn-requestid": "0631b12c-a9c9-11e7-b1a6-170ff8aa22cc", + "date": "Thu, 05 Oct 2017 12:30:51 GMT", + "content-length": "141", + "content-type": "application/x-amz-json-1.1" + } + } + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_distribution_wafv2_regex/wafv2.ListWebACLs_1.json b/tests/data/placebo/test_distribution_wafv2_regex/wafv2.ListWebACLs_1.json new file mode 100644 index 00000000000..18c3532f5ed --- /dev/null +++ b/tests/data/placebo/test_distribution_wafv2_regex/wafv2.ListWebACLs_1.json @@ -0,0 +1,24 @@ +{ + "status_code": 200, + "data": { + "NextMarker": "1ebe0b46-0fd2-4e07-a74c-27bf25adc0bf", + "ResponseMetadata": { + "RetryAttempts": 0, + "HTTPStatusCode": 200, + "RequestId": "05ff3012-a9c9-11e7-8af9-c510054683ae", + "HTTPHeaders": { + "x-amzn-requestid": "05ff3012-a9c9-11e7-8af9-c510054683ae", + "date": "Thu, 05 Oct 2017 12:30:50 GMT", + "content-length": "131", + "content-type": "application/x-amz-json-1.1" + } + }, + "WebACLs": [ + { + "Id": "96494e83-ee49-4505-9f68-9103c6cd9406", + "Name": "FMManagedWebACLV2-FMS-TEST-1656966584517", + "ARN": "arn:aws:wafv2:us-east-1:012345678912:regional/webacl/FMManagedWebACLV2-FMS-TEST-1656966584517/96494e83-ee49-4505-9f68-9103c6cd9406" + } + ] + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/cloudfront.GetDistributionConfig_1.json b/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/cloudfront.GetDistributionConfig_1.json new file mode 100644 index 00000000000..a9285791104 --- /dev/null +++ b/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/cloudfront.GetDistributionConfig_1.json @@ -0,0 +1,113 @@ +{ + "status_code": 200, + "data": { + "ETag": "EIZMGDN1LXJRI", + "DistributionConfig": { + "Comment": "", + "CacheBehaviors": { + "Quantity": 0 + }, + "IsIPV6Enabled": true, + "Logging": { + "Bucket": "", + "Prefix": "", + "Enabled": false, + "IncludeCookies": false + }, + "WebACLId": "arn:aws:wafv2:us-east-1:012345678912:regional/webacl/FMManagedWebACLV2-FMS-TEST-1656966584517/96494e83-ee49-4505-9f68-9103c6cd9406", + "Origins": { + "Items": [ + { + "S3OriginConfig": { + "OriginAccessIdentity": "" + }, + "OriginPath": "", + "CustomHeaders": { + "Quantity": 0 + }, + "Id": "S3-sns-notify-test", + "DomainName": "sns-notify-test.s3.amazonaws.com" + } + ], + "Quantity": 1 + }, + "DefaultRootObject": "", + "PriceClass": "PriceClass_All", + "Enabled": true, + "DefaultCacheBehavior": { + "TrustedSigners": { + "Enabled": false, + "Quantity": 0 + }, + "LambdaFunctionAssociations": { + "Quantity": 0 + }, + "TargetOriginId": "S3-sns-notify-test", + "ViewerProtocolPolicy": "allow-all", + "ForwardedValues": { + "Headers": { + "Quantity": 0 + }, + "Cookies": { + "Forward": "none" + }, + "QueryStringCacheKeys": { + "Quantity": 0 + }, + "QueryString": false + }, + "MaxTTL": 31536000, + "SmoothStreaming": false, + "DefaultTTL": 86400, + "AllowedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "CachedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "Quantity": 2 + }, + "Quantity": 2 + }, + "MinTTL": 0, + "Compress": false + }, + "CallerReference": "1499952607732", + "ViewerCertificate": { + "CloudFrontDefaultCertificate": true, + "MinimumProtocolVersion": "TLSv1", + "CertificateSource": "cloudfront" + }, + "CustomErrorResponses": { + "Quantity": 0 + }, + "HttpVersion": "http2", + "Restrictions": { + "GeoRestriction": { + "RestrictionType": "none", + "Quantity": 0 + } + }, + "Aliases": { + "Quantity": 0 + } + }, + "ResponseMetadata": { + "RetryAttempts": 0, + "HTTPStatusCode": 200, + "RequestId": "0755e5c5-a9c9-11e7-82fd-ed12cccaa8d8", + "HTTPHeaders": { + "x-amzn-requestid": "0755e5c5-a9c9-11e7-82fd-ed12cccaa8d8", + "content-length": "2180", + "vary": "Accept-Encoding", + "etag": "EIZMGDN1LXJRI", + "date": "Thu, 05 Oct 2017 12:30:53 GMT", + "content-type": "text/xml" + } + } + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/cloudfront.ListDistributions_1.json b/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/cloudfront.ListDistributions_1.json new file mode 100644 index 00000000000..e5cb49b02ec --- /dev/null +++ b/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/cloudfront.ListDistributions_1.json @@ -0,0 +1,281 @@ +{ + "status_code": 200, + "data": { + "DistributionList": { + "Marker": "", + "Items": [ + { + "Status": "Deployed", + "CacheBehaviors": { + "Quantity": 0 + }, + "Restrictions": { + "GeoRestriction": { + "RestrictionType": "none", + "Quantity": 0 + } + }, + "Origins": { + "Items": [ + { + "S3OriginConfig": { + "OriginAccessIdentity": "" + }, + "OriginPath": "", + "CustomHeaders": { + "Quantity": 0 + }, + "Id": "S3-sns-notify-test", + "DomainName": "sns-notify-test.s3.amazonaws.com" + } + ], + "Quantity": 1 + }, + "DomainName": "d3naej5h8q7gej.cloudfront.net", + "WebACLId": "arn:aws:wafv2:us-east-1:012345678912:regional/webacl/FMManagedWebACLV2-FMS-TEST-1656966584517/96494e83-ee49-4505-9f68-9103c6cd9406", + "PriceClass": "PriceClass_All", + "Enabled": true, + "DefaultCacheBehavior": { + "TrustedSigners": { + "Enabled": false, + "Quantity": 0 + }, + "LambdaFunctionAssociations": { + "Quantity": 0 + }, + "TargetOriginId": "S3-sns-notify-test", + "ViewerProtocolPolicy": "allow-all", + "ForwardedValues": { + "Headers": { + "Quantity": 0 + }, + "Cookies": { + "Forward": "none" + }, + "QueryStringCacheKeys": { + "Quantity": 0 + }, + "QueryString": false + }, + "MaxTTL": 31536000, + "SmoothStreaming": false, + "DefaultTTL": 86400, + "AllowedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "CachedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "Quantity": 2 + }, + "Quantity": 2 + }, + "MinTTL": 0, + "Compress": false + }, + "IsIPV6Enabled": true, + "Comment": "", + "ViewerCertificate": { + "CloudFrontDefaultCertificate": true, + "MinimumProtocolVersion": "TLSv1", + "CertificateSource": "cloudfront" + }, + "CustomErrorResponses": { + "Quantity": 0 + }, + "LastModifiedTime": { + "hour": 13, + "__class__": "datetime", + "month": 7, + "second": 8, + "microsecond": 399000, + "year": 2017, + "day": 13, + "minute": 30 + }, + "HttpVersion": "HTTP2", + "Id": "E53370FUHBNLK", + "ARN": "arn:aws:cloudfront::012345678912:distribution/E53370FUHBNLK", + "Aliases": { + "Quantity": 0 + } + }, + { + "Status": "Deployed", + "CacheBehaviors": { + "Items": [ + { + "TrustedSigners": { + "Enabled": false, + "Quantity": 0 + }, + "LambdaFunctionAssociations": { + "Quantity": 0 + }, + "TargetOriginId": "Custom-google.com", + "ViewerProtocolPolicy": "allow-all", + "ForwardedValues": { + "Headers": { + "Quantity": 0 + }, + "Cookies": { + "Forward": "none" + }, + "QueryStringCacheKeys": { + "Quantity": 0 + }, + "QueryString": false + }, + "MaxTTL": 31536000, + "PathPattern": "sadf", + "SmoothStreaming": false, + "DefaultTTL": 86400, + "AllowedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "CachedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "Quantity": 2 + }, + "Quantity": 2 + }, + "MinTTL": 0, + "Compress": false + } + ], + "Quantity": 1 + }, + "Restrictions": { + "GeoRestriction": { + "RestrictionType": "none", + "Quantity": 0 + } + }, + "Origins": { + "Items": [ + { + "OriginPath": "", + "CustomOriginConfig": { + "OriginSslProtocols": { + "Items": [ + "TLSv1.1", + "TLSv1.2" + ], + "Quantity": 2 + }, + "OriginProtocolPolicy": "http-only", + "OriginReadTimeout": 30, + "HTTPPort": 80, + "HTTPSPort": 443, + "OriginKeepaliveTimeout": 5 + }, + "CustomHeaders": { + "Quantity": 0 + }, + "Id": "Custom-google.com", + "DomainName": "google.com" + } + ], + "Quantity": 1 + }, + "DomainName": "d34vi31c0msjue.cloudfront.net", + "WebACLId": "", + "PriceClass": "PriceClass_All", + "Enabled": true, + "DefaultCacheBehavior": { + "TrustedSigners": { + "Enabled": false, + "Quantity": 0 + }, + "LambdaFunctionAssociations": { + "Quantity": 0 + }, + "TargetOriginId": "Custom-google.com", + "ViewerProtocolPolicy": "https-only", + "ForwardedValues": { + "Headers": { + "Quantity": 0 + }, + "Cookies": { + "Forward": "none" + }, + "QueryStringCacheKeys": { + "Quantity": 0 + }, + "QueryString": false + }, + "MaxTTL": 31536000, + "SmoothStreaming": false, + "DefaultTTL": 86400, + "AllowedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "CachedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "Quantity": 2 + }, + "Quantity": 2 + }, + "MinTTL": 0, + "Compress": false + }, + "IsIPV6Enabled": true, + "Comment": "", + "ViewerCertificate": { + "CloudFrontDefaultCertificate": true, + "MinimumProtocolVersion": "TLSv1", + "CertificateSource": "cloudfront" + }, + "CustomErrorResponses": { + "Quantity": 0 + }, + "LastModifiedTime": { + "hour": 18, + "__class__": "datetime", + "month": 9, + "second": 38, + "microsecond": 66000, + "year": 2017, + "day": 21, + "minute": 13 + }, + "HttpVersion": "HTTP2", + "Id": "EX42KVJ3ATGH", + "ARN": "arn:aws:cloudfront::012345678912:distribution/EX42KVJ3ATGH", + "Aliases": { + "Quantity": 0 + } + } + ], + "IsTruncated": false, + "MaxItems": 100, + "Quantity": 2 + }, + "ResponseMetadata": { + "RetryAttempts": 0, + "HTTPStatusCode": 200, + "RequestId": "05a7e864-a9c9-11e7-b379-c16d51d99c4d", + "HTTPHeaders": { + "x-amzn-requestid": "05a7e864-a9c9-11e7-b379-c16d51d99c4d", + "vary": "Accept-Encoding", + "content-length": "5686", + "content-type": "text/xml", + "date": "Thu, 05 Oct 2017 12:30:50 GMT" + } + } + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/cloudfront.UpdateDistribution_1.json b/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/cloudfront.UpdateDistribution_1.json new file mode 100644 index 00000000000..50ce38791c9 --- /dev/null +++ b/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/cloudfront.UpdateDistribution_1.json @@ -0,0 +1,134 @@ +{ + "status_code": 200, + "data": { + "Distribution": { + "Status": "InProgress", + "DomainName": "d3naej5h8q7gej.cloudfront.net", + "InProgressInvalidationBatches": 0, + "DistributionConfig": { + "Comment": "", + "CacheBehaviors": { + "Quantity": 0 + }, + "IsIPV6Enabled": true, + "Logging": { + "Bucket": "", + "Prefix": "", + "Enabled": false, + "IncludeCookies": false + }, + "WebACLId": "arn:aws:wafv2:us-east-1:012345678912:regional/webacl/FMManagedWebACLV2-FMS-TEST-1656966584517/96494e83-ee49-4505-9f68-9103c6cd9406", + "Origins": { + "Items": [ + { + "S3OriginConfig": { + "OriginAccessIdentity": "" + }, + "OriginPath": "", + "CustomHeaders": { + "Quantity": 0 + }, + "Id": "S3-sns-notify-test", + "DomainName": "sns-notify-test.s3.amazonaws.com" + } + ], + "Quantity": 1 + }, + "DefaultRootObject": "", + "PriceClass": "PriceClass_All", + "Enabled": true, + "DefaultCacheBehavior": { + "TrustedSigners": { + "Enabled": false, + "Quantity": 0 + }, + "LambdaFunctionAssociations": { + "Quantity": 0 + }, + "TargetOriginId": "S3-sns-notify-test", + "ViewerProtocolPolicy": "allow-all", + "ForwardedValues": { + "Headers": { + "Quantity": 0 + }, + "Cookies": { + "Forward": "none" + }, + "QueryStringCacheKeys": { + "Quantity": 0 + }, + "QueryString": false + }, + "MaxTTL": 31536000, + "SmoothStreaming": false, + "DefaultTTL": 86400, + "AllowedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "CachedMethods": { + "Items": [ + "HEAD", + "GET" + ], + "Quantity": 2 + }, + "Quantity": 2 + }, + "MinTTL": 0, + "Compress": false + }, + "CallerReference": "1499952607732", + "ViewerCertificate": { + "CloudFrontDefaultCertificate": true, + "MinimumProtocolVersion": "TLSv1", + "CertificateSource": "cloudfront" + }, + "CustomErrorResponses": { + "Quantity": 0 + }, + "HttpVersion": "http2", + "Restrictions": { + "GeoRestriction": { + "RestrictionType": "none", + "Quantity": 0 + } + }, + "Aliases": { + "Quantity": 0 + } + }, + "ActiveTrustedSigners": { + "Enabled": false, + "Quantity": 0 + }, + "LastModifiedTime": { + "hour": 12, + "__class__": "datetime", + "month": 10, + "second": 53, + "microsecond": 843000, + "year": 2017, + "day": 5, + "minute": 30 + }, + "Id": "E53370FUHBNLK", + "ARN": "arn:aws:cloudfront::012345678912:distribution/E53370FUHBNLK" + }, + "ETag": "E12XBCJWKPGMKF", + "ResponseMetadata": { + "RetryAttempts": 0, + "HTTPStatusCode": 200, + "RequestId": "0772e3a8-a9c9-11e7-82fd-ed12cccaa8d8", + "HTTPHeaders": { + "x-amzn-requestid": "0772e3a8-a9c9-11e7-82fd-ed12cccaa8d8", + "content-length": "2634", + "vary": "Accept-Encoding", + "etag": "E12XBCJWKPGMKF", + "date": "Thu, 05 Oct 2017 12:30:53 GMT", + "content-type": "text/xml" + } + } + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/tagging.GetResources_1.json b/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/tagging.GetResources_1.json new file mode 100644 index 00000000000..0388c0b6b72 --- /dev/null +++ b/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/tagging.GetResources_1.json @@ -0,0 +1,18 @@ +{ + "status_code": 200, + "data": { + "PaginationToken": "", + "ResourceTagMappingList": [], + "ResponseMetadata": { + "RetryAttempts": 0, + "HTTPStatusCode": 200, + "RequestId": "05d75c18-a9c9-11e7-a028-2f7bd19c01f1", + "HTTPHeaders": { + "x-amzn-requestid": "05d75c18-a9c9-11e7-a028-2f7bd19c01f1", + "date": "Thu, 05 Oct 2017 12:30:50 GMT", + "content-length": "50", + "content-type": "application/x-amz-json-1.1" + } + } + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/tagging.GetResources_2.json b/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/tagging.GetResources_2.json new file mode 100644 index 00000000000..b0588275990 --- /dev/null +++ b/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/tagging.GetResources_2.json @@ -0,0 +1,18 @@ +{ + "status_code": 200, + "data": { + "PaginationToken": "", + "ResourceTagMappingList": [], + "ResponseMetadata": { + "RetryAttempts": 0, + "HTTPStatusCode": 200, + "RequestId": "08a6d06e-a9c9-11e7-bbe7-91ba2b470183", + "HTTPHeaders": { + "x-amzn-requestid": "08a6d06e-a9c9-11e7-bbe7-91ba2b470183", + "date": "Thu, 05 Oct 2017 12:30:55 GMT", + "content-length": "50", + "content-type": "application/x-amz-json-1.1" + } + } + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/wafv2.GetWebACL_1.json b/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/wafv2.GetWebACL_1.json new file mode 100644 index 00000000000..2ea5437b62b --- /dev/null +++ b/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/wafv2.GetWebACL_1.json @@ -0,0 +1,27 @@ +{ + "status_code": 200, + "data": { + "WebACL": { + "DefaultAction": { + "Type": "BLOCK" + }, + "Rules": [], + "MetricName": "test2", + "Id": "96494e83-ee49-4505-9f68-9103c6cd9406", + "Name": "FMManagedWebACLV2-FMS-TEST-1656966584517", + "ARN": "arn:aws:wafv2:us-east-1:012345678912:regional/webacl/FMManagedWebACLV2-FMS-TEST-1656966584517/96494e83-ee49-4505-9f68-9103c6cd9406", + "Description": "FMManagedWebACLV2-FMS-TEST-1656966584517" + }, + "ResponseMetadata": { + "RetryAttempts": 0, + "HTTPStatusCode": 200, + "RequestId": "0631b12c-a9c9-11e7-b1a6-170ff8aa22cc", + "HTTPHeaders": { + "x-amzn-requestid": "0631b12c-a9c9-11e7-b1a6-170ff8aa22cc", + "date": "Thu, 05 Oct 2017 12:30:51 GMT", + "content-length": "141", + "content-type": "application/x-amz-json-1.1" + } + } + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/wafv2.ListWebACLs_1.json b/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/wafv2.ListWebACLs_1.json new file mode 100644 index 00000000000..6c19ace60a9 --- /dev/null +++ b/tests/data/placebo/test_distribution_wafv2_regex_multiple_webacl_match/wafv2.ListWebACLs_1.json @@ -0,0 +1,29 @@ +{ + "status_code": 200, + "data": { + "NextMarker": "1ebe0b46-0fd2-4e07-a74c-27bf25adc0bf", + "ResponseMetadata": { + "RetryAttempts": 0, + "HTTPStatusCode": 200, + "RequestId": "05ff3012-a9c9-11e7-8af9-c510054683ae", + "HTTPHeaders": { + "x-amzn-requestid": "05ff3012-a9c9-11e7-8af9-c510054683ae", + "date": "Thu, 05 Oct 2017 12:30:50 GMT", + "content-length": "131", + "content-type": "application/x-amz-json-1.1" + } + }, + "WebACLs": [ + { + "Id": "96494e83-ee49-4505-9f68-9103c6cd9406", + "Name": "FMManagedWebACLV2-FMS-TEST-1656966584517", + "ARN": "arn:aws:wafv2:us-east-1:012345678912:regional/webacl/FMManagedWebACLV2-FMS-TEST-1656966584517/96494e83-ee49-4505-9f68-9103c6cd9406" + }, + { + "Id": "3c5f3db9-04c1-47f4-a6ab-23b70a3a8509", + "Name": "FMManagedWebACLV2-FMS-TEST2-1656966576062", + "ARN": "arn:aws:wafv2:us-east-1:012345678912:regional/webacl/FMManagedWebACLV2-FMS-TEST2-1656966576062/3c5f3db9-04c1-47f4-a6ab-23b70a3a8509" + } + ] + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_elasticsearch_source_ip/es.DescribeElasticsearchDomain_1.json b/tests/data/placebo/test_elasticsearch_source_ip/es.DescribeElasticsearchDomain_1.json new file mode 100644 index 00000000000..2098c347c2f --- /dev/null +++ b/tests/data/placebo/test_elasticsearch_source_ip/es.DescribeElasticsearchDomain_1.json @@ -0,0 +1,84 @@ +{ + "status_code": 200, + "data": { + "ResponseMetadata": {}, + "DomainStatus": { + "DomainId": "644160558196/ddaotest", + "DomainName": "ddaotest", + "ARN": "arn:aws:es:us-east-1:644160558196:domain/ddaotest", + "Created": true, + "Deleted": false, + "Endpoint": "search-ddaotest-e34rjob4numse2xbbkfng3mzs4.us-east-1.es.amazonaws.com", + "Processing": true, + "UpgradeProcessing": false, + "ElasticsearchVersion": "OpenSearch_1.3", + "ElasticsearchClusterConfig": { + "InstanceType": "t3.small.elasticsearch", + "InstanceCount": 1, + "DedicatedMasterEnabled": false, + "ZoneAwarenessEnabled": false, + "WarmEnabled": false, + "ColdStorageOptions": { + "Enabled": false + } + }, + "EBSOptions": { + "EBSEnabled": true, + "VolumeType": "gp3", + "VolumeSize": 10, + "Iops": 3000, + "Throughput": 125 + }, + "AccessPolicies": "{\"Version\":\"2012-10-17\",\"Statement\":[{\"Effect\":\"Deny\",\"Principal\":{\"AWS\":\"*\"},\"Action\":\"es:*\",\"Resource\":\"arn:aws:es:us-east-1:644160558196:domain/ddaotest/*\"},{\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"*\"},\"Action\":\"es:*\",\"Resource\":\"arn:aws:es:us-east-1:644160558196:domain/ddaotest/*\",\"Condition\":{\"IpAddress\":{\"aws:SourceIp\":\"103.15.250.2\"}}}]}", + "SnapshotOptions": {}, + "CognitoOptions": { + "Enabled": false + }, + "EncryptionAtRestOptions": { + "Enabled": true, + "KmsKeyId": "arn:aws:kms:us-east-1:644160558196:key/59f9f646-4f41-40f3-9637-a0537a22a67c" + }, + "NodeToNodeEncryptionOptions": { + "Enabled": true + }, + "AdvancedOptions": { + "indices.fielddata.cache.size": "20", + "indices.query.bool.max_clause_count": "1024", + "override_main_response_version": "false", + "rest.action.multi.allow_explicit_index": "true" + }, + "ServiceSoftwareOptions": { + "CurrentVersion": "R20220323-P6", + "NewVersion": "", + "UpdateAvailable": false, + "Cancellable": false, + "UpdateStatus": "COMPLETED", + "Description": "There is no software update available for this domain.", + "AutomatedUpdateDate": { + "__class__": "datetime", + "year": 1969, + "month": 12, + "day": 31, + "hour": 16, + "minute": 0, + "second": 0, + "microsecond": 0 + }, + "OptionalDeployment": true + }, + "DomainEndpointOptions": { + "EnforceHTTPS": true, + "TLSSecurityPolicy": "Policy-Min-TLS-1-0-2019-07", + "CustomEndpointEnabled": false + }, + "AdvancedSecurityOptions": { + "Enabled": true, + "InternalUserDatabaseEnabled": true, + "AnonymousAuthEnabled": false + }, + "AutoTuneOptions": { + "State": "ENABLE_IN_PROGRESS" + } + } + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_elasticsearch_source_ip/es.DescribeElasticsearchDomains_1.json b/tests/data/placebo/test_elasticsearch_source_ip/es.DescribeElasticsearchDomains_1.json new file mode 100644 index 00000000000..fb33f6a6795 --- /dev/null +++ b/tests/data/placebo/test_elasticsearch_source_ip/es.DescribeElasticsearchDomains_1.json @@ -0,0 +1,164 @@ +{ + "status_code": 200, + "data": { + "ResponseMetadata": {}, + "DomainStatusList": [ + { + "DomainId": "644160558196/ddaotest2", + "DomainName": "ddaotest2", + "ARN": "arn:aws:es:us-east-1:644160558196:domain/ddaotest2", + "Created": true, + "Deleted": false, + "Endpoint": "search-ddaotest2-lu2dt65rj332cs6tlihhmmgvcm.us-east-1.es.amazonaws.com", + "Processing": false, + "UpgradeProcessing": false, + "ElasticsearchVersion": "OpenSearch_1.3", + "ElasticsearchClusterConfig": { + "InstanceType": "t3.small.elasticsearch", + "InstanceCount": 1, + "DedicatedMasterEnabled": false, + "ZoneAwarenessEnabled": false, + "WarmEnabled": false, + "ColdStorageOptions": { + "Enabled": false + } + }, + "EBSOptions": { + "EBSEnabled": true, + "VolumeType": "gp3", + "VolumeSize": 10, + "Iops": 3000, + "Throughput": 125 + }, + "AccessPolicies": "{\"Version\":\"2012-10-17\",\"Statement\":[{\"Effect\":\"Deny\",\"Principal\":{\"AWS\":\"*\"},\"Action\":\"es:*\",\"Resource\":\"arn:aws:es:us-east-1:644160558196:domain/ddaotest2/*\"},{\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"*\"},\"Action\":\"es:*\",\"Resource\":\"arn:aws:es:us-east-1:644160558196:domain/ddaotest2/*\",\"Condition\":{\"IpAddress\":{\"aws:SourceIp\":\"103.15.250.2\"}}}]}", + "SnapshotOptions": {}, + "CognitoOptions": { + "Enabled": false + }, + "EncryptionAtRestOptions": { + "Enabled": true, + "KmsKeyId": "arn:aws:kms:us-east-1:644160558196:key/59f9f646-4f41-40f3-9637-a0537a22a67c" + }, + "NodeToNodeEncryptionOptions": { + "Enabled": true + }, + "AdvancedOptions": { + "indices.fielddata.cache.size": "20", + "indices.query.bool.max_clause_count": "1024", + "override_main_response_version": "false", + "rest.action.multi.allow_explicit_index": "true" + }, + "ServiceSoftwareOptions": { + "CurrentVersion": "R20220323-P6", + "NewVersion": "", + "UpdateAvailable": false, + "Cancellable": false, + "UpdateStatus": "COMPLETED", + "Description": "There is no software update available for this domain.", + "AutomatedUpdateDate": { + "__class__": "datetime", + "year": 1969, + "month": 12, + "day": 31, + "hour": 16, + "minute": 0, + "second": 0, + "microsecond": 0 + }, + "OptionalDeployment": true + }, + "DomainEndpointOptions": { + "EnforceHTTPS": true, + "TLSSecurityPolicy": "Policy-Min-TLS-1-0-2019-07", + "CustomEndpointEnabled": false + }, + "AdvancedSecurityOptions": { + "Enabled": true, + "InternalUserDatabaseEnabled": true, + "AnonymousAuthEnabled": false + }, + "AutoTuneOptions": { + "State": "ENABLE_IN_PROGRESS" + } + }, + { + "DomainId": "644160558196/ddaotest", + "DomainName": "ddaotest", + "ARN": "arn:aws:es:us-east-1:644160558196:domain/ddaotest", + "Created": true, + "Deleted": false, + "Endpoint": "search-ddaotest-e34rjob4numse2xbbkfng3mzs4.us-east-1.es.amazonaws.com", + "Processing": false, + "UpgradeProcessing": false, + "ElasticsearchVersion": "OpenSearch_1.3", + "ElasticsearchClusterConfig": { + "InstanceType": "t3.small.elasticsearch", + "InstanceCount": 1, + "DedicatedMasterEnabled": false, + "ZoneAwarenessEnabled": false, + "WarmEnabled": false, + "ColdStorageOptions": { + "Enabled": false + } + }, + "EBSOptions": { + "EBSEnabled": true, + "VolumeType": "gp3", + "VolumeSize": 10, + "Iops": 3000, + "Throughput": 125 + }, + "AccessPolicies": "{\"Version\":\"2012-10-17\",\"Statement\":[{\"Effect\":\"Deny\",\"Principal\":{\"AWS\":\"*\"},\"Action\":\"es:*\",\"Resource\":\"arn:aws:es:us-east-1:644160558196:domain/ddaotest/*\"},{\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"*\"},\"Action\":\"es:*\",\"Resource\":\"arn:aws:es:us-east-1:644160558196:domain/ddaotest/*\",\"Condition\":{\"IpAddress\":{\"aws:SourceIp\":[\"103.15.250.2\",\"10.0.0.0/24\"]}}}]}", + "SnapshotOptions": {}, + "CognitoOptions": { + "Enabled": false + }, + "EncryptionAtRestOptions": { + "Enabled": true, + "KmsKeyId": "arn:aws:kms:us-east-1:644160558196:key/59f9f646-4f41-40f3-9637-a0537a22a67c" + }, + "NodeToNodeEncryptionOptions": { + "Enabled": true + }, + "AdvancedOptions": { + "indices.fielddata.cache.size": "20", + "indices.query.bool.max_clause_count": "1024", + "override_main_response_version": "false", + "rest.action.multi.allow_explicit_index": "true" + }, + "ServiceSoftwareOptions": { + "CurrentVersion": "R20220323-P6", + "NewVersion": "", + "UpdateAvailable": false, + "Cancellable": false, + "UpdateStatus": "COMPLETED", + "Description": "There is no software update available for this domain.", + "AutomatedUpdateDate": { + "__class__": "datetime", + "year": 1969, + "month": 12, + "day": 31, + "hour": 16, + "minute": 0, + "second": 0, + "microsecond": 0 + }, + "OptionalDeployment": true + }, + "DomainEndpointOptions": { + "EnforceHTTPS": true, + "TLSSecurityPolicy": "Policy-Min-TLS-1-0-2019-07", + "CustomEndpointEnabled": false + }, + "AdvancedSecurityOptions": { + "Enabled": true, + "InternalUserDatabaseEnabled": true, + "AnonymousAuthEnabled": false + }, + "AutoTuneOptions": { + "State": "ENABLE_IN_PROGRESS" + } + } + ] + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_elasticsearch_source_ip/es.ListDomainNames_1.json b/tests/data/placebo/test_elasticsearch_source_ip/es.ListDomainNames_1.json new file mode 100644 index 00000000000..633db4f06f3 --- /dev/null +++ b/tests/data/placebo/test_elasticsearch_source_ip/es.ListDomainNames_1.json @@ -0,0 +1,16 @@ +{ + "status_code": 200, + "data": { + "ResponseMetadata": {}, + "DomainNames": [ + { + "DomainName": "ddaotest2", + "EngineType": "OpenSearch" + }, + { + "DomainName": "ddaotest", + "EngineType": "OpenSearch" + } + ] + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_elasticsearch_source_ip/es.ListTags_1.json b/tests/data/placebo/test_elasticsearch_source_ip/es.ListTags_1.json new file mode 100644 index 00000000000..db3be6e3f6f --- /dev/null +++ b/tests/data/placebo/test_elasticsearch_source_ip/es.ListTags_1.json @@ -0,0 +1,7 @@ +{ + "status_code": 200, + "data": { + "ResponseMetadata": {}, + "TagList": [] + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_elasticsearch_source_ip/es.ListTags_2.json b/tests/data/placebo/test_elasticsearch_source_ip/es.ListTags_2.json new file mode 100644 index 00000000000..db3be6e3f6f --- /dev/null +++ b/tests/data/placebo/test_elasticsearch_source_ip/es.ListTags_2.json @@ -0,0 +1,7 @@ +{ + "status_code": 200, + "data": { + "ResponseMetadata": {}, + "TagList": [] + } +} \ No newline at end of file diff --git a/tests/data/placebo/test_elasticsearch_source_ip/es.UpdateElasticsearchDomainConfig_1.json b/tests/data/placebo/test_elasticsearch_source_ip/es.UpdateElasticsearchDomainConfig_1.json new file mode 100644 index 00000000000..226e550aede --- /dev/null +++ b/tests/data/placebo/test_elasticsearch_source_ip/es.UpdateElasticsearchDomainConfig_1.json @@ -0,0 +1,444 @@ +{ + "status_code": 200, + "data": { + "ResponseMetadata": {}, + "DomainConfig": { + "ElasticsearchVersion": { + "Options": "OpenSearch_1.3", + "Status": { + "CreationDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 17, + "second": 22, + "microsecond": 84000 + }, + "UpdateDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 33, + "second": 0, + "microsecond": 976000 + }, + "UpdateVersion": 7, + "State": "Active", + "PendingDeletion": false + } + }, + "ElasticsearchClusterConfig": { + "Options": { + "InstanceType": "t3.small.elasticsearch", + "InstanceCount": 1, + "DedicatedMasterEnabled": false, + "ZoneAwarenessEnabled": false, + "WarmEnabled": false, + "ColdStorageOptions": { + "Enabled": false + } + }, + "Status": { + "CreationDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 17, + "second": 22, + "microsecond": 84000 + }, + "UpdateDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 33, + "second": 0, + "microsecond": 976000 + }, + "UpdateVersion": 7, + "State": "Active", + "PendingDeletion": false + } + }, + "EBSOptions": { + "Options": { + "EBSEnabled": true, + "VolumeType": "gp3", + "VolumeSize": 10, + "Iops": 3000, + "Throughput": 125 + }, + "Status": { + "CreationDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 17, + "second": 22, + "microsecond": 84000 + }, + "UpdateDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 33, + "second": 0, + "microsecond": 976000 + }, + "UpdateVersion": 7, + "State": "Active", + "PendingDeletion": false + } + }, + "AccessPolicies": { + "Options": "{\"Version\":\"2012-10-17\",\"Statement\":[{\"Effect\":\"Deny\",\"Principal\":{\"AWS\":\"*\"},\"Action\":\"es:*\",\"Resource\":\"arn:aws:es:us-east-1:644160558196:domain/ddaotest/*\"},{\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"*\"},\"Action\":\"es:*\",\"Resource\":\"arn:aws:es:us-east-1:644160558196:domain/ddaotest/*\",\"Condition\":{\"IpAddress\":{\"aws:SourceIp\":\"103.15.250.2\"}}}]}", + "Status": { + "CreationDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 17, + "second": 22, + "microsecond": 84000 + }, + "UpdateDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 14, + "minute": 55, + "second": 22, + "microsecond": 233000 + }, + "UpdateVersion": 20, + "State": "Processing", + "PendingDeletion": false + } + }, + "SnapshotOptions": { + "Options": { + "AutomatedSnapshotStartHour": 0 + }, + "Status": { + "CreationDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 17, + "second": 22, + "microsecond": 84000 + }, + "UpdateDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 33, + "second": 0, + "microsecond": 976000 + }, + "UpdateVersion": 7, + "State": "Active", + "PendingDeletion": false + } + }, + "VPCOptions": { + "Options": {}, + "Status": { + "CreationDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 14, + "minute": 55, + "second": 22, + "microsecond": 329000 + }, + "UpdateDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 14, + "minute": 55, + "second": 22, + "microsecond": 329000 + }, + "UpdateVersion": 20, + "State": "Active", + "PendingDeletion": false + } + }, + "CognitoOptions": { + "Options": { + "Enabled": false + }, + "Status": { + "CreationDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 14, + "minute": 55, + "second": 22, + "microsecond": 329000 + }, + "UpdateDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 14, + "minute": 55, + "second": 22, + "microsecond": 329000 + }, + "UpdateVersion": 20, + "State": "Active", + "PendingDeletion": false + } + }, + "EncryptionAtRestOptions": { + "Options": { + "Enabled": true, + "KmsKeyId": "arn:aws:kms:us-east-1:644160558196:key/59f9f646-4f41-40f3-9637-a0537a22a67c" + }, + "Status": { + "CreationDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 17, + "second": 22, + "microsecond": 84000 + }, + "UpdateDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 33, + "second": 0, + "microsecond": 976000 + }, + "UpdateVersion": 7, + "State": "Active", + "PendingDeletion": false + } + }, + "NodeToNodeEncryptionOptions": { + "Options": { + "Enabled": true + }, + "Status": { + "CreationDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 17, + "second": 22, + "microsecond": 84000 + }, + "UpdateDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 33, + "second": 0, + "microsecond": 976000 + }, + "UpdateVersion": 7, + "State": "Active", + "PendingDeletion": false + } + }, + "AdvancedOptions": { + "Options": { + "indices.fielddata.cache.size": "20", + "indices.query.bool.max_clause_count": "1024", + "override_main_response_version": "false", + "rest.action.multi.allow_explicit_index": "true" + }, + "Status": { + "CreationDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 17, + "second": 22, + "microsecond": 84000 + }, + "UpdateDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 33, + "second": 0, + "microsecond": 976000 + }, + "UpdateVersion": 7, + "State": "Active", + "PendingDeletion": false + } + }, + "LogPublishingOptions": { + "Options": {}, + "Status": { + "CreationDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 14, + "minute": 55, + "second": 22, + "microsecond": 330000 + }, + "UpdateDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 14, + "minute": 55, + "second": 22, + "microsecond": 330000 + }, + "UpdateVersion": 20, + "State": "Active", + "PendingDeletion": false + } + }, + "DomainEndpointOptions": { + "Options": { + "EnforceHTTPS": true, + "TLSSecurityPolicy": "Policy-Min-TLS-1-0-2019-07", + "CustomEndpointEnabled": false + }, + "Status": { + "CreationDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 17, + "second": 22, + "microsecond": 84000 + }, + "UpdateDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 33, + "second": 0, + "microsecond": 976000 + }, + "UpdateVersion": 7, + "State": "Active", + "PendingDeletion": false + } + }, + "AdvancedSecurityOptions": { + "Options": { + "Enabled": true, + "InternalUserDatabaseEnabled": true, + "AnonymousAuthEnabled": false + }, + "Status": { + "CreationDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 17, + "second": 22, + "microsecond": 84000 + }, + "UpdateDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 33, + "second": 0, + "microsecond": 976000 + }, + "UpdateVersion": 7, + "State": "Active", + "PendingDeletion": false + } + }, + "AutoTuneOptions": { + "Options": { + "DesiredState": "ENABLED", + "RollbackOnDisable": "NO_ROLLBACK", + "MaintenanceSchedules": [] + }, + "Status": { + "CreationDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 17, + "second": 22, + "microsecond": 84000 + }, + "UpdateDate": { + "__class__": "datetime", + "year": 2022, + "month": 9, + "day": 30, + "hour": 13, + "minute": 33, + "second": 0, + "microsecond": 976000 + }, + "UpdateVersion": 7, + "State": "ENABLE_IN_PROGRESS", + "PendingDeletion": false + } + }, + "ChangeProgressDetails": { + "ChangeId": "d52279a2-7526-460a-a6cb-118bf183cc75" + } + } + } +} \ No newline at end of file diff --git a/tests/test_appelb.py b/tests/test_appelb.py index 691a1f88595..f917ced8873 100644 --- a/tests/test_appelb.py +++ b/tests/test_appelb.py @@ -526,6 +526,110 @@ def test_appelb_waf_to_wafv2(self): resources = p.run() self.assertEqual(len(resources), 1) + def test_appelb_filter_wafv2_regex(self): + factory = self.replay_flight_data("test_appelb_wafv2_regex") + + p = self.load_policy( + { + "name": "appelb-waf-wafv2", + "resource": "app-elb", + "filters": [ + {"type": "wafv2-enabled", "state": False} + ] + }, + session_factory=factory, + ) + resources = p.run() + self.assertEqual(len(resources), 0) + + p = self.load_policy( + { + "name": "appelb-waf-wafv2", + "resource": "app-elb", + "filters": [ + {"type": "wafv2-enabled", + "web-acl": "FMManagedWebACLV2-FMS-.*", + "state": True} + ] + }, + session_factory=factory, + ) + resources = p.run() + self.assertEqual(len(resources), 1) + + p = self.load_policy( + { + "name": "appelb-waf-wafv2", + "resource": "app-elb", + "filters": [ + {"type": "wafv2-enabled", "web-acl": "testv3", + "state": False} + ] + }, + session_factory=factory, + ) + resources = p.run() + self.assertEqual(len(resources), 1) + + def test_appelb_action_wafv2_not_found(self): + self.assertRaises( + PolicyValidationError, + self.load_policy, + { + "name": "appelb-waf-wafv2", + "resource": "app-elb", + "filters": [ + {"state": False} + ], + "actions": [ + {"type": "set-wafv2", "web-acl": "FMManagedWebACLV2-FMS-T.*"} + ], + }, + ) + + def test_appelb_action_wafv2_regex_multiple_webacl_match(self): + factory = self.replay_flight_data( + "test_appelb_wafv2_regex_multiple_webacl_match") + + p = self.load_policy( + { + "name": "appelb-waf-wafv2", + "resource": "app-elb", + "filters": [ + {"type": "wafv2-enabled", "state": True} + ], + "actions": [ + {"type": "set-wafv2", "web-acl": "FMManagedWebACLV2-FMS-T.*"} + ], + }, + session_factory=factory, + ) + with self.assertRaises(ValueError) as ctx: + p.run() + self.assertTrue('matching to none or multiple webacls' in str( + ctx.exception)) + + def test_appelb_action_wafv2_regex_disassociate_webacl(self): + factory = self.replay_flight_data( + "test_appelb_wafv2_regex") + + p = self.load_policy( + { + "name": "appelb-waf-wafv2", + "resource": "app-elb", + "filters": [ + {"type": "wafv2-enabled", + "web-acl": "FMManagedWebACLV2-FMS-T.*", "state": True} + ], + "actions": [ + {"type": "set-wafv2", "state": False} + ], + }, + session_factory=factory, + ) + response = p.run() + self.assertEqual(response[0]['LoadBalancerName'], 'test') + def test_set_wafv2_active_response(self): factory = self.replay_flight_data("test_appelb_wafv2") policy = self.load_policy( diff --git a/tests/test_cloudfront.py b/tests/test_cloudfront.py index d5d6fdb1762..25a9b1d119a 100644 --- a/tests/test_cloudfront.py +++ b/tests/test_cloudfront.py @@ -105,6 +105,87 @@ def test_set_wafv2_active_response(self): resources = policy.push(event_data("event-cloud-trail-create-distribution.json")) self.assertEqual(len(resources), 1) + def test_set_wafv2_filter_regex(self): + factory = self.replay_flight_data("test_distribution_wafv2_regex") + + policy = self.load_policy( + { + "name": "waf-cloudfront-update-response", + "resource": "distribution", + "mode": {"type": "cloudtrail", "events": [{ + "source": "cloudfront.amazonaws.com", + "ids": "requestParameters.id", + "event": "UpdateDistribution" + }]}, + "filters": [{"type": "wafv2-enabled", "state": True}], + }, + session_factory=factory, + ) + resources = policy.push(event_data("event-cloud-trail-update-distribution.json")) + self.assertEqual(len(resources), 1) + + policy = self.load_policy( + { + "name": "waf-cloudfront-update-response", + "resource": "distribution", + "mode": {"type": "cloudtrail", "events": [{ + "source": "cloudfront.amazonaws.com", + "ids": "requestParameters.id", + "event": "UpdateDistribution" + }]}, + "filters": [{"type": "wafv2-enabled", + "web-acl": "FMManagedWebACLV2-FMS-.*", + "state": True}], + }, + session_factory=factory, + ) + resources = policy.push(event_data("event-cloud-trail-update-distribution.json")) + self.assertEqual(len(resources), 1) + + policy = self.load_policy( + { + "name": "waf-cloudfront-update-response", + "resource": "distribution", + "mode": {"type": "cloudtrail", "events": [{ + "source": "cloudfront.amazonaws.com", + "ids": "requestParameters.id", + "event": "UpdateDistribution" + }]}, + "filters": [{"type": "wafv2-enabled", + "web-acl": "FMManagedWebACLV2-FMS-.*", + "state": True}], + "actions": [{"type": "set-wafv2", "state": True, + "force": True, "web-acl": "FMManagedWebACLV2-FMS-T.*"}], + }, + session_factory=factory, + ) + resources = policy.push(event_data("event-cloud-trail-update-distribution.json")) + self.assertEqual(len(resources), 1) + + def test_set_wafv2_action_regex_multiple_webacl_match(self): + factory = self.replay_flight_data("test_distribution_wafv2_regex_multiple_webacl_match") + + policy = self.load_policy( + { + "name": "waf-cloudfront-update-response", + "resource": "distribution", + "mode": {"type": "cloudtrail", "events": [{ + "source": "cloudfront.amazonaws.com", + "ids": "requestParameters.id", + "event": "UpdateDistribution" + }]}, + "filters": [{"type": "wafv2-enabled", + "web-acl": "testv2", + "state": False}], + "actions": [{"type": "set-wafv2", "state": True, "force": True, + "web-acl": "FMManagedWebACLV2-FMS-T.*"}], + }, + session_factory=factory, + ) + with self.assertRaises(ValueError) as ctx: + policy.push(event_data("event-cloud-trail-update-distribution.json")) + self.assertTrue('matching to none or multiple webacls' in str(ctx)) + def test_set_wafv2_active_response_tag_resource(self): factory = self.replay_flight_data("test_distribution_wafv2") policy = self.load_policy( diff --git a/tests/test_docker.py b/tests/test_docker.py index 53e64575ad8..d834eeae0e0 100644 --- a/tests/test_docker.py +++ b/tests/test_docker.py @@ -153,7 +153,7 @@ def test_image_metadata(image_name): def test_cli_providers_available(): providers = os.environ.get("CUSTODIAN_PROVIDERS", None) if providers is None: - providers = {"aws", "azure", "gcp", "k8s", "openstack"} + providers = {"aws", "azure", "gcp", "k8s", "openstack", "tencentcloud"} elif providers == "": providers = {"aws"} else: diff --git a/tests/test_elasticsearch.py b/tests/test_elasticsearch.py index 738dc96ff36..7eed99747ee 100644 --- a/tests/test_elasticsearch.py +++ b/tests/test_elasticsearch.py @@ -563,6 +563,34 @@ def test_elasticsearch_not_has_statement(self): resources = p.run() self.assertEqual(len(resources), 0) + def test_source_ip(self): + factory = self.replay_flight_data("test_elasticsearch_source_ip") + client = factory().client("es") + p = self.load_policy( + { + "name": "elasticsearch-source-ip", + "resource": "elasticsearch", + "filters": [ + { + "type": "source-ip", + "op": "not-in", + "value_type": "cidr", + "value": ["103.15.250.0/24", "73.240.160.0/21", "106.108.40.0/21"] + } + ], + "actions": [ + "remove-matched-source-ips" + ] + }, + session_factory=factory, + ) + resources = p.run() + self.assertEqual(len(resources), 1) + self.assertEqual(resources[0]['c7n:MatchedSourceIps'], [{'SourceIp': '10.0.0.0/24'}]) + + resp = client.describe_elasticsearch_domain(DomainName=resources[0]['DomainName']) + self.assertNotIn('10.0.0.0/24', resp['DomainStatus']['AccessPolicies']) + class TestReservedInstances(BaseTest): diff --git a/tests/test_s3.py b/tests/test_s3.py index 2667c52dd0a..e2c004f535b 100644 --- a/tests/test_s3.py +++ b/tests/test_s3.py @@ -1040,6 +1040,16 @@ def test_config_normalize_notification(self): }, ) + def test_config_handle_missing_attr(self): + # test for bug of + # https://github.com/cloud-custodian/cloud-custodian/issues/7808 + event = event_data("s3-from-rule-sans-accelerator.json", "config") + p = self.load_policy({"name": "s3cfg", "resource": "s3"}) + source = p.resource_manager.get_source("config") + resource_config = json.loads(event["invokingEvent"])["configurationItem"] + resource = source.load_resource(resource_config) + assert resource['Name'] == 'c7n-fire-logs' + def test_config_normalize_lifecycle_null_predicate(self): event = event_data("s3-lifecycle-null-predicate.json", "config") p = self.load_policy({"name": "s3cfg", "resource": "s3"}) diff --git a/tests/test_servicecatalog.py b/tests/test_servicecatalog.py index 143b4a92cf3..b6022b65c3f 100644 --- a/tests/test_servicecatalog.py +++ b/tests/test_servicecatalog.py @@ -82,3 +82,23 @@ def test_portfolio_cross_account_whitelist(self): session_factory=session_factory) resources = p.run() self.assertEqual(len(resources), 0) + + def test_catalog_product_resource(self): + session_factory = self.replay_flight_data('test_catalog_product_resource') + p = self.load_policy( + { + 'name': 'test-catalog-product', + 'resource': 'catalog-product', + 'filters': [ + { + 'type': 'value', + 'key': 'ProductId', + 'value': 'test-6orqs3iobd7om' + } + ] + }, + session_factory=session_factory + ) + resources = p.run() + self.assertTrue(len(resources), 1) + self.assertTrue(resources[0]['Name'], 'testProduct') diff --git a/tests/test_sqs.py b/tests/test_sqs.py index 9b6cbe3cdb4..486abd5960a 100644 --- a/tests/test_sqs.py +++ b/tests/test_sqs.py @@ -91,6 +91,49 @@ def test_sqs_delete(test, sqs_delete): time.sleep(2) +def test_sqs_set_encryption_options(test): + p = test.load_policy({ + 'name': 'set-encryption-params', + 'resource': 'sqs', + 'actions': [{'type': 'set-encryption'}] + }) + + set_encrypt = p.resource_manager.actions[0] + collected = [] + + def collect_params(client, queue_url, params): + collected.append(params) + set_encrypt.process_queue = collect_params + + set_encrypt.data = {'enabled': False} + set_encrypt.process([{}]) + assert collected.pop() == {'SqsManagedSseEnabled': 'false', + 'KmsMasterKeyId': ''} + + set_encrypt.data = {} + set_encrypt.process([{}]) + assert collected.pop() == {'SqsManagedSseEnabled': 'true', + 'KmsMasterKeyId': ''} + + set_encrypt.data = {'key': 'xyz'} + set_encrypt.process([{}]) + assert collected.pop() == {'SqsManagedSseEnabled': 'false', + 'KmsDataKeyReusePeriodSeconds': '300', + 'KmsMasterKeyId': 'alias/xyz'} + + set_encrypt.data = {'key': '40753d23-0bef-459d-870e-c0963b827b51'} + set_encrypt.process([{}]) + assert collected.pop() == {'SqsManagedSseEnabled': 'false', + 'KmsDataKeyReusePeriodSeconds': '300', + 'KmsMasterKeyId': '40753d23-0bef-459d-870e-c0963b827b51'} + + set_encrypt.data = {'key': 'arn:aws:kms:us-east-1:1122334455:key/fb5bc39f-3cdb-438b-b959-3b812ae71628'} # noqa + set_encrypt.process([{}]) + assert collected.pop() == {'SqsManagedSseEnabled': 'false', + 'KmsDataKeyReusePeriodSeconds': '300', + 'KmsMasterKeyId': 'arn:aws:kms:us-east-1:1122334455:key/fb5bc39f-3cdb-438b-b959-3b812ae71628'} # noqa + + @terraform('sqs_set_encryption') def test_sqs_set_encryption(test, sqs_set_encryption): session_factory = test.replay_flight_data("test_sqs_set_encryption", region='us-west-2') diff --git a/tests/test_varfmt.py b/tests/test_varfmt.py new file mode 100644 index 00000000000..0bb9a92715f --- /dev/null +++ b/tests/test_varfmt.py @@ -0,0 +1,78 @@ +import pytest + +from c7n.varfmt import VarFormat +from c7n.utils import parse_date, format_string_values + + +def test_format_mixed(): + assert VarFormat().format("{x} abc {Y}", x=2, Y='a') == '2 abc a' + + +def test_format_pass_list(): + assert VarFormat().format("{x}", x=[1, 2, 3]) == [1, 2, 3] + + +def test_format_pass_int(): + assert VarFormat().format("{x}", x=2) == 2 + + +def test_format_pass_empty(): + assert VarFormat().format("{x}", x=[]) == [] + assert VarFormat().format("{x}", x=None) is None + assert VarFormat().format("{x}", x={}) == {} + assert VarFormat().format("{x}", x=0) == 0 + + +def test_format_string_values_empty(): + formatter = VarFormat().format + assert format_string_values({'a': '{x}'}, x=None, formatter=formatter) == { + 'a': None + } + assert format_string_values({'a': '{x}'}, x={}, formatter=formatter) == {'a': {}} + assert format_string_values({'a': '{x}'}, x=[], formatter=formatter) == {'a': []} + assert format_string_values({'a': '{x}'}, x=0, formatter=formatter) == {'a': 0} + + +def test_format_manual_to_auto(): + # coverage check for stdlib impl behavior + with pytest.raises(ValueError) as err: + VarFormat().format("{0} {}", 1, 2) + assert str(err.value) == ( + 'cannot switch from manual field specification to automatic field numbering' + ) + + +def test_format_auto_to_manual(): + # coverage check for stdlib impl behavior + with pytest.raises(ValueError) as err: + VarFormat().format('{} {1}', 'a', 'b') + assert str(err.value) == ( + 'cannot switch from manual field specification to automatic field numbering' + ) + + +def test_format_date_fmt(): + d = parse_date("2018-02-02 12:00") + assert VarFormat().format("{:%Y-%m-%d}", d, "2018-02-02") + assert VarFormat().format("{}", d) == d + + +def test_load_policy_var_retain_type(test): + p = test.load_policy( + { + 'name': 'x', + 'resource': 'aws.sqs', + 'filters': [ + {'type': 'value', 'key': 'why', 'op': 'in', 'value': "{my_list}"}, + {'type': 'value', 'key': 'why_not', 'value': "{my_int}"}, + {'key': "{my_date:%Y-%m-%d}"}, + ], + } + ) + + p.expand_variables( + dict(my_list=[1, 2, 3], my_int=22, my_date=parse_date('2022-02-01 12:00')) + ) + test.assertJmes('filters[0].value', p.data, [1, 2, 3]) + test.assertJmes('filters[1].value', p.data, 22) + test.assertJmes('filters[2].key', p.data, "2022-02-01") diff --git a/tools/c7n_awscc/poetry.lock b/tools/c7n_awscc/poetry.lock index 5ad014d1b5f..1c8ac90b02d 100644 --- a/tools/c7n_awscc/poetry.lock +++ b/tools/c7n_awscc/poetry.lock @@ -21,21 +21,21 @@ optional = false python-versions = ">=3.5" [package.extras] -dev = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "furo", "sphinx", "sphinx-notfound-page", "pre-commit", "cloudpickle"] -docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] -tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] -tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "cloudpickle"] +dev = ["cloudpickle", "coverage[toml] (>=5.0.2)", "furo", "hypothesis", "mypy (>=0.900,!=0.940)", "pre-commit", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "sphinx", "sphinx-notfound-page", "zope.interface"] +docs = ["furo", "sphinx", "sphinx-notfound-page", "zope.interface"] +tests = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "zope.interface"] +tests_no_zope = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins"] [[package]] name = "boto3" -version = "1.24.77" +version = "1.24.87" description = "The AWS SDK for Python" category = "dev" optional = false python-versions = ">= 3.7" [package.dependencies] -botocore = ">=1.27.77,<1.28.0" +botocore = ">=1.27.87,<1.28.0" jmespath = ">=0.7.1,<2.0.0" s3transfer = ">=0.6.0,<0.7.0" @@ -44,7 +44,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "botocore" -version = "1.27.77" +version = "1.27.87" description = "Low-level, data-driven core of boto 3." category = "dev" optional = false @@ -111,7 +111,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" [[package]] name = "importlib-metadata" -version = "4.12.0" +version = "4.13.0" description = "Read metadata from Python packages" category = "main" optional = false @@ -122,9 +122,9 @@ typing-extensions = {version = ">=3.6.4", markers = "python_version < \"3.8\""} zipp = ">=0.5" [package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)"] perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.3)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] +testing = ["flake8 (<5)", "flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] [[package]] name = "importlib-resources" @@ -138,8 +138,8 @@ python-versions = ">=3.7" zipp = {version = ">=3.1.0", markers = "python_version < \"3.10\""} [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [[package]] name = "jmespath" @@ -189,7 +189,7 @@ format = ["fqdn", "idna", "isoduration", "jsonpointer (>1.13)", "rfc3339-validat format-nongpl = ["fqdn", "idna", "isoduration", "jsonpointer (>1.13)", "rfc3339-validator", "rfc3986-validator (>0.1.0)", "uri-template", "webcolors (>=1.11)"] [[package]] -name = "pkgutil-resolve-name" +name = "pkgutil_resolve_name" version = "1.3.10" description = "Resolve a name to an object." category = "dev" @@ -216,7 +216,7 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,>=2.7" six = ">=1.5" [[package]] -name = "pyyaml" +name = "PyYAML" version = "6.0" description = "YAML parser and emitter for Python" category = "dev" @@ -273,8 +273,8 @@ optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*, <4" [package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "urllib3-secure-extra", "ipaddress"] +brotli = ["brotli (>=1.0.9)", "brotlicffi (>=0.8.0)", "brotlipy (>=0.6.0)"] +secure = ["certifi", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "ipaddress", "pyOpenSSL (>=0.14)", "urllib3-secure-extra"] socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] [[package]] @@ -286,8 +286,8 @@ optional = false python-versions = ">=3.7" [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "func-timeout", "jaraco.itertools", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["func-timeout", "jaraco.itertools", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [metadata] lock-version = "1.1" @@ -304,12 +304,12 @@ attrs = [ {file = "attrs-22.1.0.tar.gz", hash = "sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6"}, ] boto3 = [ - {file = "boto3-1.24.77-py3-none-any.whl", hash = "sha256:fc16e50263c24631d5fe75464e76f3a1b454b4c0015c864948a61691f9702a6e"}, - {file = "boto3-1.24.77.tar.gz", hash = "sha256:16646de3303779d6dc9c192d8a863095244de81d2e0b94f50692fbde767c6f1b"}, + {file = "boto3-1.24.87-py3-none-any.whl", hash = "sha256:bcc579e801774cb2c7dda87ff985feda1ae7e10591d11ef37526363139138bd4"}, + {file = "boto3-1.24.87.tar.gz", hash = "sha256:3dd7ed74d1d29dd8094a078be86ed61c45de6638fe18856f7a1ff9282b4d929e"}, ] botocore = [ - {file = "botocore-1.27.77-py3-none-any.whl", hash = "sha256:d88509ed291b95525205cc06ca87b54d077aae996827039f5e32375949c5aaf7"}, - {file = "botocore-1.27.77.tar.gz", hash = "sha256:77a43e970d0762080b4b79a7e00ea572ef2ae7a9f578c3c8e7f0a344ee4b4e6d"}, + {file = "botocore-1.27.87-py3-none-any.whl", hash = "sha256:c4cbd22056ace4c7aa99e62e8ae629865ab80cc8bbf7c6d68ccf0f768f0034b6"}, + {file = "botocore-1.27.87.tar.gz", hash = "sha256:216de9751116d0d1cc3901e26d95a5c9a30ecb6973ae6147af1cf504858d845a"}, ] c7n = [] click = [ @@ -325,8 +325,8 @@ docutils = [ {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, ] importlib-metadata = [ - {file = "importlib_metadata-4.12.0-py3-none-any.whl", hash = "sha256:7401a975809ea1fdc658c3aa4f78cc2195a0e019c5cbc4c06122884e9ae80c23"}, - {file = "importlib_metadata-4.12.0.tar.gz", hash = "sha256:637245b8bab2b6502fcbc752cc4b7a6f6243bb02b31c5c26156ad103d3d45670"}, + {file = "importlib_metadata-4.13.0-py3-none-any.whl", hash = "sha256:8a8a81bcf996e74fee46f0d16bd3eaa382a7eb20fd82445c3ad11f4090334116"}, + {file = "importlib_metadata-4.13.0.tar.gz", hash = "sha256:dd0173e8f150d6815e098fd354f6414b0f079af4644ddfe90c71e2fc6174346d"}, ] importlib-resources = [ {file = "importlib_resources-5.9.0-py3-none-any.whl", hash = "sha256:f78a8df21a79bcc30cfd400bdc38f314333de7c0fb619763f6b9dabab8268bb7"}, @@ -348,7 +348,7 @@ jsonschema = [ {file = "jsonschema-4.16.0-py3-none-any.whl", hash = "sha256:9e74b8f9738d6a946d70705dc692b74b5429cd0960d58e79ffecfc43b2221eb9"}, {file = "jsonschema-4.16.0.tar.gz", hash = "sha256:165059f076eff6971bae5b742fc029a7b4ef3f9bcf04c14e4776a7605de14b23"}, ] -pkgutil-resolve-name = [ +pkgutil_resolve_name = [ {file = "pkgutil_resolve_name-1.3.10-py3-none-any.whl", hash = "sha256:ca27cc078d25c5ad71a9de0a7a330146c4e014c2462d9af19c6b828280649c5e"}, {file = "pkgutil_resolve_name-1.3.10.tar.gz", hash = "sha256:357d6c9e6a755653cfd78893817c0853af365dd51ec97f3d358a819373bbd174"}, ] @@ -379,7 +379,7 @@ python-dateutil = [ {file = "python-dateutil-2.8.2.tar.gz", hash = "sha256:0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86"}, {file = "python_dateutil-2.8.2-py2.py3-none-any.whl", hash = "sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9"}, ] -pyyaml = [ +PyYAML = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, @@ -387,6 +387,13 @@ pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782"}, + {file = "PyYAML-6.0-cp311-cp311-win32.whl", hash = "sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7"}, + {file = "PyYAML-6.0-cp311-cp311-win_amd64.whl", hash = "sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf"}, {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, @@ -424,7 +431,6 @@ six = [ ] tabulate = [ {file = "tabulate-0.8.10-py3-none-any.whl", hash = "sha256:0ba055423dbaa164b9e456abe7920c5e8ed33fcc16f6d1b2f2d152c8e1e8b4fc"}, - {file = "tabulate-0.8.10-py3.8.egg", hash = "sha256:436f1c768b424654fce8597290d2764def1eea6a77cfa5c33be00b1bc0f4f63d"}, {file = "tabulate-0.8.10.tar.gz", hash = "sha256:6c57f3f3dd7ac2782770155f3adb2db0b1a269637e42f27599925e64b114f519"}, ] typing-extensions = [ diff --git a/tools/c7n_awscc/requirements.txt b/tools/c7n_awscc/requirements.txt index 1358c5b77c0..662d3f3b04a 100644 --- a/tools/c7n_awscc/requirements.txt +++ b/tools/c7n_awscc/requirements.txt @@ -1,7 +1,7 @@ -click==8.1.3; python_version >= "3.7" -colorama==0.4.5; python_version >= "3.7" and python_full_version < "3.0.0" and platform_system == "Windows" or platform_system == "Windows" and python_version >= "3.7" and python_full_version >= "3.5.0" -importlib-metadata==4.12.0; python_version < "3.8" and python_version >= "3.7" -jsonpatch==1.32; (python_version >= "2.7" and python_full_version < "3.0.0") or (python_full_version >= "3.5.0") -jsonpointer==2.3; python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" -typing-extensions==4.3.0; python_version < "3.8" and python_version >= "3.7" -zipp==3.8.1; python_version < "3.8" and python_version >= "3.7" +click==8.1.3 ; python_version >= "3.7" and python_version < "4.0" +colorama==0.4.5 ; python_version >= "3.7" and python_version < "4.0" and platform_system == "Windows" +importlib-metadata==4.13.0 ; python_version >= "3.7" and python_version < "3.8" +jsonpatch==1.32 ; python_version >= "3.7" and python_version < "4.0" +jsonpointer==2.3 ; python_version >= "3.7" and python_version < "4.0" +typing-extensions==4.3.0 ; python_version >= "3.7" and python_version < "3.8" +zipp==3.8.1 ; python_version >= "3.7" and python_version < "3.8" diff --git a/tools/c7n_awscc/setup.py b/tools/c7n_awscc/setup.py index 02de5c701b1..96232ea83c7 100644 --- a/tools/c7n_awscc/setup.py +++ b/tools/c7n_awscc/setup.py @@ -12,17 +12,17 @@ install_requires = \ ['argcomplete (>=2.0.0,<3.0.0)', 'attrs (>=22.1.0,<23.0.0)', - 'boto3 (>=1.24.77,<2.0.0)', - 'botocore (>=1.27.77,<2.0.0)', + 'boto3 (>=1.24.87,<2.0.0)', + 'botocore (>=1.27.87,<2.0.0)', 'c7n (>=0.9.19,<0.10.0)', 'click>=8.0,<9.0', 'docutils (>=0.17.1,<0.18.0)', - 'importlib-metadata (>=4.12.0,<5.0.0)', + 'importlib-metadata (>=4.13.0,<5.0.0)', 'importlib-resources (>=5.9.0,<6.0.0)', 'jmespath (>=1.0.1,<2.0.0)', 'jsonpatch>=1.32,<2.0', 'jsonschema (>=4.16.0,<5.0.0)', - 'pkgutil-resolve-name (>=1.3.10,<2.0.0)', + 'pkgutil_resolve_name (>=1.3.10,<2.0.0)', 'pyrsistent (>=0.18.1,<0.19.0)', 'python-dateutil (>=2.8.2,<3.0.0)', 'pyyaml (>=6.0,<7.0)', @@ -46,10 +46,13 @@ 'long_description': '\n# Custodian AWS Cloud Control Provider\n\n\n', 'long_description_content_type': 'text/markdown', 'author': 'Cloud Custodian Project', - 'author_email': None, - 'maintainer': None, - 'maintainer_email': None, - 'url': 'https://cloudcustodian.io', + 'author_email': 'cloud-custodian@googlegroups.com', + 'project_urls': { + 'Homepage': 'https://cloudcustodian.io', + 'Documentation': 'https://cloudcustodian.io/docs/', + 'Source': 'https://github.com/cloud-custodian/cloud-custodian', + 'Issue Tracker': 'https://github.com/cloud-custodian/cloud-custodian/issues', + }, 'packages': packages, 'package_data': package_data, 'install_requires': install_requires, diff --git a/tools/c7n_azure/poetry.lock b/tools/c7n_azure/poetry.lock index 36bd0af5a48..5222c5548f8 100644 --- a/tools/c7n_azure/poetry.lock +++ b/tools/c7n_azure/poetry.lock @@ -21,7 +21,7 @@ optional = false python-versions = "*" [[package]] -name = "apscheduler" +name = "APScheduler" version = "3.9.1" description = "In-process task scheduler with Cron-like capabilities" category = "main" @@ -30,6 +30,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, <4" [package.dependencies] pytz = "*" +setuptools = ">=0.7" six = ">=1.4.0" tzlocal = ">=2.0,<3.0.0 || >=4.0.0" @@ -41,7 +42,7 @@ mongodb = ["pymongo (>=3.0)"] redis = ["redis (>=3.0)"] rethinkdb = ["rethinkdb (>=2.4.0)"] sqlalchemy = ["sqlalchemy (>=0.8)"] -testing = ["pytest", "pytest-cov", "pytest-tornado5", "mock", "pytest-asyncio (<0.6)", "pytest-asyncio"] +testing = ["mock", "pytest", "pytest-asyncio", "pytest-asyncio (<0.6)", "pytest-cov", "pytest-tornado5"] tornado = ["tornado (>=4.3)"] twisted = ["twisted"] zookeeper = ["kazoo"] @@ -69,10 +70,10 @@ optional = false python-versions = ">=3.5" [package.extras] -dev = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "furo", "sphinx", "sphinx-notfound-page", "pre-commit", "cloudpickle"] -docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] -tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] -tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "cloudpickle"] +dev = ["cloudpickle", "coverage[toml] (>=5.0.2)", "furo", "hypothesis", "mypy (>=0.900,!=0.940)", "pre-commit", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "sphinx", "sphinx-notfound-page", "zope.interface"] +docs = ["furo", "sphinx", "sphinx-notfound-page", "zope.interface"] +tests = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "zope.interface"] +tests_no_zope = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins"] [[package]] name = "azure-common" @@ -135,14 +136,14 @@ requests = "*" [[package]] name = "azure-functions" -version = "1.11.3" +version = "1.11.2" description = "Azure Functions for Python" category = "main" optional = false python-versions = "*" [package.extras] -dev = ["flake8 (>=4.0.1,<4.1.0)", "mypy", "pytest", "pytest-cov", "requests (>=2.0.0,<3.0.0)", "coverage"] +dev = ["coverage", "flake8 (>=4.0.1,<4.1.0)", "mypy", "pytest", "pytest-cov", "requests (>=2.0.0,<3.0.0)"] [[package]] name = "azure-graphrbac" @@ -858,14 +859,14 @@ tzdata = ["tzdata"] [[package]] name = "boto3" -version = "1.24.77" +version = "1.24.87" description = "The AWS SDK for Python" category = "dev" optional = false python-versions = ">= 3.7" [package.dependencies] -botocore = ">=1.27.77,<1.28.0" +botocore = ">=1.27.87,<1.28.0" jmespath = ">=0.7.1,<2.0.0" s3transfer = ">=0.6.0,<0.7.0" @@ -874,7 +875,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "botocore" -version = "1.27.77" +version = "1.27.87" description = "Low-level, data-driven core of boto 3." category = "dev" optional = false @@ -913,7 +914,7 @@ url = "../.." [[package]] name = "certifi" -version = "2022.9.14" +version = "2022.9.24" description = "Python package for providing Mozilla's CA Bundle." category = "main" optional = false @@ -974,11 +975,11 @@ cffi = ">=1.12" [package.extras] docs = ["sphinx (>=1.6.5,!=1.8.0,!=3.1.0,!=3.1.1)", "sphinx-rtd-theme"] -docstest = ["pyenchant (>=1.6.11)", "twine (>=1.12.0)", "sphinxcontrib-spelling (>=4.0.1)"] +docstest = ["pyenchant (>=1.6.11)", "sphinxcontrib-spelling (>=4.0.1)", "twine (>=1.12.0)"] pep8test = ["black", "flake8", "flake8-import-order", "pep8-naming"] sdist = ["setuptools-rust (>=0.11.4)"] ssh = ["bcrypt (>=3.1.5)"] -test = ["pytest (>=6.2.0)", "pytest-benchmark", "pytest-cov", "pytest-subtests", "pytest-xdist", "pretend", "iso8601", "pytz", "hypothesis (>=1.11.4,!=3.79.2)"] +test = ["hypothesis (>=1.11.4,!=3.79.2)", "iso8601", "pretend", "pytest (>=6.2.0)", "pytest-benchmark", "pytest-cov", "pytest-subtests", "pytest-xdist", "pytz"] [[package]] name = "distlib" @@ -1006,7 +1007,7 @@ python-versions = ">=3.5" [[package]] name = "importlib-metadata" -version = "4.12.0" +version = "4.13.0" description = "Read metadata from Python packages" category = "main" optional = false @@ -1017,9 +1018,9 @@ typing-extensions = {version = ">=3.6.4", markers = "python_version < \"3.8\""} zipp = ">=0.5" [package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)"] perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.3)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] +testing = ["flake8 (<5)", "flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] [[package]] name = "importlib-resources" @@ -1033,8 +1034,8 @@ python-versions = ">=3.7" zipp = {version = ">=3.1.0", markers = "python_version < \"3.10\""} [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [[package]] name = "isodate" @@ -1099,8 +1100,8 @@ python-versions = "*" [package.dependencies] msal = ">=0.4.1,<2.0.0" portalocker = [ - {version = ">=1.0,<3", markers = "python_version >= \"3.5\" and platform_system != \"Windows\""}, {version = ">=1.6,<3", markers = "python_version >= \"3.5\" and platform_system == \"Windows\""}, + {version = ">=1.0,<3", markers = "python_version >= \"3.5\" and platform_system != \"Windows\""}, ] [[package]] @@ -1175,7 +1176,7 @@ python-versions = "*" dev = ["jinja2"] [[package]] -name = "pkgutil-resolve-name" +name = "pkgutil_resolve_name" version = "1.3.10" description = "Resolve a name to an object." category = "dev" @@ -1196,7 +1197,7 @@ pywin32 = {version = ">=226", markers = "platform_system == \"Windows\""} [package.extras] docs = ["sphinx (>=1.7.1)"] redis = ["redis"] -tests = ["pytest (>=5.4.1)", "pytest-cov (>=2.8.1)", "pytest-timeout (>=2.1.0)", "sphinx (>=3.0.3)", "pytest-mypy (>=0.8.0)", "redis"] +tests = ["pytest (>=5.4.1)", "pytest-cov (>=2.8.1)", "pytest-mypy (>=0.8.0)", "pytest-timeout (>=2.1.0)", "redis", "sphinx (>=3.0.3)"] [[package]] name = "pycparser" @@ -1207,7 +1208,7 @@ optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] -name = "pyjwt" +name = "PyJWT" version = "2.5.0" description = "JSON Web Token implementation in Python" category = "main" @@ -1220,9 +1221,9 @@ types-cryptography = {version = ">=3.3.21", optional = true, markers = "extra == [package.extras] crypto = ["cryptography (>=3.3.1)", "types-cryptography (>=3.3.21)"] -dev = ["sphinx (>=4.5.0,<5.0.0)", "sphinx-rtd-theme", "zope.interface", "cryptography (>=3.3.1)", "types-cryptography (>=3.3.21)", "pytest (>=6.0.0,<7.0.0)", "coverage[toml] (==5.0.4)", "pre-commit"] +dev = ["coverage[toml] (==5.0.4)", "cryptography (>=3.3.1)", "pre-commit", "pytest (>=6.0.0,<7.0.0)", "sphinx (>=4.5.0,<5.0.0)", "sphinx-rtd-theme", "types-cryptography (>=3.3.21)", "zope.interface"] docs = ["sphinx (>=4.5.0,<5.0.0)", "sphinx-rtd-theme", "zope.interface"] -tests = ["pytest (>=6.0.0,<7.0.0)", "coverage[toml] (==5.0.4)"] +tests = ["coverage[toml] (==5.0.4)", "pytest (>=6.0.0,<7.0.0)"] [[package]] name = "pyrsistent" @@ -1245,7 +1246,7 @@ six = ">=1.5" [[package]] name = "pytz" -version = "2022.2.1" +version = "2022.4" description = "World timezone definitions, modern and historical" category = "main" optional = false @@ -1272,7 +1273,7 @@ optional = false python-versions = "*" [[package]] -name = "pyyaml" +name = "PyYAML" version = "6.0" description = "YAML parser and emitter for Python" category = "dev" @@ -1326,6 +1327,19 @@ botocore = ">=1.12.36,<2.0a.0" [package.extras] crt = ["botocore[crt] (>=1.20.29,<2.0a.0)"] +[[package]] +name = "setuptools" +version = "65.4.1" +description = "Easily download, build, install, upgrade, and uninstall Python packages" +category = "main" +optional = false +python-versions = ">=3.7" + +[package.extras] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "pygments-github-lexers (==0.0.5)", "rst.linker (>=1.9)", "sphinx (>=3.5)", "sphinx-favicon", "sphinx-hoverxref (<2)", "sphinx-inline-tabs", "sphinx-notfound-page (==0.8.3)", "sphinx-reredirects", "sphinxcontrib-towncrier"] +testing = ["build[virtualenv]", "filelock (>=3.4.0)", "flake8 (<5)", "flake8-2020", "ini2toml[lite] (>=0.9)", "jaraco.envs (>=2.2)", "jaraco.path (>=3.2.0)", "mock", "pip (>=19.1)", "pip-run (>=8.8)", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf", "pytest-xdist", "tomli-w (>=1.0.0)", "virtualenv (>=13.0.0)", "wheel"] +testing-integration = ["build[virtualenv]", "filelock (>=3.4.0)", "jaraco.envs (>=2.2)", "jaraco.path (>=3.2.0)", "pytest", "pytest-enabler", "pytest-xdist", "tomli", "virtualenv (>=13.0.0)", "wheel"] + [[package]] name = "six" version = "1.16.0" @@ -1363,7 +1377,7 @@ python-versions = ">=3.7" [[package]] name = "tzdata" -version = "2022.2" +version = "2022.4" description = "Provider of IANA time zone data" category = "main" optional = false @@ -1384,7 +1398,7 @@ tzdata = {version = "*", markers = "platform_system == \"Windows\""} [package.extras] devenv = ["black", "pyroma", "pytest-cov", "zest.releaser"] -test = ["pytest-mock (>=3.3)", "pytest (>=4.3)"] +test = ["pytest (>=4.3)", "pytest-mock (>=3.3)"] [[package]] name = "urllib3" @@ -1395,8 +1409,8 @@ optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*, <4" [package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "urllib3-secure-extra", "ipaddress"] +brotli = ["brotli (>=1.0.9)", "brotlicffi (>=0.8.0)", "brotlipy (>=0.6.0)"] +secure = ["certifi", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "ipaddress", "pyOpenSSL (>=0.14)", "urllib3-secure-extra"] socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] [[package]] @@ -1454,8 +1468,8 @@ optional = false python-versions = ">=3.7" [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "func-timeout", "jaraco.itertools", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["func-timeout", "jaraco.itertools", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [metadata] lock-version = "1.1" @@ -1471,7 +1485,7 @@ applicationinsights = [ {file = "applicationinsights-0.11.10-py2.py3-none-any.whl", hash = "sha256:e89a890db1c6906b6a7d0bcfd617dac83974773c64573147c8d6654f9cf2a6ea"}, {file = "applicationinsights-0.11.10.tar.gz", hash = "sha256:0b761f3ef0680acf4731906dfc1807faa6f2a57168ae74592db0084a6099f7b3"}, ] -apscheduler = [ +APScheduler = [ {file = "APScheduler-3.9.1-py2.py3-none-any.whl", hash = "sha256:ddc25a0ddd899de44d7f451f4375fb971887e65af51e41e5dcf681f59b8b2c9a"}, {file = "APScheduler-3.9.1.tar.gz", hash = "sha256:65e6574b6395498d371d045f2a8a7e4f7d50c6ad21ef7313d15b1c7cf20df1e3"}, ] @@ -1504,8 +1518,8 @@ azure-cosmosdb-table = [ {file = "azure_cosmosdb_table-1.0.6-py2.py3-none-any.whl", hash = "sha256:ee525233d6c8c016526593bf28f8a374275cfe204a00c41134b83a1736f7b5f7"}, ] azure-functions = [ - {file = "azure-functions-1.11.3.tar.gz", hash = "sha256:c389d58ecf85c957d6023ba43966f9f1e57150492ade1bc48ca1d15850f2d00c"}, - {file = "azure_functions-1.11.3-py3-none-any.whl", hash = "sha256:48d7dfed7cc9fcaa834e69cfe98368950ae8354a62162d104329ad7e3c185808"}, + {file = "azure-functions-1.11.2.tar.gz", hash = "sha256:a4bca1b650810c1063140fef8d9d51fb1837f869e48fbf8869ff9eee642c42f4"}, + {file = "azure_functions-1.11.2-py3-none-any.whl", hash = "sha256:db5730aad1b3eb6716790d593935abb5b49d2690bb446f2b4b83d91f3195f2f3"}, ] azure-graphrbac = [ {file = "azure-graphrbac-0.61.1.zip", hash = "sha256:53e98ae2ca7c19b349e9e9bb1b6a824aeae8dcfcbe17190d20fe69c0f185b2e2"}, @@ -1743,17 +1757,17 @@ azure-storage-queue = [ {file = "backports.zoneinfo-0.2.1.tar.gz", hash = "sha256:fadbfe37f74051d024037f223b8e001611eac868b5c5b06144ef4d8b799862f2"}, ] boto3 = [ - {file = "boto3-1.24.77-py3-none-any.whl", hash = "sha256:fc16e50263c24631d5fe75464e76f3a1b454b4c0015c864948a61691f9702a6e"}, - {file = "boto3-1.24.77.tar.gz", hash = "sha256:16646de3303779d6dc9c192d8a863095244de81d2e0b94f50692fbde767c6f1b"}, + {file = "boto3-1.24.87-py3-none-any.whl", hash = "sha256:bcc579e801774cb2c7dda87ff985feda1ae7e10591d11ef37526363139138bd4"}, + {file = "boto3-1.24.87.tar.gz", hash = "sha256:3dd7ed74d1d29dd8094a078be86ed61c45de6638fe18856f7a1ff9282b4d929e"}, ] botocore = [ - {file = "botocore-1.27.77-py3-none-any.whl", hash = "sha256:d88509ed291b95525205cc06ca87b54d077aae996827039f5e32375949c5aaf7"}, - {file = "botocore-1.27.77.tar.gz", hash = "sha256:77a43e970d0762080b4b79a7e00ea572ef2ae7a9f578c3c8e7f0a344ee4b4e6d"}, + {file = "botocore-1.27.87-py3-none-any.whl", hash = "sha256:c4cbd22056ace4c7aa99e62e8ae629865ab80cc8bbf7c6d68ccf0f768f0034b6"}, + {file = "botocore-1.27.87.tar.gz", hash = "sha256:216de9751116d0d1cc3901e26d95a5c9a30ecb6973ae6147af1cf504858d845a"}, ] c7n = [] certifi = [ - {file = "certifi-2022.9.14-py3-none-any.whl", hash = "sha256:e232343de1ab72c2aa521b625c80f699e356830fd0e2c620b465b304b17b0516"}, - {file = "certifi-2022.9.14.tar.gz", hash = "sha256:36973885b9542e6bd01dea287b2b4b3b21236307c56324fcc3f1160f2d655ed5"}, + {file = "certifi-2022.9.24-py3-none-any.whl", hash = "sha256:90c1a32f1d68f940488354e36370f6cca89f0f106db09518524c88d6ed83f382"}, + {file = "certifi-2022.9.24.tar.gz", hash = "sha256:0d9c601124e5a6ba9712dbc60d9c53c21e34f5f641fe83002317394311bdce14"}, ] cffi = [ {file = "cffi-1.15.1-cp27-cp27m-macosx_10_9_x86_64.whl", hash = "sha256:a66d3508133af6e8548451b25058d5812812ec3798c886bf38ed24a98216fab2"}, @@ -1874,8 +1888,8 @@ idna = [ {file = "idna-3.4.tar.gz", hash = "sha256:814f528e8dead7d329833b91c5faa87d60bf71824cd12a7530b5526063d02cb4"}, ] importlib-metadata = [ - {file = "importlib_metadata-4.12.0-py3-none-any.whl", hash = "sha256:7401a975809ea1fdc658c3aa4f78cc2195a0e019c5cbc4c06122884e9ae80c23"}, - {file = "importlib_metadata-4.12.0.tar.gz", hash = "sha256:637245b8bab2b6502fcbc752cc4b7a6f6243bb02b31c5c26156ad103d3d45670"}, + {file = "importlib_metadata-4.13.0-py3-none-any.whl", hash = "sha256:8a8a81bcf996e74fee46f0d16bd3eaa382a7eb20fd82445c3ad11f4090334116"}, + {file = "importlib_metadata-4.13.0.tar.gz", hash = "sha256:dd0173e8f150d6815e098fd354f6414b0f079af4644ddfe90c71e2fc6174346d"}, ] importlib-resources = [ {file = "importlib_resources-5.9.0-py3-none-any.whl", hash = "sha256:f78a8df21a79bcc30cfd400bdc38f314333de7c0fb619763f6b9dabab8268bb7"}, @@ -1982,7 +1996,7 @@ parameterized = [ {file = "parameterized-0.7.5-py2.py3-none-any.whl", hash = "sha256:b36f709fcfd9e8c144c1374b16a40fc0b5984efe93e41d53e6d228ae2a1540c5"}, {file = "parameterized-0.7.5.tar.gz", hash = "sha256:b5e6af67b9e49485e30125b1c8f031ffa81a265ca08bfa73f31551bf03cf68c4"}, ] -pkgutil-resolve-name = [ +pkgutil_resolve_name = [ {file = "pkgutil_resolve_name-1.3.10-py3-none-any.whl", hash = "sha256:ca27cc078d25c5ad71a9de0a7a330146c4e014c2462d9af19c6b828280649c5e"}, {file = "pkgutil_resolve_name-1.3.10.tar.gz", hash = "sha256:357d6c9e6a755653cfd78893817c0853af365dd51ec97f3d358a819373bbd174"}, ] @@ -1994,7 +2008,7 @@ pycparser = [ {file = "pycparser-2.21-py2.py3-none-any.whl", hash = "sha256:8ee45429555515e1f6b185e78100aea234072576aa43ab53aefcae078162fca9"}, {file = "pycparser-2.21.tar.gz", hash = "sha256:e644fdec12f7872f86c58ff790da456218b10f863970249516d60a5eaca77206"}, ] -pyjwt = [ +PyJWT = [ {file = "PyJWT-2.5.0-py3-none-any.whl", hash = "sha256:8d82e7087868e94dd8d7d418e5088ce64f7daab4b36db654cbaedb46f9d1ca80"}, {file = "PyJWT-2.5.0.tar.gz", hash = "sha256:e77ab89480905d86998442ac5788f35333fa85f65047a534adc38edf3c88fc3b"}, ] @@ -2026,8 +2040,8 @@ python-dateutil = [ {file = "python_dateutil-2.8.2-py2.py3-none-any.whl", hash = "sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9"}, ] pytz = [ - {file = "pytz-2022.2.1-py2.py3-none-any.whl", hash = "sha256:220f481bdafa09c3955dfbdddb7b57780e9a94f5127e35456a48589b9e0c0197"}, - {file = "pytz-2022.2.1.tar.gz", hash = "sha256:cea221417204f2d1a2aa03ddae3e867921971d0d76f14d87abb4414415bbdcf5"}, + {file = "pytz-2022.4-py2.py3-none-any.whl", hash = "sha256:2c0784747071402c6e99f0bafdb7da0fa22645f06554c7ae06bf6358897e9c91"}, + {file = "pytz-2022.4.tar.gz", hash = "sha256:48ce799d83b6f8aab2020e369b627446696619e79645419610b9facd909b3174"}, ] pytz-deprecation-shim = [ {file = "pytz_deprecation_shim-0.1.0.post0-py2.py3-none-any.whl", hash = "sha256:8314c9692a636c8eb3bda879b9f119e350e93223ae83e70e80c31675a0fdc1a6"}, @@ -2049,7 +2063,7 @@ pywin32 = [ {file = "pywin32-304-cp39-cp39-win32.whl", hash = "sha256:25746d841201fd9f96b648a248f731c1dec851c9a08b8e33da8b56148e4c65cc"}, {file = "pywin32-304-cp39-cp39-win_amd64.whl", hash = "sha256:d24a3382f013b21aa24a5cfbfad5a2cd9926610c0affde3e8ab5b3d7dbcf4ac9"}, ] -pyyaml = [ +PyYAML = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, @@ -2057,6 +2071,13 @@ pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782"}, + {file = "PyYAML-6.0-cp311-cp311-win32.whl", hash = "sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7"}, + {file = "PyYAML-6.0-cp311-cp311-win_amd64.whl", hash = "sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf"}, {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, @@ -2096,13 +2117,16 @@ s3transfer = [ {file = "s3transfer-0.6.0-py3-none-any.whl", hash = "sha256:06176b74f3a15f61f1b4f25a1fc29a4429040b7647133a463da8fa5bd28d5ecd"}, {file = "s3transfer-0.6.0.tar.gz", hash = "sha256:2ed07d3866f523cc561bf4a00fc5535827981b117dd7876f036b0c1aca42c947"}, ] +setuptools = [ + {file = "setuptools-65.4.1-py3-none-any.whl", hash = "sha256:1b6bdc6161661409c5f21508763dc63ab20a9ac2f8ba20029aaaa7fdb9118012"}, + {file = "setuptools-65.4.1.tar.gz", hash = "sha256:3050e338e5871e70c72983072fe34f6032ae1cdeeeb67338199c2f74e083a80e"}, +] six = [ {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] tabulate = [ {file = "tabulate-0.8.10-py3-none-any.whl", hash = "sha256:0ba055423dbaa164b9e456abe7920c5e8ed33fcc16f6d1b2f2d152c8e1e8b4fc"}, - {file = "tabulate-0.8.10-py3.8.egg", hash = "sha256:436f1c768b424654fce8597290d2764def1eea6a77cfa5c33be00b1bc0f4f63d"}, {file = "tabulate-0.8.10.tar.gz", hash = "sha256:6c57f3f3dd7ac2782770155f3adb2db0b1a269637e42f27599925e64b114f519"}, ] types-cryptography = [ @@ -2114,8 +2138,8 @@ typing-extensions = [ {file = "typing_extensions-4.3.0.tar.gz", hash = "sha256:e6d2677a32f47fc7eb2795db1dd15c1f34eff616bcaf2cfb5e997f854fa1c4a6"}, ] tzdata = [ - {file = "tzdata-2022.2-py2.py3-none-any.whl", hash = "sha256:c3119520447d68ef3eb8187a55a4f44fa455f30eb1b4238fa5691ba094f2b05b"}, - {file = "tzdata-2022.2.tar.gz", hash = "sha256:21f4f0d7241572efa7f7a4fdabb052e61b55dc48274e6842697ccdf5253e5451"}, + {file = "tzdata-2022.4-py2.py3-none-any.whl", hash = "sha256:74da81ecf2b3887c94e53fc1d466d4362aaf8b26fc87cda18f22004544694583"}, + {file = "tzdata-2022.4.tar.gz", hash = "sha256:ada9133fbd561e6ec3d1674d3fba50251636e918aa97bd59d63735bef5a513bb"}, ] tzlocal = [ {file = "tzlocal-4.2-py3-none-any.whl", hash = "sha256:89885494684c929d9191c57aa27502afc87a579be5cdd3225c77c463ea043745"}, diff --git a/tools/c7n_azure/requirements.txt b/tools/c7n_azure/requirements.txt index 3e3345de575..9964df70d0e 100644 --- a/tools/c7n_azure/requirements.txt +++ b/tools/c7n_azure/requirements.txt @@ -1,97 +1,99 @@ -adal==1.2.7 -applicationinsights==0.11.10 -apscheduler==3.9.1; (python_version >= "2.7" and python_full_version < "3.0.0") or (python_full_version >= "3.5.0" and python_version < "4") -azure-common==1.1.28; python_version >= "3.6" -azure-core==1.25.1; python_version >= "3.7" -azure-cosmos==3.2.0 -azure-cosmosdb-nspkg==2.0.2 -azure-cosmosdb-table==1.0.6 -azure-functions==1.11.3; python_version >= "3" and python_version < "4" -azure-graphrbac==0.61.1 -azure-identity==1.11.0; python_version >= "3.7" -azure-keyvault-certificates==4.6.0; python_version >= "3.6" -azure-keyvault-keys==4.7.0; python_version >= "3.6" -azure-keyvault-secrets==4.6.0; python_version >= "3.6" -azure-keyvault==4.2.0 -azure-mgmt-advisor==9.0.0 -azure-mgmt-apimanagement==1.0.0 -azure-mgmt-applicationinsights==1.0.0 -azure-mgmt-authorization==1.0.0 -azure-mgmt-batch==15.0.0 -azure-mgmt-cdn==10.0.0 -azure-mgmt-cognitiveservices==11.0.0 -azure-mgmt-compute==19.0.0 -azure-mgmt-containerinstance==7.0.0 -azure-mgmt-containerregistry==8.0.0b1 -azure-mgmt-containerservice==15.1.0 -azure-mgmt-core==1.3.2; python_version >= "3.6" -azure-mgmt-cosmosdb==6.4.0 -azure-mgmt-costmanagement==1.0.0 -azure-mgmt-databricks==1.0.0b1 -azure-mgmt-datafactory==1.1.0 -azure-mgmt-datalake-store==1.0.0 -azure-mgmt-dns==8.0.0b1 -azure-mgmt-eventgrid==8.0.0 -azure-mgmt-eventhub==8.0.0 -azure-mgmt-frontdoor==1.0.1; python_version >= "3.6" -azure-mgmt-hdinsight==7.0.0 -azure-mgmt-iothub==1.0.0 -azure-mgmt-keyvault==8.0.0 -azure-mgmt-logic==9.0.0 -azure-mgmt-managementgroups==1.0.0b1 -azure-mgmt-monitor==2.0.0 -azure-mgmt-msi==1.0.0 -azure-mgmt-network==17.1.0 -azure-mgmt-policyinsights==1.0.0 -azure-mgmt-rdbms==8.1.0 -azure-mgmt-redis==12.0.0 -azure-mgmt-resource==16.1.0 -azure-mgmt-resourcegraph==7.0.0 -azure-mgmt-search==8.0.0 -azure-mgmt-security==1.0.0 -azure-mgmt-servicefabric==1.0.0 -azure-mgmt-sql==1.0.0 -azure-mgmt-storage==17.1.0 -azure-mgmt-subscription==1.0.0 -azure-mgmt-trafficmanager==0.51.0 -azure-mgmt-web==2.0.0 -azure-nspkg==3.0.2 -azure-storage-blob==12.13.1; python_version >= "3.6" -azure-storage-common==2.1.0 -azure-storage-file-share==12.9.0; python_version >= "3.6" -azure-storage-file==2.1.0 -azure-storage-queue==12.4.0; python_version >= "3.6" -backports.zoneinfo==0.2.1; python_version >= "3.6" and python_full_version < "3.0.0" and python_version < "3.9" and (python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version < "4" and python_version >= "3.6") or python_full_version >= "3.5.0" and python_version < "3.9" and python_version >= "3.6" and (python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version < "4" and python_version >= "3.6") -certifi==2022.9.14; python_version >= "3.7" and python_version < "4" -cffi==1.15.1; python_version >= "3.7" -charset-normalizer==2.1.1; python_version >= "3.7" and python_version < "4" and python_full_version >= "3.6.0" -click==8.1.3; python_version >= "3.7" -colorama==0.4.5; python_version >= "3.7" and python_full_version < "3.0.0" and platform_system == "Windows" or platform_system == "Windows" and python_version >= "3.7" and python_full_version >= "3.5.0" -cryptography==38.0.1; python_version >= "3.6" -distlib==0.3.6 -idna==3.4; python_version >= "3.7" and python_version < "4" -importlib-metadata==4.12.0; python_version < "3.8" and python_version >= "3.7" -isodate==0.6.1; python_version >= "3.6" -jmespath==1.0.1; python_version >= "3.7" -msal-extensions==1.0.0; python_version >= "3.7" -msal==1.19.0; python_version >= "3.7" -msrest==0.7.1; python_version >= "3.6" -msrestazure==0.6.4 -netaddr==0.7.20 -oauthlib==3.2.1; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.6" -portalocker==2.5.1 -pycparser==2.21; python_version >= "3.7" and python_full_version < "3.0.0" or python_version >= "3.7" and python_full_version >= "3.4.0" -pyjwt==2.5.0; python_version >= "3.7" -python-dateutil==2.8.2; python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.3.0" -pytz-deprecation-shim==0.1.0.post0; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version < "4" and python_version >= "3.6" -pytz==2022.2.1; python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" and python_version < "4" -pywin32==304; python_version >= "3.7" and platform_system == "Windows" -requests-oauthlib==1.3.1; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.6" -requests==2.28.1; python_version >= "3.7" and python_version < "4" -six==1.16.0; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" and python_version < "4" and python_version >= "3.7" -types-cryptography==3.3.23; python_version >= "3.7" -typing-extensions==4.3.0; python_version < "3.8" and python_version >= "3.7" -tzdata==2022.2; python_version >= "3.6" and python_full_version < "3.0.0" and platform_system == "Windows" or python_full_version >= "3.6.0" and python_version < "4" and python_version >= "3.6" and platform_system == "Windows" -tzlocal==4.2; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" and python_version < "4" and python_version >= "3.6" -urllib3==1.26.12; python_version >= "3.7" and python_full_version < "3.0.0" and python_version < "4" or python_full_version >= "3.6.0" and python_version < "4" and python_version >= "3.7" -zipp==3.8.1; python_version < "3.8" and python_version >= "3.7" +adal==1.2.7 ; python_version >= "3.7" and python_version < "4.0" +applicationinsights==0.11.10 ; python_version >= "3.7" and python_version < "4.0" +apscheduler==3.9.1 ; python_version >= "3.7" and python_version < "4" +azure-common==1.1.28 ; python_version >= "3.7" and python_version < "4.0" +azure-core==1.25.1 ; python_version >= "3.7" and python_version < "4.0" +azure-cosmos==3.2.0 ; python_version >= "3.7" and python_version < "4.0" +azure-cosmosdb-nspkg==2.0.2 ; python_version >= "3.7" and python_version < "4.0" +azure-cosmosdb-table==1.0.6 ; python_version >= "3.7" and python_version < "4.0" +azure-functions==1.11.2 ; python_version >= "3.7" and python_version < "4" +azure-graphrbac==0.61.1 ; python_version >= "3.7" and python_version < "4.0" +azure-identity==1.11.0 ; python_version >= "3.7" and python_version < "4.0" +azure-keyvault-certificates==4.6.0 ; python_version >= "3.7" and python_version < "4.0" +azure-keyvault-keys==4.7.0 ; python_version >= "3.7" and python_version < "4.0" +azure-keyvault-secrets==4.6.0 ; python_version >= "3.7" and python_version < "4.0" +azure-keyvault==4.2.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-advisor==9.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-apimanagement==1.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-applicationinsights==1.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-authorization==1.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-batch==15.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-cdn==10.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-cognitiveservices==11.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-compute==19.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-containerinstance==7.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-containerregistry==8.0.0b1 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-containerservice==15.1.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-core==1.3.2 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-cosmosdb==6.4.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-costmanagement==1.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-databricks==1.0.0b1 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-datafactory==1.1.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-datalake-store==1.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-dns==8.0.0b1 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-eventgrid==8.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-eventhub==8.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-frontdoor==1.0.1 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-hdinsight==7.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-iothub==1.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-keyvault==8.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-logic==9.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-managementgroups==1.0.0b1 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-monitor==2.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-msi==1.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-network==17.1.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-policyinsights==1.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-rdbms==8.1.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-redis==12.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-resource==16.1.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-resourcegraph==7.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-search==8.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-security==1.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-servicefabric==1.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-sql==1.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-storage==17.1.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-subscription==1.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-trafficmanager==0.51.0 ; python_version >= "3.7" and python_version < "4.0" +azure-mgmt-web==2.0.0 ; python_version >= "3.7" and python_version < "4.0" +azure-nspkg==3.0.2 ; python_version >= "3.7" and python_version < "4.0" +azure-storage-blob==12.13.1 ; python_version >= "3.7" and python_version < "4.0" +azure-storage-common==2.1.0 ; python_version >= "3.7" and python_version < "4.0" +azure-storage-file-share==12.9.0 ; python_version >= "3.7" and python_version < "4.0" +azure-storage-file==2.1.0 ; python_version >= "3.7" and python_version < "4.0" +azure-storage-queue==12.4.0 ; python_version >= "3.7" and python_version < "4.0" +backports-zoneinfo==0.2.1 ; python_version >= "3.7" and python_version < "3.9" +certifi==2022.9.24 ; python_version >= "3.7" and python_version < "4" +cffi==1.15.1 ; python_version >= "3.7" and python_version < "4.0" +charset-normalizer==2.1.1 ; python_version >= "3.7" and python_version < "4" +click==8.1.3 ; python_version >= "3.7" and python_version < "4.0" +colorama==0.4.5 ; python_version >= "3.7" and python_version < "4.0" and platform_system == "Windows" +cryptography==38.0.1 ; python_version >= "3.7" and python_version < "4.0" +distlib==0.3.6 ; python_version >= "3.7" and python_version < "4.0" +idna==3.4 ; python_version >= "3.7" and python_version < "4" +importlib-metadata==4.13.0 ; python_version >= "3.7" and python_version < "3.8" +isodate==0.6.1 ; python_version >= "3.7" and python_version < "4.0" +jmespath==1.0.1 ; python_version >= "3.7" and python_version < "4.0" +msal-extensions==1.0.0 ; python_version >= "3.7" and python_version < "4.0" +msal==1.19.0 ; python_version >= "3.7" and python_version < "4.0" +msrest==0.7.1 ; python_version >= "3.7" and python_version < "4.0" +msrestazure==0.6.4 ; python_version >= "3.7" and python_version < "4.0" +netaddr==0.7.20 ; python_version >= "3.7" and python_version < "4.0" +oauthlib==3.2.1 ; python_version >= "3.7" and python_version < "4.0" +portalocker==2.5.1 ; python_version >= "3.7" and python_version < "4.0" +pycparser==2.21 ; python_version >= "3.7" and python_version < "4.0" +pyjwt==2.5.0 ; python_version >= "3.7" and python_version < "4.0" +pyjwt[crypto]==2.5.0 ; python_version >= "3.7" and python_version < "4.0" +python-dateutil==2.8.2 ; python_version >= "3.7" and python_version < "4.0" +pytz-deprecation-shim==0.1.0.post0 ; python_version >= "3.7" and python_version < "4" +pytz==2022.4 ; python_version >= "3.7" and python_version < "4" +pywin32==304 ; python_version >= "3.7" and platform_system == "Windows" and python_version < "4.0" +requests-oauthlib==1.3.1 ; python_version >= "3.7" and python_version < "4.0" +requests==2.28.1 ; python_version >= "3.7" and python_version < "4" +setuptools==65.4.1 ; python_version >= "3.7" and python_version < "4" +six==1.16.0 ; python_version >= "3.7" and python_version < "4" +types-cryptography==3.3.23 ; python_version >= "3.7" and python_version < "4.0" +typing-extensions==4.3.0 ; python_version >= "3.7" and python_version < "4.0" +tzdata==2022.4 ; python_version >= "3.7" and python_version < "4" +tzlocal==4.2 ; python_version >= "3.7" and python_version < "4" +urllib3==1.26.12 ; python_version >= "3.7" and python_version < "4" +zipp==3.8.1 ; python_version >= "3.7" and python_version < "3.8" diff --git a/tools/c7n_azure/setup.py b/tools/c7n_azure/setup.py index f37415a5670..2d4450fcd07 100644 --- a/tools/c7n_azure/setup.py +++ b/tools/c7n_azure/setup.py @@ -73,20 +73,20 @@ 'azure-storage-file-share>=12.4.1,<13.0.0', 'azure-storage-file>=2.1.0,<3.0.0', 'azure-storage-queue>=12.1.5,<13.0.0', - 'boto3 (>=1.24.77,<2.0.0)', - 'botocore (>=1.27.77,<2.0.0)', + 'boto3 (>=1.24.87,<2.0.0)', + 'botocore (>=1.27.87,<2.0.0)', 'c7n (>=0.9.19,<0.10.0)', 'click>=8.0,<9.0', 'cryptography>=3.4.6', 'distlib>=0.3.0,<0.4.0', 'docutils (>=0.17.1,<0.18.0)', - 'importlib-metadata (>=4.12.0,<5.0.0)', + 'importlib-metadata (>=4.13.0,<5.0.0)', 'importlib-resources (>=5.9.0,<6.0.0)', 'jmespath (>=1.0.1,<2.0.0)', 'jmespath>=1.0.0,<2.0.0', 'jsonschema (>=4.16.0,<5.0.0)', 'netaddr>=0.7.19,<0.8.0', - 'pkgutil-resolve-name (>=1.3.10,<2.0.0)', + 'pkgutil_resolve_name (>=1.3.10,<2.0.0)', 'pyrsistent (>=0.18.1,<0.19.0)', 'python-dateutil (>=2.8.2,<3.0.0)', 'pyyaml (>=6.0,<7.0)', @@ -114,10 +114,13 @@ 'long_description': '\n# Cloud Custodian - Azure Support\n\nThis a plugin to Cloud Custodian that adds Azure support.\n\n## Install Cloud Custodian and Azure Plugin\n\nThe Azure provider must be installed as a separate package in addition to c7n. \n\n $ git clone https://github.com/cloud-custodian/cloud-custodian.git\n $ virtualenv custodian\n $ source custodian/bin/activate\n (custodian) $ pip install -e cloud-custodian/.\n (custodian) $ pip install -e cloud-custodian/tools/c7n_azure/.\n\n\n## Write your first policy\n\nA policy specifies the following items:\n\n- The type of resource to run the policy against\n- Filters to narrow down the set of resources\n- Actions to take on the filtered set of resources\n\nFor this tutorial we will add a tag to all virtual machines with the name "Hello" and the value "World".\n\nCreate a file named ``custodian.yml`` with this content:\n\n policies:\n - name: my-first-policy\n description: |\n Adds a tag to all virtual machines\n resource: azure.vm\n actions:\n - type: tag\n tag: Hello\n value: World\n\n## Run your policy\n\nFirst, choose one of the supported authentication mechanisms and either log in to Azure CLI or set\nenvironment variables as documented in [Authentication](https://cloudcustodian.io/docs/azure/authentication.html#azure-authentication).\n\n custodian run --output-dir=. custodian.yml\n\n\nIf successful, you should see output similar to the following on the command line\n\n 2016-12-20 08:35:06,133: custodian.policy:INFO Running policy my-first-policy resource: azure.vm\n 2016-12-20 08:35:07,514: custodian.policy:INFO policy: my-first-policy resource:azure.vm has count:1 time:1.38\n 2016-12-20 08:35:08,188: custodian.policy:INFO policy: my-first-policy action: tag: 1 execution_time: 0.67\n\n\nYou should also find a new ``my-first-policy`` directory with a log and other\nfiles (subsequent runs will append to the log by default rather than\noverwriting it). \n\n## Links\n- [Getting Started](https://cloudcustodian.io/docs/azure/gettingstarted.html)\n- [Example Scenarios](https://cloudcustodian.io/docs/azure/examples/index.html)\n- [Example Policies](https://cloudcustodian.io/docs/azure/policy/index.html)\n\n\n\n\n', 'long_description_content_type': 'text/markdown', 'author': 'Cloud Custodian Project', - 'author_email': None, - 'maintainer': None, - 'maintainer_email': None, - 'url': 'https://cloudcustodian.io', + 'author_email': 'cloud-custodian@googlegroups.com', + 'project_urls': { + 'Homepage': 'https://cloudcustodian.io', + 'Documentation': 'https://cloudcustodian.io/docs/', + 'Source': 'https://github.com/cloud-custodian/cloud-custodian', + 'Issue Tracker': 'https://github.com/cloud-custodian/cloud-custodian/issues', + }, 'packages': packages, 'package_data': package_data, 'install_requires': install_requires, diff --git a/tools/c7n_gcp/poetry.lock b/tools/c7n_gcp/poetry.lock index c5cdee6d618..c8fd9936a1b 100644 --- a/tools/c7n_gcp/poetry.lock +++ b/tools/c7n_gcp/poetry.lock @@ -28,14 +28,14 @@ tests_no_zope = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy [[package]] name = "boto3" -version = "1.24.77" +version = "1.24.87" description = "The AWS SDK for Python" category = "dev" optional = false python-versions = ">= 3.7" [package.dependencies] -botocore = ">=1.27.77,<1.28.0" +botocore = ">=1.27.87,<1.28.0" jmespath = ">=0.7.1,<2.0.0" s3transfer = ">=0.6.0,<0.7.0" @@ -44,7 +44,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "botocore" -version = "1.27.77" +version = "1.27.87" description = "Low-level, data-driven core of boto 3." category = "dev" optional = false @@ -91,7 +91,7 @@ python-versions = "~=3.7" [[package]] name = "certifi" -version = "2022.9.14" +version = "2022.9.24" description = "Python package for providing Mozilla's CA Bundle." category = "main" optional = false @@ -158,7 +158,7 @@ grpcio-gcp = ["grpcio-gcp (>=0.2.2,<1.0dev)"] [[package]] name = "google-api-python-client" -version = "2.62.0" +version = "2.64.0" description = "Google API Client Library for Python" category = "main" optional = false @@ -173,7 +173,7 @@ uritemplate = ">=3.0.1,<5" [[package]] name = "google-auth" -version = "2.11.1" +version = "2.12.0" description = "Google Authentication Library" category = "main" optional = false @@ -206,7 +206,7 @@ six = "*" [[package]] name = "google-cloud-appengine-logging" -version = "1.1.4" +version = "1.1.5" description = "" category = "main" optional = false @@ -215,7 +215,7 @@ python-versions = ">=3.7" [package.dependencies] google-api-core = {version = ">=1.31.5,<2.0.0 || >2.3.0,<3.0.0dev", extras = ["grpc"]} proto-plus = ">=1.22.0,<2.0.0dev" -protobuf = ">=3.19.0,<5.0.0dev" +protobuf = ">=3.20.2,<5.0.0dev" [[package]] name = "google-cloud-audit-log" @@ -246,7 +246,7 @@ grpc = ["grpcio (>=1.38.0,<2.0dev)"] [[package]] name = "google-cloud-logging" -version = "3.2.2" +version = "3.2.4" description = "Stackdriver Logging API client library" category = "main" optional = false @@ -259,11 +259,11 @@ google-cloud-audit-log = ">=0.1.0,<1.0.0dev" google-cloud-core = ">=2.0.0,<3.0.0dev" grpc-google-iam-v1 = ">=0.12.4,<1.0.0dev" proto-plus = ">=1.22.0,<2.0.0dev" -protobuf = ">=3.19.0,<5.0.0dev" +protobuf = ">=3.20.2,<5.0.0dev" [[package]] name = "google-cloud-monitoring" -version = "2.11.1" +version = "2.11.2" description = "Stackdriver Monitoring API client library" category = "main" optional = false @@ -272,7 +272,7 @@ python-versions = ">=3.7" [package.dependencies] google-api-core = {version = ">=1.32.0,<2.0.0 || >=2.8.0,<3.0.0dev", extras = ["grpc"]} proto-plus = ">=1.22.0,<2.0.0dev" -protobuf = ">=3.19.0,<5.0.0dev" +protobuf = ">=3.20.2,<5.0.0dev" [package.extras] pandas = ["pandas (>=0.17.1)"] @@ -307,11 +307,11 @@ testing = ["pytest"] [[package]] name = "google-resumable-media" -version = "2.3.3" +version = "2.4.0" description = "Utilities for Google Media Downloads and Resumable Uploads" category = "main" optional = false -python-versions = ">= 3.6" +python-versions = ">= 3.7" [package.dependencies] google-crc32c = ">=1.0,<2.0dev" @@ -349,21 +349,21 @@ grpcio = ">=1.0.0,<2.0.0dev" [[package]] name = "grpcio" -version = "1.48.1" +version = "1.49.1" description = "HTTP/2-based RPC framework" category = "main" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [package.dependencies] six = ">=1.5.2" [package.extras] -protobuf = ["grpcio-tools (>=1.48.1)"] +protobuf = ["grpcio-tools (>=1.49.1)"] [[package]] name = "grpcio-status" -version = "1.48.1" +version = "1.49.1" description = "Status proto mapping for gRPC" category = "main" optional = false @@ -371,8 +371,8 @@ python-versions = ">=3.6" [package.dependencies] googleapis-common-protos = ">=1.5.5" -grpcio = ">=1.48.1" -protobuf = ">=3.12.0" +grpcio = ">=1.49.1" +protobuf = ">=4.21.3" [[package]] name = "httplib2" @@ -395,7 +395,7 @@ python-versions = ">=3.5" [[package]] name = "importlib-metadata" -version = "4.12.0" +version = "4.13.0" description = "Read metadata from Python packages" category = "dev" optional = false @@ -406,9 +406,9 @@ typing-extensions = {version = ">=3.6.4", markers = "python_version < \"3.8\""} zipp = ">=0.5" [package.extras] -docs = ["jaraco.packaging (>=9)", "rst.linker (>=1.9)", "sphinx"] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)"] perf = ["ipython"] -testing = ["flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] +testing = ["flake8 (<5)", "flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] [[package]] name = "importlib-resources" @@ -473,7 +473,7 @@ python-versions = ">=3.6" pyparsing = ">=2.0.2,<3.0.5 || >3.0.5" [[package]] -name = "pkgutil-resolve-name" +name = "pkgutil_resolve_name" version = "1.3.10" description = "Resolve a name to an object." category = "dev" @@ -527,7 +527,7 @@ testing = ["google-api-core[grpc] (>=1.31.5)"] [[package]] name = "protobuf" -version = "4.21.6" +version = "4.21.7" description = "" category = "main" optional = false @@ -664,7 +664,7 @@ optional = false python-versions = "*" [[package]] -name = "pyyaml" +name = "PyYAML" version = "6.0" description = "YAML parser and emitter for Python" category = "dev" @@ -819,12 +819,12 @@ attrs = [ {file = "attrs-22.1.0.tar.gz", hash = "sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6"}, ] boto3 = [ - {file = "boto3-1.24.77-py3-none-any.whl", hash = "sha256:fc16e50263c24631d5fe75464e76f3a1b454b4c0015c864948a61691f9702a6e"}, - {file = "boto3-1.24.77.tar.gz", hash = "sha256:16646de3303779d6dc9c192d8a863095244de81d2e0b94f50692fbde767c6f1b"}, + {file = "boto3-1.24.87-py3-none-any.whl", hash = "sha256:bcc579e801774cb2c7dda87ff985feda1ae7e10591d11ef37526363139138bd4"}, + {file = "boto3-1.24.87.tar.gz", hash = "sha256:3dd7ed74d1d29dd8094a078be86ed61c45de6638fe18856f7a1ff9282b4d929e"}, ] botocore = [ - {file = "botocore-1.27.77-py3-none-any.whl", hash = "sha256:d88509ed291b95525205cc06ca87b54d077aae996827039f5e32375949c5aaf7"}, - {file = "botocore-1.27.77.tar.gz", hash = "sha256:77a43e970d0762080b4b79a7e00ea572ef2ae7a9f578c3c8e7f0a344ee4b4e6d"}, + {file = "botocore-1.27.87-py3-none-any.whl", hash = "sha256:c4cbd22056ace4c7aa99e62e8ae629865ab80cc8bbf7c6d68ccf0f768f0034b6"}, + {file = "botocore-1.27.87.tar.gz", hash = "sha256:216de9751116d0d1cc3901e26d95a5c9a30ecb6973ae6147af1cf504858d845a"}, ] c7n = [] cachetools = [ @@ -832,8 +832,8 @@ cachetools = [ {file = "cachetools-5.2.0.tar.gz", hash = "sha256:6a94c6402995a99c3970cc7e4884bb60b4a8639938157eeed436098bf9831757"}, ] certifi = [ - {file = "certifi-2022.9.14-py3-none-any.whl", hash = "sha256:e232343de1ab72c2aa521b625c80f699e356830fd0e2c620b465b304b17b0516"}, - {file = "certifi-2022.9.14.tar.gz", hash = "sha256:36973885b9542e6bd01dea287b2b4b3b21236307c56324fcc3f1160f2d655ed5"}, + {file = "certifi-2022.9.24-py3-none-any.whl", hash = "sha256:90c1a32f1d68f940488354e36370f6cca89f0f106db09518524c88d6ed83f382"}, + {file = "certifi-2022.9.24.tar.gz", hash = "sha256:0d9c601124e5a6ba9712dbc60d9c53c21e34f5f641fe83002317394311bdce14"}, ] charset-normalizer = [ {file = "charset-normalizer-2.1.1.tar.gz", hash = "sha256:5a3d016c7c547f69d6f81fb0db9449ce888b418b5b9952cc5e6e66843e9dd845"}, @@ -856,20 +856,20 @@ google-api-core = [ {file = "google_api_core-2.10.1-py3-none-any.whl", hash = "sha256:92d17123cfe399b5ef7e026c63babf978d8475e1ac877919eb7933e25dea2273"}, ] google-api-python-client = [ - {file = "google-api-python-client-2.62.0.tar.gz", hash = "sha256:8307b85f0b8f84252747326de50eda279220cc1a3966d6b82e94486618275637"}, - {file = "google_api_python_client-2.62.0-py2.py3-none-any.whl", hash = "sha256:7b3295ee5f165726da1dbce9ed139fcf605efce634c94e586606e7b66b54a852"}, + {file = "google-api-python-client-2.64.0.tar.gz", hash = "sha256:0dc4c967a5c795e981af01340f1bd22173a986534de968b5456cb208ed6775a6"}, + {file = "google_api_python_client-2.64.0-py2.py3-none-any.whl", hash = "sha256:90545cd71969f8bcf15a6362c2a8c44c38b94ec35a88cfd60cf2c0df68a5eb74"}, ] google-auth = [ - {file = "google-auth-2.11.1.tar.gz", hash = "sha256:516e6623038b81430dd062a1a25ecd24f173d7c15cdf4e48a9e78bc87e97aeec"}, - {file = "google_auth-2.11.1-py2.py3-none-any.whl", hash = "sha256:53bdc0c2b4e25895575779caef4cfb3a6bdff1b7b32dc38a654d71aba35bb5f8"}, + {file = "google-auth-2.12.0.tar.gz", hash = "sha256:f12d86502ce0f2c0174e2e70ecc8d36c69593817e67e1d9c5e34489120422e4b"}, + {file = "google_auth-2.12.0-py2.py3-none-any.whl", hash = "sha256:98f601773978c969e1769f97265e732a81a8e598da3263895023958d456ee625"}, ] google-auth-httplib2 = [ {file = "google-auth-httplib2-0.1.0.tar.gz", hash = "sha256:a07c39fd632becacd3f07718dfd6021bf396978f03ad3ce4321d060015cc30ac"}, {file = "google_auth_httplib2-0.1.0-py2.py3-none-any.whl", hash = "sha256:31e49c36c6b5643b57e82617cb3e021e3e1d2df9da63af67252c02fa9c1f4a10"}, ] google-cloud-appengine-logging = [ - {file = "google-cloud-appengine-logging-1.1.4.tar.gz", hash = "sha256:8a6d00d78390821c98aa0b640fbebba86fa788a417e23a5bd299b6c8d0700424"}, - {file = "google_cloud_appengine_logging-1.1.4-py2.py3-none-any.whl", hash = "sha256:06ba651b1d46fcf380ab978b554e95fd5da725829e8203c06731d31b884eef43"}, + {file = "google-cloud-appengine-logging-1.1.5.tar.gz", hash = "sha256:ff32905faa25652d32975c80bbb1e0ba3f3b1940a23dfb9ff686a6a1b147c63c"}, + {file = "google_cloud_appengine_logging-1.1.5-py2.py3-none-any.whl", hash = "sha256:1a06dc41997c7daacadd83497b26208d49c30625103e790c4ce6dafa8ea5501c"}, ] google-cloud-audit-log = [ {file = "google-cloud-audit-log-0.2.4.tar.gz", hash = "sha256:aabe5543671e4f8a9c7a4c0e3ea9a87ba2ba2b96f9ffad6faa02209900e1f308"}, @@ -880,12 +880,12 @@ google-cloud-core = [ {file = "google_cloud_core-2.3.2-py2.py3-none-any.whl", hash = "sha256:8417acf6466be2fa85123441696c4badda48db314c607cf1e5d543fa8bdc22fe"}, ] google-cloud-logging = [ - {file = "google-cloud-logging-3.2.2.tar.gz", hash = "sha256:719121491cc349ee3f84600f3c2916b5bb95d6860b94d90d34f8f63d979d1220"}, - {file = "google_cloud_logging-3.2.2-py2.py3-none-any.whl", hash = "sha256:1870ac9dae719b5344f31d523005930bd8fc8031e8686c55b6764912a0108bbf"}, + {file = "google-cloud-logging-3.2.4.tar.gz", hash = "sha256:0ecab8fb6104f9f81b3162999ad94ed65029e9ad44696a4c2ef0ce0bb135d1e9"}, + {file = "google_cloud_logging-3.2.4-py2.py3-none-any.whl", hash = "sha256:c27b121b0d211ab45d797c938d4ef5aed8462dfa323a4f89e9fb72c48448fe55"}, ] google-cloud-monitoring = [ - {file = "google-cloud-monitoring-2.11.1.tar.gz", hash = "sha256:3d76463cc7abfd8e339b1d94b3c11facb60b9c5d6d805eb76431e60663cf334c"}, - {file = "google_cloud_monitoring-2.11.1-py2.py3-none-any.whl", hash = "sha256:cc8a4b118b56ce2566ad7dfab56926f35747ca28465dbac21e8f6e258704a16f"}, + {file = "google-cloud-monitoring-2.11.2.tar.gz", hash = "sha256:28ebd7254b0b023ec07dcd5d2c4de230b85953fa6252f788c2dbe330df87fd1c"}, + {file = "google_cloud_monitoring-2.11.2-py2.py3-none-any.whl", hash = "sha256:931ec25d507f4dc6deaac174aabadee626ff7d9d24b4ee6112531b4502b69889"}, ] google-cloud-storage = [ {file = "google-cloud-storage-1.44.0.tar.gz", hash = "sha256:29edbfeedd157d853049302bf5d104055c6f0cb7ef283537da3ce3f730073001"}, @@ -962,8 +962,8 @@ google-crc32c = [ {file = "google_crc32c-1.5.0-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:c672d99a345849301784604bfeaeba4db0c7aae50b95be04dd651fd2a7310b93"}, ] google-resumable-media = [ - {file = "google-resumable-media-2.3.3.tar.gz", hash = "sha256:27c52620bd364d1c8116eaac4ea2afcbfb81ae9139fb3199652fcac1724bfb6c"}, - {file = "google_resumable_media-2.3.3-py2.py3-none-any.whl", hash = "sha256:5b52774ea7a829a8cdaa8bd2d4c3d4bc660c91b30857ab2668d0eb830f4ea8c5"}, + {file = "google-resumable-media-2.4.0.tar.gz", hash = "sha256:8d5518502f92b9ecc84ac46779bd4f09694ecb3ba38a3e7ca737a86d15cbca1f"}, + {file = "google_resumable_media-2.4.0-py2.py3-none-any.whl", hash = "sha256:2aa004c16d295c8f6c33b2b4788ba59d366677c0a25ae7382436cb30f776deaa"}, ] googleapis-common-protos = [ {file = "googleapis-common-protos-1.56.4.tar.gz", hash = "sha256:c25873c47279387cfdcbdafa36149887901d36202cb645a0e4f29686bf6e4417"}, @@ -974,56 +974,55 @@ grpc-google-iam-v1 = [ {file = "grpc_google_iam_v1-0.12.4-py2.py3-none-any.whl", hash = "sha256:312801ae848aeb8408c099ea372b96d253077e7851aae1a9e745df984f81f20c"}, ] grpcio = [ - {file = "grpcio-1.48.1-cp310-cp310-linux_armv7l.whl", hash = "sha256:19f9c021ae858d3ef6d5ec4c0acf3f0b0a61e599e5aa36c36943c209520a0e66"}, - {file = "grpcio-1.48.1-cp310-cp310-macosx_10_10_x86_64.whl", hash = "sha256:b0fa666fecdb1b118d37823937e9237afa17fe734fc4dbe6dd642e1e4cca0246"}, - {file = "grpcio-1.48.1-cp310-cp310-manylinux_2_17_aarch64.whl", hash = "sha256:a661d4b9b314327dec1e92ed57e591e8e5eb055700e0ba9e9687f734d922dcb6"}, - {file = "grpcio-1.48.1-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:598c8c42420443c55431eba1821c7a2f72707f1ff674a4de9e0bb03282923cfb"}, - {file = "grpcio-1.48.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1c924d4e0493fd536ba3b82584b370e8b3c809ef341f9f828cff2dc3c761b3ab"}, - {file = "grpcio-1.48.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:a5edbcb8289681fcb5ded7542f2b7dd456489e83007a95e32fcaf55e9f18603e"}, - {file = "grpcio-1.48.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:9d116106cf220c79e91595523c893f1cf09ec0c2ea49de4fb82152528b7e6833"}, - {file = "grpcio-1.48.1-cp310-cp310-win32.whl", hash = "sha256:5d81cd3c161291339ed3b469250c2f5013c3083dea7796e93aedff8f05fdcec1"}, - {file = "grpcio-1.48.1-cp310-cp310-win_amd64.whl", hash = "sha256:d751f8beb383c4a5a95625d7ccc1ab183b98b02c6a88924814ea7fbff530872d"}, - {file = "grpcio-1.48.1-cp36-cp36m-linux_armv7l.whl", hash = "sha256:1471e6f25a8e47d9f88499f48c565fc5b2876e8ee91bfb0ff33eaadd188b7ea6"}, - {file = "grpcio-1.48.1-cp36-cp36m-macosx_10_10_x86_64.whl", hash = "sha256:9fba1d0ba7cf56811728f1951c800a9aca6677e86433c5e353f2cc2c4039fda6"}, - {file = "grpcio-1.48.1-cp36-cp36m-manylinux_2_17_aarch64.whl", hash = "sha256:f3a99ed422c38bd1bc893cb2cb2cea6d64173ec30927f699e95f5f58bdf625cf"}, - {file = "grpcio-1.48.1-cp36-cp36m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b005502c59835f9ba3c3f8742f64c19eeb3db41eae1a89b035a559b39b421803"}, - {file = "grpcio-1.48.1-cp36-cp36m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f0ef1dafb4eadeaca58aec8c721a5a73d551064b0c63d57fa003e233277c642e"}, - {file = "grpcio-1.48.1-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:9477967e605ba08715dcc769b5ee0f0d8b22bda40ef25a0df5a8759e5a4d21a5"}, - {file = "grpcio-1.48.1-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:dbba883c2b6d63949bc98ab1950bc22cf7c8d4e8cb68de6edde49d3cccd8fd26"}, - {file = "grpcio-1.48.1-cp36-cp36m-win32.whl", hash = "sha256:8bbaa6647986b874891bc682a1093df54cbdb073b5d4b844a2b480c47c7ffafd"}, - {file = "grpcio-1.48.1-cp36-cp36m-win_amd64.whl", hash = "sha256:e02f6ba10a3d4e289fa7ae91b301783a750d118b60f17924ca05e506c7d29bc8"}, - {file = "grpcio-1.48.1-cp37-cp37m-linux_armv7l.whl", hash = "sha256:97dc35a99c61d5f35ec6457d3df0a4695ba9bb04a35686e1c254462b15c53f98"}, - {file = "grpcio-1.48.1-cp37-cp37m-macosx_10_10_x86_64.whl", hash = "sha256:ca382028cdfd2d79b7704b2acb8ae1fb54e9e1a03a6765e1895ba89a6fcfaba1"}, - {file = "grpcio-1.48.1-cp37-cp37m-manylinux_2_17_aarch64.whl", hash = "sha256:3d319a0c89ffac9b8dfc75bfe727a4c835d18bbccc14203b20eb5949c6c7d87d"}, - {file = "grpcio-1.48.1-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:a1b81849061c67c2ffaa6ed27aa3d9b0762e71e68e784e24b0330b7b1c67470a"}, - {file = "grpcio-1.48.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:1ff1be0474846ed15682843b187e6062f845ddfeaceb2b28972073f474f7b735"}, - {file = "grpcio-1.48.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:53b6306f9473020bc47ddf64ca704356466e63d5f88f5c2a7bf0a4692e7f03c4"}, - {file = "grpcio-1.48.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:dad2501603f954f222a6e555413c454a5f8d763ab910fbab3855bcdfef6b3148"}, - {file = "grpcio-1.48.1-cp37-cp37m-win32.whl", hash = "sha256:4786323555a9f2c6380cd9a9922bcfd42165a51d68d242eebfcdfdc667651c96"}, - {file = "grpcio-1.48.1-cp37-cp37m-win_amd64.whl", hash = "sha256:934aad7350d9577f4275e787f3d91d3c8ff4efffa8d6b807d343d3c891ff53eb"}, - {file = "grpcio-1.48.1-cp38-cp38-linux_armv7l.whl", hash = "sha256:2563357697f5f2d7fd80c1b07a57ef4736551327ad84de604e7b9f6c1b6b4e20"}, - {file = "grpcio-1.48.1-cp38-cp38-macosx_10_10_x86_64.whl", hash = "sha256:1d065f40fe74b52b88a6c42d4373a0983f1b0090f952a0747f34f2c11d6cbc64"}, - {file = "grpcio-1.48.1-cp38-cp38-manylinux_2_17_aarch64.whl", hash = "sha256:3340cb2224cc397954def015729391d85fb31135b5a7efca363e73e6f1b0e908"}, - {file = "grpcio-1.48.1-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:d03009a26f7edca9f0a581aa5d3153242b815b858cb4790e34a955afb303c6ba"}, - {file = "grpcio-1.48.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:53fa2fc1a1713195fa7acf7443a6f59b6ac7837607690f813c66cc18a9cb8135"}, - {file = "grpcio-1.48.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:5a6a750c8324f3974e95265d3f9a0541573c537af1f67b3f6f46bf9c0b2e1b36"}, - {file = "grpcio-1.48.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:626822d799d8fab08f07c8d95ef5c36213d24143f7cad3f548e97413db9f4110"}, - {file = "grpcio-1.48.1-cp38-cp38-win32.whl", hash = "sha256:ca5209ef89f7607be47a308fa92308cf079805ed556ecda672f00039a26e366f"}, - {file = "grpcio-1.48.1-cp38-cp38-win_amd64.whl", hash = "sha256:7cee20a4f873d61274d70c28ff63d19677d9eeea869c6a9cbaf3a00712336b6c"}, - {file = "grpcio-1.48.1-cp39-cp39-linux_armv7l.whl", hash = "sha256:460f5bec23fffa3c041aeba1f93a0f06b7a29e6a4da3658a52e1a866494920ab"}, - {file = "grpcio-1.48.1-cp39-cp39-macosx_10_10_x86_64.whl", hash = "sha256:c54734a6eb3be544d332e65c846236d02e5fc71325e8c53af91e83a46b87b506"}, - {file = "grpcio-1.48.1-cp39-cp39-manylinux_2_17_aarch64.whl", hash = "sha256:c6b6969c529521c86884a13745a4b68930db1ef2e051735c0f479d0a7adb25b6"}, - {file = "grpcio-1.48.1-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:346bef672a1536d59437210f16af35389d715d2b321bfe4899b3d6476a196706"}, - {file = "grpcio-1.48.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f29627d66ae816837fd32c9450dc9c54780962cd74d034513ed829ba3ab46652"}, - {file = "grpcio-1.48.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:b01faf7934c606d5050cf055c1d03943180f23d995d68d04cf50c80d1ef2c65a"}, - {file = "grpcio-1.48.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:741eeff39a26d26da2b6d74ff0559f882ee95ee4e3b20c0b4b829021cb917f96"}, - {file = "grpcio-1.48.1-cp39-cp39-win32.whl", hash = "sha256:a15409bc1d05c52ecb00f5e42ab8ff280e7149f2eb854728f628fb2a0a161a5b"}, - {file = "grpcio-1.48.1-cp39-cp39-win_amd64.whl", hash = "sha256:2b6c336409937fd1cd2bf78eb72651f44d292d88da5e63059a4e8bd01b9d7411"}, - {file = "grpcio-1.48.1.tar.gz", hash = "sha256:660217eccd2943bf23ea9a36e2a292024305aec04bf747fbcff1f5032b83610e"}, + {file = "grpcio-1.49.1-cp310-cp310-linux_armv7l.whl", hash = "sha256:fd86040232e805b8e6378b2348c928490ee595b058ce9aaa27ed8e4b0f172b20"}, + {file = "grpcio-1.49.1-cp310-cp310-macosx_10_10_x86_64.whl", hash = "sha256:6fd0c9cede9552bf00f8c5791d257d5bf3790d7057b26c59df08be5e7a1e021d"}, + {file = "grpcio-1.49.1-cp310-cp310-manylinux_2_17_aarch64.whl", hash = "sha256:d0d402e158d4e84e49c158cb5204119d55e1baf363ee98d6cb5dce321c3a065d"}, + {file = "grpcio-1.49.1-cp310-cp310-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:822ceec743d42a627e64ea266059a62d214c5a3cdfcd0d7fe2b7a8e4e82527c7"}, + {file = "grpcio-1.49.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:2106d9c16527f0a85e2eea6e6b91a74fc99579c60dd810d8690843ea02bc0f5f"}, + {file = "grpcio-1.49.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:52dd02b7e7868233c571b49bc38ebd347c3bb1ff8907bb0cb74cb5f00c790afc"}, + {file = "grpcio-1.49.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:120fecba2ec5d14b5a15d11063b39783fda8dc8d24addd83196acb6582cabd9b"}, + {file = "grpcio-1.49.1-cp310-cp310-win32.whl", hash = "sha256:f1a3b88e3c53c1a6e6bed635ec1bbb92201bb6a1f2db186179f7f3f244829788"}, + {file = "grpcio-1.49.1-cp310-cp310-win_amd64.whl", hash = "sha256:a7d0017b92d3850abea87c1bdec6ea41104e71c77bca44c3e17f175c6700af62"}, + {file = "grpcio-1.49.1-cp311-cp311-linux_armv7l.whl", hash = "sha256:9fb17ff8c0d56099ac6ebfa84f670c5a62228d6b5c695cf21c02160c2ac1446b"}, + {file = "grpcio-1.49.1-cp311-cp311-macosx_10_10_x86_64.whl", hash = "sha256:075f2d06e3db6b48a2157a1bcd52d6cbdca980dd18988fe6afdb41795d51625f"}, + {file = "grpcio-1.49.1-cp311-cp311-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:46d93a1b4572b461a227f1db6b8d35a88952db1c47e5fadcf8b8a2f0e1dd9201"}, + {file = "grpcio-1.49.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:dc79b2b37d779ac42341ddef40ad5bf0966a64af412c89fc2b062e3ddabb093f"}, + {file = "grpcio-1.49.1-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:5f8b3a971c7820ea9878f3fd70086240a36aeee15d1b7e9ecbc2743b0e785568"}, + {file = "grpcio-1.49.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:49b301740cf5bc8fed4fee4c877570189ae3951432d79fa8e524b09353659811"}, + {file = "grpcio-1.49.1-cp311-cp311-win32.whl", hash = "sha256:1c66a25afc6c71d357867b341da594a5587db5849b48f4b7d5908d236bb62ede"}, + {file = "grpcio-1.49.1-cp311-cp311-win_amd64.whl", hash = "sha256:6b6c3a95d27846f4145d6967899b3ab25fffc6ae99544415e1adcacef84842d2"}, + {file = "grpcio-1.49.1-cp37-cp37m-linux_armv7l.whl", hash = "sha256:1cc400c8a2173d1c042997d98a9563e12d9bb3fb6ad36b7f355bc77c7663b8af"}, + {file = "grpcio-1.49.1-cp37-cp37m-macosx_10_10_x86_64.whl", hash = "sha256:34f736bd4d0deae90015c0e383885b431444fe6b6c591dea288173df20603146"}, + {file = "grpcio-1.49.1-cp37-cp37m-manylinux_2_17_aarch64.whl", hash = "sha256:196082b9c89ebf0961dcd77cb114bed8171964c8e3063b9da2fb33536a6938ed"}, + {file = "grpcio-1.49.1-cp37-cp37m-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:8c9f89c42749890618cd3c2464e1fbf88446e3d2f67f1e334c8e5db2f3272bbd"}, + {file = "grpcio-1.49.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:64419cb8a5b612cdb1550c2fd4acbb7d4fb263556cf4625f25522337e461509e"}, + {file = "grpcio-1.49.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:8a5272061826e6164f96e3255405ef6f73b88fd3e8bef464c7d061af8585ac62"}, + {file = "grpcio-1.49.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:ea9d0172445241ad7cb49577314e39d0af2c5267395b3561d7ced5d70458a9f3"}, + {file = "grpcio-1.49.1-cp37-cp37m-win32.whl", hash = "sha256:2070e87d95991473244c72d96d13596c751cb35558e11f5df5414981e7ed2492"}, + {file = "grpcio-1.49.1-cp37-cp37m-win_amd64.whl", hash = "sha256:4fcedcab49baaa9db4a2d240ac81f2d57eb0052b1c6a9501b46b8ae912720fbf"}, + {file = "grpcio-1.49.1-cp38-cp38-linux_armv7l.whl", hash = "sha256:afbb3475cf7f4f7d380c2ca37ee826e51974f3e2665613996a91d6a58583a534"}, + {file = "grpcio-1.49.1-cp38-cp38-macosx_10_10_x86_64.whl", hash = "sha256:a4f9ba141380abde6c3adc1727f21529137a2552002243fa87c41a07e528245c"}, + {file = "grpcio-1.49.1-cp38-cp38-manylinux_2_17_aarch64.whl", hash = "sha256:cf0a1fb18a7204b9c44623dfbd1465b363236ce70c7a4ed30402f9f60d8b743b"}, + {file = "grpcio-1.49.1-cp38-cp38-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:17bb6fe72784b630728c6cff9c9d10ccc3b6d04e85da6e0a7b27fb1d135fac62"}, + {file = "grpcio-1.49.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:18305d5a082d1593b005a895c10041f833b16788e88b02bb81061f5ebcc465df"}, + {file = "grpcio-1.49.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:b6a1b39e59ac5a3067794a0e498911cf2e37e4b19ee9e9977dc5e7051714f13f"}, + {file = "grpcio-1.49.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:0e20d59aafc086b1cc68400463bddda6e41d3e5ed30851d1e2e0f6a2e7e342d3"}, + {file = "grpcio-1.49.1-cp38-cp38-win32.whl", hash = "sha256:e1e83233d4680863a421f3ee4a7a9b80d33cd27ee9ed7593bc93f6128302d3f2"}, + {file = "grpcio-1.49.1-cp38-cp38-win_amd64.whl", hash = "sha256:221d42c654d2a41fa31323216279c73ed17d92f533bc140a3390cc1bd78bf63c"}, + {file = "grpcio-1.49.1-cp39-cp39-linux_armv7l.whl", hash = "sha256:fa9e6e61391e99708ac87fc3436f6b7b9c6b845dc4639b406e5e61901e1aacde"}, + {file = "grpcio-1.49.1-cp39-cp39-macosx_10_10_x86_64.whl", hash = "sha256:9b449e966ef518ce9c860d21f8afe0b0f055220d95bc710301752ac1db96dd6a"}, + {file = "grpcio-1.49.1-cp39-cp39-manylinux_2_17_aarch64.whl", hash = "sha256:aa34d2ad9f24e47fa9a3172801c676e4037d862247e39030165fe83821a7aafd"}, + {file = "grpcio-1.49.1-cp39-cp39-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:5207f4eed1b775d264fcfe379d8541e1c43b878f2b63c0698f8f5c56c40f3d68"}, + {file = "grpcio-1.49.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:0b24a74651438d45619ac67004638856f76cc13d78b7478f2457754cbcb1c8ad"}, + {file = "grpcio-1.49.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:fe763781669790dc8b9618e7e677c839c87eae6cf28b655ee1fa69ae04eea03f"}, + {file = "grpcio-1.49.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:2f2ff7ba0f8f431f32d4b4bc3a3713426949d3533b08466c4ff1b2b475932ca8"}, + {file = "grpcio-1.49.1-cp39-cp39-win32.whl", hash = "sha256:08ff74aec8ff457a89b97152d36cb811dcc1d17cd5a92a65933524e363327394"}, + {file = "grpcio-1.49.1-cp39-cp39-win_amd64.whl", hash = "sha256:274ffbb39717918c514b35176510ae9be06e1d93121e84d50b350861dcb9a705"}, + {file = "grpcio-1.49.1.tar.gz", hash = "sha256:d4725fc9ec8e8822906ae26bb26f5546891aa7fbc3443de970cc556d43a5c99f"}, ] grpcio-status = [ - {file = "grpcio-status-1.48.1.tar.gz", hash = "sha256:655af4d0d6e67586cb2ca24c3db5fe08e4e2972d17f295f6b546fa7bd7eef1f6"}, - {file = "grpcio_status-1.48.1-py3-none-any.whl", hash = "sha256:e04f8c2daa580a8f0f9929c10dc9d696857473f21469a5f2a990a15bafc21a86"}, + {file = "grpcio-status-1.49.1.tar.gz", hash = "sha256:658f48dc146ee0c7b6eebd302d74e0d45c00727c20035ff51d68750dbaccf5d9"}, + {file = "grpcio_status-1.49.1-py3-none-any.whl", hash = "sha256:fe4ae9f624f03e50ccf6f6ead60727ab20b17735bb3d0dd506ef355349282378"}, ] httplib2 = [ {file = "httplib2-0.20.4-py3-none-any.whl", hash = "sha256:8b6a905cb1c79eefd03f8669fd993c36dc341f7c558f056cb5a33b5c2f458543"}, @@ -1034,8 +1033,8 @@ idna = [ {file = "idna-3.4.tar.gz", hash = "sha256:814f528e8dead7d329833b91c5faa87d60bf71824cd12a7530b5526063d02cb4"}, ] importlib-metadata = [ - {file = "importlib_metadata-4.12.0-py3-none-any.whl", hash = "sha256:7401a975809ea1fdc658c3aa4f78cc2195a0e019c5cbc4c06122884e9ae80c23"}, - {file = "importlib_metadata-4.12.0.tar.gz", hash = "sha256:637245b8bab2b6502fcbc752cc4b7a6f6243bb02b31c5c26156ad103d3d45670"}, + {file = "importlib_metadata-4.13.0-py3-none-any.whl", hash = "sha256:8a8a81bcf996e74fee46f0d16bd3eaa382a7eb20fd82445c3ad11f4090334116"}, + {file = "importlib_metadata-4.13.0.tar.gz", hash = "sha256:dd0173e8f150d6815e098fd354f6414b0f079af4644ddfe90c71e2fc6174346d"}, ] importlib-resources = [ {file = "importlib_resources-5.9.0-py3-none-any.whl", hash = "sha256:f78a8df21a79bcc30cfd400bdc38f314333de7c0fb619763f6b9dabab8268bb7"}, @@ -1057,7 +1056,7 @@ packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, {file = "packaging-21.3.tar.gz", hash = "sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb"}, ] -pkgutil-resolve-name = [ +pkgutil_resolve_name = [ {file = "pkgutil_resolve_name-1.3.10-py3-none-any.whl", hash = "sha256:ca27cc078d25c5ad71a9de0a7a330146c4e014c2462d9af19c6b828280649c5e"}, {file = "pkgutil_resolve_name-1.3.10.tar.gz", hash = "sha256:357d6c9e6a755653cfd78893817c0853af365dd51ec97f3d358a819373bbd174"}, ] @@ -1074,20 +1073,20 @@ proto-plus = [ {file = "proto_plus-1.22.1-py3-none-any.whl", hash = "sha256:ea8982669a23c379f74495bc48e3dcb47c822c484ce8ee1d1d7beb339d4e34c5"}, ] protobuf = [ - {file = "protobuf-4.21.6-cp310-abi3-win32.whl", hash = "sha256:49f88d56a9180dbb7f6199c920f5bb5c1dd0172f672983bb281298d57c2ac8eb"}, - {file = "protobuf-4.21.6-cp310-abi3-win_amd64.whl", hash = "sha256:7a6cc8842257265bdfd6b74d088b829e44bcac3cca234c5fdd6052730017b9ea"}, - {file = "protobuf-4.21.6-cp37-abi3-macosx_10_9_universal2.whl", hash = "sha256:ba596b9ffb85c909fcfe1b1a23136224ed678af3faf9912d3fa483d5f9813c4e"}, - {file = "protobuf-4.21.6-cp37-abi3-manylinux2014_aarch64.whl", hash = "sha256:4143513c766db85b9d7c18dbf8339673c8a290131b2a0fe73855ab20770f72b0"}, - {file = "protobuf-4.21.6-cp37-abi3-manylinux2014_x86_64.whl", hash = "sha256:b6cea204865595a92a7b240e4b65bcaaca3ad5d2ce25d9db3756eba06041138e"}, - {file = "protobuf-4.21.6-cp37-cp37m-win32.whl", hash = "sha256:9666da97129138585b26afcb63ad4887f602e169cafe754a8258541c553b8b5d"}, - {file = "protobuf-4.21.6-cp37-cp37m-win_amd64.whl", hash = "sha256:308173d3e5a3528787bb8c93abea81d5a950bdce62840d9760effc84127fb39c"}, - {file = "protobuf-4.21.6-cp38-cp38-win32.whl", hash = "sha256:aa29113ec901281f29d9d27b01193407a98aa9658b8a777b0325e6d97149f5ce"}, - {file = "protobuf-4.21.6-cp38-cp38-win_amd64.whl", hash = "sha256:8f9e60f7d44592c66e7b332b6a7b4b6e8d8b889393c79dbc3a91f815118f8eac"}, - {file = "protobuf-4.21.6-cp39-cp39-win32.whl", hash = "sha256:80e6540381080715fddac12690ee42d087d0d17395f8d0078dfd6f1181e7be4c"}, - {file = "protobuf-4.21.6-cp39-cp39-win_amd64.whl", hash = "sha256:77b355c8604fe285536155286b28b0c4cbc57cf81b08d8357bf34829ea982860"}, - {file = "protobuf-4.21.6-py2.py3-none-any.whl", hash = "sha256:07a0bb9cc6114f16a39c866dc28b6e3d96fa4ffb9cc1033057412547e6e75cb9"}, - {file = "protobuf-4.21.6-py3-none-any.whl", hash = "sha256:c7c864148a237f058c739ae7a05a2b403c0dfa4ce7d1f3e5213f352ad52d57c6"}, - {file = "protobuf-4.21.6.tar.gz", hash = "sha256:6b1040a5661cd5f6e610cbca9cfaa2a17d60e2bb545309bc1b278bb05be44bdd"}, + {file = "protobuf-4.21.7-cp310-abi3-win32.whl", hash = "sha256:c7cb105d69a87416bd9023e64324e1c089593e6dae64d2536f06bcbe49cd97d8"}, + {file = "protobuf-4.21.7-cp310-abi3-win_amd64.whl", hash = "sha256:3ec85328a35a16463c6f419dbce3c0fc42b3e904d966f17f48bae39597c7a543"}, + {file = "protobuf-4.21.7-cp37-abi3-macosx_10_9_universal2.whl", hash = "sha256:db9056b6a11cb5131036d734bcbf91ef3ef9235d6b681b2fc431cbfe5a7f2e56"}, + {file = "protobuf-4.21.7-cp37-abi3-manylinux2014_aarch64.whl", hash = "sha256:ca200645d6235ce0df3ccfdff1567acbab35c4db222a97357806e015f85b5744"}, + {file = "protobuf-4.21.7-cp37-abi3-manylinux2014_x86_64.whl", hash = "sha256:b019c79e23a80735cc8a71b95f76a49a262f579d6b84fd20a0b82279f40e2cc1"}, + {file = "protobuf-4.21.7-cp37-cp37m-win32.whl", hash = "sha256:d3f89ccf7182293feba2de2739c8bf34fed1ed7c65a5cf987be00311acac57c1"}, + {file = "protobuf-4.21.7-cp37-cp37m-win_amd64.whl", hash = "sha256:a74d96cd960b87b4b712797c741bb3ea3a913f5c2dc4b6cbe9c0f8360b75297d"}, + {file = "protobuf-4.21.7-cp38-cp38-win32.whl", hash = "sha256:8e09d1916386eca1ef1353767b6efcebc0a6859ed7f73cb7fb974feba3184830"}, + {file = "protobuf-4.21.7-cp38-cp38-win_amd64.whl", hash = "sha256:9e355f2a839d9930d83971b9f562395e13493f0e9211520f8913bd11efa53c02"}, + {file = "protobuf-4.21.7-cp39-cp39-win32.whl", hash = "sha256:f370c0a71712f8965023dd5b13277444d3cdfecc96b2c778b0e19acbfd60df6e"}, + {file = "protobuf-4.21.7-cp39-cp39-win_amd64.whl", hash = "sha256:9643684232b6b340b5e63bb69c9b4904cdd39e4303d498d1a92abddc7e895b7f"}, + {file = "protobuf-4.21.7-py2.py3-none-any.whl", hash = "sha256:8066322588d4b499869bf9f665ebe448e793036b552f68c585a9b28f1e393f66"}, + {file = "protobuf-4.21.7-py3-none-any.whl", hash = "sha256:58b81358ec6c0b5d50df761460ae2db58405c063fd415e1101209221a0a810e1"}, + {file = "protobuf-4.21.7.tar.gz", hash = "sha256:71d9dba03ed3432c878a801e2ea51e034b0ea01cf3a4344fb60166cb5f6c8757"}, ] py = [ {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, @@ -1164,7 +1163,7 @@ pywin32 = [ {file = "pywin32-304-cp39-cp39-win32.whl", hash = "sha256:25746d841201fd9f96b648a248f731c1dec851c9a08b8e33da8b56148e4c65cc"}, {file = "pywin32-304-cp39-cp39-win_amd64.whl", hash = "sha256:d24a3382f013b21aa24a5cfbfad5a2cd9926610c0affde3e8ab5b3d7dbcf4ac9"}, ] -pyyaml = [ +PyYAML = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, diff --git a/tools/c7n_gcp/requirements.txt b/tools/c7n_gcp/requirements.txt index 63dbdddec59..7cc296174a8 100644 --- a/tools/c7n_gcp/requirements.txt +++ b/tools/c7n_gcp/requirements.txt @@ -1,28 +1,28 @@ cachetools==5.2.0 ; python_version >= "3.7" and python_version < "4.0" -certifi==2022.9.14 ; python_version >= "3.7" and python_version < "4" +certifi==2022.9.24 ; python_version >= "3.7" and python_version < "4" charset-normalizer==2.1.1 ; python_version >= "3.7" and python_version < "4" google-api-core==2.10.1 ; python_version >= "3.7" and python_version < "4.0" google-api-core[grpc]==2.10.1 ; python_version >= "3.7" and python_version < "4.0" -google-api-python-client==2.62.0 ; python_version >= "3.7" and python_version < "4.0" +google-api-python-client==2.64.0 ; python_version >= "3.7" and python_version < "4.0" google-auth-httplib2==0.1.0 ; python_version >= "3.7" and python_version < "4.0" -google-auth==2.11.1 ; python_version >= "3.7" and python_version < "4.0" -google-cloud-appengine-logging==1.1.4 ; python_version >= "3.7" and python_version < "4.0" +google-auth==2.12.0 ; python_version >= "3.7" and python_version < "4.0" +google-cloud-appengine-logging==1.1.5 ; python_version >= "3.7" and python_version < "4.0" google-cloud-audit-log==0.2.4 ; python_version >= "3.7" and python_version < "4.0" google-cloud-core==2.3.2 ; python_version >= "3.7" and python_version < "4.0" -google-cloud-logging==3.2.2 ; python_version >= "3.7" and python_version < "4.0" -google-cloud-monitoring==2.11.1 ; python_version >= "3.7" and python_version < "4.0" +google-cloud-logging==3.2.4 ; python_version >= "3.7" and python_version < "4.0" +google-cloud-monitoring==2.11.2 ; python_version >= "3.7" and python_version < "4.0" google-cloud-storage==1.44.0 ; python_version >= "3.7" and python_version < "4.0" google-crc32c==1.5.0 ; python_version >= "3.7" and python_version < "4.0" -google-resumable-media==2.3.3 ; python_version >= "3.7" and python_version < "4.0" +google-resumable-media==2.4.0 ; python_version >= "3.7" and python_version < "4.0" googleapis-common-protos==1.56.4 ; python_version >= "3.7" and python_version < "4.0" googleapis-common-protos[grpc]==1.56.4 ; python_version >= "3.7" and python_version < "4.0" grpc-google-iam-v1==0.12.4 ; python_version >= "3.7" and python_version < "4.0" -grpcio-status==1.48.1 ; python_version >= "3.7" and python_version < "4.0" -grpcio==1.48.1 ; python_version >= "3.7" and python_version < "4.0" +grpcio-status==1.49.1 ; python_version >= "3.7" and python_version < "4.0" +grpcio==1.49.1 ; python_version >= "3.7" and python_version < "4.0" httplib2==0.20.4 ; python_version >= "3.7" and python_version < "4.0" idna==3.4 ; python_version >= "3.7" and python_version < "4" proto-plus==1.22.1 ; python_version >= "3.7" and python_version < "4.0" -protobuf==4.21.6 ; python_version >= "3.7" and python_version < "4.0" +protobuf==4.21.7 ; python_version >= "3.7" and python_version < "4.0" pyasn1-modules==0.2.8 ; python_version >= "3.7" and python_version < "4.0" pyasn1==0.4.8 ; python_version >= "3.7" and python_version < "4.0" pyparsing==3.0.9 ; python_version >= "3.7" and python_version < "4.0" diff --git a/tools/c7n_gcp/setup.py b/tools/c7n_gcp/setup.py index b5b9a3f6a98..aed56f54293 100644 --- a/tools/c7n_gcp/setup.py +++ b/tools/c7n_gcp/setup.py @@ -12,8 +12,8 @@ install_requires = \ ['argcomplete (>=2.0.0,<3.0.0)', 'attrs (>=22.1.0,<23.0.0)', - 'boto3 (>=1.24.77,<2.0.0)', - 'botocore (>=1.27.77,<2.0.0)', + 'boto3 (>=1.24.87,<2.0.0)', + 'botocore (>=1.27.87,<2.0.0)', 'c7n (>=0.9.19,<0.10.0)', 'docutils (>=0.17.1,<0.18.0)', 'google-api-python-client>=2.0,<3.0', @@ -21,11 +21,11 @@ 'google-cloud-logging>=3.2,<4.0', 'google-cloud-monitoring>=2.5.0,<3.0.0', 'google-cloud-storage>=1.42.2,<2.0.0', - 'importlib-metadata (>=4.12.0,<5.0.0)', + 'importlib-metadata (>=4.13.0,<5.0.0)', 'importlib-resources (>=5.9.0,<6.0.0)', 'jmespath (>=1.0.1,<2.0.0)', 'jsonschema (>=4.16.0,<5.0.0)', - 'pkgutil-resolve-name (>=1.3.10,<2.0.0)', + 'pkgutil_resolve_name (>=1.3.10,<2.0.0)', 'pyrsistent (>=0.18.1,<0.19.0)', 'python-dateutil (>=2.8.2,<3.0.0)', 'pyyaml (>=6.0,<7.0)', @@ -51,10 +51,13 @@ 'long_description': '# Custodian GCP Support\n\nStatus - Alpha\n\n# Features\n\n - Serverless ✅\n - Api Subscriber ✅\n - Metrics ✅\n - Resource Query ✅\n - Multi Account (c7n-org) ✅\n\n# Getting Started\n\n\n## via pip\n\n```\npip install c7n_gcp\n```\n\nBy default custodian will use credentials associated to the gcloud cli, which will generate\nwarnings per google.auth (https://github.com/googleapis/google-auth-library-python/issues/292)\n\nThe recommended authentication form for production usage is to create a service account and\ncredentials, which will be picked up via by the custodian cli via setting the\n*GOOGLE_APPLICATION_CREDENTIALS* environment variable.\n\n\n# Serverless\n\nCustodian supports both periodic and api call events for serverless\npolicy execution.\n\nGCP Cloud Functions require cloudbuild api be enabled on the project\nthe functions are deployed to.\n\nPeriodic execution mode also requires cloudscheduler api be enabled on\na project. Cloudscheduler usage also requires an app engine instance\nin the same region as the function deployment.\n', 'long_description_content_type': 'text/markdown', 'author': 'Cloud Custodian Project', - 'author_email': None, - 'maintainer': None, - 'maintainer_email': None, - 'url': 'https://cloudcustodian.io', + 'author_email': 'cloud-custodian@googlegroups.com', + 'project_urls': { + 'Homepage': 'https://cloudcustodian.io', + 'Documentation': 'https://cloudcustodian.io/docs/', + 'Source': 'https://github.com/cloud-custodian/cloud-custodian', + 'Issue Tracker': 'https://github.com/cloud-custodian/cloud-custodian/issues', + }, 'packages': packages, 'package_data': package_data, 'install_requires': install_requires, diff --git a/tools/c7n_kube/poetry.lock b/tools/c7n_kube/poetry.lock index fa56dd41d77..b902ae93b2c 100644 --- a/tools/c7n_kube/poetry.lock +++ b/tools/c7n_kube/poetry.lock @@ -21,21 +21,21 @@ optional = false python-versions = ">=3.5" [package.extras] -dev = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "furo", "sphinx", "sphinx-notfound-page", "pre-commit", "cloudpickle"] -docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] -tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] -tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "cloudpickle"] +dev = ["cloudpickle", "coverage[toml] (>=5.0.2)", "furo", "hypothesis", "mypy (>=0.900,!=0.940)", "pre-commit", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "sphinx", "sphinx-notfound-page", "zope.interface"] +docs = ["furo", "sphinx", "sphinx-notfound-page", "zope.interface"] +tests = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "zope.interface"] +tests_no_zope = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins"] [[package]] name = "boto3" -version = "1.24.77" +version = "1.24.87" description = "The AWS SDK for Python" category = "dev" optional = false python-versions = ">= 3.7" [package.dependencies] -botocore = ">=1.27.77,<1.28.0" +botocore = ">=1.27.87,<1.28.0" jmespath = ">=0.7.1,<2.0.0" s3transfer = ">=0.6.0,<0.7.0" @@ -44,7 +44,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "botocore" -version = "1.27.77" +version = "1.27.87" description = "Low-level, data-driven core of boto 3." category = "dev" optional = false @@ -91,7 +91,7 @@ python-versions = "~=3.7" [[package]] name = "certifi" -version = "2022.9.14" +version = "2022.9.24" description = "Python package for providing Mozilla's CA Bundle." category = "main" optional = false @@ -126,7 +126,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" [[package]] name = "google-auth" -version = "2.11.1" +version = "2.12.0" description = "Google Authentication Library" category = "main" optional = false @@ -139,7 +139,7 @@ rsa = {version = ">=3.1.4,<5", markers = "python_version >= \"3.6\""} six = ">=1.9.0" [package.extras] -aiohttp = ["requests (>=2.20.0,<3.0.0dev)", "aiohttp (>=3.6.2,<4.0.0dev)"] +aiohttp = ["aiohttp (>=3.6.2,<4.0.0dev)", "requests (>=2.20.0,<3.0.0dev)"] enterprise_cert = ["cryptography (==36.0.2)", "pyopenssl (==22.0.0)"] pyopenssl = ["pyopenssl (>=20.0.0)"] reauth = ["pyu2f (>=0.1.5)"] @@ -154,7 +154,7 @@ python-versions = ">=3.5" [[package]] name = "importlib-metadata" -version = "4.12.0" +version = "4.13.0" description = "Read metadata from Python packages" category = "dev" optional = false @@ -165,9 +165,9 @@ typing-extensions = {version = ">=3.6.4", markers = "python_version < \"3.8\""} zipp = ">=0.5" [package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)"] perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.3)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] +testing = ["flake8 (<5)", "flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] [[package]] name = "importlib-resources" @@ -181,8 +181,8 @@ python-versions = ">=3.7" zipp = {version = ">=3.1.0", markers = "python_version < \"3.10\""} [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [[package]] name = "iniconfig" @@ -235,6 +235,7 @@ python-dateutil = ">=2.5.3" pyyaml = ">=3.12" requests = "*" requests-oauthlib = "*" +setuptools = ">=21.0.0" six = ">=1.9.0" urllib3 = ">=1.24.2" websocket-client = ">=0.32.0,<0.40.0 || >0.40.0,<0.41.0 || >=0.43.0" @@ -275,7 +276,7 @@ python-versions = ">=3.6" pyparsing = ">=2.0.2,<3.0.5 || >3.0.5" [[package]] -name = "pkgutil-resolve-name" +name = "pkgutil_resolve_name" version = "1.3.10" description = "Resolve a name to an object." category = "dev" @@ -333,7 +334,7 @@ optional = false python-versions = ">=3.6.8" [package.extras] -diagrams = ["railroad-diagrams", "jinja2"] +diagrams = ["jinja2", "railroad-diagrams"] [[package]] name = "pyrsistent" @@ -376,7 +377,7 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,>=2.7" six = ">=1.5" [[package]] -name = "pyyaml" +name = "PyYAML" version = "6.0" description = "YAML parser and emitter for Python" category = "main" @@ -441,6 +442,19 @@ botocore = ">=1.12.36,<2.0a.0" [package.extras] crt = ["botocore[crt] (>=1.20.29,<2.0a.0)"] +[[package]] +name = "setuptools" +version = "65.4.1" +description = "Easily download, build, install, upgrade, and uninstall Python packages" +category = "main" +optional = false +python-versions = ">=3.7" + +[package.extras] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "pygments-github-lexers (==0.0.5)", "rst.linker (>=1.9)", "sphinx (>=3.5)", "sphinx-favicon", "sphinx-hoverxref (<2)", "sphinx-inline-tabs", "sphinx-notfound-page (==0.8.3)", "sphinx-reredirects", "sphinxcontrib-towncrier"] +testing = ["build[virtualenv]", "filelock (>=3.4.0)", "flake8 (<5)", "flake8-2020", "ini2toml[lite] (>=0.9)", "jaraco.envs (>=2.2)", "jaraco.path (>=3.2.0)", "mock", "pip (>=19.1)", "pip-run (>=8.8)", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf", "pytest-xdist", "tomli-w (>=1.0.0)", "virtualenv (>=13.0.0)", "wheel"] +testing-integration = ["build[virtualenv]", "filelock (>=3.4.0)", "jaraco.envs (>=2.2)", "jaraco.path (>=3.2.0)", "pytest", "pytest-enabler", "pytest-xdist", "tomli", "virtualenv (>=13.0.0)", "wheel"] + [[package]] name = "six" version = "1.16.0" @@ -485,8 +499,8 @@ optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*, <4" [package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "urllib3-secure-extra", "ipaddress"] +brotli = ["brotli (>=1.0.9)", "brotlicffi (>=0.8.0)", "brotlipy (>=0.6.0)"] +secure = ["certifi", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "ipaddress", "pyOpenSSL (>=0.14)", "urllib3-secure-extra"] socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] [[package]] @@ -512,9 +526,9 @@ optional = false python-versions = ">=3.7" [package.extras] +docs = ["Sphinx (>=3.4)", "sphinx-rtd-theme (>=0.5)"] +optional = ["python-socks", "wsaccel"] test = ["websockets"] -optional = ["wsaccel", "python-socks"] -docs = ["sphinx-rtd-theme (>=0.5)", "Sphinx (>=3.4)"] [[package]] name = "wrapt" @@ -546,8 +560,8 @@ optional = false python-versions = ">=3.7" [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "func-timeout", "jaraco.itertools", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["func-timeout", "jaraco.itertools", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [metadata] lock-version = "1.1" @@ -564,12 +578,12 @@ attrs = [ {file = "attrs-22.1.0.tar.gz", hash = "sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6"}, ] boto3 = [ - {file = "boto3-1.24.77-py3-none-any.whl", hash = "sha256:fc16e50263c24631d5fe75464e76f3a1b454b4c0015c864948a61691f9702a6e"}, - {file = "boto3-1.24.77.tar.gz", hash = "sha256:16646de3303779d6dc9c192d8a863095244de81d2e0b94f50692fbde767c6f1b"}, + {file = "boto3-1.24.87-py3-none-any.whl", hash = "sha256:bcc579e801774cb2c7dda87ff985feda1ae7e10591d11ef37526363139138bd4"}, + {file = "boto3-1.24.87.tar.gz", hash = "sha256:3dd7ed74d1d29dd8094a078be86ed61c45de6638fe18856f7a1ff9282b4d929e"}, ] botocore = [ - {file = "botocore-1.27.77-py3-none-any.whl", hash = "sha256:d88509ed291b95525205cc06ca87b54d077aae996827039f5e32375949c5aaf7"}, - {file = "botocore-1.27.77.tar.gz", hash = "sha256:77a43e970d0762080b4b79a7e00ea572ef2ae7a9f578c3c8e7f0a344ee4b4e6d"}, + {file = "botocore-1.27.87-py3-none-any.whl", hash = "sha256:c4cbd22056ace4c7aa99e62e8ae629865ab80cc8bbf7c6d68ccf0f768f0034b6"}, + {file = "botocore-1.27.87.tar.gz", hash = "sha256:216de9751116d0d1cc3901e26d95a5c9a30ecb6973ae6147af1cf504858d845a"}, ] c7n = [] cachetools = [ @@ -577,8 +591,8 @@ cachetools = [ {file = "cachetools-5.2.0.tar.gz", hash = "sha256:6a94c6402995a99c3970cc7e4884bb60b4a8639938157eeed436098bf9831757"}, ] certifi = [ - {file = "certifi-2022.9.14-py3-none-any.whl", hash = "sha256:e232343de1ab72c2aa521b625c80f699e356830fd0e2c620b465b304b17b0516"}, - {file = "certifi-2022.9.14.tar.gz", hash = "sha256:36973885b9542e6bd01dea287b2b4b3b21236307c56324fcc3f1160f2d655ed5"}, + {file = "certifi-2022.9.24-py3-none-any.whl", hash = "sha256:90c1a32f1d68f940488354e36370f6cca89f0f106db09518524c88d6ed83f382"}, + {file = "certifi-2022.9.24.tar.gz", hash = "sha256:0d9c601124e5a6ba9712dbc60d9c53c21e34f5f641fe83002317394311bdce14"}, ] charset-normalizer = [ {file = "charset-normalizer-2.1.1.tar.gz", hash = "sha256:5a3d016c7c547f69d6f81fb0db9449ce888b418b5b9952cc5e6e66843e9dd845"}, @@ -593,16 +607,16 @@ docutils = [ {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, ] google-auth = [ - {file = "google-auth-2.11.1.tar.gz", hash = "sha256:516e6623038b81430dd062a1a25ecd24f173d7c15cdf4e48a9e78bc87e97aeec"}, - {file = "google_auth-2.11.1-py2.py3-none-any.whl", hash = "sha256:53bdc0c2b4e25895575779caef4cfb3a6bdff1b7b32dc38a654d71aba35bb5f8"}, + {file = "google-auth-2.12.0.tar.gz", hash = "sha256:f12d86502ce0f2c0174e2e70ecc8d36c69593817e67e1d9c5e34489120422e4b"}, + {file = "google_auth-2.12.0-py2.py3-none-any.whl", hash = "sha256:98f601773978c969e1769f97265e732a81a8e598da3263895023958d456ee625"}, ] idna = [ {file = "idna-3.4-py3-none-any.whl", hash = "sha256:90b77e79eaa3eba6de819a0c442c0b4ceefc341a7a2ab77d7562bf49f425c5c2"}, {file = "idna-3.4.tar.gz", hash = "sha256:814f528e8dead7d329833b91c5faa87d60bf71824cd12a7530b5526063d02cb4"}, ] importlib-metadata = [ - {file = "importlib_metadata-4.12.0-py3-none-any.whl", hash = "sha256:7401a975809ea1fdc658c3aa4f78cc2195a0e019c5cbc4c06122884e9ae80c23"}, - {file = "importlib_metadata-4.12.0.tar.gz", hash = "sha256:637245b8bab2b6502fcbc752cc4b7a6f6243bb02b31c5c26156ad103d3d45670"}, + {file = "importlib_metadata-4.13.0-py3-none-any.whl", hash = "sha256:8a8a81bcf996e74fee46f0d16bd3eaa382a7eb20fd82445c3ad11f4090334116"}, + {file = "importlib_metadata-4.13.0.tar.gz", hash = "sha256:dd0173e8f150d6815e098fd354f6414b0f079af4644ddfe90c71e2fc6174346d"}, ] importlib-resources = [ {file = "importlib_resources-5.9.0-py3-none-any.whl", hash = "sha256:f78a8df21a79bcc30cfd400bdc38f314333de7c0fb619763f6b9dabab8268bb7"}, @@ -693,7 +707,7 @@ packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, {file = "packaging-21.3.tar.gz", hash = "sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb"}, ] -pkgutil-resolve-name = [ +pkgutil_resolve_name = [ {file = "pkgutil_resolve_name-1.3.10-py3-none-any.whl", hash = "sha256:ca27cc078d25c5ad71a9de0a7a330146c4e014c2462d9af19c6b828280649c5e"}, {file = "pkgutil_resolve_name-1.3.10.tar.gz", hash = "sha256:357d6c9e6a755653cfd78893817c0853af365dd51ec97f3d358a819373bbd174"}, ] @@ -706,34 +720,12 @@ py = [ {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, ] pyasn1 = [ - {file = "pyasn1-0.4.8-py2.4.egg", hash = "sha256:fec3e9d8e36808a28efb59b489e4528c10ad0f480e57dcc32b4de5c9d8c9fdf3"}, - {file = "pyasn1-0.4.8-py2.5.egg", hash = "sha256:0458773cfe65b153891ac249bcf1b5f8f320b7c2ce462151f8fa74de8934becf"}, - {file = "pyasn1-0.4.8-py2.6.egg", hash = "sha256:5c9414dcfede6e441f7e8f81b43b34e834731003427e5b09e4e00e3172a10f00"}, - {file = "pyasn1-0.4.8-py2.7.egg", hash = "sha256:6e7545f1a61025a4e58bb336952c5061697da694db1cae97b116e9c46abcf7c8"}, {file = "pyasn1-0.4.8-py2.py3-none-any.whl", hash = "sha256:39c7e2ec30515947ff4e87fb6f456dfc6e84857d34be479c9d4a4ba4bf46aa5d"}, - {file = "pyasn1-0.4.8-py3.1.egg", hash = "sha256:78fa6da68ed2727915c4767bb386ab32cdba863caa7dbe473eaae45f9959da86"}, - {file = "pyasn1-0.4.8-py3.2.egg", hash = "sha256:08c3c53b75eaa48d71cf8c710312316392ed40899cb34710d092e96745a358b7"}, - {file = "pyasn1-0.4.8-py3.3.egg", hash = "sha256:03840c999ba71680a131cfaee6fab142e1ed9bbd9c693e285cc6aca0d555e576"}, - {file = "pyasn1-0.4.8-py3.4.egg", hash = "sha256:7ab8a544af125fb704feadb008c99a88805126fb525280b2270bb25cc1d78a12"}, - {file = "pyasn1-0.4.8-py3.5.egg", hash = "sha256:e89bf84b5437b532b0803ba5c9a5e054d21fec423a89952a74f87fa2c9b7bce2"}, - {file = "pyasn1-0.4.8-py3.6.egg", hash = "sha256:014c0e9976956a08139dc0712ae195324a75e142284d5f87f1a87ee1b068a359"}, - {file = "pyasn1-0.4.8-py3.7.egg", hash = "sha256:99fcc3c8d804d1bc6d9a099921e39d827026409a58f2a720dcdb89374ea0c776"}, {file = "pyasn1-0.4.8.tar.gz", hash = "sha256:aef77c9fb94a3ac588e87841208bdec464471d9871bd5050a287cc9a475cd0ba"}, ] pyasn1-modules = [ {file = "pyasn1-modules-0.2.8.tar.gz", hash = "sha256:905f84c712230b2c592c19470d3ca8d552de726050d1d1716282a1f6146be65e"}, - {file = "pyasn1_modules-0.2.8-py2.4.egg", hash = "sha256:0fe1b68d1e486a1ed5473f1302bd991c1611d319bba158e98b106ff86e1d7199"}, - {file = "pyasn1_modules-0.2.8-py2.5.egg", hash = "sha256:fe0644d9ab041506b62782e92b06b8c68cca799e1a9636ec398675459e031405"}, - {file = "pyasn1_modules-0.2.8-py2.6.egg", hash = "sha256:a99324196732f53093a84c4369c996713eb8c89d360a496b599fb1a9c47fc3eb"}, - {file = "pyasn1_modules-0.2.8-py2.7.egg", hash = "sha256:0845a5582f6a02bb3e1bde9ecfc4bfcae6ec3210dd270522fee602365430c3f8"}, {file = "pyasn1_modules-0.2.8-py2.py3-none-any.whl", hash = "sha256:a50b808ffeb97cb3601dd25981f6b016cbb3d31fbf57a8b8a87428e6158d0c74"}, - {file = "pyasn1_modules-0.2.8-py3.1.egg", hash = "sha256:f39edd8c4ecaa4556e989147ebf219227e2cd2e8a43c7e7fcb1f1c18c5fd6a3d"}, - {file = "pyasn1_modules-0.2.8-py3.2.egg", hash = "sha256:b80486a6c77252ea3a3e9b1e360bc9cf28eaac41263d173c032581ad2f20fe45"}, - {file = "pyasn1_modules-0.2.8-py3.3.egg", hash = "sha256:65cebbaffc913f4fe9e4808735c95ea22d7a7775646ab690518c056784bc21b4"}, - {file = "pyasn1_modules-0.2.8-py3.4.egg", hash = "sha256:15b7c67fabc7fc240d87fb9aabf999cf82311a6d6fb2c70d00d3d0604878c811"}, - {file = "pyasn1_modules-0.2.8-py3.5.egg", hash = "sha256:426edb7a5e8879f1ec54a1864f16b882c2837bfd06eee62f2c982315ee2473ed"}, - {file = "pyasn1_modules-0.2.8-py3.6.egg", hash = "sha256:cbac4bc38d117f2a49aeedec4407d23e8866ea4ac27ff2cf7fb3e5b570df19e0"}, - {file = "pyasn1_modules-0.2.8-py3.7.egg", hash = "sha256:c29a5e5cc7a3f05926aff34e097e84f8589cd790ce0ed41b67aed6857b26aafd"}, ] pyparsing = [ {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, @@ -770,7 +762,7 @@ python-dateutil = [ {file = "python-dateutil-2.8.2.tar.gz", hash = "sha256:0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86"}, {file = "python_dateutil-2.8.2-py2.py3-none-any.whl", hash = "sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9"}, ] -pyyaml = [ +PyYAML = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, @@ -778,6 +770,13 @@ pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782"}, + {file = "PyYAML-6.0-cp311-cp311-win32.whl", hash = "sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7"}, + {file = "PyYAML-6.0-cp311-cp311-win_amd64.whl", hash = "sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf"}, {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, @@ -821,13 +820,16 @@ s3transfer = [ {file = "s3transfer-0.6.0-py3-none-any.whl", hash = "sha256:06176b74f3a15f61f1b4f25a1fc29a4429040b7647133a463da8fa5bd28d5ecd"}, {file = "s3transfer-0.6.0.tar.gz", hash = "sha256:2ed07d3866f523cc561bf4a00fc5535827981b117dd7876f036b0c1aca42c947"}, ] +setuptools = [ + {file = "setuptools-65.4.1-py3-none-any.whl", hash = "sha256:1b6bdc6161661409c5f21508763dc63ab20a9ac2f8ba20029aaaa7fdb9118012"}, + {file = "setuptools-65.4.1.tar.gz", hash = "sha256:3050e338e5871e70c72983072fe34f6032ae1cdeeeb67338199c2f74e083a80e"}, +] six = [ {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] tabulate = [ {file = "tabulate-0.8.10-py3-none-any.whl", hash = "sha256:0ba055423dbaa164b9e456abe7920c5e8ed33fcc16f6d1b2f2d152c8e1e8b4fc"}, - {file = "tabulate-0.8.10-py3.8.egg", hash = "sha256:436f1c768b424654fce8597290d2764def1eea6a77cfa5c33be00b1bc0f4f63d"}, {file = "tabulate-0.8.10.tar.gz", hash = "sha256:6c57f3f3dd7ac2782770155f3adb2db0b1a269637e42f27599925e64b114f519"}, ] tomli = [ diff --git a/tools/c7n_kube/requirements.txt b/tools/c7n_kube/requirements.txt index 85cb75c650a..ef1ddc41b46 100644 --- a/tools/c7n_kube/requirements.txt +++ b/tools/c7n_kube/requirements.txt @@ -1,17 +1,18 @@ -cachetools==5.2.0; python_version >= "3.7" and python_version < "4.0" and (python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.6.0") -certifi==2022.9.14; python_version >= "3.7" and python_version < "4" -charset-normalizer==2.1.1; python_version >= "3.7" and python_version < "4" and python_full_version >= "3.6.0" -google-auth==2.11.1; python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" -idna==3.4; python_version >= "3.7" and python_version < "4" -kubernetes==10.0.1 -oauthlib==3.2.1; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.6" -pyasn1-modules==0.2.8; python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" -pyasn1==0.4.8; python_version >= "3.6" and python_full_version < "3.0.0" and python_version < "4" and (python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6") or python_version >= "3.6" and python_version < "4" and (python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6") and python_full_version >= "3.6.0" -python-dateutil==2.8.2; python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.3.0" -pyyaml==6.0; python_version >= "3.6" -requests-oauthlib==1.3.1; python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" -requests==2.28.1; python_version >= "3.7" and python_version < "4" and (python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0") -rsa==4.9; python_version >= "3.6" and python_version < "4" and (python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" and python_version >= "3.6") -six==1.16.0; python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.6.0" -urllib3==1.26.12; python_version >= "3.7" and python_full_version < "3.0.0" and python_version < "4" or python_full_version >= "3.6.0" and python_version < "4" and python_version >= "3.7" -websocket-client==1.4.1; python_version >= "3.7" +cachetools==5.2.0 ; python_version >= "3.7" and python_version < "4.0" +certifi==2022.9.24 ; python_version >= "3.7" and python_version < "4.0" +charset-normalizer==2.1.1 ; python_version >= "3.7" and python_version < "4" +google-auth==2.12.0 ; python_version >= "3.7" and python_version < "4.0" +idna==3.4 ; python_version >= "3.7" and python_version < "4" +kubernetes==10.0.1 ; python_version >= "3.7" and python_version < "4.0" +oauthlib==3.2.1 ; python_version >= "3.7" and python_version < "4.0" +pyasn1-modules==0.2.8 ; python_version >= "3.7" and python_version < "4.0" +pyasn1==0.4.8 ; python_version >= "3.7" and python_version < "4.0" +python-dateutil==2.8.2 ; python_version >= "3.7" and python_version < "4.0" +pyyaml==6.0 ; python_version >= "3.7" and python_version < "4.0" +requests-oauthlib==1.3.1 ; python_version >= "3.7" and python_version < "4.0" +requests==2.28.1 ; python_version >= "3.7" and python_version < "4" +rsa==4.9 ; python_version >= "3.7" and python_version < "4" +setuptools==65.4.1 ; python_version >= "3.7" and python_version < "4.0" +six==1.16.0 ; python_version >= "3.7" and python_version < "4.0" +urllib3==1.26.12 ; python_version >= "3.7" and python_version < "4" +websocket-client==1.4.1 ; python_version >= "3.7" and python_version < "4.0" diff --git a/tools/c7n_kube/setup.py b/tools/c7n_kube/setup.py index ea76ff8e3ce..021448f2fb7 100644 --- a/tools/c7n_kube/setup.py +++ b/tools/c7n_kube/setup.py @@ -16,16 +16,16 @@ install_requires = \ ['argcomplete (>=2.0.0,<3.0.0)', 'attrs (>=22.1.0,<23.0.0)', - 'boto3 (>=1.24.77,<2.0.0)', - 'botocore (>=1.27.77,<2.0.0)', + 'boto3 (>=1.24.87,<2.0.0)', + 'botocore (>=1.27.87,<2.0.0)', 'c7n (>=0.9.19,<0.10.0)', 'docutils (>=0.17.1,<0.18.0)', - 'importlib-metadata (>=4.12.0,<5.0.0)', + 'importlib-metadata (>=4.13.0,<5.0.0)', 'importlib-resources (>=5.9.0,<6.0.0)', 'jmespath (>=1.0.1,<2.0.0)', 'jsonschema (>=4.16.0,<5.0.0)', 'kubernetes>=10.0.1,<11.0.0', - 'pkgutil-resolve-name (>=1.3.10,<2.0.0)', + 'pkgutil_resolve_name (>=1.3.10,<2.0.0)', 'pyrsistent (>=0.18.1,<0.19.0)', 'python-dateutil (>=2.8.2,<3.0.0)', 'pyyaml (>=6.0,<7.0)', @@ -49,10 +49,13 @@ 'long_description': '# Custodian Kubernetes Support\n\n\nWork in Progress - Not Ready For Use.\n\n', 'long_description_content_type': 'text/markdown', 'author': 'Cloud Custodian Project', - 'author_email': None, - 'maintainer': None, - 'maintainer_email': None, - 'url': 'https://cloudcustodian.io', + 'author_email': 'cloud-custodian@googlegroups.com', + 'project_urls': { + 'Homepage': 'https://cloudcustodian.io', + 'Documentation': 'https://cloudcustodian.io/docs/', + 'Source': 'https://github.com/cloud-custodian/cloud-custodian', + 'Issue Tracker': 'https://github.com/cloud-custodian/cloud-custodian/issues', + }, 'packages': packages, 'package_data': package_data, 'install_requires': install_requires, diff --git a/tools/c7n_left/README.md b/tools/c7n_left/README.md new file mode 100644 index 00000000000..d8cacdd5f3b --- /dev/null +++ b/tools/c7n_left/README.md @@ -0,0 +1,73 @@ +# Custodian policies for Infrastructure Code + + +This package allows cloud custodian to evaluate policies directly +against infrastructure as code source assets. + +It also provides a separate cli for better command line ux for +source asset evaluation. + +# Install + +We currently only support python 3.10 on mac and linux. We plan to +expand support for additional operating systems and python versions +over time. + + +```shell +pip install c7n_left +``` + +# Usage + +```shell +$ c7n-left run --help + +Usage: c7n-left run [OPTIONS] + + evaluate policies against iac sources + +Options: + --format TEXT + -p, --policy-dir PATH + -d, --directory PATH + -o, --output [cli|github|json] + --output-file FILENAME + --help Show this message and exit. +``` + + +We'll create an empty directory with a policy in it + +```yaml +policies: + - name: test + resource: terraform.aws_s3_bucket + filters: + - server_side_encryption_configuration: absent +``` + +And now we can use it to evaluate a terraform root module + +```shell +$ c7n-left run --policy-dir policies -d root_module +DEBUG:c7n.iac:Loaded 3 resources +Running 1 policies +DEBUG:c7n.iac:Filtered from 3 to 1 terraformresourcemanager +test - terraform.aws_s3_bucket + Failed + File: main.tf:25-28 + 25 resource "aws_s3_bucket" "example_c" { + 26 bucket = "c7n-aws-s3-encryption-audit-test-c" + 27 acl = "private" + 28 } + +Execution complete 0.01 seconds +``` + + +# Outputs + +if your using this in github actions, we have special output mode +for reporting annotations directly into the ui. + diff --git a/tools/c7n_left/c7n_left/cli.py b/tools/c7n_left/c7n_left/cli.py new file mode 100644 index 00000000000..b3d49a11a1c --- /dev/null +++ b/tools/c7n_left/c7n_left/cli.py @@ -0,0 +1,53 @@ +# Copyright The Cloud Custodian Authors. +# SPDX-License-Identifier: Apache-2.0 +# +import logging +from pathlib import Path + +import click +from c7n.config import Config + +from .entry import initialize_iac +from .output import get_reporter, report_outputs +from .core import CollectionRunner +from .utils import load_policies + + +@click.group() +def cli(): + """Shift Left Policy""" + logging.basicConfig(level=logging.DEBUG) + initialize_iac() + + +@cli.command() +@click.option("--format", default="terraform") +@click.option("-p", "--policy-dir", type=click.Path()) +@click.option("-d", "--directory", type=click.Path()) +@click.option("-o", "--output", default="cli", type=click.Choice(report_outputs.keys())) +@click.option("--output-file", type=click.File("w"), default="-") +def run(format, policy_dir, directory, output, output_file): + """evaluate policies against IaC sources. + + WARNING - CLI interface subject to change. + """ + config = Config.empty( + source_dir=Path(directory), + policy_dir=Path(policy_dir), + output=output, + output_file=output_file, + ) + policies = load_policies(policy_dir, config) + reporter = get_reporter(config) + runner = CollectionRunner(policies, config, reporter) + runner.run() + + +if __name__ == "__main__": # pragma: no cover + try: + cli() + except Exception: + import pdb, sys, traceback + + traceback.print_exc() + pdb.post_mortem(sys.exc_info()[-1]) diff --git a/tools/c7n_left/c7n_left/core.py b/tools/c7n_left/c7n_left/core.py new file mode 100644 index 00000000000..2e9d39db5fd --- /dev/null +++ b/tools/c7n_left/c7n_left/core.py @@ -0,0 +1,174 @@ +# Copyright The Cloud Custodian Authors. +# SPDX-License-Identifier: Apache-2.0 +# +import fnmatch +import logging + +from c7n.actions import ActionRegistry +from c7n.cache import NullCache +from c7n.filters import FilterRegistry +from c7n.manager import ResourceManager + +from c7n.provider import Provider, clouds +from c7n.policy import PolicyExecutionMode + + +log = logging.getLogger("c7n.iac") + + +class IACSourceProvider(Provider): + + display_name = "IAC" + + def get_session_factory(self, options): + return lambda *args, **kw: None + + def initialize(self, options): + pass + + def initialize_policies(self, policies, options): + return policies + + +class CollectionRunner: + def __init__(self, policies, options, reporter): + self.policies = policies + self.options = options + self.reporter = reporter + + def run(self): + event = self.get_event() + provider = self.get_provider() + + if not provider.match_dir(self.options.source_dir): + raise NotImplementedError( + "no %s source files found" % provider.provider_name + ) + + graph = provider.parse(self.options.source_dir) + + for p in self.policies: + p.expand_variables(p.get_variables()) + p.validate() + + self.reporter.on_execution_started(self.policies) + # consider inverting this order to allow for results grouped by policy + # at the moment, we're doing results grouped by resource. + for rtype, resources in graph.get_resources_by_type(): + for p in self.policies: + if not self.match_type(rtype, p): + continue + result_set = self.run_policy(p, graph, resources, event) + if result_set: + self.reporter.on_results(result_set) + self.reporter.on_execution_ended() + + def run_policy(self, policy, graph, resources, event): + event = dict(event) + event.update({"graph": graph, "resources": resources}) + return policy.push(event) + + def get_provider(self): + provider_name = {p.provider_name for p in self.policies}.pop() + provider = clouds[provider_name]() + return provider + + def get_event(self): + return {"config": self.options} + + @staticmethod + def match_type(rtype, p): + if isinstance(p.resource_type, str): + return fnmatch.fnmatch(rtype, p.resource_type.split(".", 1)[-1]) + if isinstance(p.resource_type, list): + for pr in p.resource_type: + return fnmatch.fnmatch(rtype, pr.split(".", 1)[-1]) + + +class IACSourceMode(PolicyExecutionMode): + @property + def manager(self): + return self.policy.resource_manager + + def run(self, event, ctx): + if not self.policy.is_runnable(event): + return [] + + resources = event["resources"] + resources = self.manager.filter_resources(resources, event) + return self.as_results(resources) + + def as_results(self, resources): + return ResultSet([PolicyResourceResult(r, self.policy) for r in resources]) + + +class ResultSet(list): + pass + + +class PolicyResourceResult: + def __init__(self, resource, policy): + self.resource = resource + self.policy = policy + + +class IACResourceManager(ResourceManager): + + filter_registry = FilterRegistry("iac.filters") + action_registry = ActionRegistry("iac.actions") + log = log + + def __init__(self, ctx, data): + self.ctx = ctx + self.data = data + self._cache = NullCache(None) + self.session_factory = lambda: None + self.filters = self.filter_registry.parse(self.data.get("filters", []), self) + self.actions = self.action_registry.parse(self.data.get("actions", []), self) + + def get_resource_manager(self, resource_type, data=None): + return self.__class__(self.ctx, data or {}) + + +class IACResourceMap(object): + + resource_class = None + + def __init__(self, prefix): + self.prefix = prefix + + def __contains__(self, k): + if k.startswith(self.prefix): + return True + return False + + def __getitem__(self, k): + if k.startswith(self.prefix): + return self.resource_class + raise KeyError(k) + + def __iter__(self): + return iter(()) + + def notify(self, *args): + pass + + def keys(self): + return () + + def items(self): + return () + + def get(self, k, default=None): + # that the resource is in the map has alerady been verified + # we get the unprefixed resource on get + return self.resource_class + + +class ResourceGraph: + def __init__(self, resource_data, src_dir): + self.resource_data = resource_data + self.src_dir = src_dir + + def get_resource_by_type(self): + raise NotImplementedError() diff --git a/tools/c7n_left/c7n_left/entry.py b/tools/c7n_left/c7n_left/entry.py new file mode 100644 index 00000000000..23ddb397d07 --- /dev/null +++ b/tools/c7n_left/c7n_left/entry.py @@ -0,0 +1,3 @@ +def initialize_iac(): + # import to get side effect registration into clouds + from .providers.terraform import TerraformProvider # noqa diff --git a/tools/c7n_left/c7n_left/output.py b/tools/c7n_left/c7n_left/output.py new file mode 100644 index 00000000000..7c4f6cab83f --- /dev/null +++ b/tools/c7n_left/c7n_left/output.py @@ -0,0 +1,174 @@ +# Copyright The Cloud Custodian Authors. +# SPDX-License-Identifier: Apache-2.0 +# +import json +import time + +from c7n.output import OutputRegistry + +from rich.console import Console +from rich.syntax import Syntax + + +report_outputs = OutputRegistry("left") + + +def get_reporter(config): + for k, v in report_outputs.items(): + if k == config.output: + return v(None, config) + + +class PolicyMetadata: + def __init__(self, policy): + self.policy = policy + + @property + def resource_type(self): + return self.policy.resource_type + + @property + def provider(self): + return self.policy.provider_name + + @property + def name(self): + return self.policy.name + + @property + def description(self): + return self.policy.data.get("description") + + @property + def category(self): + return " ".join(self.policy.data.get("metadata", {}).get("category", [])) + + @property + def severity(self): + return self.policy.data.get("metadata", {}).get("severity", "") + + @property + def title(self): + title = self.policy.data.get("metadata", {}).get("title", "") + if title: + return title + title = f"{self.resource_type} - policy:{self.name}" + if self.category: + title += f"category:{self.category}" + if self.severity: + title += f"severity:{self.severity}" + return title + + +class Output: + def __init__(self, ctx, config): + self.ctx = ctx + self.config = config + + def on_execution_started(self, policies): + pass + + def on_execution_ended(self): + pass + + def on_results(self, results): + pass + + +@report_outputs.register("cli") +class RichCli(Output): + def __init__(self, ctx, config): + super().__init__(ctx, config) + self.console = Console(file=config.output_file) + self.started = None + + def on_execution_started(self, policies): + self.console.print("Running %d policies" % (len(policies),)) + self.started = time.time() + + def on_execution_ended(self): + self.console.print( + "Execution complete %0.2f seconds" % (time.time() - self.started) + ) + + def on_results(self, results): + for r in results: + self.console.print(RichResult(r)) + + +class RichResult: + def __init__(self, policy_resource): + self.policy_resource = policy_resource + + def __rich_console__(self, console, options): + policy = self.policy_resource.policy + resource = self.policy_resource.resource + + yield f"[bold]{policy.name}[/bold] - {policy.resource_type}" + yield " [red]Failed[/red]" + yield f" [purple]File: {resource.filename}:{resource.line_start}-{resource.line_end}" + + lines = resource.get_source_lines() + yield Syntax( + "\n".join(lines), + start_line=resource.line_start, + line_numbers=True, + lexer=resource.format, + ) + yield "" + + +@report_outputs.register("github") +class Github(Output): + + # https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#setting-an-error-message + + "::error file={name},line={line},endLine={endLine},title={title}::{message}" + + def on_results(self, results): + for r in results: + print(self.format_result(r), file=self.config.output_file) + + def format_result(self, result): + resource = result.resource + + md = PolicyMetadata(result.policy) + filename = resource.src_dir / resource.filename + title = md.title + message = md.description or "" + + return f"::error file={filename} line={resource.line_start} lineEnd={resource.line_end} title={title}::{message}" # noqa + + +@report_outputs.register("json") +class Json(Output): + def __init__(self, ctx, config): + super().__init__(ctx, config) + self.results = [] + + def on_results(self, results): + self.results.extend(results) + + def on_execution_ended(self): + formatted_results = [self.format_result(r) for r in self.results] + self.config.output_file.write( + json.dumps({"results": formatted_results}, indent=2) + ) + + def format_result(self, result): + resource = result.resource + + lines = resource.get_source_lines() + line_pairs = [] + index = resource.line_start + for l in lines: + line_pairs.append((index, l)) + index += 1 + + return { + "policy": dict(result.policy.data), + "file_path": str(resource.src_dir / resource.filename), + "file_line_start": resource.line_start, + "file_line_end": resource.line_end, + "code_block": line_pairs, + } diff --git a/tools/c7n_left/c7n_left/providers/terraform/__init__.py b/tools/c7n_left/c7n_left/providers/terraform/__init__.py new file mode 100644 index 00000000000..814230290d4 --- /dev/null +++ b/tools/c7n_left/c7n_left/providers/terraform/__init__.py @@ -0,0 +1,4 @@ +# Copyright The Cloud Custodian Authors. +# SPDX-License-Identifier: Apache-2.0 +# +from .provider import TerraformProvider diff --git a/tools/c7n_left/c7n_left/providers/terraform/graph.py b/tools/c7n_left/c7n_left/providers/terraform/graph.py new file mode 100644 index 00000000000..356a2f5e20d --- /dev/null +++ b/tools/c7n_left/c7n_left/providers/terraform/graph.py @@ -0,0 +1,43 @@ +# Copyright The Cloud Custodian Authors. +# SPDX-License-Identifier: Apache-2.0 +# + +from ...core import ResourceGraph +from .resource import TerraformResource + + +class TerraformGraph(ResourceGraph): + def __len__(self): + return sum(map(len, self.resource_data.values())) + + def get_resources_by_type(self, types=()): + if isinstance(types, str): + types = (types,) + for type_name, type_items in self.resource_data.items(): + if types and type_name not in types: + continue + if type_name == "data": + for data_type, data_items in type_items.items(): + resources = [] + for name, data in data_items.items(): + resources.append(self.as_resource(name, data)) + yield "%s.%s" % (type_name, data_type), resources + elif type_name == "moved": + yield type_name, self.as_resource(type_name, data) + elif type_name == "locals": + yield type_name, self.as_resource(type_name, data) + elif type_name == "terraform": + yield type_name, self.as_resource(type_name, data) + else: + resources = [] + for name, data in type_items.items(): + resources.append(self.as_resource(name, data)) + yield type_name, resources + + def as_resource(self, name, data): + if isinstance(data["__tfmeta"], list): + for m in data["__tfmeta"]: + m["src_dir"] = self.src_dir + else: + data["__tfmeta"]["src_dir"] = self.src_dir + return TerraformResource(name, data) diff --git a/tools/c7n_left/c7n_left/providers/terraform/provider.py b/tools/c7n_left/c7n_left/providers/terraform/provider.py new file mode 100644 index 00000000000..8fb2e586230 --- /dev/null +++ b/tools/c7n_left/c7n_left/providers/terraform/provider.py @@ -0,0 +1,57 @@ +# Copyright The Cloud Custodian Authors. +# SPDX-License-Identifier: Apache-2.0 +# + +from tfparse import load_from_path + +from c7n.provider import clouds +from c7n.policy import execution +from c7n.utils import type_schema + +from ...core import ( + IACResourceManager, + IACResourceMap, + IACSourceProvider, + IACSourceMode, + log, +) +from .graph import TerraformGraph + + +class TerraformResourceManager(IACResourceManager): + pass + + +class TerraformResourceMap(IACResourceMap): + + resource_class = TerraformResourceManager + + +@clouds.register("terraform") +class TerraformProvider(IACSourceProvider): + + display_name = "Terraform" + resource_prefix = "terraform" + resource_map = TerraformResourceMap(resource_prefix) + resources = resource_map + + def initialize_policies(self, policies, options): + for p in policies: + p.data["mode"] = {"type": "terraform-source"} + return policies + + def parse(self, source_dir): + graph = TerraformGraph(load_from_path(source_dir), source_dir) + log.debug("Loaded %d resources", len(graph)) + return graph + + def match_dir(self, source_dir): + files = list(source_dir.glob("*.tf")) + files += list(source_dir.glob("*.tf.json")) + return files + + +@execution.register("terraform-source") +class TerraformSource(IACSourceMode): + + schema = type_schema("terraform-source") diff --git a/tools/c7n_left/c7n_left/providers/terraform/resource.py b/tools/c7n_left/c7n_left/providers/terraform/resource.py new file mode 100644 index 00000000000..cd7a4e88baa --- /dev/null +++ b/tools/c7n_left/c7n_left/providers/terraform/resource.py @@ -0,0 +1,39 @@ +# Copyright The Cloud Custodian Authors. +# SPDX-License-Identifier: Apache-2.0 +# + + +class TerraformResource(dict): + + __slots__ = ("name", "data", "location") + + # pygments lexer + format = "terraform" + + def __init__(self, name, data): + self.name = name + if isinstance(data["__tfmeta"], list): + self.location = data["__tfmeta"][0] + else: + self.location = data["__tfmeta"] + super().__init__(data) + + @property + def filename(self): + return self.location["filename"] + + @property + def line_start(self): + return self.location["line_start"] + + @property + def line_end(self): + return self.location["line_end"] + + @property + def src_dir(self): + return self.location["src_dir"] + + def get_source_lines(self): + lines = (self.src_dir / self.filename).read_text().split("\n") + return lines[self.line_start - 1 : self.line_end] # noqa diff --git a/tools/c7n_left/c7n_left/utils.py b/tools/c7n_left/c7n_left/utils.py new file mode 100644 index 00000000000..2d21ada3ffc --- /dev/null +++ b/tools/c7n_left/c7n_left/utils.py @@ -0,0 +1,18 @@ +# Copyright The Cloud Custodian Authors. +# SPDX-License-Identifier: Apache-2.0 +# + +from c7n.provider import clouds +from c7n.loader import DirectoryLoader + + +def load_policies(policy_dir, options): + + loader = DirectoryLoader(config=options) + policies = loader.load_directory(policy_dir) + providers = {p.provider_name for p in policies} + assert len(providers), "only a single provider per policy dir" + provider_name = providers.pop() + provider = clouds[provider_name]() + p_options = provider.initialize(options) + return provider.initialize_policies(policies, p_options) diff --git a/tools/c7n_left/notes.md b/tools/c7n_left/notes.md new file mode 100644 index 00000000000..66ed488726d --- /dev/null +++ b/tools/c7n_left/notes.md @@ -0,0 +1,41 @@ + + +# core + +- exit code +- ref resolution syntax exploration + - ref resolve function / auto dispatch from value filter +- graph functions instead of resolver? + +# terraform + +- variable count node + +- provider tags /flow +- cloud provider resource map ( tf provider to custodian) + - data sources + - related filters- + - default tag flow + + +# cli + +- hosting providers / env +- policy zip +- policy zip s3 +- include / exclude policies +- list available checks + + + +# providers + +- ms templates +- cfn provider + + +want to be able to execute across multiple policies, auto expland + + + +undo lazy loading / resource loading :/ reflexive match as default dict though \ No newline at end of file diff --git a/tools/c7n_left/poetry.lock b/tools/c7n_left/poetry.lock new file mode 100644 index 00000000000..de34a7a606f --- /dev/null +++ b/tools/c7n_left/poetry.lock @@ -0,0 +1,801 @@ +[[package]] +name = "argcomplete" +version = "2.0.0" +description = "Bash tab completion for argparse" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +importlib-metadata = {version = ">=0.23,<5", markers = "python_version == \"3.7\""} + +[package.extras] +test = ["coverage", "flake8", "pexpect", "wheel"] + +[[package]] +name = "attrs" +version = "22.1.0" +description = "Classes Without Boilerplate" +category = "dev" +optional = false +python-versions = ">=3.5" + +[package.extras] +dev = ["cloudpickle", "coverage[toml] (>=5.0.2)", "furo", "hypothesis", "mypy (>=0.900,!=0.940)", "pre-commit", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "sphinx", "sphinx-notfound-page", "zope.interface"] +docs = ["furo", "sphinx", "sphinx-notfound-page", "zope.interface"] +tests = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "zope.interface"] +tests_no_zope = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins"] + +[[package]] +name = "boto3" +version = "1.24.77" +description = "The AWS SDK for Python" +category = "dev" +optional = false +python-versions = ">= 3.7" + +[package.dependencies] +botocore = ">=1.27.77,<1.28.0" +jmespath = ">=0.7.1,<2.0.0" +s3transfer = ">=0.6.0,<0.7.0" + +[package.extras] +crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] + +[[package]] +name = "botocore" +version = "1.27.77" +description = "Low-level, data-driven core of boto 3." +category = "dev" +optional = false +python-versions = ">= 3.7" + +[package.dependencies] +jmespath = ">=0.7.1,<2.0.0" +python-dateutil = ">=2.1,<3.0.0" +urllib3 = ">=1.25.4,<1.27" + +[package.extras] +crt = ["awscrt (==0.14.0)"] + +[[package]] +name = "c7n" +version = "0.9.19" +description = "Cloud Custodian - Policy Rules Engine" +category = "dev" +optional = false +python-versions = "^3.7" +develop = true + +[package.dependencies] +argcomplete = ">=1.12.3" +boto3 = "^1.12.31" +docutils = ">=0.14,<0.18" +importlib-metadata = ">=4.11.1" +jsonschema = ">=3.0.0" +python-dateutil = "^2.8.2" +pyyaml = ">=5.4.0" +tabulate = "^0.8.6" + +[package.source] +type = "directory" +url = "../.." + +[[package]] +name = "cffi" +version = "1.15.1" +description = "Foreign Function Interface for Python calling C code." +category = "main" +optional = false +python-versions = "*" + +[package.dependencies] +pycparser = "*" + +[[package]] +name = "click" +version = "8.1.3" +description = "Composable command line interface toolkit" +category = "main" +optional = false +python-versions = ">=3.7" + +[package.dependencies] +colorama = {version = "*", markers = "platform_system == \"Windows\""} +importlib-metadata = {version = "*", markers = "python_version < \"3.8\""} + +[[package]] +name = "colorama" +version = "0.4.5" +description = "Cross-platform colored terminal text." +category = "main" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[[package]] +name = "commonmark" +version = "0.9.1" +description = "Python parser for the CommonMark Markdown spec" +category = "main" +optional = false +python-versions = "*" + +[package.extras] +test = ["flake8 (==3.7.8)", "hypothesis (==3.55.3)"] + +[[package]] +name = "docutils" +version = "0.17.1" +description = "Docutils -- Python Documentation Utilities" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[[package]] +name = "execnet" +version = "1.9.0" +description = "execnet: rapid multi-Python deployment" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[package.extras] +testing = ["pre-commit"] + +[[package]] +name = "importlib-metadata" +version = "4.12.0" +description = "Read metadata from Python packages" +category = "main" +optional = false +python-versions = ">=3.7" + +[package.dependencies] +typing-extensions = {version = ">=3.6.4", markers = "python_version < \"3.8\""} +zipp = ">=0.5" + +[package.extras] +docs = ["jaraco.packaging (>=9)", "rst.linker (>=1.9)", "sphinx"] +perf = ["ipython"] +testing = ["flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] + +[[package]] +name = "importlib-resources" +version = "5.9.0" +description = "Read resources from Python packages" +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.dependencies] +zipp = {version = ">=3.1.0", markers = "python_version < \"3.10\""} + +[package.extras] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] + +[[package]] +name = "iniconfig" +version = "1.1.1" +description = "iniconfig: brain-dead simple config-ini parsing" +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "jmespath" +version = "1.0.1" +description = "JSON Matching Expressions" +category = "dev" +optional = false +python-versions = ">=3.7" + +[[package]] +name = "jsonschema" +version = "4.16.0" +description = "An implementation of JSON Schema validation for Python" +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.dependencies] +attrs = ">=17.4.0" +importlib-metadata = {version = "*", markers = "python_version < \"3.8\""} +importlib-resources = {version = ">=1.4.0", markers = "python_version < \"3.9\""} +pkgutil-resolve-name = {version = ">=1.3.10", markers = "python_version < \"3.9\""} +pyrsistent = ">=0.14.0,<0.17.0 || >0.17.0,<0.17.1 || >0.17.1,<0.17.2 || >0.17.2" +typing-extensions = {version = "*", markers = "python_version < \"3.8\""} + +[package.extras] +format = ["fqdn", "idna", "isoduration", "jsonpointer (>1.13)", "rfc3339-validator", "rfc3987", "uri-template", "webcolors (>=1.11)"] +format-nongpl = ["fqdn", "idna", "isoduration", "jsonpointer (>1.13)", "rfc3339-validator", "rfc3986-validator (>0.1.0)", "uri-template", "webcolors (>=1.11)"] + +[[package]] +name = "packaging" +version = "21.3" +description = "Core utilities for Python packages" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +pyparsing = ">=2.0.2,<3.0.5 || >3.0.5" + +[[package]] +name = "pkgutil_resolve_name" +version = "1.3.10" +description = "Resolve a name to an object." +category = "dev" +optional = false +python-versions = ">=3.6" + +[[package]] +name = "pluggy" +version = "1.0.0" +description = "plugin and hook calling mechanisms for python" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +importlib-metadata = {version = ">=0.12", markers = "python_version < \"3.8\""} + +[package.extras] +dev = ["pre-commit", "tox"] +testing = ["pytest", "pytest-benchmark"] + +[[package]] +name = "portalocker" +version = "2.5.1" +description = "Wraps the portalocker recipe for easy usage" +category = "dev" +optional = false +python-versions = ">=3.5" + +[package.dependencies] +pywin32 = {version = ">=226", markers = "platform_system == \"Windows\""} + +[package.extras] +docs = ["sphinx (>=1.7.1)"] +redis = ["redis"] +tests = ["pytest (>=5.4.1)", "pytest-cov (>=2.8.1)", "pytest-mypy (>=0.8.0)", "pytest-timeout (>=2.1.0)", "redis", "sphinx (>=3.0.3)"] + +[[package]] +name = "py" +version = "1.11.0" +description = "library with cross-python path, ini-parsing, io, code, log facilities" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[[package]] +name = "pycparser" +version = "2.21" +description = "C parser in Python" +category = "main" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" + +[[package]] +name = "pygments" +version = "2.13.0" +description = "Pygments is a syntax highlighting package written in Python." +category = "main" +optional = false +python-versions = ">=3.6" + +[package.extras] +plugins = ["importlib-metadata"] + +[[package]] +name = "pyparsing" +version = "3.0.9" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" +category = "dev" +optional = false +python-versions = ">=3.6.8" + +[package.extras] +diagrams = ["jinja2", "railroad-diagrams"] + +[[package]] +name = "pyrsistent" +version = "0.18.1" +description = "Persistent/Functional/Immutable data structures" +category = "dev" +optional = false +python-versions = ">=3.7" + +[[package]] +name = "pytest" +version = "7.1.3" +description = "pytest: simple powerful testing with Python" +category = "dev" +optional = false +python-versions = ">=3.7" + +[package.dependencies] +attrs = ">=19.2.0" +colorama = {version = "*", markers = "sys_platform == \"win32\""} +importlib-metadata = {version = ">=0.12", markers = "python_version < \"3.8\""} +iniconfig = "*" +packaging = "*" +pluggy = ">=0.12,<2.0" +py = ">=1.8.2" +tomli = ">=1.0.0" + +[package.extras] +testing = ["argcomplete", "hypothesis (>=3.56)", "mock", "nose", "pygments (>=2.7.2)", "requests", "xmlschema"] + +[[package]] +name = "pytest-forked" +version = "1.4.0" +description = "run tests in isolated forked subprocesses" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +py = "*" +pytest = ">=3.10" + +[[package]] +name = "pytest-terraform" +version = "0.6.4" +description = "A pytest plugin for using terraform fixtures" +category = "dev" +optional = false +python-versions = ">=3.6,<4.0" + +[package.dependencies] +jmespath = ">=0.10.0" +portalocker = ">=1.7.0" +pytest = ">=6.0" +pytest-xdist = ">=1.31.0" + +[[package]] +name = "pytest-xdist" +version = "2.5.0" +description = "pytest xdist plugin for distributed testing and loop-on-failing modes" +category = "dev" +optional = false +python-versions = ">=3.6" + +[package.dependencies] +execnet = ">=1.1" +pytest = ">=6.2.0" +pytest-forked = "*" + +[package.extras] +psutil = ["psutil (>=3.0)"] +setproctitle = ["setproctitle"] +testing = ["filelock"] + +[[package]] +name = "python-dateutil" +version = "2.8.2" +description = "Extensions to the standard Python datetime module" +category = "dev" +optional = false +python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,>=2.7" + +[package.dependencies] +six = ">=1.5" + +[[package]] +name = "pywin32" +version = "304" +description = "Python for Window Extensions" +category = "dev" +optional = false +python-versions = "*" + +[[package]] +name = "PyYAML" +version = "6.0" +description = "YAML parser and emitter for Python" +category = "dev" +optional = false +python-versions = ">=3.6" + +[[package]] +name = "rich" +version = "12.5.1" +description = "Render rich text, tables, progress bars, syntax highlighting, markdown and more to the terminal" +category = "main" +optional = false +python-versions = ">=3.6.3,<4.0.0" + +[package.dependencies] +commonmark = ">=0.9.0,<0.10.0" +pygments = ">=2.6.0,<3.0.0" +typing-extensions = {version = ">=4.0.0,<5.0", markers = "python_version < \"3.9\""} + +[package.extras] +jupyter = ["ipywidgets (>=7.5.1,<8.0.0)"] + +[[package]] +name = "s3transfer" +version = "0.6.0" +description = "An Amazon S3 Transfer Manager" +category = "dev" +optional = false +python-versions = ">= 3.7" + +[package.dependencies] +botocore = ">=1.12.36,<2.0a.0" + +[package.extras] +crt = ["botocore[crt] (>=1.20.29,<2.0a.0)"] + +[[package]] +name = "six" +version = "1.16.0" +description = "Python 2 and 3 compatibility utilities" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" + +[[package]] +name = "tabulate" +version = "0.8.10" +description = "Pretty-print tabular data" +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" + +[package.extras] +widechars = ["wcwidth"] + +[[package]] +name = "tfparse" +version = "0.1.3" +description = "Python HCL/Terraform parser via extension for AquaSecurity defsec" +category = "main" +optional = false +python-versions = "*" + +[package.dependencies] +cffi = ">=1.0.0" + +[[package]] +name = "tomli" +version = "2.0.1" +description = "A lil' TOML parser" +category = "dev" +optional = false +python-versions = ">=3.7" + +[[package]] +name = "typing-extensions" +version = "4.3.0" +description = "Backported and Experimental Type Hints for Python 3.7+" +category = "main" +optional = false +python-versions = ">=3.7" + +[[package]] +name = "urllib3" +version = "1.26.12" +description = "HTTP library with thread-safe connection pooling, file post, and more." +category = "dev" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*, <4" + +[package.extras] +brotli = ["brotli (>=1.0.9)", "brotlicffi (>=0.8.0)", "brotlipy (>=0.6.0)"] +secure = ["certifi", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "ipaddress", "pyOpenSSL (>=0.14)", "urllib3-secure-extra"] +socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] + +[[package]] +name = "zipp" +version = "3.8.1" +description = "Backport of pathlib-compatible object wrapper for zip files" +category = "main" +optional = false +python-versions = ">=3.7" + +[package.extras] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["func-timeout", "jaraco.itertools", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] + +[metadata] +lock-version = "1.1" +python-versions = "^3.7" +content-hash = "4ce0a33620924a59e61b371fe326efab08e25354018188202bf21b6337370194" + +[metadata.files] +argcomplete = [ + {file = "argcomplete-2.0.0-py2.py3-none-any.whl", hash = "sha256:cffa11ea77999bb0dd27bb25ff6dc142a6796142f68d45b1a26b11f58724561e"}, + {file = "argcomplete-2.0.0.tar.gz", hash = "sha256:6372ad78c89d662035101418ae253668445b391755cfe94ea52f1b9d22425b20"}, +] +attrs = [ + {file = "attrs-22.1.0-py2.py3-none-any.whl", hash = "sha256:86efa402f67bf2df34f51a335487cf46b1ec130d02b8d39fd248abfd30da551c"}, + {file = "attrs-22.1.0.tar.gz", hash = "sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6"}, +] +boto3 = [ + {file = "boto3-1.24.77-py3-none-any.whl", hash = "sha256:fc16e50263c24631d5fe75464e76f3a1b454b4c0015c864948a61691f9702a6e"}, + {file = "boto3-1.24.77.tar.gz", hash = "sha256:16646de3303779d6dc9c192d8a863095244de81d2e0b94f50692fbde767c6f1b"}, +] +botocore = [ + {file = "botocore-1.27.77-py3-none-any.whl", hash = "sha256:d88509ed291b95525205cc06ca87b54d077aae996827039f5e32375949c5aaf7"}, + {file = "botocore-1.27.77.tar.gz", hash = "sha256:77a43e970d0762080b4b79a7e00ea572ef2ae7a9f578c3c8e7f0a344ee4b4e6d"}, +] +c7n = [] +cffi = [ + {file = "cffi-1.15.1-cp27-cp27m-macosx_10_9_x86_64.whl", hash = "sha256:a66d3508133af6e8548451b25058d5812812ec3798c886bf38ed24a98216fab2"}, + {file = "cffi-1.15.1-cp27-cp27m-manylinux1_i686.whl", hash = "sha256:470c103ae716238bbe698d67ad020e1db9d9dba34fa5a899b5e21577e6d52ed2"}, + {file = "cffi-1.15.1-cp27-cp27m-manylinux1_x86_64.whl", hash = "sha256:9ad5db27f9cabae298d151c85cf2bad1d359a1b9c686a275df03385758e2f914"}, + {file = "cffi-1.15.1-cp27-cp27m-win32.whl", hash = "sha256:b3bbeb01c2b273cca1e1e0c5df57f12dce9a4dd331b4fa1635b8bec26350bde3"}, + {file = "cffi-1.15.1-cp27-cp27m-win_amd64.whl", hash = "sha256:e00b098126fd45523dd056d2efba6c5a63b71ffe9f2bbe1a4fe1716e1d0c331e"}, + {file = "cffi-1.15.1-cp27-cp27mu-manylinux1_i686.whl", hash = "sha256:d61f4695e6c866a23a21acab0509af1cdfd2c013cf256bbf5b6b5e2695827162"}, + {file = "cffi-1.15.1-cp27-cp27mu-manylinux1_x86_64.whl", hash = "sha256:ed9cb427ba5504c1dc15ede7d516b84757c3e3d7868ccc85121d9310d27eed0b"}, + {file = "cffi-1.15.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:39d39875251ca8f612b6f33e6b1195af86d1b3e60086068be9cc053aa4376e21"}, + {file = "cffi-1.15.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:285d29981935eb726a4399badae8f0ffdff4f5050eaa6d0cfc3f64b857b77185"}, + {file = "cffi-1.15.1-cp310-cp310-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:3eb6971dcff08619f8d91607cfc726518b6fa2a9eba42856be181c6d0d9515fd"}, + {file = "cffi-1.15.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:21157295583fe8943475029ed5abdcf71eb3911894724e360acff1d61c1d54bc"}, + {file = "cffi-1.15.1-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:5635bd9cb9731e6d4a1132a498dd34f764034a8ce60cef4f5319c0541159392f"}, + {file = "cffi-1.15.1-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:2012c72d854c2d03e45d06ae57f40d78e5770d252f195b93f581acf3ba44496e"}, + {file = "cffi-1.15.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:dd86c085fae2efd48ac91dd7ccffcfc0571387fe1193d33b6394db7ef31fe2a4"}, + {file = "cffi-1.15.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:fa6693661a4c91757f4412306191b6dc88c1703f780c8234035eac011922bc01"}, + {file = "cffi-1.15.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:59c0b02d0a6c384d453fece7566d1c7e6b7bae4fc5874ef2ef46d56776d61c9e"}, + {file = "cffi-1.15.1-cp310-cp310-win32.whl", hash = "sha256:cba9d6b9a7d64d4bd46167096fc9d2f835e25d7e4c121fb2ddfc6528fb0413b2"}, + {file = "cffi-1.15.1-cp310-cp310-win_amd64.whl", hash = "sha256:ce4bcc037df4fc5e3d184794f27bdaab018943698f4ca31630bc7f84a7b69c6d"}, + {file = "cffi-1.15.1-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:3d08afd128ddaa624a48cf2b859afef385b720bb4b43df214f85616922e6a5ac"}, + {file = "cffi-1.15.1-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:3799aecf2e17cf585d977b780ce79ff0dc9b78d799fc694221ce814c2c19db83"}, + {file = "cffi-1.15.1-cp311-cp311-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:a591fe9e525846e4d154205572a029f653ada1a78b93697f3b5a8f1f2bc055b9"}, + {file = "cffi-1.15.1-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:3548db281cd7d2561c9ad9984681c95f7b0e38881201e157833a2342c30d5e8c"}, + {file = "cffi-1.15.1-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:91fc98adde3d7881af9b59ed0294046f3806221863722ba7d8d120c575314325"}, + {file = "cffi-1.15.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:94411f22c3985acaec6f83c6df553f2dbe17b698cc7f8ae751ff2237d96b9e3c"}, + {file = "cffi-1.15.1-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:03425bdae262c76aad70202debd780501fabeaca237cdfddc008987c0e0f59ef"}, + {file = "cffi-1.15.1-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:cc4d65aeeaa04136a12677d3dd0b1c0c94dc43abac5860ab33cceb42b801c1e8"}, + {file = "cffi-1.15.1-cp311-cp311-win32.whl", hash = "sha256:a0f100c8912c114ff53e1202d0078b425bee3649ae34d7b070e9697f93c5d52d"}, + {file = "cffi-1.15.1-cp311-cp311-win_amd64.whl", hash = "sha256:04ed324bda3cda42b9b695d51bb7d54b680b9719cfab04227cdd1e04e5de3104"}, + {file = "cffi-1.15.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:50a74364d85fd319352182ef59c5c790484a336f6db772c1a9231f1c3ed0cbd7"}, + {file = "cffi-1.15.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e263d77ee3dd201c3a142934a086a4450861778baaeeb45db4591ef65550b0a6"}, + {file = "cffi-1.15.1-cp36-cp36m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:cec7d9412a9102bdc577382c3929b337320c4c4c4849f2c5cdd14d7368c5562d"}, + {file = "cffi-1.15.1-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:4289fc34b2f5316fbb762d75362931e351941fa95fa18789191b33fc4cf9504a"}, + {file = "cffi-1.15.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.whl", hash = "sha256:173379135477dc8cac4bc58f45db08ab45d228b3363adb7af79436135d028405"}, + {file = "cffi-1.15.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.whl", hash = "sha256:6975a3fac6bc83c4a65c9f9fcab9e47019a11d3d2cf7f3c0d03431bf145a941e"}, + {file = "cffi-1.15.1-cp36-cp36m-win32.whl", hash = "sha256:2470043b93ff09bf8fb1d46d1cb756ce6132c54826661a32d4e4d132e1977adf"}, + {file = "cffi-1.15.1-cp36-cp36m-win_amd64.whl", hash = "sha256:30d78fbc8ebf9c92c9b7823ee18eb92f2e6ef79b45ac84db507f52fbe3ec4497"}, + {file = "cffi-1.15.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:198caafb44239b60e252492445da556afafc7d1e3ab7a1fb3f0584ef6d742375"}, + {file = "cffi-1.15.1-cp37-cp37m-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:5ef34d190326c3b1f822a5b7a45f6c4535e2f47ed06fec77d3d799c450b2651e"}, + {file = "cffi-1.15.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8102eaf27e1e448db915d08afa8b41d6c7ca7a04b7d73af6514df10a3e74bd82"}, + {file = "cffi-1.15.1-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:5df2768244d19ab7f60546d0c7c63ce1581f7af8b5de3eb3004b9b6fc8a9f84b"}, + {file = "cffi-1.15.1-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:a8c4917bd7ad33e8eb21e9a5bbba979b49d9a97acb3a803092cbc1133e20343c"}, + {file = "cffi-1.15.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:0e2642fe3142e4cc4af0799748233ad6da94c62a8bec3a6648bf8ee68b1c7426"}, + {file = "cffi-1.15.1-cp37-cp37m-win32.whl", hash = "sha256:e229a521186c75c8ad9490854fd8bbdd9a0c9aa3a524326b55be83b54d4e0ad9"}, + {file = "cffi-1.15.1-cp37-cp37m-win_amd64.whl", hash = "sha256:a0b71b1b8fbf2b96e41c4d990244165e2c9be83d54962a9a1d118fd8657d2045"}, + {file = "cffi-1.15.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:320dab6e7cb2eacdf0e658569d2575c4dad258c0fcc794f46215e1e39f90f2c3"}, + {file = "cffi-1.15.1-cp38-cp38-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:1e74c6b51a9ed6589199c787bf5f9875612ca4a8a0785fb2d4a84429badaf22a"}, + {file = "cffi-1.15.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a5c84c68147988265e60416b57fc83425a78058853509c1b0629c180094904a5"}, + {file = "cffi-1.15.1-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3b926aa83d1edb5aa5b427b4053dc420ec295a08e40911296b9eb1b6170f6cca"}, + {file = "cffi-1.15.1-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:87c450779d0914f2861b8526e035c5e6da0a3199d8f1add1a665e1cbc6fc6d02"}, + {file = "cffi-1.15.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4f2c9f67e9821cad2e5f480bc8d83b8742896f1242dba247911072d4fa94c192"}, + {file = "cffi-1.15.1-cp38-cp38-win32.whl", hash = "sha256:8b7ee99e510d7b66cdb6c593f21c043c248537a32e0bedf02e01e9553a172314"}, + {file = "cffi-1.15.1-cp38-cp38-win_amd64.whl", hash = "sha256:00a9ed42e88df81ffae7a8ab6d9356b371399b91dbdf0c3cb1e84c03a13aceb5"}, + {file = "cffi-1.15.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:54a2db7b78338edd780e7ef7f9f6c442500fb0d41a5a4ea24fff1c929d5af585"}, + {file = "cffi-1.15.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:fcd131dd944808b5bdb38e6f5b53013c5aa4f334c5cad0c72742f6eba4b73db0"}, + {file = "cffi-1.15.1-cp39-cp39-manylinux_2_12_i686.manylinux2010_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:7473e861101c9e72452f9bf8acb984947aa1661a7704553a9f6e4baa5ba64415"}, + {file = "cffi-1.15.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6c9a799e985904922a4d207a94eae35c78ebae90e128f0c4e521ce339396be9d"}, + {file = "cffi-1.15.1-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3bcde07039e586f91b45c88f8583ea7cf7a0770df3a1649627bf598332cb6984"}, + {file = "cffi-1.15.1-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:33ab79603146aace82c2427da5ca6e58f2b3f2fb5da893ceac0c42218a40be35"}, + {file = "cffi-1.15.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5d598b938678ebf3c67377cdd45e09d431369c3b1a5b331058c338e201f12b27"}, + {file = "cffi-1.15.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:db0fbb9c62743ce59a9ff687eb5f4afbe77e5e8403d6697f7446e5f609976f76"}, + {file = "cffi-1.15.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:98d85c6a2bef81588d9227dde12db8a7f47f639f4a17c9ae08e773aa9c697bf3"}, + {file = "cffi-1.15.1-cp39-cp39-win32.whl", hash = "sha256:40f4774f5a9d4f5e344f31a32b5096977b5d48560c5592e2f3d2c4374bd543ee"}, + {file = "cffi-1.15.1-cp39-cp39-win_amd64.whl", hash = "sha256:70df4e3b545a17496c9b3f41f5115e69a4f2e77e94e1d2a8e1070bc0c38c8a3c"}, + {file = "cffi-1.15.1.tar.gz", hash = "sha256:d400bfb9a37b1351253cb402671cea7e89bdecc294e8016a707f6d1d8ac934f9"}, +] +click = [ + {file = "click-8.1.3-py3-none-any.whl", hash = "sha256:bb4d8133cb15a609f44e8213d9b391b0809795062913b383c62be0ee95b1db48"}, + {file = "click-8.1.3.tar.gz", hash = "sha256:7682dc8afb30297001674575ea00d1814d808d6a36af415a82bd481d37ba7b8e"}, +] +colorama = [ + {file = "colorama-0.4.5-py2.py3-none-any.whl", hash = "sha256:854bf444933e37f5824ae7bfc1e98d5bce2ebe4160d46b5edf346a89358e99da"}, + {file = "colorama-0.4.5.tar.gz", hash = "sha256:e6c6b4334fc50988a639d9b98aa429a0b57da6e17b9a44f0451f930b6967b7a4"}, +] +commonmark = [ + {file = "commonmark-0.9.1-py2.py3-none-any.whl", hash = "sha256:da2f38c92590f83de410ba1a3cbceafbc74fee9def35f9251ba9a971d6d66fd9"}, + {file = "commonmark-0.9.1.tar.gz", hash = "sha256:452f9dc859be7f06631ddcb328b6919c67984aca654e5fefb3914d54691aed60"}, +] +docutils = [ + {file = "docutils-0.17.1-py2.py3-none-any.whl", hash = "sha256:cf316c8370a737a022b72b56874f6602acf974a37a9fba42ec2876387549fc61"}, + {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, +] +execnet = [ + {file = "execnet-1.9.0-py2.py3-none-any.whl", hash = "sha256:a295f7cc774947aac58dde7fdc85f4aa00c42adf5d8f5468fc630c1acf30a142"}, + {file = "execnet-1.9.0.tar.gz", hash = "sha256:8f694f3ba9cc92cab508b152dcfe322153975c29bda272e2fd7f3f00f36e47c5"}, +] +importlib-metadata = [ + {file = "importlib_metadata-4.12.0-py3-none-any.whl", hash = "sha256:7401a975809ea1fdc658c3aa4f78cc2195a0e019c5cbc4c06122884e9ae80c23"}, + {file = "importlib_metadata-4.12.0.tar.gz", hash = "sha256:637245b8bab2b6502fcbc752cc4b7a6f6243bb02b31c5c26156ad103d3d45670"}, +] +importlib-resources = [ + {file = "importlib_resources-5.9.0-py3-none-any.whl", hash = "sha256:f78a8df21a79bcc30cfd400bdc38f314333de7c0fb619763f6b9dabab8268bb7"}, + {file = "importlib_resources-5.9.0.tar.gz", hash = "sha256:5481e97fb45af8dcf2f798952625591c58fe599d0735d86b10f54de086a61681"}, +] +iniconfig = [ + {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, + {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, +] +jmespath = [ + {file = "jmespath-1.0.1-py3-none-any.whl", hash = "sha256:02e2e4cc71b5bcab88332eebf907519190dd9e6e82107fa7f83b1003a6252980"}, + {file = "jmespath-1.0.1.tar.gz", hash = "sha256:90261b206d6defd58fdd5e85f478bf633a2901798906be2ad389150c5c60edbe"}, +] +jsonschema = [ + {file = "jsonschema-4.16.0-py3-none-any.whl", hash = "sha256:9e74b8f9738d6a946d70705dc692b74b5429cd0960d58e79ffecfc43b2221eb9"}, + {file = "jsonschema-4.16.0.tar.gz", hash = "sha256:165059f076eff6971bae5b742fc029a7b4ef3f9bcf04c14e4776a7605de14b23"}, +] +packaging = [ + {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, + {file = "packaging-21.3.tar.gz", hash = "sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb"}, +] +pkgutil_resolve_name = [ + {file = "pkgutil_resolve_name-1.3.10-py3-none-any.whl", hash = "sha256:ca27cc078d25c5ad71a9de0a7a330146c4e014c2462d9af19c6b828280649c5e"}, + {file = "pkgutil_resolve_name-1.3.10.tar.gz", hash = "sha256:357d6c9e6a755653cfd78893817c0853af365dd51ec97f3d358a819373bbd174"}, +] +pluggy = [ + {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, + {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, +] +portalocker = [ + {file = "portalocker-2.5.1-py2.py3-none-any.whl", hash = "sha256:400bae275366e7b840d4baad0654c6ec5994e07c40c423d78e9e1340279b8352"}, + {file = "portalocker-2.5.1.tar.gz", hash = "sha256:ae8e9cc2660da04bf41fa1a0eef7e300bb5e4a5869adfb1a6d8551632b559b2b"}, +] +py = [ + {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, + {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, +] +pycparser = [ + {file = "pycparser-2.21-py2.py3-none-any.whl", hash = "sha256:8ee45429555515e1f6b185e78100aea234072576aa43ab53aefcae078162fca9"}, + {file = "pycparser-2.21.tar.gz", hash = "sha256:e644fdec12f7872f86c58ff790da456218b10f863970249516d60a5eaca77206"}, +] +pygments = [ + {file = "Pygments-2.13.0-py3-none-any.whl", hash = "sha256:f643f331ab57ba3c9d89212ee4a2dabc6e94f117cf4eefde99a0574720d14c42"}, + {file = "Pygments-2.13.0.tar.gz", hash = "sha256:56a8508ae95f98e2b9bdf93a6be5ae3f7d8af858b43e02c5a2ff083726be40c1"}, +] +pyparsing = [ + {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, + {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, +] +pyrsistent = [ + {file = "pyrsistent-0.18.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:df46c854f490f81210870e509818b729db4488e1f30f2a1ce1698b2295a878d1"}, + {file = "pyrsistent-0.18.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5d45866ececf4a5fff8742c25722da6d4c9e180daa7b405dc0a2a2790d668c26"}, + {file = "pyrsistent-0.18.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:4ed6784ceac462a7d6fcb7e9b663e93b9a6fb373b7f43594f9ff68875788e01e"}, + {file = "pyrsistent-0.18.1-cp310-cp310-win32.whl", hash = "sha256:e4f3149fd5eb9b285d6bfb54d2e5173f6a116fe19172686797c056672689daf6"}, + {file = "pyrsistent-0.18.1-cp310-cp310-win_amd64.whl", hash = "sha256:636ce2dc235046ccd3d8c56a7ad54e99d5c1cd0ef07d9ae847306c91d11b5fec"}, + {file = "pyrsistent-0.18.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:e92a52c166426efbe0d1ec1332ee9119b6d32fc1f0bbfd55d5c1088070e7fc1b"}, + {file = "pyrsistent-0.18.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d7a096646eab884bf8bed965bad63ea327e0d0c38989fc83c5ea7b8a87037bfc"}, + {file = "pyrsistent-0.18.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:cdfd2c361b8a8e5d9499b9082b501c452ade8bbf42aef97ea04854f4a3f43b22"}, + {file = "pyrsistent-0.18.1-cp37-cp37m-win32.whl", hash = "sha256:7ec335fc998faa4febe75cc5268a9eac0478b3f681602c1f27befaf2a1abe1d8"}, + {file = "pyrsistent-0.18.1-cp37-cp37m-win_amd64.whl", hash = "sha256:6455fc599df93d1f60e1c5c4fe471499f08d190d57eca040c0ea182301321286"}, + {file = "pyrsistent-0.18.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:fd8da6d0124efa2f67d86fa70c851022f87c98e205f0594e1fae044e7119a5a6"}, + {file = "pyrsistent-0.18.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7bfe2388663fd18bd8ce7db2c91c7400bf3e1a9e8bd7d63bf7e77d39051b85ec"}, + {file = "pyrsistent-0.18.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:0e3e1fcc45199df76053026a51cc59ab2ea3fc7c094c6627e93b7b44cdae2c8c"}, + {file = "pyrsistent-0.18.1-cp38-cp38-win32.whl", hash = "sha256:b568f35ad53a7b07ed9b1b2bae09eb15cdd671a5ba5d2c66caee40dbf91c68ca"}, + {file = "pyrsistent-0.18.1-cp38-cp38-win_amd64.whl", hash = "sha256:d1b96547410f76078eaf66d282ddca2e4baae8964364abb4f4dcdde855cd123a"}, + {file = "pyrsistent-0.18.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:f87cc2863ef33c709e237d4b5f4502a62a00fab450c9e020892e8e2ede5847f5"}, + {file = "pyrsistent-0.18.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6bc66318fb7ee012071b2792024564973ecc80e9522842eb4e17743604b5e045"}, + {file = "pyrsistent-0.18.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:914474c9f1d93080338ace89cb2acee74f4f666fb0424896fcfb8d86058bf17c"}, + {file = "pyrsistent-0.18.1-cp39-cp39-win32.whl", hash = "sha256:1b34eedd6812bf4d33814fca1b66005805d3640ce53140ab8bbb1e2651b0d9bc"}, + {file = "pyrsistent-0.18.1-cp39-cp39-win_amd64.whl", hash = "sha256:e24a828f57e0c337c8d8bb9f6b12f09dfdf0273da25fda9e314f0b684b415a07"}, + {file = "pyrsistent-0.18.1.tar.gz", hash = "sha256:d4d61f8b993a7255ba714df3aca52700f8125289f84f704cf80916517c46eb96"}, +] +pytest = [ + {file = "pytest-7.1.3-py3-none-any.whl", hash = "sha256:1377bda3466d70b55e3f5cecfa55bb7cfcf219c7964629b967c37cf0bda818b7"}, + {file = "pytest-7.1.3.tar.gz", hash = "sha256:4f365fec2dff9c1162f834d9f18af1ba13062db0c708bf7b946f8a5c76180c39"}, +] +pytest-forked = [ + {file = "pytest-forked-1.4.0.tar.gz", hash = "sha256:8b67587c8f98cbbadfdd804539ed5455b6ed03802203485dd2f53c1422d7440e"}, + {file = "pytest_forked-1.4.0-py3-none-any.whl", hash = "sha256:bbbb6717efc886b9d64537b41fb1497cfaf3c9601276be8da2cccfea5a3c8ad8"}, +] +pytest-terraform = [ + {file = "pytest-terraform-0.6.4.tar.gz", hash = "sha256:5d6c5087c8524fe471f3d31f107e22b05f8ee9c7f6aa5984d953a6559589dff9"}, + {file = "pytest_terraform-0.6.4-py3-none-any.whl", hash = "sha256:713d502d0de2a2889dcefbd5620f113b5bfb797a40cd8409ab663eceefffe283"}, +] +pytest-xdist = [ + {file = "pytest-xdist-2.5.0.tar.gz", hash = "sha256:4580deca3ff04ddb2ac53eba39d76cb5dd5edeac050cb6fbc768b0dd712b4edf"}, + {file = "pytest_xdist-2.5.0-py3-none-any.whl", hash = "sha256:6fe5c74fec98906deb8f2d2b616b5c782022744978e7bd4695d39c8f42d0ce65"}, +] +python-dateutil = [ + {file = "python-dateutil-2.8.2.tar.gz", hash = "sha256:0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86"}, + {file = "python_dateutil-2.8.2-py2.py3-none-any.whl", hash = "sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9"}, +] +pywin32 = [ + {file = "pywin32-304-cp310-cp310-win32.whl", hash = "sha256:3c7bacf5e24298c86314f03fa20e16558a4e4138fc34615d7de4070c23e65af3"}, + {file = "pywin32-304-cp310-cp310-win_amd64.whl", hash = "sha256:4f32145913a2447736dad62495199a8e280a77a0ca662daa2332acf849f0be48"}, + {file = "pywin32-304-cp310-cp310-win_arm64.whl", hash = "sha256:d3ee45adff48e0551d1aa60d2ec066fec006083b791f5c3527c40cd8aefac71f"}, + {file = "pywin32-304-cp311-cp311-win32.whl", hash = "sha256:30c53d6ce44c12a316a06c153ea74152d3b1342610f1b99d40ba2795e5af0269"}, + {file = "pywin32-304-cp311-cp311-win_amd64.whl", hash = "sha256:7ffa0c0fa4ae4077e8b8aa73800540ef8c24530057768c3ac57c609f99a14fd4"}, + {file = "pywin32-304-cp311-cp311-win_arm64.whl", hash = "sha256:cbbe34dad39bdbaa2889a424d28752f1b4971939b14b1bb48cbf0182a3bcfc43"}, + {file = "pywin32-304-cp36-cp36m-win32.whl", hash = "sha256:be253e7b14bc601718f014d2832e4c18a5b023cbe72db826da63df76b77507a1"}, + {file = "pywin32-304-cp36-cp36m-win_amd64.whl", hash = "sha256:de9827c23321dcf43d2f288f09f3b6d772fee11e809015bdae9e69fe13213988"}, + {file = "pywin32-304-cp37-cp37m-win32.whl", hash = "sha256:f64c0377cf01b61bd5e76c25e1480ca8ab3b73f0c4add50538d332afdf8f69c5"}, + {file = "pywin32-304-cp37-cp37m-win_amd64.whl", hash = "sha256:bb2ea2aa81e96eee6a6b79d87e1d1648d3f8b87f9a64499e0b92b30d141e76df"}, + {file = "pywin32-304-cp38-cp38-win32.whl", hash = "sha256:94037b5259701988954931333aafd39cf897e990852115656b014ce72e052e96"}, + {file = "pywin32-304-cp38-cp38-win_amd64.whl", hash = "sha256:ead865a2e179b30fb717831f73cf4373401fc62fbc3455a0889a7ddac848f83e"}, + {file = "pywin32-304-cp39-cp39-win32.whl", hash = "sha256:25746d841201fd9f96b648a248f731c1dec851c9a08b8e33da8b56148e4c65cc"}, + {file = "pywin32-304-cp39-cp39-win_amd64.whl", hash = "sha256:d24a3382f013b21aa24a5cfbfad5a2cd9926610c0affde3e8ab5b3d7dbcf4ac9"}, +] +PyYAML = [ + {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, + {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:a80a78046a72361de73f8f395f1f1e49f956c6be882eed58505a15f3e430962b"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, + {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, + {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782"}, + {file = "PyYAML-6.0-cp311-cp311-win32.whl", hash = "sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7"}, + {file = "PyYAML-6.0-cp311-cp311-win_amd64.whl", hash = "sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf"}, + {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:98c4d36e99714e55cfbaaee6dd5badbc9a1ec339ebfc3b1f52e293aee6bb71a4"}, + {file = "PyYAML-6.0-cp36-cp36m-win32.whl", hash = "sha256:0283c35a6a9fbf047493e3a0ce8d79ef5030852c51e9d911a27badfde0605293"}, + {file = "PyYAML-6.0-cp36-cp36m-win_amd64.whl", hash = "sha256:07751360502caac1c067a8132d150cf3d61339af5691fe9e87803040dbc5db57"}, + {file = "PyYAML-6.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:819b3830a1543db06c4d4b865e70ded25be52a2e0631ccd2f6a47a2822f2fd7c"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:473f9edb243cb1935ab5a084eb238d842fb8f404ed2193a915d1784b5a6b5fc0"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:0ce82d761c532fe4ec3f87fc45688bdd3a4c1dc5e0b4a19814b9009a29baefd4"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:231710d57adfd809ef5d34183b8ed1eeae3f76459c18fb4a0b373ad56bedcdd9"}, + {file = "PyYAML-6.0-cp37-cp37m-win32.whl", hash = "sha256:c5687b8d43cf58545ade1fe3e055f70eac7a5a1a0bf42824308d868289a95737"}, + {file = "PyYAML-6.0-cp37-cp37m-win_amd64.whl", hash = "sha256:d15a181d1ecd0d4270dc32edb46f7cb7733c7c508857278d3d378d14d606db2d"}, + {file = "PyYAML-6.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0b4624f379dab24d3725ffde76559cff63d9ec94e1736b556dacdfebe5ab6d4b"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:213c60cd50106436cc818accf5baa1aba61c0189ff610f64f4a3e8c6726218ba"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:9fa600030013c4de8165339db93d182b9431076eb98eb40ee068700c9c813e34"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:277a0ef2981ca40581a47093e9e2d13b3f1fbbeffae064c1d21bfceba2030287"}, + {file = "PyYAML-6.0-cp38-cp38-win32.whl", hash = "sha256:d4eccecf9adf6fbcc6861a38015c2a64f38b9d94838ac1810a9023a0609e1b78"}, + {file = "PyYAML-6.0-cp38-cp38-win_amd64.whl", hash = "sha256:1e4747bc279b4f613a09eb64bba2ba602d8a6664c6ce6396a4d0cd413a50ce07"}, + {file = "PyYAML-6.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:055d937d65826939cb044fc8c9b08889e8c743fdc6a32b33e2390f66013e449b"}, + {file = "PyYAML-6.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:e61ceaab6f49fb8bdfaa0f92c4b57bcfbea54c09277b1b4f7ac376bfb7a7c174"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d67d839ede4ed1b28a4e8909735fc992a923cdb84e618544973d7dfc71540803"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:cba8c411ef271aa037d7357a2bc8f9ee8b58b9965831d9e51baf703280dc73d3"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:40527857252b61eacd1d9af500c3337ba8deb8fc298940291486c465c8b46ec0"}, + {file = "PyYAML-6.0-cp39-cp39-win32.whl", hash = "sha256:b5b9eccad747aabaaffbc6064800670f0c297e52c12754eb1d976c57e4f74dcb"}, + {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, + {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, +] +rich = [ + {file = "rich-12.5.1-py3-none-any.whl", hash = "sha256:2eb4e6894cde1e017976d2975ac210ef515d7548bc595ba20e195fb9628acdeb"}, + {file = "rich-12.5.1.tar.gz", hash = "sha256:63a5c5ce3673d3d5fbbf23cd87e11ab84b6b451436f1b7f19ec54b6bc36ed7ca"}, +] +s3transfer = [ + {file = "s3transfer-0.6.0-py3-none-any.whl", hash = "sha256:06176b74f3a15f61f1b4f25a1fc29a4429040b7647133a463da8fa5bd28d5ecd"}, + {file = "s3transfer-0.6.0.tar.gz", hash = "sha256:2ed07d3866f523cc561bf4a00fc5535827981b117dd7876f036b0c1aca42c947"}, +] +six = [ + {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, + {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, +] +tabulate = [ + {file = "tabulate-0.8.10-py3-none-any.whl", hash = "sha256:0ba055423dbaa164b9e456abe7920c5e8ed33fcc16f6d1b2f2d152c8e1e8b4fc"}, + {file = "tabulate-0.8.10.tar.gz", hash = "sha256:6c57f3f3dd7ac2782770155f3adb2db0b1a269637e42f27599925e64b114f519"}, +] +tfparse = [ + {file = "tfparse-0.1.3-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f6bd58cac7de1e07f02a9c0eb824b5e7d0963814d966c969fafdc1d1bd7c63d5"}, + {file = "tfparse-0.1.3-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:90dd576bd1b5ac093b78b4041fa54352318b22c425f3ff7c565da8088de0dcbf"}, + {file = "tfparse-0.1.3-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c6e5d9b01b807c96c70ed8b342a46686c0e477266e2479c4cf9b15fe0e58e1ea"}, + {file = "tfparse-0.1.3-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:29d466c3dace725b2b5c7905e8a4f472b51c63abed5426b27b3e3a584fac7819"}, +] +tomli = [ + {file = "tomli-2.0.1-py3-none-any.whl", hash = "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc"}, + {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, +] +typing-extensions = [ + {file = "typing_extensions-4.3.0-py3-none-any.whl", hash = "sha256:25642c956049920a5aa49edcdd6ab1e06d7e5d467fc00e0506c44ac86fbfca02"}, + {file = "typing_extensions-4.3.0.tar.gz", hash = "sha256:e6d2677a32f47fc7eb2795db1dd15c1f34eff616bcaf2cfb5e997f854fa1c4a6"}, +] +urllib3 = [ + {file = "urllib3-1.26.12-py2.py3-none-any.whl", hash = "sha256:b930dd878d5a8afb066a637fbb35144fe7901e3b209d1cd4f524bd0e9deee997"}, + {file = "urllib3-1.26.12.tar.gz", hash = "sha256:3fa96cf423e6987997fc326ae8df396db2a8b7c667747d47ddd8ecba91f4a74e"}, +] +zipp = [ + {file = "zipp-3.8.1-py3-none-any.whl", hash = "sha256:47c40d7fe183a6f21403a199b3e4192cca5774656965b0a4988ad2f8feb5f009"}, + {file = "zipp-3.8.1.tar.gz", hash = "sha256:05b45f1ee8f807d0cc928485ca40a07cb491cf092ff587c0df9cb1fd154848d2"}, +] diff --git a/tools/c7n_left/pyproject.toml b/tools/c7n_left/pyproject.toml new file mode 100644 index 00000000000..860126e5ebc --- /dev/null +++ b/tools/c7n_left/pyproject.toml @@ -0,0 +1,32 @@ +[tool.poetry] +name = "c7n_left" +version = "0.1.0" +description = "Custodian policies for IAAC definitions" +authors = ["Cloud Custodian Project"] +license = "Apache-2" +homepage = "https://cloudcustodian.io" +repository = "https://github.com/cloud-custodian/cloud-custodian" +documentation = "https://cloudcustodian.io/docs/" +classifiers = [ + "License :: OSI Approved :: Apache Software License", + "Topic :: System :: Systems Administration", + "Topic :: System :: Distributed Computing" +] + +[tool.poetry.scripts] +c7n-left = 'c7n_left.cli:cli' + +[tool.poetry.dependencies] +python = "^3.7" +click = ">=8.0" +rich = "^12.5" +tfparse = "^0.1" + +[tool.poetry.dev-dependencies] +pytest = "^7.1.3" +pytest-terraform = "^0.6.4" +c7n = {path = "../..", develop = true} + +[build-system] +requires = ["poetry-core>=1.0.0"] +build-backend = "poetry.core.masonry.api" diff --git a/tools/c7n_left/tests/conftest.py b/tools/c7n_left/tests/conftest.py new file mode 100644 index 00000000000..71782cd0c1f --- /dev/null +++ b/tools/c7n_left/tests/conftest.py @@ -0,0 +1,9 @@ +import pytest + +from c7n.testing import PyTestUtils + + +@pytest.fixture(scope="function") +def test(request): + test_utils = PyTestUtils(request) + return test_utils diff --git a/tools/c7n_left/tests/test_left.py b/tools/c7n_left/tests/test_left.py new file mode 100644 index 00000000000..2a394a3aed2 --- /dev/null +++ b/tools/c7n_left/tests/test_left.py @@ -0,0 +1,189 @@ +# Copyright The Cloud Custodian Authors. +# SPDX-License-Identifier: Apache-2.0 +# +import json +import os +import pytest +from pathlib import Path + +from click.testing import CliRunner + +from c7n.config import Config +from c7n.resources import load_resources + +try: + from c7n_left import cli, utils + from c7n_left.providers.terraform import TerraformProvider + + LEFT_INSTALLED = True +except ImportError: + pytest.skip(reason="c7n_left not installed", allow_module_level=True) + LEFT_INSTALLED = False +else: + load_resources(("terraform.*",)) + +cur_dir = Path(os.curdir).absolute() +terraform_dir = Path(__file__).parent.parent.parent.parent / "tests" / "terraform" +terraform_dir = terraform_dir.relative_to(cur_dir) + + +def test_load_policy(test): + test.load_policy( + {"name": "check1", "resource": "terraform.aws_s3_bucket"}, validate=True + ) + test.load_policy( + {"name": "check2", "resource": ["terraform.aws_s3_bucket"]}, validate=True + ) + test.load_policy({"name": "check3", "resource": ["terraform.aws_*"]}, validate=True) + + +def test_load_policy_dir(tmp_path): + write_output_test_policy(tmp_path) + policies = utils.load_policies(tmp_path, Config.empty()) + assert len(policies) == 1 + + +def test_provider_parse(): + graph = TerraformProvider().parse(terraform_dir / "ec2_stop_protection_disabled") + resource_types = list(graph.get_resources_by_type("aws_subnet")) + rtype, resources = resource_types.pop() + assert rtype == "aws_subnet" + assert resources[0]["__tfmeta"] == { + "filename": "network.tf", + "line_start": 5, + "line_end": 8, + "src_dir": Path("tests") / "terraform" / "ec2_stop_protection_disabled", + } + + +def test_multi_resource_policy(tmp_path): + (tmp_path / "policy.json").write_text( + json.dumps( + { + "policies": [ + { + "name": "check-wild", + "resource": "terraform.aws_*", + } + ] + } + ) + ) + runner = CliRunner() + result = runner.invoke( + cli.cli, + [ + "run", + "-p", + str(tmp_path), + "-d", + str(terraform_dir / "aws_lambda_check_permissions"), + "-o", + "json", + "--output-file", + str(tmp_path / "output.json"), + ], + ) + assert result.exit_code == 0 + data = json.loads((tmp_path / "output.json").read_text()) + assert len(data["results"]) == 2 + + +def write_output_test_policy(tmp_path): + (tmp_path / "policy.json").write_text( + json.dumps( + { + "policies": [ + { + "name": "check-bucket", + "resource": "terraform.aws_s3_bucket", + "filters": [{"server_side_encryption_configuration": "absent"}], + } + ] + } + ) + ) + + +def test_cli_output_rich(tmp_path): + write_output_test_policy(tmp_path) + runner = CliRunner() + result = runner.invoke( + cli.cli, + [ + "run", + "-p", + str(tmp_path), + "-d", + str(terraform_dir / "aws_s3_encryption_audit"), + "-o", + "cli", + ], + ) + assert result.exit_code == 0 + + +def test_cli_output_github(tmp_path): + write_output_test_policy(tmp_path) + + runner = CliRunner() + result = runner.invoke( + cli.cli, + [ + "run", + "-p", + str(tmp_path), + "-d", + str(terraform_dir / "aws_s3_encryption_audit"), + "-o", + "github", + ], + ) + assert result.exit_code == 0 + assert result.output == ( + "::error file=tests/terraform/aws_s3_encryption_audit/main.tf line=25 lineEnd=28" + " title=terraform.aws_s3_bucket - policy:check-bucket::\n" + ) + + +def test_cli_output_json(tmp_path): + write_output_test_policy(tmp_path) + + runner = CliRunner() + result = runner.invoke( + cli.cli, + [ + "run", + "-p", + str(tmp_path), + "-d", + str(terraform_dir / "aws_s3_encryption_audit"), + "-o", + "json", + "--output-file", + str(tmp_path / "output.json"), + ], + ) + assert result.exit_code == 0 + + results = json.loads((tmp_path / "output.json").read_text()) + assert "results" in results + assert results["results"] == [ + { + "code_block": [ + [25, 'resource "aws_s3_bucket" "example_c" {'], + [26, " bucket = " '"c7n-aws-s3-encryption-audit-test-c"'], + [27, ' acl = "private"'], + [28, "}"], + ], + "file_line_end": 28, + "file_line_start": 25, + "file_path": "tests/terraform/aws_s3_encryption_audit/main.tf", + "policy": { + "filters": [{"server_side_encryption_configuration": "absent"}], + "mode": {"type": "terraform-source"}, + "name": "check-bucket", + "resource": "terraform.aws_s3_bucket", + }, + } + ] diff --git a/tools/c7n_logexporter/poetry.lock b/tools/c7n_logexporter/poetry.lock index 945f8dbe773..50e58162287 100644 --- a/tools/c7n_logexporter/poetry.lock +++ b/tools/c7n_logexporter/poetry.lock @@ -21,21 +21,21 @@ optional = false python-versions = ">=3.5" [package.extras] -dev = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "furo", "sphinx", "sphinx-notfound-page", "pre-commit", "cloudpickle"] -docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] -tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] -tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "cloudpickle"] +dev = ["cloudpickle", "coverage[toml] (>=5.0.2)", "furo", "hypothesis", "mypy (>=0.900,!=0.940)", "pre-commit", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "sphinx", "sphinx-notfound-page", "zope.interface"] +docs = ["furo", "sphinx", "sphinx-notfound-page", "zope.interface"] +tests = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "zope.interface"] +tests_no_zope = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins"] [[package]] name = "boto3" -version = "1.24.77" +version = "1.24.87" description = "The AWS SDK for Python" category = "dev" optional = false python-versions = ">= 3.7" [package.dependencies] -botocore = ">=1.27.77,<1.28.0" +botocore = ">=1.27.87,<1.28.0" jmespath = ">=0.7.1,<2.0.0" s3transfer = ">=0.6.0,<0.7.0" @@ -44,7 +44,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "botocore" -version = "1.27.77" +version = "1.27.87" description = "Low-level, data-driven core of boto 3." category = "dev" optional = false @@ -111,7 +111,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" [[package]] name = "importlib-metadata" -version = "4.12.0" +version = "4.13.0" description = "Read metadata from Python packages" category = "main" optional = false @@ -122,9 +122,9 @@ typing-extensions = {version = ">=3.6.4", markers = "python_version < \"3.8\""} zipp = ">=0.5" [package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)"] perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.3)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] +testing = ["flake8 (<5)", "flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] [[package]] name = "importlib-resources" @@ -138,8 +138,8 @@ python-versions = ">=3.7" zipp = {version = ">=3.1.0", markers = "python_version < \"3.10\""} [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [[package]] name = "jmespath" @@ -170,7 +170,7 @@ format = ["fqdn", "idna", "isoduration", "jsonpointer (>1.13)", "rfc3339-validat format-nongpl = ["fqdn", "idna", "isoduration", "jsonpointer (>1.13)", "rfc3339-validator", "rfc3986-validator (>0.1.0)", "uri-template", "webcolors (>=1.11)"] [[package]] -name = "pkgutil-resolve-name" +name = "pkgutil_resolve_name" version = "1.3.10" description = "Resolve a name to an object." category = "dev" @@ -197,7 +197,7 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,>=2.7" six = ">=1.5" [[package]] -name = "pyyaml" +name = "PyYAML" version = "6.0" description = "YAML parser and emitter for Python" category = "dev" @@ -254,8 +254,8 @@ optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*, <4" [package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "urllib3-secure-extra", "ipaddress"] +brotli = ["brotli (>=1.0.9)", "brotlicffi (>=0.8.0)", "brotlipy (>=0.6.0)"] +secure = ["certifi", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "ipaddress", "pyOpenSSL (>=0.14)", "urllib3-secure-extra"] socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] [[package]] @@ -267,8 +267,8 @@ optional = false python-versions = ">=3.7" [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "func-timeout", "jaraco.itertools", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["func-timeout", "jaraco.itertools", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [metadata] lock-version = "1.1" @@ -285,12 +285,12 @@ attrs = [ {file = "attrs-22.1.0.tar.gz", hash = "sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6"}, ] boto3 = [ - {file = "boto3-1.24.77-py3-none-any.whl", hash = "sha256:fc16e50263c24631d5fe75464e76f3a1b454b4c0015c864948a61691f9702a6e"}, - {file = "boto3-1.24.77.tar.gz", hash = "sha256:16646de3303779d6dc9c192d8a863095244de81d2e0b94f50692fbde767c6f1b"}, + {file = "boto3-1.24.87-py3-none-any.whl", hash = "sha256:bcc579e801774cb2c7dda87ff985feda1ae7e10591d11ef37526363139138bd4"}, + {file = "boto3-1.24.87.tar.gz", hash = "sha256:3dd7ed74d1d29dd8094a078be86ed61c45de6638fe18856f7a1ff9282b4d929e"}, ] botocore = [ - {file = "botocore-1.27.77-py3-none-any.whl", hash = "sha256:d88509ed291b95525205cc06ca87b54d077aae996827039f5e32375949c5aaf7"}, - {file = "botocore-1.27.77.tar.gz", hash = "sha256:77a43e970d0762080b4b79a7e00ea572ef2ae7a9f578c3c8e7f0a344ee4b4e6d"}, + {file = "botocore-1.27.87-py3-none-any.whl", hash = "sha256:c4cbd22056ace4c7aa99e62e8ae629865ab80cc8bbf7c6d68ccf0f768f0034b6"}, + {file = "botocore-1.27.87.tar.gz", hash = "sha256:216de9751116d0d1cc3901e26d95a5c9a30ecb6973ae6147af1cf504858d845a"}, ] c7n = [] click = [ @@ -306,8 +306,8 @@ docutils = [ {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, ] importlib-metadata = [ - {file = "importlib_metadata-4.12.0-py3-none-any.whl", hash = "sha256:7401a975809ea1fdc658c3aa4f78cc2195a0e019c5cbc4c06122884e9ae80c23"}, - {file = "importlib_metadata-4.12.0.tar.gz", hash = "sha256:637245b8bab2b6502fcbc752cc4b7a6f6243bb02b31c5c26156ad103d3d45670"}, + {file = "importlib_metadata-4.13.0-py3-none-any.whl", hash = "sha256:8a8a81bcf996e74fee46f0d16bd3eaa382a7eb20fd82445c3ad11f4090334116"}, + {file = "importlib_metadata-4.13.0.tar.gz", hash = "sha256:dd0173e8f150d6815e098fd354f6414b0f079af4644ddfe90c71e2fc6174346d"}, ] importlib-resources = [ {file = "importlib_resources-5.9.0-py3-none-any.whl", hash = "sha256:f78a8df21a79bcc30cfd400bdc38f314333de7c0fb619763f6b9dabab8268bb7"}, @@ -321,7 +321,7 @@ jsonschema = [ {file = "jsonschema-4.16.0-py3-none-any.whl", hash = "sha256:9e74b8f9738d6a946d70705dc692b74b5429cd0960d58e79ffecfc43b2221eb9"}, {file = "jsonschema-4.16.0.tar.gz", hash = "sha256:165059f076eff6971bae5b742fc029a7b4ef3f9bcf04c14e4776a7605de14b23"}, ] -pkgutil-resolve-name = [ +pkgutil_resolve_name = [ {file = "pkgutil_resolve_name-1.3.10-py3-none-any.whl", hash = "sha256:ca27cc078d25c5ad71a9de0a7a330146c4e014c2462d9af19c6b828280649c5e"}, {file = "pkgutil_resolve_name-1.3.10.tar.gz", hash = "sha256:357d6c9e6a755653cfd78893817c0853af365dd51ec97f3d358a819373bbd174"}, ] @@ -352,7 +352,7 @@ python-dateutil = [ {file = "python-dateutil-2.8.2.tar.gz", hash = "sha256:0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86"}, {file = "python_dateutil-2.8.2-py2.py3-none-any.whl", hash = "sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9"}, ] -pyyaml = [ +PyYAML = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, @@ -360,6 +360,13 @@ pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782"}, + {file = "PyYAML-6.0-cp311-cp311-win32.whl", hash = "sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7"}, + {file = "PyYAML-6.0-cp311-cp311-win_amd64.whl", hash = "sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf"}, {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, @@ -397,7 +404,6 @@ six = [ ] tabulate = [ {file = "tabulate-0.8.10-py3-none-any.whl", hash = "sha256:0ba055423dbaa164b9e456abe7920c5e8ed33fcc16f6d1b2f2d152c8e1e8b4fc"}, - {file = "tabulate-0.8.10-py3.8.egg", hash = "sha256:436f1c768b424654fce8597290d2764def1eea6a77cfa5c33be00b1bc0f4f63d"}, {file = "tabulate-0.8.10.tar.gz", hash = "sha256:6c57f3f3dd7ac2782770155f3adb2db0b1a269637e42f27599925e64b114f519"}, ] typing-extensions = [ diff --git a/tools/c7n_logexporter/requirements.txt b/tools/c7n_logexporter/requirements.txt index 5c3125c119c..4b53288a517 100644 --- a/tools/c7n_logexporter/requirements.txt +++ b/tools/c7n_logexporter/requirements.txt @@ -1,5 +1,5 @@ -click==8.1.3; python_version >= "3.7" -colorama==0.4.5; python_version >= "3.7" and python_full_version < "3.0.0" and platform_system == "Windows" or platform_system == "Windows" and python_version >= "3.7" and python_full_version >= "3.5.0" -importlib-metadata==4.12.0; python_version < "3.8" and python_version >= "3.7" -typing-extensions==4.3.0; python_version < "3.8" and python_version >= "3.7" -zipp==3.8.1; python_version < "3.8" and python_version >= "3.7" +click==8.1.3 ; python_version >= "3.7" and python_version < "4.0" +colorama==0.4.5 ; python_version >= "3.7" and python_version < "4.0" and platform_system == "Windows" +importlib-metadata==4.13.0 ; python_version >= "3.7" and python_version < "3.8" +typing-extensions==4.3.0 ; python_version >= "3.7" and python_version < "3.8" +zipp==3.8.1 ; python_version >= "3.7" and python_version < "3.8" diff --git a/tools/c7n_logexporter/setup.py b/tools/c7n_logexporter/setup.py index 824d83fe89b..1005878b76c 100644 --- a/tools/c7n_logexporter/setup.py +++ b/tools/c7n_logexporter/setup.py @@ -12,16 +12,16 @@ install_requires = \ ['argcomplete (>=2.0.0,<3.0.0)', 'attrs (>=22.1.0,<23.0.0)', - 'boto3 (>=1.24.77,<2.0.0)', - 'botocore (>=1.27.77,<2.0.0)', + 'boto3 (>=1.24.87,<2.0.0)', + 'botocore (>=1.27.87,<2.0.0)', 'c7n (>=0.9.19,<0.10.0)', 'click>=8.0,<9.0', 'docutils (>=0.17.1,<0.18.0)', - 'importlib-metadata (>=4.12.0,<5.0.0)', + 'importlib-metadata (>=4.13.0,<5.0.0)', 'importlib-resources (>=5.9.0,<6.0.0)', 'jmespath (>=1.0.1,<2.0.0)', 'jsonschema (>=4.16.0,<5.0.0)', - 'pkgutil-resolve-name (>=1.3.10,<2.0.0)', + 'pkgutil_resolve_name (>=1.3.10,<2.0.0)', 'pyrsistent (>=0.18.1,<0.19.0)', 'python-dateutil (>=2.8.2,<3.0.0)', 'pyyaml (>=6.0,<7.0)', @@ -48,10 +48,13 @@ 'long_description': '# c7n-log-exporter: Cloud watch log exporter automation\n\nA small serverless app to archive cloud logs across accounts to an archive bucket. It utilizes\ncloud log export to s3 feature for historical exports.\n\nIt also supports kinesis streams / firehose to move to realtime exports in the same format\nas the periodic historical exports.\n\n\n## Features\n\n - Log group filtering by regex\n - Incremental support based on previously synced dates\n - Incremental support based on last log group write time\n - Cross account via sts role assume\n - Lambda and CLI support.\n - Day based log segmentation (output keys look\n like $prefix/$account_id/$group/$year/$month/$day/$export_task_uuid/$stream/$log)\n \n\n## Assumptions\n\n - The archive bucket has already has appropriate bucket policy permissions.\n For details see:\n https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/S3ExportTasks.html#S3Permissions\n - Default periodicity for log group archival into s3 is daily.\n - Exporter is run with account credentials that have access to the archive s3 bucket.\n - Catch up archiving is not run in lambda (do a cli run first)\n\n\n## Cli usage\n\n```\nmake install\n```\n\nYou can run on a single account / log group via the export subcommand\n```\nc7n-log-exporter export --help\n```\n\n## Config format\n\nTo ease usage when running across multiple accounts, a config file can be specified, as\nan example.\n\n### Using S3 Bucket as destination\n\n```\ndestination:\n bucket: custodian-log-archive\n prefix: logs2\n\naccounts:\n - name: custodian-demo\n role: "arn:aws:iam::111111111111:role/CloudCustodianRole"\n groups:\n - "/aws/lambda/*"\n - "vpc-flow-logs"\n```\n\n### Using CloudWatch Destination as destination cross account\nThe Cloudwatch Destination needs setup in account and access policy set on CloudWatch Destination to to allow \nsource account access to the Cloudwatch Destination\n\n```\nsubscription:\n destination-arn: "arn:aws:logs:us-east-1:111111111111:destination:CustodianCWLogsDestination"\n destination-role: "arn:aws:iam::111111111111:role/CWLtoKinesisRole"\n name: "CustodianCWLogsDestination"\n\ndestination:\n bucket: custodian-log-archive\n prefix: logs2\n\naccounts:\n - name: custodian-demo\n # https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CreateSubscriptionFilter-IAMrole.html\n subscription-role: "arn:aws:iam::111111111111:role/"\n role: "arn:aws:iam::111111111111:role/CloudCustodianRole"\n groups:\n - "/aws/lambda/*"\n - "vpc-flow-logs"\n```\n\n## Multiple accounts via cli\n\nTo run on the cli across multiple accounts, edit the config.yml to specify multiple\naccounts and log groups.\n\n```\nc7n-log-exporter run --config config.yml\n```\n\n## Serverless Usage\n\nEdit config.yml to specify the accounts, archive bucket, and log groups you want to\nuse.\n\n```\nmake install\nmake deploy\n```\n\n', 'long_description_content_type': 'text/markdown', 'author': 'Cloud Custodian Project', - 'author_email': None, - 'maintainer': None, - 'maintainer_email': None, - 'url': 'https://cloudcustodian.io', + 'author_email': 'cloud-custodian@googlegroups.com', + 'project_urls': { + 'Homepage': 'https://cloudcustodian.io', + 'Documentation': 'https://cloudcustodian.io/docs/', + 'Source': 'https://github.com/cloud-custodian/cloud-custodian', + 'Issue Tracker': 'https://github.com/cloud-custodian/cloud-custodian/issues', + }, 'packages': packages, 'package_data': package_data, 'install_requires': install_requires, diff --git a/tools/c7n_mailer/poetry.lock b/tools/c7n_mailer/poetry.lock index 6f33c3900d3..c5bca3c51f5 100644 --- a/tools/c7n_mailer/poetry.lock +++ b/tools/c7n_mailer/poetry.lock @@ -37,14 +37,14 @@ uvloop = ["uvloop (>=0.15.2)"] [[package]] name = "boto3" -version = "1.24.79" +version = "1.24.87" description = "The AWS SDK for Python" category = "main" optional = false python-versions = ">= 3.7" [package.dependencies] -botocore = ">=1.27.79,<1.28.0" +botocore = ">=1.27.87,<1.28.0" jmespath = ">=0.7.1,<2.0.0" s3transfer = ">=0.6.0,<0.7.0" @@ -53,7 +53,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "botocore" -version = "1.27.79" +version = "1.27.87" description = "Low-level, data-driven core of boto 3." category = "main" optional = false @@ -77,7 +77,7 @@ python-versions = "~=3.7" [[package]] name = "certifi" -version = "2022.9.14" +version = "2022.9.24" description = "Python package for providing Mozilla's CA Bundle." category = "main" optional = false @@ -174,7 +174,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" [[package]] name = "fakeredis" -version = "1.9.1" +version = "1.9.3" description = "Fake implementation of redis API for testing purposes." category = "dev" optional = false @@ -182,7 +182,6 @@ python-versions = ">=3.7,<4.0" [package.dependencies] redis = "<4.4" -six = ">=1.16.0,<2.0.0" sortedcontainers = ">=2.4.0,<3.0.0" [package.extras] @@ -212,7 +211,7 @@ grpcio-gcp = ["grpcio-gcp (>=0.2.2,<1.0dev)"] [[package]] name = "google-auth" -version = "2.11.1" +version = "2.12.0" description = "Google Authentication Library" category = "main" optional = false @@ -232,7 +231,7 @@ reauth = ["pyu2f (>=0.1.5)"] [[package]] name = "google-cloud-secret-manager" -version = "2.12.4" +version = "2.12.5" description = "Secret Manager API API client library" category = "main" optional = false @@ -242,7 +241,7 @@ python-versions = ">=3.7" google-api-core = {version = ">=1.32.0,<2.0.0 || >=2.8.0,<3.0.0dev", extras = ["grpc"]} grpc-google-iam-v1 = ">=0.12.4,<1.0.0dev" proto-plus = ">=1.22.0,<2.0.0dev" -protobuf = ">=3.19.0,<5.0.0dev" +protobuf = ">=3.20.2,<5.0.0dev" [package.extras] libcst = ["libcst (>=0.2.5)"] @@ -280,7 +279,7 @@ version = "1.49.1" description = "HTTP/2-based RPC framework" category = "main" optional = false -python-versions = ">=3.6" +python-versions = ">=3.7" [package.dependencies] six = ">=1.5.2" @@ -311,7 +310,7 @@ python-versions = ">=3.5" [[package]] name = "importlib-metadata" -version = "4.12.0" +version = "4.13.0" description = "Read metadata from Python packages" category = "main" optional = false @@ -322,9 +321,9 @@ typing-extensions = {version = ">=3.6.4", markers = "python_version < \"3.8\""} zipp = ">=0.5" [package.extras] -docs = ["jaraco.packaging (>=9)", "rst.linker (>=1.9)", "sphinx"] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)"] perf = ["ipython"] -testing = ["flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] +testing = ["flake8 (<5)", "flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] [[package]] name = "importlib-resources" @@ -615,7 +614,7 @@ testing = ["google-api-core[grpc] (>=1.31.5)"] [[package]] name = "protobuf" -version = "4.21.6" +version = "4.21.7" description = "" category = "main" optional = false @@ -877,7 +876,7 @@ python-versions = ">=3.6" [[package]] name = "types-six" -version = "1.16.19" +version = "1.16.21" description = "Typing stubs for six" category = "main" optional = false @@ -952,20 +951,20 @@ black = [ {file = "black-22.8.0.tar.gz", hash = "sha256:792f7eb540ba9a17e8656538701d3eb1afcb134e3b45b71f20b25c77a8db7e6e"}, ] boto3 = [ - {file = "boto3-1.24.79-py3-none-any.whl", hash = "sha256:c05f82633b086a7aa6dba9edec56ba8137835d6eb2bfca98bedb32d93eb657a9"}, - {file = "boto3-1.24.79.tar.gz", hash = "sha256:973a23d629a7aed77a662fcd55505c210bc48642cddfc64a1a9f3dbd18468d19"}, + {file = "boto3-1.24.87-py3-none-any.whl", hash = "sha256:bcc579e801774cb2c7dda87ff985feda1ae7e10591d11ef37526363139138bd4"}, + {file = "boto3-1.24.87.tar.gz", hash = "sha256:3dd7ed74d1d29dd8094a078be86ed61c45de6638fe18856f7a1ff9282b4d929e"}, ] botocore = [ - {file = "botocore-1.27.79-py3-none-any.whl", hash = "sha256:10be90eb6ece83fc915b1bb15d2561a0ecefd33a7c1612a8f78da006f99d58f0"}, - {file = "botocore-1.27.79.tar.gz", hash = "sha256:1187a685f0205b8acdde873fc3b081b036bed9104c91e9702b176e7b76ea63d0"}, + {file = "botocore-1.27.87-py3-none-any.whl", hash = "sha256:c4cbd22056ace4c7aa99e62e8ae629865ab80cc8bbf7c6d68ccf0f768f0034b6"}, + {file = "botocore-1.27.87.tar.gz", hash = "sha256:216de9751116d0d1cc3901e26d95a5c9a30ecb6973ae6147af1cf504858d845a"}, ] cachetools = [ {file = "cachetools-5.2.0-py3-none-any.whl", hash = "sha256:f9f17d2aec496a9aa6b76f53e3b614c965223c061982d434d160f930c698a9db"}, {file = "cachetools-5.2.0.tar.gz", hash = "sha256:6a94c6402995a99c3970cc7e4884bb60b4a8639938157eeed436098bf9831757"}, ] certifi = [ - {file = "certifi-2022.9.14-py3-none-any.whl", hash = "sha256:e232343de1ab72c2aa521b625c80f699e356830fd0e2c620b465b304b17b0516"}, - {file = "certifi-2022.9.14.tar.gz", hash = "sha256:36973885b9542e6bd01dea287b2b4b3b21236307c56324fcc3f1160f2d655ed5"}, + {file = "certifi-2022.9.24-py3-none-any.whl", hash = "sha256:90c1a32f1d68f940488354e36370f6cca89f0f106db09518524c88d6ed83f382"}, + {file = "certifi-2022.9.24.tar.gz", hash = "sha256:0d9c601124e5a6ba9712dbc60d9c53c21e34f5f641fe83002317394311bdce14"}, ] cffi = [ {file = "cffi-1.15.1-cp27-cp27m-macosx_10_9_x86_64.whl", hash = "sha256:a66d3508133af6e8548451b25058d5812812ec3798c886bf38ed24a98216fab2"}, @@ -1086,20 +1085,20 @@ defusedxml = [ {file = "defusedxml-0.7.1.tar.gz", hash = "sha256:1bb3032db185915b62d7c6209c5a8792be6a32ab2fedacc84e01b52c51aa3e69"}, ] fakeredis = [ - {file = "fakeredis-1.9.1-py3-none-any.whl", hash = "sha256:b9830f68dafafc0abe6c037775765166e9e2ff6b0da8abd3838eb2c3910f8e65"}, - {file = "fakeredis-1.9.1.tar.gz", hash = "sha256:e884776d7d0216e9c6c514527718259cfbd555777b36ba403ae680bd1489f7a1"}, + {file = "fakeredis-1.9.3-py3-none-any.whl", hash = "sha256:74a2f1e5e8781014418fe734b156808d5d1a2d15edec982fada3d6e7603f8536"}, + {file = "fakeredis-1.9.3.tar.gz", hash = "sha256:ea7e4ed076def2eea36188662586a9f2271946ae56ebc2de6a998c82b33df776"}, ] google-api-core = [ {file = "google-api-core-2.10.1.tar.gz", hash = "sha256:e16c15a11789bc5a3457afb2818a3540a03f341e6e710d7f9bbf6cde2ef4a7c8"}, {file = "google_api_core-2.10.1-py3-none-any.whl", hash = "sha256:92d17123cfe399b5ef7e026c63babf978d8475e1ac877919eb7933e25dea2273"}, ] google-auth = [ - {file = "google-auth-2.11.1.tar.gz", hash = "sha256:516e6623038b81430dd062a1a25ecd24f173d7c15cdf4e48a9e78bc87e97aeec"}, - {file = "google_auth-2.11.1-py2.py3-none-any.whl", hash = "sha256:53bdc0c2b4e25895575779caef4cfb3a6bdff1b7b32dc38a654d71aba35bb5f8"}, + {file = "google-auth-2.12.0.tar.gz", hash = "sha256:f12d86502ce0f2c0174e2e70ecc8d36c69593817e67e1d9c5e34489120422e4b"}, + {file = "google_auth-2.12.0-py2.py3-none-any.whl", hash = "sha256:98f601773978c969e1769f97265e732a81a8e598da3263895023958d456ee625"}, ] google-cloud-secret-manager = [ - {file = "google-cloud-secret-manager-2.12.4.tar.gz", hash = "sha256:9db33eb99afb6b7457bed2c8ee7e576590fdafd655a21e62092a190270c8b904"}, - {file = "google_cloud_secret_manager-2.12.4-py2.py3-none-any.whl", hash = "sha256:ddb2b856b767ba3dca5edc2fe8d7a06ec253074e32f4990b8a675caa70c231c8"}, + {file = "google-cloud-secret-manager-2.12.5.tar.gz", hash = "sha256:cdf0cc614134e6b8eee966fa821132befe0c7379b57a1aa15b23d6267805590e"}, + {file = "google_cloud_secret_manager-2.12.5-py2.py3-none-any.whl", hash = "sha256:c6a745388b93dc6c22ba00e248b8cd6d5692f35c766e6459f6b93d466f308a27"}, ] googleapis-common-protos = [ {file = "googleapis-common-protos-1.56.4.tar.gz", hash = "sha256:c25873c47279387cfdcbdafa36149887901d36202cb645a0e4f29686bf6e4417"}, @@ -1165,8 +1164,8 @@ idna = [ {file = "idna-3.4.tar.gz", hash = "sha256:814f528e8dead7d329833b91c5faa87d60bf71824cd12a7530b5526063d02cb4"}, ] importlib-metadata = [ - {file = "importlib_metadata-4.12.0-py3-none-any.whl", hash = "sha256:7401a975809ea1fdc658c3aa4f78cc2195a0e019c5cbc4c06122884e9ae80c23"}, - {file = "importlib_metadata-4.12.0.tar.gz", hash = "sha256:637245b8bab2b6502fcbc752cc4b7a6f6243bb02b31c5c26156ad103d3d45670"}, + {file = "importlib_metadata-4.13.0-py3-none-any.whl", hash = "sha256:8a8a81bcf996e74fee46f0d16bd3eaa382a7eb20fd82445c3ad11f4090334116"}, + {file = "importlib_metadata-4.13.0.tar.gz", hash = "sha256:dd0173e8f150d6815e098fd354f6414b0f079af4644ddfe90c71e2fc6174346d"}, ] importlib-resources = [ {file = "importlib_resources-5.9.0-py3-none-any.whl", hash = "sha256:f78a8df21a79bcc30cfd400bdc38f314333de7c0fb619763f6b9dabab8268bb7"}, @@ -1317,20 +1316,20 @@ proto-plus = [ {file = "proto_plus-1.22.1-py3-none-any.whl", hash = "sha256:ea8982669a23c379f74495bc48e3dcb47c822c484ce8ee1d1d7beb339d4e34c5"}, ] protobuf = [ - {file = "protobuf-4.21.6-cp310-abi3-win32.whl", hash = "sha256:49f88d56a9180dbb7f6199c920f5bb5c1dd0172f672983bb281298d57c2ac8eb"}, - {file = "protobuf-4.21.6-cp310-abi3-win_amd64.whl", hash = "sha256:7a6cc8842257265bdfd6b74d088b829e44bcac3cca234c5fdd6052730017b9ea"}, - {file = "protobuf-4.21.6-cp37-abi3-macosx_10_9_universal2.whl", hash = "sha256:ba596b9ffb85c909fcfe1b1a23136224ed678af3faf9912d3fa483d5f9813c4e"}, - {file = "protobuf-4.21.6-cp37-abi3-manylinux2014_aarch64.whl", hash = "sha256:4143513c766db85b9d7c18dbf8339673c8a290131b2a0fe73855ab20770f72b0"}, - {file = "protobuf-4.21.6-cp37-abi3-manylinux2014_x86_64.whl", hash = "sha256:b6cea204865595a92a7b240e4b65bcaaca3ad5d2ce25d9db3756eba06041138e"}, - {file = "protobuf-4.21.6-cp37-cp37m-win32.whl", hash = "sha256:9666da97129138585b26afcb63ad4887f602e169cafe754a8258541c553b8b5d"}, - {file = "protobuf-4.21.6-cp37-cp37m-win_amd64.whl", hash = "sha256:308173d3e5a3528787bb8c93abea81d5a950bdce62840d9760effc84127fb39c"}, - {file = "protobuf-4.21.6-cp38-cp38-win32.whl", hash = "sha256:aa29113ec901281f29d9d27b01193407a98aa9658b8a777b0325e6d97149f5ce"}, - {file = "protobuf-4.21.6-cp38-cp38-win_amd64.whl", hash = "sha256:8f9e60f7d44592c66e7b332b6a7b4b6e8d8b889393c79dbc3a91f815118f8eac"}, - {file = "protobuf-4.21.6-cp39-cp39-win32.whl", hash = "sha256:80e6540381080715fddac12690ee42d087d0d17395f8d0078dfd6f1181e7be4c"}, - {file = "protobuf-4.21.6-cp39-cp39-win_amd64.whl", hash = "sha256:77b355c8604fe285536155286b28b0c4cbc57cf81b08d8357bf34829ea982860"}, - {file = "protobuf-4.21.6-py2.py3-none-any.whl", hash = "sha256:07a0bb9cc6114f16a39c866dc28b6e3d96fa4ffb9cc1033057412547e6e75cb9"}, - {file = "protobuf-4.21.6-py3-none-any.whl", hash = "sha256:c7c864148a237f058c739ae7a05a2b403c0dfa4ce7d1f3e5213f352ad52d57c6"}, - {file = "protobuf-4.21.6.tar.gz", hash = "sha256:6b1040a5661cd5f6e610cbca9cfaa2a17d60e2bb545309bc1b278bb05be44bdd"}, + {file = "protobuf-4.21.7-cp310-abi3-win32.whl", hash = "sha256:c7cb105d69a87416bd9023e64324e1c089593e6dae64d2536f06bcbe49cd97d8"}, + {file = "protobuf-4.21.7-cp310-abi3-win_amd64.whl", hash = "sha256:3ec85328a35a16463c6f419dbce3c0fc42b3e904d966f17f48bae39597c7a543"}, + {file = "protobuf-4.21.7-cp37-abi3-macosx_10_9_universal2.whl", hash = "sha256:db9056b6a11cb5131036d734bcbf91ef3ef9235d6b681b2fc431cbfe5a7f2e56"}, + {file = "protobuf-4.21.7-cp37-abi3-manylinux2014_aarch64.whl", hash = "sha256:ca200645d6235ce0df3ccfdff1567acbab35c4db222a97357806e015f85b5744"}, + {file = "protobuf-4.21.7-cp37-abi3-manylinux2014_x86_64.whl", hash = "sha256:b019c79e23a80735cc8a71b95f76a49a262f579d6b84fd20a0b82279f40e2cc1"}, + {file = "protobuf-4.21.7-cp37-cp37m-win32.whl", hash = "sha256:d3f89ccf7182293feba2de2739c8bf34fed1ed7c65a5cf987be00311acac57c1"}, + {file = "protobuf-4.21.7-cp37-cp37m-win_amd64.whl", hash = "sha256:a74d96cd960b87b4b712797c741bb3ea3a913f5c2dc4b6cbe9c0f8360b75297d"}, + {file = "protobuf-4.21.7-cp38-cp38-win32.whl", hash = "sha256:8e09d1916386eca1ef1353767b6efcebc0a6859ed7f73cb7fb974feba3184830"}, + {file = "protobuf-4.21.7-cp38-cp38-win_amd64.whl", hash = "sha256:9e355f2a839d9930d83971b9f562395e13493f0e9211520f8913bd11efa53c02"}, + {file = "protobuf-4.21.7-cp39-cp39-win32.whl", hash = "sha256:f370c0a71712f8965023dd5b13277444d3cdfecc96b2c778b0e19acbfd60df6e"}, + {file = "protobuf-4.21.7-cp39-cp39-win_amd64.whl", hash = "sha256:9643684232b6b340b5e63bb69c9b4904cdd39e4303d498d1a92abddc7e895b7f"}, + {file = "protobuf-4.21.7-py2.py3-none-any.whl", hash = "sha256:8066322588d4b499869bf9f665ebe448e793036b552f68c585a9b28f1e393f66"}, + {file = "protobuf-4.21.7-py3-none-any.whl", hash = "sha256:58b81358ec6c0b5d50df761460ae2db58405c063fd415e1101209221a0a810e1"}, + {file = "protobuf-4.21.7.tar.gz", hash = "sha256:71d9dba03ed3432c878a801e2ea51e034b0ea01cf3a4344fb60166cb5f6c8757"}, ] py = [ {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, @@ -1521,8 +1520,8 @@ typed-ast = [ {file = "typed_ast-1.5.4.tar.gz", hash = "sha256:39e21ceb7388e4bb37f4c679d72707ed46c2fbf2a5609b8b8ebc4b067d977df2"}, ] types-six = [ - {file = "types-six-1.16.19.tar.gz", hash = "sha256:5bd851a00d761c5b5df78a379cb174a9aa63defc8d967600bbb37df607099ed2"}, - {file = "types_six-1.16.19-py3-none-any.whl", hash = "sha256:c9892951c3fd39e193aa35952049c48b31b56bd9c0bf104eb9735de030f20c8d"}, + {file = "types-six-1.16.21.tar.gz", hash = "sha256:562b036de1a837eafe164827c5c53d7a8d703a44bb211642932dcd59e9e0f7c9"}, + {file = "types_six-1.16.21-py3-none-any.whl", hash = "sha256:e4428b56da2505b5de228a3b5603561fa98571540fd75a90306eed8b3016ddf4"}, ] typing-extensions = [ {file = "typing_extensions-4.3.0-py3-none-any.whl", hash = "sha256:25642c956049920a5aa49edcdd6ab1e06d7e5d467fc00e0506c44ac86fbfca02"}, diff --git a/tools/c7n_mailer/requirements.txt b/tools/c7n_mailer/requirements.txt index 23072875a9c..d9a98f3b78f 100644 --- a/tools/c7n_mailer/requirements.txt +++ b/tools/c7n_mailer/requirements.txt @@ -1,21 +1,21 @@ attrs==22.1.0 ; python_version >= "3.7" and python_version < "4.0" -boto3==1.24.77 ; python_version >= "3.7" and python_version < "4.0" -botocore==1.27.77 ; python_version >= "3.7" and python_version < "4.0" +boto3==1.24.87 ; python_version >= "3.7" and python_version < "4.0" +botocore==1.27.87 ; python_version >= "3.7" and python_version < "4.0" cachetools==5.2.0 ; python_version >= "3.7" and python_version < "4.0" -certifi==2022.9.14 ; python_version >= "3.7" and python_version < "4" +certifi==2022.9.24 ; python_version >= "3.7" and python_version < "4" charset-normalizer==2.1.1 ; python_version >= "3.7" and python_version < "4" datadog==0.34.1 ; python_version >= "3.7" and python_version < "4.0" decorator==5.1.1 ; python_version >= "3.7" and python_version < "4.0" google-api-core[grpc]==2.10.1 ; python_version >= "3.7" and python_version < "4.0" -google-auth==2.11.1 ; python_version >= "3.7" and python_version < "4.0" -google-cloud-secret-manager==2.12.4 ; python_version >= "3.7" and python_version < "4.0" +google-auth==2.12.0 ; python_version >= "3.7" and python_version < "4.0" +google-cloud-secret-manager==2.12.5 ; python_version >= "3.7" and python_version < "4.0" googleapis-common-protos==1.56.4 ; python_version >= "3.7" and python_version < "4.0" googleapis-common-protos[grpc]==1.56.4 ; python_version >= "3.7" and python_version < "4.0" grpc-google-iam-v1==0.12.4 ; python_version >= "3.7" and python_version < "4.0" -grpcio-status==1.48.1 ; python_version >= "3.7" and python_version < "4.0" -grpcio==1.48.1 ; python_version >= "3.7" and python_version < "4.0" +grpcio-status==1.49.1 ; python_version >= "3.7" and python_version < "4.0" +grpcio==1.49.1 ; python_version >= "3.7" and python_version < "4.0" idna==3.4 ; python_version >= "3.7" and python_version < "4" -importlib-metadata==4.12.0 ; python_version >= "3.7" and python_version < "4.0" +importlib-metadata==4.13.0 ; python_version >= "3.7" and python_version < "4.0" importlib-resources==5.9.0 ; python_version >= "3.7" and python_version < "3.9" jinja2==3.1.2 ; python_version >= "3.7" and python_version < "4.0" jmespath==1.0.1 ; python_version >= "3.7" and python_version < "4.0" @@ -26,7 +26,7 @@ ldap3==2.9.1 ; python_version >= "3.7" and python_version < "4.0" markupsafe==2.1.1 ; python_version >= "3.7" and python_version < "4.0" pkgutil-resolve-name==1.3.10 ; python_version >= "3.7" and python_version < "3.9" proto-plus==1.22.1 ; python_version >= "3.7" and python_version < "4.0" -protobuf==4.21.6 ; python_version >= "3.7" and python_version < "4.0" +protobuf==4.21.7 ; python_version >= "3.7" and python_version < "4.0" pyasn1-modules==0.2.8 ; python_version >= "3.7" and python_version < "4.0" pyasn1==0.4.8 ; python_version >= "3.7" and python_version < "4.0" pyrsistent==0.18.1 ; python_version >= "3.7" and python_version < "4.0" @@ -40,7 +40,7 @@ s3transfer==0.6.0 ; python_version >= "3.7" and python_version < "4.0" sendgrid==6.9.7 ; python_version >= "3.7" and python_version < "4.0" six==1.16.0 ; python_version >= "3.7" and python_version < "4.0" starkbank-ecdsa==2.1.0 ; python_version >= "3.7" and python_version < "4.0" -types-six==1.16.19 ; python_version >= "3.7" and python_version < "4.0" +types-six==1.16.21 ; python_version >= "3.7" and python_version < "4.0" typing-extensions==4.3.0 ; python_version >= "3.7" and python_version < "3.8" urllib3==1.26.12 ; python_version >= "3.7" and python_version < "4" zipp==3.8.1 ; python_version >= "3.7" and python_version < "4.0" diff --git a/tools/c7n_mailer/setup.py b/tools/c7n_mailer/setup.py index e8799013cad..dac126db5cb 100644 --- a/tools/c7n_mailer/setup.py +++ b/tools/c7n_mailer/setup.py @@ -14,7 +14,7 @@ 'boto3>=1.11.12', 'datadog>=0.34.0,<0.35.0', 'google-cloud-secret-manager>=2.8.0,<3.0.0', - 'importlib-metadata>=4.11.1', + 'importlib-metadata>=4.11.1,<5.0', 'jsonpatch>=1.25,<2.0', 'jsonpointer>=2.0,<3.0', 'jsonschema>=3.2.0', @@ -42,10 +42,13 @@ 'long_description': '# c7n-mailer: Custodian Mailer\n\n% [comment]: # ( !!! IMPORTANT !!! )\n% [comment]: # (This file is moved during document generation.)\n% [comment]: # (Only edit the original document at ./tools/c7n_mailer/README.md)\n\nA mailer implementation for Custodian. Outbound mail delivery is still somewhat\norganization-specific, so this at the moment serves primarily as an example\nimplementation.\n\n> The Cloud Custodian Mailer can now be easily run in a Docker container. Click [here](https://hub.docker.com/r/cloudcustodian/mailer) for details.\n\n\n## Message Relay\n\nCustodian Mailer subscribes to an SQS queue, looks up users, and sends email\nvia SES and/or send notification to DataDog. Custodian lambda and instance policies can send to it. SQS queues\nshould be cross-account enabled for sending between accounts.\n\n\n## Tutorial\n\nOur goal in starting out with the Custodian mailer is to install the mailer,\nand run a policy that triggers an email to your inbox.\n\n1. [Install](#developer-install-os-x-el-capitan) the mailer on your laptop (if you are not running as a [Docker container](https://hub.docker.com/r/cloudcustodian/mailer)\n - or use `pip install c7n-mailer`\n2. In your text editor, create a `mailer.yml` file to hold your mailer config.\n3. In the AWS console, create a new standard SQS queue (quick create is fine).\n Copy the queue URL to `queue_url` in `mailer.yml`.\n4. In AWS, locate or create a role that has read access to the queue. Grab the\n role ARN and set it as `role` in `mailer.yml`.\n\nThere are different notification endpoints options, you can combine both.\n\n### Email:\nMake sure your email address is verified in SES, and set it as\n`from_address` in `mailer.yml`. By default SES is in sandbox mode where you\nmust\n[verify](http://docs.aws.amazon.com/ses/latest/DeveloperGuide/verify-email-addresses.html)\nevery individual recipient of emails. If need be, make an AWS support ticket to\nbe taken out of SES sandbox mode.\n\nYour `mailer.yml` should now look something like this:\n\n```yaml\nqueue_url: https://sqs.us-east-1.amazonaws.com/1234567890/c7n-mailer-test\nrole: arn:aws:iam::123456790:role/c7n-mailer-test\nfrom_address: you@example.com\n```\n\nYou can also set `region` if you are in a region other than `us-east-1` as well as `lambda_tags` to give the mailer tags.\n\n```yaml\nregion: us-east-2\nlambda_tags:\n owner: ops\n```\n\nNow let\'s make a Custodian policy to populate your mailer queue. Create a\n`test-policy.yml` file with this content (update `to` and `queue` to match your\nenvironment)\n\n```yaml\n policies:\n - name: c7n-mailer-test\n resource: sqs\n filters:\n - "tag:MailerTest": absent\n actions:\n - type: notify\n template: default\n priority_header: \'2\'\n subject: testing the c7n mailer\n to:\n - you@example.com\n transport:\n type: sqs\n queue: https://sqs.us-east-1.amazonaws.com/1234567890/c7n-mailer-test\n```\n\n### DataDog:\nThe standard way to do a DataDog integration is use the\nc7n integration with AWS CloudWatch and use the\n[DataDog integration with AWS](https://docs.datadoghq.com/integrations/amazon_web_services/)\nto collect CloudWatch metrics. The mailer/messenger integration is only\nfor the case you don\'t want or you can\'t use AWS CloudWatch, e.g. in Azure or GCP.\n\nNote this integration requires the additional dependency of datadog python bindings:\n```\npip install datadog\n```\n\nYour `mailer.yml` should now look something like this:\n\n```yaml\nqueue_url: https://sqs.us-east-1.amazonaws.com/1234567890/c7n-mailer-test\nrole: arn:aws:iam::123456790:role/c7n-mailer-test\ndatadog_api_key: XXXXXXXXXXXXXXXXXXXXXXXXXXXXX\ndatadog_application_key: YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY\n```\n\n(Also set `region` if you are in a region other than `us-east-1`.)\n\nNow let\'s make a Custodian policy to populate your mailer queue. Create a\n`test-policy.yml`:\n\n```yaml\npolicies:\n - name: c7n-mailer-test\n resource: ebs\n filters:\n - Attachments: []\n actions:\n - type: notify\n to:\n - datadog://?metric_name=datadog.metric.name&metric_value_tag=Size\n transport:\n type: sqs\n queue: https://sqs.us-east-1.amazonaws.com/1234567890/c7n-mailer-test\n```\n\nThere is a special `to` format that specifies datadog delivery, and includes the datadog configuration via url parameters.\n- metric_name: is the name of the metrics send to DataDog\n- metric_value_tag: by default the metric value send to DataDog is `1` but if you want to use one of the tags returned in the policy you can set it with the attribute `metric_value_tag`, for example in the `test-policy.yml` the value used is the size of the EBS volume. The value must be a number and it\'s transformed to a float value.\n\n### Slack:\n\nThe Custodian mailer supports Slack messaging as a separate notification mechanism for the SQS transport method. To enable Slack integration, you must specify a Slack token in the `slack_token` field under the `mailer.yml` file.\n\n```yaml\nqueue_url: https://sqs.us-east-1.amazonaws.com/1234567890/c7n-mailer-test\nrole: arn:aws:iam::123456790:role/c7n-mailer-test\nslack_token: xoxo-token123\n```\n\nTo enable Slack messaging, several unique fields are evaluated in the policy, as shown in the below example:\n\n```\npolicies:\n - name: c7n-mailer-test\n resource: ebs\n filters:\n - Attachments: []\n actions:\n - type: notify\n slack_template: slack\n slack_msg_color: danger\n to:\n - slack://owners\n - slack://foo@bar.com\n - slack://#custodian-test\n - slack://webhook/#c7n-webhook-test\n - slack://tag/resource_tag\n - https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX\n transport:\n type: sqs\n queue: https://sqs.us-east-1.amazonaws.com/1234567890/c7n-mailer-test\n```\n\nSlack messages support use of a unique template field specified by `slack_template`. This field is unique and usage will not break\nexisting functionality for messages also specifying an email template in the `template` field. This field is optional, however,\nand if not specified, the mailer will use the default value `slack_default`.\n\nThe unique template field `slack_msg_color` can be used to specify a color\nborder for the slack message. This accepts the Slack presets of `danger` (red),\n`warning` (yellow) and `good` (green). It can also accept a HTML hex code. See\nthe [Slack documentation](https://api.slack.com/reference/messaging/attachments#fields)\nfor details.\n\nNote: if you are using a hex color code it will need to be wrapped in quotes\nlike so: `slack_msg_color: \'#4287f51\'`. Otherwise the YAML interpreter will consider it a\n[comment](https://yaml.org/spec/1.2/spec.html#id2780069).\n\nSlack integration for the mailer supports several flavors of messaging, listed below. These are not mutually exclusive and any combination of the types can be used, but the preferred method is [incoming webhooks](https://api.slack.com/incoming-webhooks).\n\n| Requires `slack_token` | Key | Type | Notes |\n|:---------------------------:|:--------------------------------------------------------------------------------|:-------|:----------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| No | `https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX` | string | **(PREFERRED)** Send to an [incoming webhook](https://api.slack.com/incoming-webhooks) (the channel is defined in the webhook) |\n| Yes | `slack://owners` | string | Send to the recipient list generated within email delivery logic |\n| Yes | `slack://foo@bar.com` | string | Send to the recipient specified by email address foo@bar.com |\n| Yes | `slack://#custodian-test` | string | Send to the Slack channel indicated in string, i.e. #custodian-test |\n| No | `slack://webhook/#c7n-webhook-test` | string | **(DEPRECATED)** Send to a Slack webhook; appended with the target channel. **IMPORTANT**: *This requires a `slack_webhook` value defined in the `mailer.yml`.* |\n| Yes | `slack://tag/resource-tag` | string | Send to target found in resource tag. Example of value in tag: https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX |\n\nSlack delivery can also be set via a resource\'s tag name. For example, using "slack://tag/slack_channel" will look for a tag name of \'slack_channel\', and if matched on a resource will deliver the message to the value of that resource\'s tag:\n\n`slack_channel:https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX`\n`slack_channel:custodian-test`\n`owner:foo@bar`\n\nDelivery via tag has been tested with webhooks but should support all delivery methods.\n\n### Splunk HTTP Event Collector (HEC)\n\nThe Custodian mailer supports delivery to the HTTP Event Collector (HEC) endpoint of a Splunk instance as a separate notification mechanism for the SQS transport method. To enable Splunk HEC integration, you must specify the URL to the HEC endpoint as well as a valid username and token:\n\n```yaml\nqueue_url: https://sqs.us-east-1.amazonaws.com/1234567890/c7n-mailer-test\nrole: arn:aws:iam::123456790:role/c7n-mailer-test\nsplunk_hec_url: https://http-inputs-foo.splunkcloud.com/services/collector/event\nsplunk_hec_token: 268b3cc2-f32e-4a19-a1e8-aee08d86ca7f\n```\n\nTo send events for a policy to the Splunk HEC endpoint, add a ``to`` address notify action specifying the name of the Splunk index to send events to in the form ``splunkhec://indexName``:\n\n```\npolicies:\n - name: c7n-mailer-test\n resource: ebs\n filters:\n - Attachments: []\n actions:\n - type: notify\n to:\n - splunkhec://myIndexName\n transport:\n type: sqs\n queue: https://sqs.us-east-1.amazonaws.com/1234567890/c7n-mailer-test\n```\n\nThe ``splunkhec://indexName`` address type can be combined in the same notify action with other destination types (e.g. email, Slack, DataDog, etc).\n\n### Now run:\n\n```\nc7n-mailer --config mailer.yml --update-lambda && custodian run -c test-policy.yml -s .\n```\n\nNote: You can set the profile via environment variable e.g. `export AWS_DEFAULT_PROFILE=foo`\n\nYou should see output similar to the following:\n\n```\n(env) $ c7n-mailer --config mailer.yml --update-lambda && custodian run -c test-policy.yml -s .\nDEBUG:custodian.lambda:Created custodian lambda archive size: 3.01mb\n2017-01-12 07:55:16,227: custodian.policy:INFO Running policy c7n-mailer-test resource: sqs region:default c7n:0.8.22.0\n2017-01-12 07:55:16,229: custodian.policy:INFO policy: c7n-mailer-test resource:sqs has count:1 time:0.00\n2017-01-12 07:55:18,017: custodian.actions:INFO sent message:dead-beef policy:c7n-mailer-test template:default count:1\n2017-01-12 07:55:18,017: custodian.policy:INFO policy: c7n-mailer-test action: notify resources: 1 execution_time: 1.79\n(env) $\n```\n\nCheck the AWS console for a new Lambda named `cloud-custodian-mailer`. The\nmailer runs every five minutes, so wait a bit and then look for an email in\nyour inbox. If it doesn\'t appear, look in the lambda\'s logs for debugging\ninformation. If it does, congratulations! You are off and running with the\nCustodian mailer.\n\n\n## Usage & Configuration\n\nOnce [installed](#developer-install-os-x-el-capitan) you should have a\n`c7n-mailer` executable on your path:\naws\n```\n(env) $ c7n-mailer\nusage: c7n-mailer [-h] -c CONFIG\nc7n-mailer: error: argument -c/--config is required\n(env) $\n```\n\nFundamentally what `c7n-mailer` does is deploy a Lambda (using\n[Mu](http://cloudcustodian.io/docs/policy/mu.html)) based on\nconfiguration you specify in a YAML file. Here is [the\nschema](./c7n_mailer/cli.py#L11-L41) to which the file must conform,\nand here is a description of the options:\n\n| Required? | Key | Type | Notes |\n|:---------:|:----------------|:-----------------|:------------------------------------------------------------------|\n| ✅ | `queue_url` | string | the queue to listen to for messages | \n| | `from_address` | string | default from address |\n| | `endpoint_url` | string | SQS API URL (for use with VPC Endpoints) |\n| | `contact_tags` | array of strings | tags that we should look at for address information |\n| | `email_base_url`| string | Base URL to construct a valid email address from a resource owner |\n\n\n### Standard Lambda Function Config\n\n| Required? | Key | Type |\n|:---------:|:---------------------|:-----------------|\n| | `dead_letter_config` | object |\n| | `memory` | integer |\n| | `region` | string |\n| ✅ | `role` | string |\n| | `runtime` | string |\n| | `security_groups` | array of strings |\n| | `subnets` | array of strings |\n| | `timeout` | integer |\n\n### Standard Azure Functions Config\n\n| Required? | Key | Type | Notes |\n|:---------:|:----------------------|:-------|:---------------------------------------------------------------------------------------|\n| | `function_properties` | object | Contains `appInsights`, `storageAccount` and `servicePlan` objects |\n| | `appInsights` | object | Contains `name`, `location` and `resourceGroupName` properties |\n| | `storageAccount` | object | Contains `name`, `location` and `resourceGroupName` properties |\n| | `servicePlan` | object | Contains `name`, `location`, `resourceGroupName`, `skuTier` and `skuName` properties |\n| | `name` | string | |\n| | `location` | string | Default: `west us 2` |\n| | `resourceGroupName` | string | Default `cloud-custodian` |\n| | `skuTier` | string | Default: `Basic` |\n| | `skuName` | string | Default: `B1` |\n\n\n\n\n### Mailer Infrastructure Config\n\n| Required? | Key | Type | Notes |\n|:---------:|:----------------------------|:--------|:---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| | `cache_engine` | string | cache engine; either sqlite or redis |\n| | `cross_accounts` | object | account to assume back into for sending to SNS topics |\n| | `debug` | boolean | debug on/off |\n| | `ldap_bind_dn` | string | eg: ou=people,dc=example,dc=com |\n| | `ldap_bind_user` | string | eg: FOO\\\\BAR |\n| | `ldap_bind_password` | secured string | ldap bind password |\n| | `ldap_bind_password_in_kms` | boolean | defaults to true, most people (except capone) want to set this to false. If set to true, make sure `ldap_bind_password` contains your KMS encrypted ldap bind password as a base64-encoded string. |\n| | `ldap_email_attribute` | string | |\n| | `ldap_email_key` | string | eg \'mail\' |\n| | `ldap_manager_attribute` | string | eg \'manager\' |\n| | `ldap_uid_attribute` | string | |\n| | `ldap_uid_regex` | string | |\n| | `ldap_uid_tags` | string | |\n| | `ldap_uri` | string | eg \'ldaps://example.com:636\' |\n| | `redis_host` | string | redis host if cache_engine == redis |\n| | `redis_port` | integer | redis port, default: 6369 |\n| | `ses_region` | string | AWS region that handles SES API calls |\n\n### SMTP Config\n\n| Required? | Key | Type | Notes |\n|:---------:|:----------------|:-----------------|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| | `smtp_server` | string | to configure your lambda role to talk to smtpd in your private vpc, see [here](https://docs.aws.amazon.com/lambda/latest/dg/vpc.html) | |\n| | `smtp_port` | integer | smtp port (default is 25) |\n| | `smtp_ssl` | boolean | this defaults to True |\n| | `smtp_username` | string | |\n| | `smtp_password` | secured string | |\n\nIf `smtp_server` is unset, `c7n_mailer` will use AWS SES or Azure SendGrid.\n\n#### DataDog Config\n\n| Required? | Key | Type | Notes |\n|:---------:|:--------------------------|:-------|:-------------------------|\n| | `datadog_api_key` | string | DataDog API key. |\n| | `datadog_application_key` | string | Datadog application key. |\n\nThese fields are not necessary if c7n_mailer is run in a instance/lambda/etc with the DataDog agent.\n\n### Slack Config\n\n| Required? | Key | Type | Notes |\n|:---------:|:--------------|:-------|:----------------|\n| | `slack_token` | string | Slack API token |\n\n### SendGrid Config\n\n| Required? | Key | Type | Notes |\n|:---------:|:-------------------|:---------------|:-------------------|\n| | `sendgrid_api_key` | secured string | SendGrid API token |\n\n\n### Splunk HEC Config\n\nThe following configuration items are *all* optional. The ones marked "Required for Splunk" are only required if you\'re sending notifications to ``splunkhec://`` destinations.\n\n| Required for Splunk? | Key | Type | Notes |\n|:--------------------:|:------------------------|:-----------------|:-----------------------------------------------------------------------------------------------------------------------------------|\n| ✅ | `splunk_hec_url` | string | URL to your Splunk HTTP Event Collector endpoint |\n| ✅ | `splunk_hec_token` | string | Splunk HEC authentication token for specified username |\n| | `splunk_remove_paths` | array of strings | List of [RFC6901](http://tools.ietf.org/html/rfc6901) JSON Pointers to remove from the event, if present, before sending to Splunk |\n| | `splunk_actions_list` | boolean | If true, add an `actions` list to the top-level message sent to Splunk, containing the names of all non-notify actions taken |\n| | `splunk_max_attempts` | integer | Maximum number of times to try POSTing data to Splunk HEC (default 4) |\n| | `splunk_hec_max_length` | integer | Maximum data length that Splunk HEC accepts; an error will be logged for any message sent over this length |\n| | `splunk_hec_sourcetype` | string | Configure sourcetype of the payload sent to Splunk HEC. (default is \'_json\') |\n\n### SDK Config\n\n| Required? | Key | Type | Notes |\n|:---------:|:--------------|:-------|:------|\n| | `http_proxy` | string | |\n| | `https_proxy` | string | |\n| | `profile` | string | |\n\n\n### Secured String\n\nIn order to ensure sensitive data is not stored plaintext in a policy, `c7n-mailer` supports secured\nstrings. You can treat it as a regular `string` or use `secured string` features.\n\n#### AWS\n\nYou can use KMS to encrypt your secrets and use encrypted secret in mailer policy.\nCustodian tries to decrypt the string using KMS, if it fails c7n treats it as a plaintext secret.\n\n```yaml\n plaintext_secret: \n secured_string: \n```\n\n#### Azure\n\nYou can store your secrets in Azure Key Vault secrets and reference them from the policy.\n\n```yaml\n plaintext_secret: \n secured_string:\n type: azure.keyvault\n secret: https://your-vault.vault.azure.net/secrets/your-secret\n```\n\nNote: `secrets.get` permission on the KeyVault for the Service Principal is required.\n\n#### GCP\n\nYou can store your secrets as GCP Secret Manager secrets and reference them from the policy.\n\n```yaml\n plaintext_secret: \n secured_string:\n type: gcp.secretmanager\n secret: projects/12345678912/secrets/your-secret\n```\n\nAn example of an SMTP password set as a secured string:\n\n```yaml\n smtp_password:\n type: gcp.secretmanager\n secret: projects/59808015552/secrets/smtp_pw\n```\n\nNote: If you do not specify a version, `/versions/latest` will be appended to your secret location.\n\n## Configuring a policy to send email\n\nOutbound email can be added to any policy by including the `notify` action.\n\n```yaml\n\npolicies:\n - name: bad-apples\n resource: asg\n filters:\n - "tag:ASV": absent\n actions:\n - type: notify\n template: default\n template_format: \'html\'\n priority_header: \'1\'\n subject: fix your tags\n to:\n - resource-owner\n owner_absent_contact:\n - foo@example.com\n transport:\n type: sqs\n queue: https://sqs.us-east-1.amazonaws.com/80101010101/cloud-custodian-message-relay\n```\n\nSo breaking it down, you add an action of type `notify`. You can specify a\ntemplate that\'s used to format the email; customizing templates is described\n[below](#writing-an-email-template).\n\nThe `to` list specifies the intended recipient for the email. You can specify\neither an email address, an SNS topic, a Datadog Metric, or a special value. The special values\nare either\n\n- `resource-owner`, in which case the email will be sent to the listed\n `OwnerContact` tag on the resource that matched the policy, or\n- `event-owner` for push-based/realtime policies that will send to the user\n that was responsible for the underlying event.\n- `priority_header` to indicate the importance of an email with [headers](https://www.chilkatsoft.com/p/p_471.asp). Different emails clients will display stars, exclamation points or flags depending on the value. Should be an string from 1 to 5.\n\nBoth of these special values are best effort, i.e., if no `OwnerContact` tag is\nspecified then `resource-owner` email will not be delivered, and in the case of\n`event-owner` an instance role or system account will not result in an email.\n\nThe optional `owner_absent_contact` list specifies email addresses to notify only if\nthe `resource-owner` special option was unable to find any matching owner contact\ntags.\n\nIn addition, you may choose to use a custom tag instead of the default `OwnerContact`. In order to configure this, the mailer.yaml must be modified to include the contact_tags and the custom tag. The `resource-owner` will now email the custom tag instead of `OwnerContact`.\n\n```yaml\ncontact_tags:\n - "custom_tag"\n```\n\n\nFor reference purposes, the JSON Schema of the `notify` action:\n\n```json\n{\n "type": "object",\n "required": ["type", "transport", "to"],\n "properties": {\n "type": {"enum": ["notify"]},\n "to": {"type": "array", "items": {"type": "string"}},\n "owner_absent_contact": {"type": "array", "items": {"type": "string"}},\n "subject": {"type": "string"},\n "priority_header": {"type": "string"},\n "template": {"type": "string"},\n "transport": {\n "type": "object",\n "required": ["type", "queue"],\n "properties": {\n "queue": {"type": "string"},\n "region": {"type": "string"},\n "type": {"enum": ["sqs"]}\n }\n }\n }\n}\n```\n\n## Using on Azure\n\nRequires:\n\n- `c7n_azure` package. See [Installing Azure Plugin](https://cloudcustodian.io/docs/azure/gettingstarted.html#azure-install-cc)\n- SendGrid account. See [Using SendGrid with Azure](https://docs.microsoft.com/en-us/azure/sendgrid-dotnet-how-to-send-email)\n- [Azure Storage Queue](https://azure.microsoft.com/en-us/services/storage/queues/)\n\nThe mailer supports an Azure Storage Queue transport and SendGrid delivery on Azure.\nConfiguration for this scenario requires only minor changes from AWS deployments.\n\nYou will need to grant `Storage Queue Data Contributor` role on the Queue for the identity\nmailer is running under.\n\nThe notify action in your policy will reflect transport type `asq` with the URL\nto an Azure Storage Queue. For example:\n\n```yaml\npolicies:\n - name: azure-notify\n resource: azure.resourcegroup\n description: send a message to a mailer instance\n actions:\n - type: notify\n template: default\n priority_header: \'2\'\n subject: Hello from C7N Mailer\n to:\n - you@youremail.com\n transport:\n type: asq\n queue: https://storageaccount.queue.core.windows.net/queuename\n```\n\nIn your mailer configuration, you\'ll need to provide your SendGrid API key as well as\nprefix your queue URL with `asq://` to let mailer know what type of queue it is:\n\n```yaml\nqueue_url: asq://storageaccount.queue.core.windows.net/queuename\nfrom_address: you@youremail.com\nsendgrid_api_key: SENDGRID_API_KEY\n```\n\nThe mailer will transmit all messages found on the queue on each execution, and will retry\nsending 3 times in the event of a failure calling SendGrid. After the retries the queue\nmessage will be discarded.\n\nIn addition, SendGrid delivery on Azure supports using resource tags to send emails. For example, in the `to` field:\n\n```yaml\nto:\n - tag:OwnerEmail\n```\n\nThis will find the email address associated with the resource\'s `OwnerEmail` tag, and send an email to the specified address.\nIf no tag is found, or the associated email address is invalid, no email will be sent.\n\n### Deploying Azure Functions\n\nThe `--update-lambda` CLI option will also deploy Azure Functions if you have an Azure\nmailer configuration.\n\n`c7n-mailer --config mailer.yml --update-lambda`\n\nwhere a simple `mailer.yml` using Consumption functions may look like:\n\n```yaml\nqueue_url: asq://storage.queue.core.windows.net/custodian\nfrom_address: foo@mail.com\nsendgrid_api_key: \nfunction_properties:\n servicePlan:\n name: \'testmailer1\'\n```\n\n### Configuring Function Identity\n\nYou can configure the service principal used for api calls made by the\nmailer azure function by specifying an identity configuration under\nfunction properties. Mailer supports User Assigned Identities, System\nManaged Identities, defaulting to an embedding of the cli user\'s\nservice principals credentials.\n\nWhen specifying a user assigned identity, unlike in a custodian\nfunction policy where simply providing an name is sufficient, the\nuuid/id and client id of the identity must be provided. You can\nretrieve this information on the cli using the `az identity list`.\n\n```yaml\n\nfunction_properties:\n identity:\n type: UserAssigned\n id: "/subscriptions/333fd504-7f11-2270-88c8-7325a27f7222/resourcegroups/c7n/providers/Microsoft.ManagedIdentity/userAssignedIdentities/mailer"\n client_id: "b9cb06fa-dfb8-4342-add3-aab5acb2abbc"\n```\n\nA system managed identity can also be used, and the Azure platform will\ncreate an identity when the function is provisoned, however the function\'s identity\nthen needs to be retrieved and mapped to rbac permissions post provisioning, this\nuser management activity must be performed manually.\n\n```yaml\n\nfunction_properties:\n identity:\n type: SystemAssigned\n```\n\n## Using on GCP\n\nRequires:\n\n- `c7n_gcp` package. See [GCP Getting Started](https://cloudcustodian.io/docs/gcp/gettingstarted.html)\n- `google-cloud-secret-manager` package, for pulling in secured string values.\n- A working SMTP Account.\n- [GCP Pubsub Subscription](https://cloud.google.com/pubsub/docs/)\n\nThe mailer supports GCP Pubsub transports and SMTP/Email delivery, as well as Datadog and Splunk.\nConfiguration for this scenario requires only minor changes from AWS deployments.\n\nThe notify action in your policy will reflect transport type `projects` with the URL\nto a GCP Pub/Sub Topic. For example:\n\n```yaml\npolicies:\n - name: gcp-notify\n resource: gcp.compute\n description: example policy\n actions:\n - type: notify\n template: default\n priority_header: \'2\'\n subject: Hello from C7N Mailer\n to:\n - you@youremail.com\n transport:\n type: pubsub\n topic: projects/myproject/topics/mytopic\n```\n\nIn your mailer configuration, you\'ll need to provide your SMTP account information\nas well as your topic subscription path in the queue_url variable. Please note that the\nsubscription you specify should be subscribed to the topic you assign in your policies\'\nnotify action for GCP resources.\n\n```yaml\nqueue_url: projects/myproject/subscriptions/mysubscription\nfrom_address: you@youremail.com\n# c7n-mailer currently requires a role be present, even if it\'s empty\nrole: ""\n\nsmtp_server: my.smtp.add.ress\nsmtp_port: 25\nsmtp_ssl: true\nsmtp_username: smtpuser\nsmtp_password:\n type: gcp.secretmanager\n secret: projects/12345678912/secrets/smtppassword\n```\n\nThe mailer will transmit all messages found on the queue on each execution using SMTP/Email delivery.\n\n### Deploying GCP Functions\n\nGCP Cloud Functions for c7n-mailer are currently not supported.\n\n## Writing an email template\n\nTemplates are authored in [jinja2](http://jinja.pocoo.org/docs/dev/templates/).\nDrop a file with the `.j2` extension into the a templates directory, and send a pull request to this\nrepo. You can then reference it in the `notify` action as the `template`\nvariable by file name minus extension. Templates ending with `.html.j2` are\nsent as HTML-formatted emails, all others are sent as plain text.\n\nYou can use `-t` or `--templates` cli argument to pass custom folder with your templates.\n\nThe following variables are available when rendering templates:\n\n| variable | value |\n|:------------------|:-------------------------------------------------------------|\n| `recipient` | email address |\n| `resources` | list of resources that matched the policy filters |\n| `event` | for CWE-push-based lambda policies, the event that triggered |\n| `action` | `notify` action that generated this SQS message |\n| `policy` | policy that triggered this notify action |\n| `account` | short name of the aws account |\n| `region` | region the policy was executing in |\n| `execution_start` | The time policy started executing |\n\nThe following extra global functions are available:\n\n| signature | behavior |\n|:-----------------------------------------------------------------------------|:--------------------------------------------------------------------------------------------------|\n| `format_struct(struct)` | pretty print a json structure |\n| `resource_tag(resource, key)` | retrieve a tag value from a resource or return an empty string, aliased as get_resource_tag_value |\n| `format_resource(resource, resource_type)` | renders a one line summary of a resource |\n| `date_time_format(utc_str, tz_str=\'US/Eastern\', format=\'%Y %b %d %H:%M %Z\')` | customize rendering of an utc datetime string |\n| `search(expression, value)` | jmespath search value using expression |\n| `yaml_safe(value)` | yaml dumper |\n\nThe following extra jinja filters are available:\n\n| filter | behavior |\n|:-----------------------------------------------------------------------------------------------|:----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| utc_string|date_time_format(tz_str=\'US/Pacific\', format=\'%Y %b %d %H:%M %Z\') | pretty [format](https://docs.python.org/2/library/datetime.html#strftime-strptime-behavior) the date / time |\n| 30|get_date_time_delta | Convert a time [delta](https://docs.python.org/2/library/datetime.html#datetime.timedelta) like \'30\' days in the future, to a datetime string. You can also use negative values for the past. |\n\n\n## Developer Install (OS X El Capitan)\n\nClone the repository:\n```\n$ git clone https://github.com/cloud-custodian/cloud-custodian\n```\nInstall dependencies (with virtualenv):\n```\n$ virtualenv c7n_mailer\n$ source c7n_mailer/bin/activate\n$ cd tools/c7n_mailer\n$ pip install -r requirements.txt\n```\nInstall the extensions:\n```\npython setup.py develop\n```\n\n## Testing Templates and Recipients\n\nA ``c7n-mailer-replay`` entrypoint is provided to assist in testing email notifications\nand templates. This script operates on an actual SQS message from cloud-custodian itself,\nwhich you can either retrieve from the SQS queue or replicate locally. By default it expects\nthe message file to be base64-encoded, gzipped JSON, just like c7n sends to SQS. With the\n``-p`` | ``--plain`` argument, it will expect the message file to contain plain JSON.\n\n``c7n-mailer-replay`` has three main modes of operation:\n\n* With no additional arguments, it will render the template specified by the policy the\n message is for, and actually send mail from the local machine as ``c7n-mailer`` would.\n This only works with SES, not SMTP.\n* With the ``-T`` | ``--template-print`` argument, it will log the email addresses that would\n receive mail, and print the rendered message body template to STDOUT.\n* With the ``-d`` | ``--dry-run`` argument, it will print the actual email body (including headers)\n that would be sent, for each message that would be sent, to STDOUT.\n\n### Testing Templates for Azure\n\nThe ``c7n-mailer-replay`` entrypoint can be used to test templates for Azure with either of the arguments:\n* ``-T`` | ``--template-print``\n* ``-d`` | ``--dry-run``\n\nRunning ``c7n-mailer-replay`` without either of these arguments will throw an error as it will attempt\nto authorize with AWS.\n\nThe following is an example for retrieving a sample message to test against templates:\n\n* Run a policy with the notify action, providing the name of the template to test, to populate the queue.\n\n* Using the azure cli, save the message locally:\n```\n$ az storage message get --queue-name --account-name --query \'[].content\' > test_message.gz\n```\n* The example message can be provided to ``c7n-mailer-replay`` by running:\n\n```\n$ c7n-mailer-replay test_message.gz -T --config mailer.yml\n```\n', 'long_description_content_type': 'text/markdown', 'author': 'Cloud Custodian Project', - 'author_email': None, - 'maintainer': None, - 'maintainer_email': None, - 'url': 'https://cloudcustodian.io', + 'author_email': 'cloud-custodian@googlegroups.com', + 'project_urls': { + 'Homepage': 'https://cloudcustodian.io', + 'Documentation': 'https://cloudcustodian.io/docs/', + 'Source': 'https://github.com/cloud-custodian/cloud-custodian', + 'Issue Tracker': 'https://github.com/cloud-custodian/cloud-custodian/issues', + }, 'packages': packages, 'package_data': package_data, 'install_requires': install_requires, diff --git a/tools/c7n_openstack/poetry.lock b/tools/c7n_openstack/poetry.lock index 8f75c43f845..10146125a34 100644 --- a/tools/c7n_openstack/poetry.lock +++ b/tools/c7n_openstack/poetry.lock @@ -29,21 +29,21 @@ optional = false python-versions = ">=3.5" [package.extras] -dev = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "furo", "sphinx", "sphinx-notfound-page", "pre-commit", "cloudpickle"] -docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] -tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] -tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "cloudpickle"] +dev = ["cloudpickle", "coverage[toml] (>=5.0.2)", "furo", "hypothesis", "mypy (>=0.900,!=0.940)", "pre-commit", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "sphinx", "sphinx-notfound-page", "zope.interface"] +docs = ["furo", "sphinx", "sphinx-notfound-page", "zope.interface"] +tests = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "zope.interface"] +tests_no_zope = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins"] [[package]] name = "boto3" -version = "1.24.77" +version = "1.24.87" description = "The AWS SDK for Python" category = "dev" optional = false python-versions = ">= 3.7" [package.dependencies] -botocore = ">=1.27.77,<1.28.0" +botocore = ">=1.27.87,<1.28.0" jmespath = ">=0.7.1,<2.0.0" s3transfer = ">=0.6.0,<0.7.0" @@ -52,7 +52,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "botocore" -version = "1.27.77" +version = "1.27.87" description = "Low-level, data-driven core of boto 3." category = "dev" optional = false @@ -91,7 +91,7 @@ url = "../.." [[package]] name = "certifi" -version = "2022.9.14" +version = "2022.9.24" description = "Python package for providing Mozilla's CA Bundle." category = "main" optional = false @@ -140,11 +140,11 @@ cffi = ">=1.12" [package.extras] docs = ["sphinx (>=1.6.5,!=1.8.0,!=3.1.0,!=3.1.1)", "sphinx-rtd-theme"] -docstest = ["pyenchant (>=1.6.11)", "twine (>=1.12.0)", "sphinxcontrib-spelling (>=4.0.1)"] +docstest = ["pyenchant (>=1.6.11)", "sphinxcontrib-spelling (>=4.0.1)", "twine (>=1.12.0)"] pep8test = ["black", "flake8", "flake8-import-order", "pep8-naming"] sdist = ["setuptools-rust (>=0.11.4)"] ssh = ["bcrypt (>=3.1.5)"] -test = ["pytest (>=6.2.0)", "pytest-benchmark", "pytest-cov", "pytest-subtests", "pytest-xdist", "pretend", "iso8601", "pytz", "hypothesis (>=1.11.4,!=3.79.2)"] +test = ["hypothesis (>=1.11.4,!=3.79.2)", "iso8601", "pretend", "pytest (>=6.2.0)", "pytest-benchmark", "pytest-cov", "pytest-subtests", "pytest-xdist", "pytz"] [[package]] name = "decorator" @@ -184,7 +184,7 @@ python-versions = ">=3.5" [[package]] name = "importlib-metadata" -version = "4.12.0" +version = "4.13.0" description = "Read metadata from Python packages" category = "main" optional = false @@ -195,9 +195,9 @@ typing-extensions = {version = ">=3.6.4", markers = "python_version < \"3.8\""} zipp = ">=0.5" [package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)"] perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.3)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] +testing = ["flake8 (<5)", "flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] [[package]] name = "importlib-resources" @@ -211,8 +211,8 @@ python-versions = ">=3.7" zipp = {version = ">=3.1.0", markers = "python_version < \"3.10\""} [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [[package]] name = "iniconfig" @@ -224,7 +224,7 @@ python-versions = "*" [[package]] name = "iso8601" -version = "1.0.2" +version = "1.1.0" description = "Simple module to parse ISO 8601 dates" category = "main" optional = false @@ -320,7 +320,7 @@ python-versions = "*" six = "*" [package.extras] -testing = ["pytest", "coverage", "astroid (>=1.5.3,<1.6.0)", "pylint (>=1.7.2,<1.8.0)", "astroid (>=2.0)", "pylint (>=2.3.1,<2.4.0)"] +testing = ["astroid (>=1.5.3,<1.6.0)", "astroid (>=2.0)", "coverage", "pylint (>=1.7.2,<1.8.0)", "pylint (>=2.3.1,<2.4.0)", "pytest"] yaml = ["PyYAML (>=5.1.0)"] [[package]] @@ -387,7 +387,7 @@ optional = false python-versions = ">=2.6" [[package]] -name = "pkgutil-resolve-name" +name = "pkgutil_resolve_name" version = "1.3.10" description = "Resolve a name to an object." category = "dev" @@ -434,7 +434,7 @@ optional = false python-versions = ">=3.6.8" [package.extras] -diagrams = ["railroad-diagrams", "jinja2"] +diagrams = ["jinja2", "railroad-diagrams"] [[package]] name = "pyrsistent" @@ -477,7 +477,7 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,>=2.7" six = ">=1.5" [[package]] -name = "pyyaml" +name = "PyYAML" version = "6.0" description = "YAML parser and emitter for Python" category = "main" @@ -580,8 +580,8 @@ optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*, <4" [package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "urllib3-secure-extra", "ipaddress"] +brotli = ["brotli (>=1.0.9)", "brotlicffi (>=0.8.0)", "brotlipy (>=0.6.0)"] +secure = ["certifi", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "ipaddress", "pyOpenSSL (>=0.14)", "urllib3-secure-extra"] socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] [[package]] @@ -628,8 +628,8 @@ optional = false python-versions = ">=3.7" [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "func-timeout", "jaraco.itertools", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["func-timeout", "jaraco.itertools", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [metadata] lock-version = "1.1" @@ -650,17 +650,17 @@ attrs = [ {file = "attrs-22.1.0.tar.gz", hash = "sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6"}, ] boto3 = [ - {file = "boto3-1.24.77-py3-none-any.whl", hash = "sha256:fc16e50263c24631d5fe75464e76f3a1b454b4c0015c864948a61691f9702a6e"}, - {file = "boto3-1.24.77.tar.gz", hash = "sha256:16646de3303779d6dc9c192d8a863095244de81d2e0b94f50692fbde767c6f1b"}, + {file = "boto3-1.24.87-py3-none-any.whl", hash = "sha256:bcc579e801774cb2c7dda87ff985feda1ae7e10591d11ef37526363139138bd4"}, + {file = "boto3-1.24.87.tar.gz", hash = "sha256:3dd7ed74d1d29dd8094a078be86ed61c45de6638fe18856f7a1ff9282b4d929e"}, ] botocore = [ - {file = "botocore-1.27.77-py3-none-any.whl", hash = "sha256:d88509ed291b95525205cc06ca87b54d077aae996827039f5e32375949c5aaf7"}, - {file = "botocore-1.27.77.tar.gz", hash = "sha256:77a43e970d0762080b4b79a7e00ea572ef2ae7a9f578c3c8e7f0a344ee4b4e6d"}, + {file = "botocore-1.27.87-py3-none-any.whl", hash = "sha256:c4cbd22056ace4c7aa99e62e8ae629865ab80cc8bbf7c6d68ccf0f768f0034b6"}, + {file = "botocore-1.27.87.tar.gz", hash = "sha256:216de9751116d0d1cc3901e26d95a5c9a30ecb6973ae6147af1cf504858d845a"}, ] c7n = [] certifi = [ - {file = "certifi-2022.9.14-py3-none-any.whl", hash = "sha256:e232343de1ab72c2aa521b625c80f699e356830fd0e2c620b465b304b17b0516"}, - {file = "certifi-2022.9.14.tar.gz", hash = "sha256:36973885b9542e6bd01dea287b2b4b3b21236307c56324fcc3f1160f2d655ed5"}, + {file = "certifi-2022.9.24-py3-none-any.whl", hash = "sha256:90c1a32f1d68f940488354e36370f6cca89f0f106db09518524c88d6ed83f382"}, + {file = "certifi-2022.9.24.tar.gz", hash = "sha256:0d9c601124e5a6ba9712dbc60d9c53c21e34f5f641fe83002317394311bdce14"}, ] cffi = [ {file = "cffi-1.15.1-cp27-cp27m-macosx_10_9_x86_64.whl", hash = "sha256:a66d3508133af6e8548451b25058d5812812ec3798c886bf38ed24a98216fab2"}, @@ -781,8 +781,8 @@ idna = [ {file = "idna-3.4.tar.gz", hash = "sha256:814f528e8dead7d329833b91c5faa87d60bf71824cd12a7530b5526063d02cb4"}, ] importlib-metadata = [ - {file = "importlib_metadata-4.12.0-py3-none-any.whl", hash = "sha256:7401a975809ea1fdc658c3aa4f78cc2195a0e019c5cbc4c06122884e9ae80c23"}, - {file = "importlib_metadata-4.12.0.tar.gz", hash = "sha256:637245b8bab2b6502fcbc752cc4b7a6f6243bb02b31c5c26156ad103d3d45670"}, + {file = "importlib_metadata-4.13.0-py3-none-any.whl", hash = "sha256:8a8a81bcf996e74fee46f0d16bd3eaa382a7eb20fd82445c3ad11f4090334116"}, + {file = "importlib_metadata-4.13.0.tar.gz", hash = "sha256:dd0173e8f150d6815e098fd354f6414b0f079af4644ddfe90c71e2fc6174346d"}, ] importlib-resources = [ {file = "importlib_resources-5.9.0-py3-none-any.whl", hash = "sha256:f78a8df21a79bcc30cfd400bdc38f314333de7c0fb619763f6b9dabab8268bb7"}, @@ -793,8 +793,8 @@ iniconfig = [ {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, ] iso8601 = [ - {file = "iso8601-1.0.2-py3-none-any.whl", hash = "sha256:d7bc01b1c2a43b259570bb307f057abc578786ea734ba2b87b836c5efc5bd443"}, - {file = "iso8601-1.0.2.tar.gz", hash = "sha256:27f503220e6845d9db954fb212b95b0362d8b7e6c1b2326a87061c3de93594b1"}, + {file = "iso8601-1.1.0-py3-none-any.whl", hash = "sha256:8400e90141bf792bce2634df533dc57e3bee19ea120a87bebcd3da89a58ad73f"}, + {file = "iso8601-1.1.0.tar.gz", hash = "sha256:32811e7b81deee2063ea6d2e94f8819a86d1f3811e49d23623a41fa832bef03f"}, ] jmespath = [ {file = "jmespath-1.0.1-py3-none-any.whl", hash = "sha256:02e2e4cc71b5bcab88332eebf907519190dd9e6e82107fa7f83b1003a6252980"}, @@ -929,7 +929,7 @@ pbr = [ {file = "pbr-5.10.0-py2.py3-none-any.whl", hash = "sha256:da3e18aac0a3c003e9eea1a81bd23e5a3a75d745670dcf736317b7d966887fdf"}, {file = "pbr-5.10.0.tar.gz", hash = "sha256:cfcc4ff8e698256fc17ea3ff796478b050852585aa5bae79ecd05b2ab7b39b9a"}, ] -pkgutil-resolve-name = [ +pkgutil_resolve_name = [ {file = "pkgutil_resolve_name-1.3.10-py3-none-any.whl", hash = "sha256:ca27cc078d25c5ad71a9de0a7a330146c4e014c2462d9af19c6b828280649c5e"}, {file = "pkgutil_resolve_name-1.3.10.tar.gz", hash = "sha256:357d6c9e6a755653cfd78893817c0853af365dd51ec97f3d358a819373bbd174"}, ] @@ -980,7 +980,7 @@ python-dateutil = [ {file = "python-dateutil-2.8.2.tar.gz", hash = "sha256:0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86"}, {file = "python_dateutil-2.8.2-py2.py3-none-any.whl", hash = "sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9"}, ] -pyyaml = [ +PyYAML = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, @@ -988,6 +988,13 @@ pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782"}, + {file = "PyYAML-6.0-cp311-cp311-win32.whl", hash = "sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7"}, + {file = "PyYAML-6.0-cp311-cp311-win_amd64.whl", hash = "sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf"}, {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, @@ -1037,7 +1044,6 @@ stevedore = [ ] tabulate = [ {file = "tabulate-0.8.10-py3-none-any.whl", hash = "sha256:0ba055423dbaa164b9e456abe7920c5e8ed33fcc16f6d1b2f2d152c8e1e8b4fc"}, - {file = "tabulate-0.8.10-py3.8.egg", hash = "sha256:436f1c768b424654fce8597290d2764def1eea6a77cfa5c33be00b1bc0f4f63d"}, {file = "tabulate-0.8.10.tar.gz", hash = "sha256:6c57f3f3dd7ac2782770155f3adb2db0b1a269637e42f27599925e64b114f519"}, ] tomli = [ diff --git a/tools/c7n_openstack/requirements.txt b/tools/c7n_openstack/requirements.txt index 3263a88c5ad..c2cb6f6f239 100644 --- a/tools/c7n_openstack/requirements.txt +++ b/tools/c7n_openstack/requirements.txt @@ -1,28 +1,28 @@ -appdirs==1.4.4; python_version >= "3.6" -certifi==2022.9.14; python_version >= "3.7" and python_version < "4" -cffi==1.15.1; python_version >= "3.6" -charset-normalizer==2.1.1; python_version >= "3.7" and python_version < "4" and python_full_version >= "3.6.0" -cryptography==38.0.1; python_version >= "3.6" -decorator==5.1.1; python_version >= "3.6" -dogpile.cache==1.1.8; python_version >= "3.6" -idna==3.4; python_version >= "3.7" and python_version < "4" -importlib-metadata==4.12.0; python_version < "3.8" and python_version >= "3.7" -iso8601==1.0.2; python_full_version >= "3.6.2" and python_version < "4.0" and python_version >= "3.6" -jmespath==1.0.1; python_version >= "3.7" -jsonpatch==1.32; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" and python_version >= "3.6" -jsonpointer==2.3; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.5.0" and python_version >= "3.6" -keystoneauth1==5.0.0; python_version >= "3.6" -munch==2.5.0; python_version >= "3.6" -netifaces==0.11.0; python_version >= "3.6" -openstacksdk==0.52.0; python_version >= "3.6" -os-service-types==1.7.0; python_version >= "3.6" -pbr==5.10.0; python_version >= "3.6" -pycparser==2.21; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.6" -pyyaml==6.0; python_version >= "3.6" -requests==2.28.1; python_version >= "3.7" and python_version < "4" -requestsexceptions==1.4.0; python_version >= "3.6" -six==1.16.0; python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.3.0" and python_version >= "3.6" -stevedore==3.5.0; python_version >= "3.6" -typing-extensions==4.3.0; python_version < "3.8" and python_version >= "3.7" -urllib3==1.26.12; python_version >= "3.7" and python_full_version < "3.0.0" and python_version < "4" or python_full_version >= "3.6.0" and python_version < "4" and python_version >= "3.7" -zipp==3.8.1; python_version < "3.8" and python_version >= "3.7" +appdirs==1.4.4 ; python_version >= "3.7" and python_version < "4.0" +certifi==2022.9.24 ; python_version >= "3.7" and python_version < "4" +cffi==1.15.1 ; python_version >= "3.7" and python_version < "4.0" +charset-normalizer==2.1.1 ; python_version >= "3.7" and python_version < "4" +cryptography==38.0.1 ; python_version >= "3.7" and python_version < "4.0" +decorator==5.1.1 ; python_version >= "3.7" and python_version < "4.0" +dogpile-cache==1.1.8 ; python_version >= "3.7" and python_version < "4.0" +idna==3.4 ; python_version >= "3.7" and python_version < "4" +importlib-metadata==4.13.0 ; python_version >= "3.7" and python_version < "3.8" +iso8601==1.1.0 ; python_version >= "3.7" and python_version < "4.0" +jmespath==1.0.1 ; python_version >= "3.7" and python_version < "4.0" +jsonpatch==1.32 ; python_version >= "3.7" and python_version < "4.0" +jsonpointer==2.3 ; python_version >= "3.7" and python_version < "4.0" +keystoneauth1==5.0.0 ; python_version >= "3.7" and python_version < "4.0" +munch==2.5.0 ; python_version >= "3.7" and python_version < "4.0" +netifaces==0.11.0 ; python_version >= "3.7" and python_version < "4.0" +openstacksdk==0.52.0 ; python_version >= "3.7" and python_version < "4.0" +os-service-types==1.7.0 ; python_version >= "3.7" and python_version < "4.0" +pbr==5.10.0 ; python_version >= "3.7" and python_version < "4.0" +pycparser==2.21 ; python_version >= "3.7" and python_version < "4.0" +pyyaml==6.0 ; python_version >= "3.7" and python_version < "4.0" +requests==2.28.1 ; python_version >= "3.7" and python_version < "4" +requestsexceptions==1.4.0 ; python_version >= "3.7" and python_version < "4.0" +six==1.16.0 ; python_version >= "3.7" and python_version < "4.0" +stevedore==3.5.0 ; python_version >= "3.7" and python_version < "4.0" +typing-extensions==4.3.0 ; python_version >= "3.7" and python_version < "3.8" +urllib3==1.26.12 ; python_version >= "3.7" and python_version < "4" +zipp==3.8.1 ; python_version >= "3.7" and python_version < "3.8" diff --git a/tools/c7n_openstack/setup.py b/tools/c7n_openstack/setup.py index 870901c1b7e..ef8b6e96cad 100644 --- a/tools/c7n_openstack/setup.py +++ b/tools/c7n_openstack/setup.py @@ -12,16 +12,16 @@ install_requires = \ ['argcomplete (>=2.0.0,<3.0.0)', 'attrs (>=22.1.0,<23.0.0)', - 'boto3 (>=1.24.77,<2.0.0)', - 'botocore (>=1.27.77,<2.0.0)', + 'boto3 (>=1.24.87,<2.0.0)', + 'botocore (>=1.27.87,<2.0.0)', 'c7n (>=0.9.19,<0.10.0)', 'docutils (>=0.17.1,<0.18.0)', - 'importlib-metadata (>=4.12.0,<5.0.0)', + 'importlib-metadata (>=4.13.0,<5.0.0)', 'importlib-resources (>=5.9.0,<6.0.0)', 'jmespath (>=1.0.1,<2.0.0)', 'jsonschema (>=4.16.0,<5.0.0)', 'openstacksdk>=0.52.0,<0.53.0', - 'pkgutil-resolve-name (>=1.3.10,<2.0.0)', + 'pkgutil_resolve_name (>=1.3.10,<2.0.0)', 'pyrsistent (>=0.18.1,<0.19.0)', 'python-dateutil (>=2.8.2,<3.0.0)', 'pyyaml (>=6.0,<7.0)', @@ -45,10 +45,13 @@ 'long_description': "# Custodian OpenStack Support\n\nWork in Progress - Not Ready For Use.\n\n## Quick Start\n\n### Installation\n\n```\npip install c7n_openstack\n```\n\n### OpenStack Environment Configration\n\nC7N will find cloud config for as few as 1 cloud and as many as you want to put in a config file.\nIt will read environment variables and config files, and it also contains some vendor specific default\nvalues so that you don't have to know extra info to use OpenStack:\n\n* If you have a config file, you will get the clouds listed in it\n* If you have environment variables, you will get a cloud named envvars\n* If you have neither, you will get a cloud named defaults with base defaults\n\nCreate a clouds.yml file:\n\n```yaml\nclouds:\n demo:\n region_name: RegionOne\n auth:\n username: 'admin'\n password: XXXXXXX\n project_name: 'admin'\n domain_name: 'Default'\n auth_url: 'https://montytaylor-sjc.openstack.blueboxgrid.com:5001/v2.0'\n```\n\nPlease note: c7n will look for a file called `clouds.yaml` in the following locations:\n\n* Current Directory\n* ~/.config/openstack\n* /etc/openstack\n\nMore information at [https://pypi.org/project/os-client-config](https://pypi.org/project/os-client-config)\n\n### Create a c7n policy yaml file as follows:\n\n```yaml\npolicies:\n- name: demo\n resource: openstack.flavor\n filters:\n - type: value\n key: vcpus\n value: 1\n op: gt\n```\n\n### Run c7n and report the matched resources:\n\n```sh\nmkdir -p output\ncustodian run demo.yaml -s output\ncustodian report demo.yaml -s output --format grid\n```\n\n## Examples\n\nfilter examples:\n\n```yaml\npolicies:\n- name: test-flavor\n resource: openstack.flavor\n filters:\n - type: value\n key: vcpus\n value: 1\n op: gt\n- name: test-project\n resource: openstack.project\n filters: []\n- name: test-server-image\n resource: openstack.server\n filters:\n - type: image\n image_name: cirros-0.5.1\n- name: test-user\n resource: openstack.user\n filters:\n - type: role\n project_name: demo\n role_name: _member_\n system_scope: false\n- name: test-server-flavor\n resource: openstack.server\n filters:\n - type: flavor\n vcpus: 1\n- name: test-server-age\n resource: openstack.server\n filters:\n - type: age\n op: lt\n days: 1\n- name: test-server-tags\n resource: openstack.server\n filters:\n - type: tags\n tags:\n - key: a\n value: a\n - key: b\n value: c\n op: any\n```\n", 'long_description_content_type': 'text/markdown', 'author': 'Cloud Custodian Project', - 'author_email': None, - 'maintainer': None, - 'maintainer_email': None, - 'url': 'https://cloudcustodian.io', + 'author_email': 'cloud-custodian@googlegroups.com', + 'project_urls': { + 'Homepage': 'https://cloudcustodian.io', + 'Documentation': 'https://cloudcustodian.io/docs/', + 'Source': 'https://github.com/cloud-custodian/cloud-custodian', + 'Issue Tracker': 'https://github.com/cloud-custodian/cloud-custodian/issues', + }, 'packages': packages, 'package_data': package_data, 'install_requires': install_requires, diff --git a/tools/c7n_org/poetry.lock b/tools/c7n_org/poetry.lock index 057d00aad73..a37fce1052b 100644 --- a/tools/c7n_org/poetry.lock +++ b/tools/c7n_org/poetry.lock @@ -21,21 +21,21 @@ optional = false python-versions = ">=3.5" [package.extras] -dev = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "furo", "sphinx", "sphinx-notfound-page", "pre-commit", "cloudpickle"] -docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] -tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] -tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "cloudpickle"] +dev = ["cloudpickle", "coverage[toml] (>=5.0.2)", "furo", "hypothesis", "mypy (>=0.900,!=0.940)", "pre-commit", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "sphinx", "sphinx-notfound-page", "zope.interface"] +docs = ["furo", "sphinx", "sphinx-notfound-page", "zope.interface"] +tests = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "zope.interface"] +tests_no_zope = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins"] [[package]] name = "boto3" -version = "1.24.77" +version = "1.24.87" description = "The AWS SDK for Python" category = "dev" optional = false python-versions = ">= 3.7" [package.dependencies] -botocore = ">=1.27.77,<1.28.0" +botocore = ">=1.27.87,<1.28.0" jmespath = ">=0.7.1,<2.0.0" s3transfer = ">=0.6.0,<0.7.0" @@ -44,7 +44,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "botocore" -version = "1.27.77" +version = "1.27.87" description = "Low-level, data-driven core of boto 3." category = "dev" optional = false @@ -111,7 +111,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" [[package]] name = "importlib-metadata" -version = "4.12.0" +version = "4.13.0" description = "Read metadata from Python packages" category = "main" optional = false @@ -122,9 +122,9 @@ typing-extensions = {version = ">=3.6.4", markers = "python_version < \"3.8\""} zipp = ">=0.5" [package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)"] perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.3)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] +testing = ["flake8 (<5)", "flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] [[package]] name = "importlib-resources" @@ -138,8 +138,8 @@ python-versions = ">=3.7" zipp = {version = ">=3.1.0", markers = "python_version < \"3.10\""} [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [[package]] name = "iniconfig" @@ -189,7 +189,7 @@ python-versions = ">=3.6" pyparsing = ">=2.0.2,<3.0.5 || >3.0.5" [[package]] -name = "pkgutil-resolve-name" +name = "pkgutil_resolve_name" version = "1.3.10" description = "Resolve a name to an object." category = "dev" @@ -228,7 +228,7 @@ optional = false python-versions = ">=3.6.8" [package.extras] -diagrams = ["railroad-diagrams", "jinja2"] +diagrams = ["jinja2", "railroad-diagrams"] [[package]] name = "pyrsistent" @@ -271,7 +271,7 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,>=2.7" six = ">=1.5" [[package]] -name = "pyyaml" +name = "PyYAML" version = "6.0" description = "YAML parser and emitter for Python" category = "dev" @@ -336,8 +336,8 @@ optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*, <4" [package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "urllib3-secure-extra", "ipaddress"] +brotli = ["brotli (>=1.0.9)", "brotlicffi (>=0.8.0)", "brotlipy (>=0.6.0)"] +secure = ["certifi", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "ipaddress", "pyOpenSSL (>=0.14)", "urllib3-secure-extra"] socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] [[package]] @@ -349,8 +349,8 @@ optional = false python-versions = ">=3.7" [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "func-timeout", "jaraco.itertools", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["func-timeout", "jaraco.itertools", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [metadata] lock-version = "1.1" @@ -367,12 +367,12 @@ attrs = [ {file = "attrs-22.1.0.tar.gz", hash = "sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6"}, ] boto3 = [ - {file = "boto3-1.24.77-py3-none-any.whl", hash = "sha256:fc16e50263c24631d5fe75464e76f3a1b454b4c0015c864948a61691f9702a6e"}, - {file = "boto3-1.24.77.tar.gz", hash = "sha256:16646de3303779d6dc9c192d8a863095244de81d2e0b94f50692fbde767c6f1b"}, + {file = "boto3-1.24.87-py3-none-any.whl", hash = "sha256:bcc579e801774cb2c7dda87ff985feda1ae7e10591d11ef37526363139138bd4"}, + {file = "boto3-1.24.87.tar.gz", hash = "sha256:3dd7ed74d1d29dd8094a078be86ed61c45de6638fe18856f7a1ff9282b4d929e"}, ] botocore = [ - {file = "botocore-1.27.77-py3-none-any.whl", hash = "sha256:d88509ed291b95525205cc06ca87b54d077aae996827039f5e32375949c5aaf7"}, - {file = "botocore-1.27.77.tar.gz", hash = "sha256:77a43e970d0762080b4b79a7e00ea572ef2ae7a9f578c3c8e7f0a344ee4b4e6d"}, + {file = "botocore-1.27.87-py3-none-any.whl", hash = "sha256:c4cbd22056ace4c7aa99e62e8ae629865ab80cc8bbf7c6d68ccf0f768f0034b6"}, + {file = "botocore-1.27.87.tar.gz", hash = "sha256:216de9751116d0d1cc3901e26d95a5c9a30ecb6973ae6147af1cf504858d845a"}, ] c7n = [] click = [ @@ -388,8 +388,8 @@ docutils = [ {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, ] importlib-metadata = [ - {file = "importlib_metadata-4.12.0-py3-none-any.whl", hash = "sha256:7401a975809ea1fdc658c3aa4f78cc2195a0e019c5cbc4c06122884e9ae80c23"}, - {file = "importlib_metadata-4.12.0.tar.gz", hash = "sha256:637245b8bab2b6502fcbc752cc4b7a6f6243bb02b31c5c26156ad103d3d45670"}, + {file = "importlib_metadata-4.13.0-py3-none-any.whl", hash = "sha256:8a8a81bcf996e74fee46f0d16bd3eaa382a7eb20fd82445c3ad11f4090334116"}, + {file = "importlib_metadata-4.13.0.tar.gz", hash = "sha256:dd0173e8f150d6815e098fd354f6414b0f079af4644ddfe90c71e2fc6174346d"}, ] importlib-resources = [ {file = "importlib_resources-5.9.0-py3-none-any.whl", hash = "sha256:f78a8df21a79bcc30cfd400bdc38f314333de7c0fb619763f6b9dabab8268bb7"}, @@ -411,7 +411,7 @@ packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, {file = "packaging-21.3.tar.gz", hash = "sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb"}, ] -pkgutil-resolve-name = [ +pkgutil_resolve_name = [ {file = "pkgutil_resolve_name-1.3.10-py3-none-any.whl", hash = "sha256:ca27cc078d25c5ad71a9de0a7a330146c4e014c2462d9af19c6b828280649c5e"}, {file = "pkgutil_resolve_name-1.3.10.tar.gz", hash = "sha256:357d6c9e6a755653cfd78893817c0853af365dd51ec97f3d358a819373bbd174"}, ] @@ -458,7 +458,7 @@ python-dateutil = [ {file = "python-dateutil-2.8.2.tar.gz", hash = "sha256:0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86"}, {file = "python_dateutil-2.8.2-py2.py3-none-any.whl", hash = "sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9"}, ] -pyyaml = [ +PyYAML = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, @@ -466,6 +466,13 @@ pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782"}, + {file = "PyYAML-6.0-cp311-cp311-win32.whl", hash = "sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7"}, + {file = "PyYAML-6.0-cp311-cp311-win_amd64.whl", hash = "sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf"}, {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, @@ -503,7 +510,6 @@ six = [ ] tabulate = [ {file = "tabulate-0.8.10-py3-none-any.whl", hash = "sha256:0ba055423dbaa164b9e456abe7920c5e8ed33fcc16f6d1b2f2d152c8e1e8b4fc"}, - {file = "tabulate-0.8.10-py3.8.egg", hash = "sha256:436f1c768b424654fce8597290d2764def1eea6a77cfa5c33be00b1bc0f4f63d"}, {file = "tabulate-0.8.10.tar.gz", hash = "sha256:6c57f3f3dd7ac2782770155f3adb2db0b1a269637e42f27599925e64b114f519"}, ] tomli = [ diff --git a/tools/c7n_org/pyproject.toml b/tools/c7n_org/pyproject.toml index 99e2a026ad0..0b1d3a280e6 100644 --- a/tools/c7n_org/pyproject.toml +++ b/tools/c7n_org/pyproject.toml @@ -19,7 +19,7 @@ c7n-org = 'c7n_org.cli:cli' [tool.poetry.dependencies] python = "^3.7" -click = "^8.0" +click = ">=8.0" [tool.poetry.dev-dependencies] c7n = {path = "../..", develop = true} diff --git a/tools/c7n_org/requirements.txt b/tools/c7n_org/requirements.txt index 5c3125c119c..4b53288a517 100644 --- a/tools/c7n_org/requirements.txt +++ b/tools/c7n_org/requirements.txt @@ -1,5 +1,5 @@ -click==8.1.3; python_version >= "3.7" -colorama==0.4.5; python_version >= "3.7" and python_full_version < "3.0.0" and platform_system == "Windows" or platform_system == "Windows" and python_version >= "3.7" and python_full_version >= "3.5.0" -importlib-metadata==4.12.0; python_version < "3.8" and python_version >= "3.7" -typing-extensions==4.3.0; python_version < "3.8" and python_version >= "3.7" -zipp==3.8.1; python_version < "3.8" and python_version >= "3.7" +click==8.1.3 ; python_version >= "3.7" and python_version < "4.0" +colorama==0.4.5 ; python_version >= "3.7" and python_version < "4.0" and platform_system == "Windows" +importlib-metadata==4.13.0 ; python_version >= "3.7" and python_version < "3.8" +typing-extensions==4.3.0 ; python_version >= "3.7" and python_version < "3.8" +zipp==3.8.1 ; python_version >= "3.7" and python_version < "3.8" diff --git a/tools/c7n_org/setup.py b/tools/c7n_org/setup.py index 9c860c00a36..6102de18773 100644 --- a/tools/c7n_org/setup.py +++ b/tools/c7n_org/setup.py @@ -12,16 +12,16 @@ install_requires = \ ['argcomplete (>=2.0.0,<3.0.0)', 'attrs (>=22.1.0,<23.0.0)', - 'boto3 (>=1.24.77,<2.0.0)', - 'botocore (>=1.27.77,<2.0.0)', + 'boto3 (>=1.24.87,<2.0.0)', + 'botocore (>=1.27.87,<2.0.0)', 'c7n (>=0.9.19,<0.10.0)', 'click>=8.0,<9.0', 'docutils (>=0.17.1,<0.18.0)', - 'importlib-metadata (>=4.12.0,<5.0.0)', + 'importlib-metadata (>=4.13.0,<5.0.0)', 'importlib-resources (>=5.9.0,<6.0.0)', 'jmespath (>=1.0.1,<2.0.0)', 'jsonschema (>=4.16.0,<5.0.0)', - 'pkgutil-resolve-name (>=1.3.10,<2.0.0)', + 'pkgutil_resolve_name (>=1.3.10,<2.0.0)', 'pyrsistent (>=0.18.1,<0.19.0)', 'python-dateutil (>=2.8.2,<3.0.0)', 'pyyaml (>=6.0,<7.0)', @@ -48,10 +48,13 @@ 'long_description': '# c7n-org: Multi Account Custodian Execution\n\n% [comment]: # ( !!! IMPORTANT !!! )\n% [comment]: # (This file is moved during document generation.)\n% [comment]: # (Only edit the original document at ./tools/c7n_org/README.md)\n\nc7n-org is a tool to run custodian against multiple AWS accounts,\nAzure subscriptions, or GCP projects in parallel.\n\n## Installation\n\n```shell\npip install c7n-org\n```\n\nc7n-org has 3 run modes:\n\n```shell\nUsage: c7n-org [OPTIONS] COMMAND [ARGS]...\n\n custodian organization multi-account runner.\n\nOptions:\n --help Show this message and exit.\n\nCommands:\n report report on an AWS cross account policy execution\n run run a custodian policy across accounts (AWS, Azure, GCP)\n run-script run a script across AWS accounts\n```\n\nIn order to run c7n-org against multiple accounts, a config file must\nfirst be created containing pertinent information about the accounts:\n\n\nExample AWS Config File:\n\n```yaml\naccounts:\n- account_id: \'123123123123\'\n name: account-1\n regions:\n - us-east-1\n - us-west-2\n role: arn:aws:iam::123123123123:role/CloudCustodian\n vars:\n charge_code: xyz\n tags:\n - type:prod\n - division:some division\n - partition:us\n - scope:pci\n...\n```\n\nExample Azure Config File:\n\n```yaml\nsubscriptions:\n- name: Subscription-1\n subscription_id: a1b2c3d4-e5f6-g7h8i9...\n- name: Subscription-2\n subscription_id: 1z2y3x4w-5v6u-7t8s9r...\n```\n\nExample GCP Config File:\n\n```yaml\nprojects:\n- name: app-dev\n project_id: app-203501\n tags:\n - label:env:dev \n- name: app-prod\n project_id: app-1291\n tags:\n - label:env:dev\n\n```\n\n### Config File Generation\n\nWe also distribute scripts to generate the necessary config file in the `scripts` folder.\n\n**Note** Currently these are distributed only via git, per\nhttps://github.com/cloud-custodian/cloud-custodian/issues/2420 we\'ll\nbe looking to incorporate them into a new c7n-org subcommand.\n\n- For **AWS**, the script `orgaccounts.py` generates a config file\n from the AWS Organizations API\n\n- For **Azure**, the script `azuresubs.py` generates a config file\n from the Azure Resource Management API\n\n - Please see the [Additional Azure Instructions](#Additional-Azure-Instructions)\n - for initial setup and other important info\n\n- For **GCP**, the script `gcpprojects.py` generates a config file from\n the GCP Resource Management API\n\n\n```shell\npython orgaccounts.py -f accounts.yml\n```\n```shell\npython azuresubs.py -f subscriptions.yml\n```\n```shell\npython gcpprojects.py -f projects.yml\n```\n\n## Running a Policy with c7n-org\n\nTo run a policy, the following arguments must be passed in:\n\n```shell\n-c | accounts|projects|subscriptions config file\n-s | output directory\n-u | policy\n```\n\n\n```shell\nc7n-org run -c accounts.yml -s output -u test.yml --dryrun\n```\n\nAfter running the above command, the following folder structure will be created:\n\n```\noutput\n |_ account-1\n |_ us-east-1\n |_ policy-name\n |_ resources.json\n |_ custodian-run.log\n |_ us-west-2\n |_ policy-name\n |_ resources.json\n |_ custodian-run.log\n |- account-2\n...\n```\n\nUse `c7n-org report` to generate a csv report from the output directory.\n\n## Selecting accounts, regions, policies for execution\n\nYou can filter the accounts to be run against by either passing the\naccount name or id via the `-a` flag, which can be specified multiple\ntimes, or alternatively with comma separated values.\n\nGroups of accounts can also be selected for execution by specifying\nthe `-t` tag filter. Account tags are specified in the config\nfile. ie given the above accounts config file you can specify all prod\naccounts with `-t type:prod`. you can specify the -t flag multiple\ntimes or use a comma separated list.\n\nYou can specify which policies to use for execution by either\nspecifying `-p` or selecting groups of policies via their tags with\n`-l`, both options support being specified multiple times or using\ncomma separated values.\n\nBy default in aws, c7n-org will execute in parallel across regions,\nthe \'-r\' flag can be specified multiple times, and defaults to\n(us-east-1, us-west-2). a special value of `all` will execute across\nall regions.\n\n\nSee `c7n-org run --help` for more information.\n\n## Defining and using variables\n\nEach account/subscription/project configuration in the config file can\nalso define a variables section `vars` that can be used in policies\'\ndefinitions and are interpolated at execution time. These are in\naddition to the default runtime variables custodian provides like\n`account_id`, `now`, and `region`.\n\nExample of defining in c7n-org config file:\n\n```yaml\naccounts:\n- account_id: \'123123123123\'\n name: account-1\n role: arn:aws:iam::123123123123:role/CloudCustodian\n vars:\n charge_code: xyz\n```\n\nExample of using in a policy file:\n\n```yaml\npolicies:\n - name: ec2-check-tag\n resource: aws.ec2\n filters:\n - "tag:CostCenter": "{charge_code}"\n```\n\n**Note** Variable interpolation is sensitive to proper quoting and spacing,\ni.e., `{ charge_code }` would be invalid due to the extra white space. Additionally,\nyaml parsing can transform a value like `{charge_code}` to null, unless it\'s quoted\nin strings like the above example. Values that do interpolation into other content\ndon\'t require quoting, i.e., "my_{charge_code}".\n\n## Other commands\n\nc7n-org also supports running arbitrary scripts against accounts via\nthe run-script command. For AWS the standard AWS SDK credential\ninformation is exported into the process environment before executing.\nFor Azure and GCP, only the environment variables\n`AZURE_SUBSCRIPTION_ID` and `PROJECT_ID` are exported(in addition of\nthe system env variables).\n\nc7n-org also supports generating reports for a given policy execution\nacross accounts via the `c7n-org report` subcommand.\n\n## Additional Azure Instructions\n\nIf you\'re using an Azure Service Principal for executing c7n-org\nyou\'ll need to ensure that the principal has access to multiple\nsubscriptions.\n\nFor instructions on creating a service principal and granting access\nacross subscriptions, visit the [Azure authentication docs\npage](https://cloudcustodian.io/docs/azure/authentication.html).\n', 'long_description_content_type': 'text/markdown', 'author': 'Cloud Custodian Project', - 'author_email': None, - 'maintainer': None, - 'maintainer_email': None, - 'url': 'https://cloudcustodian.io', + 'author_email': 'cloud-custodian@googlegroups.com', + 'project_urls': { + 'Homepage': 'https://cloudcustodian.io', + 'Documentation': 'https://cloudcustodian.io/docs/', + 'Source': 'https://github.com/cloud-custodian/cloud-custodian', + 'Issue Tracker': 'https://github.com/cloud-custodian/cloud-custodian/issues', + }, 'packages': packages, 'package_data': package_data, 'install_requires': install_requires, diff --git a/tools/c7n_policystream/poetry.lock b/tools/c7n_policystream/poetry.lock index 11b47c50c0d..362bcd2b326 100644 --- a/tools/c7n_policystream/poetry.lock +++ b/tools/c7n_policystream/poetry.lock @@ -21,21 +21,21 @@ optional = false python-versions = ">=3.5" [package.extras] -dev = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "furo", "sphinx", "sphinx-notfound-page", "pre-commit", "cloudpickle"] -docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] -tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] -tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "cloudpickle"] +dev = ["cloudpickle", "coverage[toml] (>=5.0.2)", "furo", "hypothesis", "mypy (>=0.900,!=0.940)", "pre-commit", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "sphinx", "sphinx-notfound-page", "zope.interface"] +docs = ["furo", "sphinx", "sphinx-notfound-page", "zope.interface"] +tests = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "zope.interface"] +tests_no_zope = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins"] [[package]] name = "boto3" -version = "1.24.77" +version = "1.24.87" description = "The AWS SDK for Python" category = "main" optional = false python-versions = ">= 3.7" [package.dependencies] -botocore = ">=1.27.77,<1.28.0" +botocore = ">=1.27.87,<1.28.0" jmespath = ">=0.7.1,<2.0.0" s3transfer = ">=0.6.0,<0.7.0" @@ -44,7 +44,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "botocore" -version = "1.27.77" +version = "1.27.87" description = "Low-level, data-driven core of boto 3." category = "main" optional = false @@ -91,7 +91,7 @@ python-versions = "*" [[package]] name = "certifi" -version = "2022.9.14" +version = "2022.9.24" description = "Python package for providing Mozilla's CA Bundle." category = "main" optional = false @@ -157,7 +157,7 @@ python-versions = ">=3.5" [[package]] name = "importlib-metadata" -version = "4.12.0" +version = "4.13.0" description = "Read metadata from Python packages" category = "main" optional = false @@ -168,9 +168,9 @@ typing-extensions = {version = ">=3.6.4", markers = "python_version < \"3.8\""} zipp = ">=0.5" [package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)"] perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.3)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] +testing = ["flake8 (<5)", "flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] [[package]] name = "importlib-resources" @@ -184,8 +184,8 @@ python-versions = ">=3.7" zipp = {version = ">=3.1.0", markers = "python_version < \"3.10\""} [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [[package]] name = "iniconfig" @@ -232,7 +232,7 @@ optional = false python-versions = ">=3.6" [package.extras] -build = ["twine", "wheel", "blurb"] +build = ["blurb", "twine", "wheel"] docs = ["sphinx"] test = ["pytest (<5.4)", "pytest-cov"] @@ -248,7 +248,7 @@ python-versions = ">=3.6" pyparsing = ">=2.0.2,<3.0.5 || >3.0.5" [[package]] -name = "pkgutil-resolve-name" +name = "pkgutil_resolve_name" version = "1.3.10" description = "Resolve a name to an object." category = "dev" @@ -307,7 +307,7 @@ optional = false python-versions = ">=3.6.8" [package.extras] -diagrams = ["railroad-diagrams", "jinja2"] +diagrams = ["jinja2", "railroad-diagrams"] [[package]] name = "pyrsistent" @@ -350,7 +350,7 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,>=2.7" six = ">=1.5" [[package]] -name = "pyyaml" +name = "PyYAML" version = "6.0" description = "YAML parser and emitter for Python" category = "main" @@ -433,8 +433,8 @@ optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*, <4" [package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "urllib3-secure-extra", "ipaddress"] +brotli = ["brotli (>=1.0.9)", "brotlicffi (>=0.8.0)", "brotlipy (>=0.6.0)"] +secure = ["certifi", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "ipaddress", "pyOpenSSL (>=0.14)", "urllib3-secure-extra"] socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] [[package]] @@ -446,8 +446,8 @@ optional = false python-versions = ">=3.7" [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "func-timeout", "jaraco.itertools", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["func-timeout", "jaraco.itertools", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [metadata] lock-version = "1.1" @@ -464,12 +464,12 @@ attrs = [ {file = "attrs-22.1.0.tar.gz", hash = "sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6"}, ] boto3 = [ - {file = "boto3-1.24.77-py3-none-any.whl", hash = "sha256:fc16e50263c24631d5fe75464e76f3a1b454b4c0015c864948a61691f9702a6e"}, - {file = "boto3-1.24.77.tar.gz", hash = "sha256:16646de3303779d6dc9c192d8a863095244de81d2e0b94f50692fbde767c6f1b"}, + {file = "boto3-1.24.87-py3-none-any.whl", hash = "sha256:bcc579e801774cb2c7dda87ff985feda1ae7e10591d11ef37526363139138bd4"}, + {file = "boto3-1.24.87.tar.gz", hash = "sha256:3dd7ed74d1d29dd8094a078be86ed61c45de6638fe18856f7a1ff9282b4d929e"}, ] botocore = [ - {file = "botocore-1.27.77-py3-none-any.whl", hash = "sha256:d88509ed291b95525205cc06ca87b54d077aae996827039f5e32375949c5aaf7"}, - {file = "botocore-1.27.77.tar.gz", hash = "sha256:77a43e970d0762080b4b79a7e00ea572ef2ae7a9f578c3c8e7f0a344ee4b4e6d"}, + {file = "botocore-1.27.87-py3-none-any.whl", hash = "sha256:c4cbd22056ace4c7aa99e62e8ae629865ab80cc8bbf7c6d68ccf0f768f0034b6"}, + {file = "botocore-1.27.87.tar.gz", hash = "sha256:216de9751116d0d1cc3901e26d95a5c9a30ecb6973ae6147af1cf504858d845a"}, ] c7n = [] cached-property = [ @@ -477,8 +477,8 @@ cached-property = [ {file = "cached_property-1.5.2-py2.py3-none-any.whl", hash = "sha256:df4f613cf7ad9a588cc381aaf4a512d26265ecebd5eb9e1ba12f1319eb85a6a0"}, ] certifi = [ - {file = "certifi-2022.9.14-py3-none-any.whl", hash = "sha256:e232343de1ab72c2aa521b625c80f699e356830fd0e2c620b465b304b17b0516"}, - {file = "certifi-2022.9.14.tar.gz", hash = "sha256:36973885b9542e6bd01dea287b2b4b3b21236307c56324fcc3f1160f2d655ed5"}, + {file = "certifi-2022.9.24-py3-none-any.whl", hash = "sha256:90c1a32f1d68f940488354e36370f6cca89f0f106db09518524c88d6ed83f382"}, + {file = "certifi-2022.9.24.tar.gz", hash = "sha256:0d9c601124e5a6ba9712dbc60d9c53c21e34f5f641fe83002317394311bdce14"}, ] cffi = [ {file = "cffi-1.15.1-cp27-cp27m-macosx_10_9_x86_64.whl", hash = "sha256:a66d3508133af6e8548451b25058d5812812ec3798c886bf38ed24a98216fab2"}, @@ -567,8 +567,8 @@ idna = [ {file = "idna-3.4.tar.gz", hash = "sha256:814f528e8dead7d329833b91c5faa87d60bf71824cd12a7530b5526063d02cb4"}, ] importlib-metadata = [ - {file = "importlib_metadata-4.12.0-py3-none-any.whl", hash = "sha256:7401a975809ea1fdc658c3aa4f78cc2195a0e019c5cbc4c06122884e9ae80c23"}, - {file = "importlib_metadata-4.12.0.tar.gz", hash = "sha256:637245b8bab2b6502fcbc752cc4b7a6f6243bb02b31c5c26156ad103d3d45670"}, + {file = "importlib_metadata-4.13.0-py3-none-any.whl", hash = "sha256:8a8a81bcf996e74fee46f0d16bd3eaa382a7eb20fd82445c3ad11f4090334116"}, + {file = "importlib_metadata-4.13.0.tar.gz", hash = "sha256:dd0173e8f150d6815e098fd354f6414b0f079af4644ddfe90c71e2fc6174346d"}, ] importlib-resources = [ {file = "importlib_resources-5.9.0-py3-none-any.whl", hash = "sha256:f78a8df21a79bcc30cfd400bdc38f314333de7c0fb619763f6b9dabab8268bb7"}, @@ -594,7 +594,7 @@ packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, {file = "packaging-21.3.tar.gz", hash = "sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb"}, ] -pkgutil-resolve-name = [ +pkgutil_resolve_name = [ {file = "pkgutil_resolve_name-1.3.10-py3-none-any.whl", hash = "sha256:ca27cc078d25c5ad71a9de0a7a330146c4e014c2462d9af19c6b828280649c5e"}, {file = "pkgutil_resolve_name-1.3.10.tar.gz", hash = "sha256:357d6c9e6a755653cfd78893817c0853af365dd51ec97f3d358a819373bbd174"}, ] @@ -680,7 +680,7 @@ python-dateutil = [ {file = "python-dateutil-2.8.2.tar.gz", hash = "sha256:0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86"}, {file = "python_dateutil-2.8.2-py2.py3-none-any.whl", hash = "sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9"}, ] -pyyaml = [ +PyYAML = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, @@ -688,6 +688,13 @@ pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782"}, + {file = "PyYAML-6.0-cp311-cp311-win32.whl", hash = "sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7"}, + {file = "PyYAML-6.0-cp311-cp311-win_amd64.whl", hash = "sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf"}, {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, @@ -729,7 +736,6 @@ six = [ ] tabulate = [ {file = "tabulate-0.8.10-py3-none-any.whl", hash = "sha256:0ba055423dbaa164b9e456abe7920c5e8ed33fcc16f6d1b2f2d152c8e1e8b4fc"}, - {file = "tabulate-0.8.10-py3.8.egg", hash = "sha256:436f1c768b424654fce8597290d2764def1eea6a77cfa5c33be00b1bc0f4f63d"}, {file = "tabulate-0.8.10.tar.gz", hash = "sha256:6c57f3f3dd7ac2782770155f3adb2db0b1a269637e42f27599925e64b114f519"}, ] tomli = [ diff --git a/tools/c7n_policystream/requirements.txt b/tools/c7n_policystream/requirements.txt index ee957885086..97d04deb3c6 100644 --- a/tools/c7n_policystream/requirements.txt +++ b/tools/c7n_policystream/requirements.txt @@ -1,21 +1,21 @@ -boto3==1.24.77; python_version >= "3.7" -botocore==1.27.77; python_version >= "3.7" -cached-property==1.5.2; python_version < "3.8" and python_version >= "3.7" -certifi==2022.9.14; python_version >= "3.7" and python_version < "4" -cffi==1.15.1; python_version >= "3.7" -charset-normalizer==2.1.1; python_version >= "3.7" and python_version < "4" and python_full_version >= "3.6.0" -click==8.1.3; python_version >= "3.7" -colorama==0.4.5; python_version >= "3.7" and python_full_version < "3.0.0" and platform_system == "Windows" or platform_system == "Windows" and python_version >= "3.7" and python_full_version >= "3.5.0" -idna==3.4; python_version >= "3.7" and python_version < "4" -importlib-metadata==4.12.0; python_version < "3.8" and python_version >= "3.7" -jmespath==1.0.1; python_version >= "3.7" -pycparser==2.21; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.7" -pygit2==1.9.2; python_version >= "3.7" -python-dateutil==2.8.2; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.3.0" and python_version >= "3.7" -pyyaml==6.0; python_version >= "3.6" -requests==2.28.1; python_version >= "3.7" and python_version < "4" -s3transfer==0.6.0; python_version >= "3.7" -six==1.16.0; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.3.0" and python_version >= "3.7" -typing-extensions==4.3.0; python_version < "3.8" and python_version >= "3.7" -urllib3==1.26.12; python_version >= "3.7" and python_full_version < "3.0.0" and python_version < "4" or python_full_version >= "3.6.0" and python_version < "4" and python_version >= "3.7" -zipp==3.8.1; python_version < "3.8" and python_version >= "3.7" +boto3==1.24.87 ; python_version >= "3.7" and python_version < "4.0" +botocore==1.27.87 ; python_version >= "3.7" and python_version < "4.0" +cached-property==1.5.2 ; python_version >= "3.7" and python_version < "3.8" +certifi==2022.9.24 ; python_version >= "3.7" and python_version < "4" +cffi==1.15.1 ; python_version >= "3.7" and python_version < "4.0" +charset-normalizer==2.1.1 ; python_version >= "3.7" and python_version < "4" +click==8.1.3 ; python_version >= "3.7" and python_version < "4.0" +colorama==0.4.5 ; python_version >= "3.7" and python_version < "4.0" and platform_system == "Windows" +idna==3.4 ; python_version >= "3.7" and python_version < "4" +importlib-metadata==4.13.0 ; python_version >= "3.7" and python_version < "3.8" +jmespath==1.0.1 ; python_version >= "3.7" and python_version < "4.0" +pycparser==2.21 ; python_version >= "3.7" and python_version < "4.0" +pygit2==1.9.2 ; python_version >= "3.7" and python_version < "4.0" +python-dateutil==2.8.2 ; python_version >= "3.7" and python_version < "4.0" +pyyaml==6.0 ; python_version >= "3.7" and python_version < "4.0" +requests==2.28.1 ; python_version >= "3.7" and python_version < "4" +s3transfer==0.6.0 ; python_version >= "3.7" and python_version < "4.0" +six==1.16.0 ; python_version >= "3.7" and python_version < "4.0" +typing-extensions==4.3.0 ; python_version >= "3.7" and python_version < "3.8" +urllib3==1.26.12 ; python_version >= "3.7" and python_version < "4" +zipp==3.8.1 ; python_version >= "3.7" and python_version < "3.8" diff --git a/tools/c7n_policystream/setup.py b/tools/c7n_policystream/setup.py index a7130c09fa4..c3c77bf7189 100644 --- a/tools/c7n_policystream/setup.py +++ b/tools/c7n_policystream/setup.py @@ -8,17 +8,17 @@ install_requires = \ ['argcomplete (>=2.0.0,<3.0.0)', 'attrs (>=22.1.0,<23.0.0)', - 'boto3 (>=1.24.77,<2.0.0)', + 'boto3 (>=1.24.87,<2.0.0)', 'boto3>=1.12.0,<2.0.0', - 'botocore (>=1.27.77,<2.0.0)', + 'botocore (>=1.27.87,<2.0.0)', 'c7n (>=0.9.19,<0.10.0)', 'click>=8.0,<9.0', 'docutils (>=0.17.1,<0.18.0)', - 'importlib-metadata (>=4.12.0,<5.0.0)', + 'importlib-metadata (>=4.13.0,<5.0.0)', 'importlib-resources (>=5.9.0,<6.0.0)', 'jmespath (>=1.0.1,<2.0.0)', 'jsonschema (>=4.16.0,<5.0.0)', - 'pkgutil-resolve-name (>=1.3.10,<2.0.0)', + 'pkgutil_resolve_name (>=1.3.10,<2.0.0)', 'pygit2>=1.9,<1.10', 'pyrsistent (>=0.18.1,<0.19.0)', 'python-dateutil (>=2.8.2,<3.0.0)', @@ -48,10 +48,13 @@ 'long_description': '# c7n-policystream: Policy Changes from Git\n\n% [comment]: # ( !!! IMPORTANT !!! )\n% [comment]: # (This file is moved during document generation.)\n% [comment]: # (Only edit the original document at ./tools/c7n_policystream/README.md)\n\nUsing custodian in accordance with infrastructure as code principles,\nwe store policy assets in a versioned control repository. This\nprovides for an audit log and facilitates code reviews. However this\ncapability is primarily of use to humans making semantic interpretations\nof changes.\n\nThis script also provides logical custodian policy changes over a git\nrepo and allows streaming those changes for machine readable/application\nconsumption. Its typically used as a basis for CI integrations or indexes\nover policies.\n\nTwo example use cases:\n\n - Doing dryrun only on changed policies within a pull request\n - Constructing a database of policy changes.\n\nPolicystream works on individual github repositories, or per Github integration\nacross an organization\'s set of repositories.\n\n## Install\n\npolicystream can be installed via pypi, provided the require pre-requisites\nlibraries are available (libgit2 > 0.26)\n\n```\npip install c7n-policystream\n```\n\nDocker images available soon, see build for constructing your own.\n\n## Build\n\nAlternatively a docker image can be built as follows\n\n```shell\n# Note must be top level directory of checkout\ncd cloud-custodian\n\ndocker build -t policystream:latest -f tools/c7n_policystream/Dockerfile .\n\ndocker run --mount src="$(pwd)",target=/repos,type=bind policystream:latest\n```\n\n## Usage\n\nStreaming use case (default stream is to stdout, also supports kinesis, rdbms and sqs)\n\n```\n $ c7n-policystream stream -r foo\n 2018-08-12 12:37:00,567: c7n.policystream:INFO Cloning repository: foo\n \n \n \n \n \n \n \n 2018-08-12 12:37:01,275: c7n.policystream:INFO Streamed 7 policy changes\n```\n\nPolicy diff between two source and target revision specs. If source\nand target are not specified default revision selection is dependent\non current working tree branch. The intent is for two use cases, if on\na non-master branch then show the diff to master. If on master show\nthe diff to previous commit on master. For repositories not using the\n`master` convention, please specify explicit source and target.\n\n\n```\n $ c7n-policystream diff -r foo -v\n```\n\nPull request use, output policies changes between current branch and master.\n\n```\n $ c7n-policystream diff -r foo\n policies:\n - filters:\n - {type: cross-account}\n name: lambda-access-check\n resource: aws.lambda\n```\n\n## Options\n\n```\n$ c7n-policystream --help\nUsage: c7n-policystream [OPTIONS] COMMAND [ARGS]...\n\n Policy changes from git history\n\nOptions:\n --help Show this message and exit.\n\nCommands:\n diff Policy diff between two arbitrary revisions.\n org-checkout Checkout repositories from a GitHub organization.\n org-stream Stream changes for repos in a GitHub organization.\n stream Stream git history policy changes to destination.\n```\n', 'long_description_content_type': 'text/markdown', 'author': 'Cloud Custodian Project', - 'author_email': None, - 'maintainer': None, - 'maintainer_email': None, - 'url': 'https://cloudcustodian.io', + 'author_email': 'cloud-custodian@googlegroups.com', + 'project_urls': { + 'Homepage': 'https://cloudcustodian.io', + 'Documentation': 'https://cloudcustodian.io/docs/', + 'Source': 'https://github.com/cloud-custodian/cloud-custodian', + 'Issue Tracker': 'https://github.com/cloud-custodian/cloud-custodian/issues', + }, 'py_modules': modules, 'install_requires': install_requires, 'entry_points': entry_points, diff --git a/tools/c7n_sphinxext/poetry.lock b/tools/c7n_sphinxext/poetry.lock index 5a651e59b20..45c9134d036 100644 --- a/tools/c7n_sphinxext/poetry.lock +++ b/tools/c7n_sphinxext/poetry.lock @@ -29,13 +29,13 @@ optional = false python-versions = ">=3.5" [package.extras] -dev = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "furo", "sphinx", "sphinx-notfound-page", "pre-commit", "cloudpickle"] -docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] -tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] -tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "cloudpickle"] +dev = ["cloudpickle", "coverage[toml] (>=5.0.2)", "furo", "hypothesis", "mypy (>=0.900,!=0.940)", "pre-commit", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "sphinx", "sphinx-notfound-page", "zope.interface"] +docs = ["furo", "sphinx", "sphinx-notfound-page", "zope.interface"] +tests = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "zope.interface"] +tests_no_zope = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins"] [[package]] -name = "babel" +name = "Babel" version = "2.10.3" description = "Internationalization utilities" category = "main" @@ -47,14 +47,14 @@ pytz = ">=2015.7" [[package]] name = "boto3" -version = "1.24.77" +version = "1.24.87" description = "The AWS SDK for Python" category = "dev" optional = false python-versions = ">= 3.7" [package.dependencies] -botocore = ">=1.27.77,<1.28.0" +botocore = ">=1.27.87,<1.28.0" jmespath = ">=0.7.1,<2.0.0" s3transfer = ">=0.6.0,<0.7.0" @@ -63,7 +63,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "botocore" -version = "1.27.77" +version = "1.27.87" description = "Low-level, data-driven core of boto 3." category = "dev" optional = false @@ -102,7 +102,7 @@ url = "../.." [[package]] name = "certifi" -version = "2022.9.14" +version = "2022.9.24" description = "Python package for providing Mozilla's CA Bundle." category = "main" optional = false @@ -176,7 +176,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [[package]] name = "importlib-metadata" -version = "4.12.0" +version = "4.13.0" description = "Read metadata from Python packages" category = "main" optional = false @@ -187,9 +187,9 @@ typing-extensions = {version = ">=3.6.4", markers = "python_version < \"3.8\""} zipp = ">=0.5" [package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)"] perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.3)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] +testing = ["flake8 (<5)", "flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] [[package]] name = "importlib-resources" @@ -203,11 +203,11 @@ python-versions = ">=3.7" zipp = {version = ">=3.1.0", markers = "python_version < \"3.10\""} [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [[package]] -name = "jinja2" +name = "Jinja2" version = "3.1.2" description = "A very fast and expressive template engine." category = "main" @@ -249,7 +249,7 @@ format = ["fqdn", "idna", "isoduration", "jsonpointer (>1.13)", "rfc3339-validat format-nongpl = ["fqdn", "idna", "isoduration", "jsonpointer (>1.13)", "rfc3339-validator", "rfc3986-validator (>0.1.0)", "uri-template", "webcolors (>=1.11)"] [[package]] -name = "markdown" +name = "Markdown" version = "3.0.1" description = "Python implementation of Markdown." category = "main" @@ -269,17 +269,17 @@ mdurl = ">=0.1,<1.0" typing_extensions = {version = ">=3.7.4", markers = "python_version < \"3.8\""} [package.extras] -testing = ["pytest-regressions", "pytest-cov", "pytest", "coverage"] -rtd = ["sphinx-book-theme", "sphinx-design", "sphinx-copybutton", "sphinx", "pyyaml", "myst-parser", "attrs"] -profiling = ["gprof2dot"] -plugins = ["mdit-py-plugins"] -linkify = ["linkify-it-py (>=1.0,<2.0)"] -compare = ["panflute (>=2.1.3,<2.2.0)", "mistune (>=2.0.2,<2.1.0)", "mistletoe (>=0.8.1,<0.9.0)", "markdown (>=3.3.6,<3.4.0)", "commonmark (>=0.9.1,<0.10.0)"] +benchmarking = ["psutil", "pytest", "pytest-benchmark (>=3.2,<4.0)"] code_style = ["pre-commit (==2.6)"] -benchmarking = ["pytest-benchmark (>=3.2,<4.0)", "pytest", "psutil"] +compare = ["commonmark (>=0.9.1,<0.10.0)", "markdown (>=3.3.6,<3.4.0)", "mistletoe (>=0.8.1,<0.9.0)", "mistune (>=2.0.2,<2.1.0)", "panflute (>=2.1.3,<2.2.0)"] +linkify = ["linkify-it-py (>=1.0,<2.0)"] +plugins = ["mdit-py-plugins"] +profiling = ["gprof2dot"] +rtd = ["attrs", "myst-parser", "pyyaml", "sphinx", "sphinx-copybutton", "sphinx-design", "sphinx_book_theme"] +testing = ["coverage", "pytest", "pytest-cov", "pytest-regressions"] [[package]] -name = "markupsafe" +name = "MarkupSafe" version = "2.1.1" description = "Safely add untrusted strings to HTML/XML markup." category = "main" @@ -288,19 +288,19 @@ python-versions = ">=3.7" [[package]] name = "mdit-py-plugins" -version = "0.3.0" +version = "0.3.1" description = "Collection of plugins for markdown-it-py" category = "main" optional = false -python-versions = "~=3.6" +python-versions = ">=3.7" [package.dependencies] markdown-it-py = ">=1.0.0,<3.0.0" [package.extras] -testing = ["pytest-regressions", "pytest-cov", "pytest (>=3.6,<4)", "coverage"] -rtd = ["sphinx-book-theme (>=0.1.0,<0.2.0)", "myst-parser (>=0.14.0,<0.15.0)"] -code_style = ["pre-commit (==2.6)"] +code_style = ["pre-commit"] +rtd = ["attrs", "myst-parser (>=0.16.1,<0.17.0)", "sphinx-book-theme (>=0.1.0,<0.2.0)"] +testing = ["coverage", "pytest", "pytest-cov", "pytest-regressions"] [[package]] name = "mdurl" @@ -312,17 +312,17 @@ python-versions = ">=3.7" [[package]] name = "myst-parser" -version = "0.18.0" +version = "0.18.1" description = "An extended commonmark compliant parser, with bridges to docutils & sphinx." category = "main" optional = false python-versions = ">=3.7" [package.dependencies] -docutils = ">=0.15,<0.19" +docutils = ">=0.15,<0.20" jinja2 = "*" markdown-it-py = ">=1.0.0,<3.0.0" -mdit-py-plugins = ">=0.3.0,<0.4.0" +mdit-py-plugins = ">=0.3.1,<0.4.0" pyyaml = "*" sphinx = ">=4,<6" typing-extensions = "*" @@ -330,8 +330,8 @@ typing-extensions = "*" [package.extras] code_style = ["pre-commit (>=2.12,<3.0)"] linkify = ["linkify-it-py (>=1.0,<2.0)"] -rtd = ["ipython", "sphinx-book-theme", "sphinx-design", "sphinxext-rediraffe (>=0.2.7,<0.3.0)", "sphinxcontrib.mermaid (>=0.7.1,<0.8.0)", "sphinxext-opengraph (>=0.6.3,<0.7.0)"] -testing = ["beautifulsoup4", "coverage", "pytest (>=6,<7)", "pytest-cov", "pytest-regressions", "pytest-param-files (>=0.3.4,<0.4.0)", "sphinx-pytest"] +rtd = ["ipython", "sphinx-book-theme", "sphinx-design", "sphinxcontrib.mermaid (>=0.7.1,<0.8.0)", "sphinxext-opengraph (>=0.6.3,<0.7.0)", "sphinxext-rediraffe (>=0.2.7,<0.3.0)"] +testing = ["beautifulsoup4", "coverage[toml]", "pytest (>=6,<7)", "pytest-cov", "pytest-param-files (>=0.3.4,<0.4.0)", "pytest-regressions", "sphinx (<5.2)", "sphinx-pytest"] [[package]] name = "packaging" @@ -345,7 +345,7 @@ python-versions = ">=3.6" pyparsing = ">=2.0.2,<3.0.5 || >3.0.5" [[package]] -name = "pkgutil-resolve-name" +name = "pkgutil_resolve_name" version = "1.3.10" description = "Resolve a name to an object." category = "dev" @@ -353,7 +353,7 @@ optional = false python-versions = ">=3.6" [[package]] -name = "pygments" +name = "Pygments" version = "2.13.0" description = "Pygments is a syntax highlighting package written in Python." category = "main" @@ -372,7 +372,7 @@ optional = false python-versions = ">=3.6.8" [package.extras] -diagrams = ["railroad-diagrams", "jinja2"] +diagrams = ["jinja2", "railroad-diagrams"] [[package]] name = "pyrsistent" @@ -395,14 +395,14 @@ six = ">=1.5" [[package]] name = "pytz" -version = "2022.2.1" +version = "2022.4" description = "World timezone definitions, modern and historical" category = "main" optional = false python-versions = "*" [[package]] -name = "pyyaml" +name = "PyYAML" version = "6.0" description = "YAML parser and emitter for Python" category = "main" @@ -471,7 +471,7 @@ optional = false python-versions = "*" [[package]] -name = "sphinx" +name = "Sphinx" version = "4.5.0" description = "Python documentation generator" category = "main" @@ -499,8 +499,8 @@ sphinxcontrib-serializinghtml = ">=1.1.5" [package.extras] docs = ["sphinxcontrib-websupport"] -lint = ["flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "docutils-stubs", "types-typed-ast", "types-requests"] -test = ["pytest", "pytest-cov", "html5lib", "cython", "typed-ast"] +lint = ["docutils-stubs", "flake8 (>=3.5.0)", "isort", "mypy (>=0.931)", "types-requests", "types-typed-ast"] +test = ["cython", "html5lib", "pytest", "pytest-cov", "typed-ast"] [[package]] name = "sphinx-markdown-tables" @@ -526,7 +526,7 @@ docutils = "<0.18" sphinx = ">=1.6" [package.extras] -dev = ["transifex-client", "sphinxcontrib-httpdomain", "bump2version"] +dev = ["bump2version", "sphinxcontrib-httpdomain", "transifex-client"] [[package]] name = "sphinxcontrib-applehelp" @@ -537,7 +537,7 @@ optional = false python-versions = ">=3.5" [package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] +lint = ["docutils-stubs", "flake8", "mypy"] test = ["pytest"] [[package]] @@ -549,7 +549,7 @@ optional = false python-versions = ">=3.5" [package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] +lint = ["docutils-stubs", "flake8", "mypy"] test = ["pytest"] [[package]] @@ -561,8 +561,8 @@ optional = false python-versions = ">=3.6" [package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] -test = ["pytest", "html5lib"] +lint = ["docutils-stubs", "flake8", "mypy"] +test = ["html5lib", "pytest"] [[package]] name = "sphinxcontrib-jsmath" @@ -573,7 +573,7 @@ optional = false python-versions = ">=3.5" [package.extras] -test = ["pytest", "flake8", "mypy"] +test = ["flake8", "mypy", "pytest"] [[package]] name = "sphinxcontrib-qthelp" @@ -584,7 +584,7 @@ optional = false python-versions = ">=3.5" [package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] +lint = ["docutils-stubs", "flake8", "mypy"] test = ["pytest"] [[package]] @@ -596,7 +596,7 @@ optional = false python-versions = ">=3.5" [package.extras] -lint = ["flake8", "mypy", "docutils-stubs"] +lint = ["docutils-stubs", "flake8", "mypy"] test = ["pytest"] [[package]] @@ -627,8 +627,8 @@ optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*, <4" [package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "urllib3-secure-extra", "ipaddress"] +brotli = ["brotli (>=1.0.9)", "brotlicffi (>=0.8.0)", "brotlipy (>=0.6.0)"] +secure = ["certifi", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "ipaddress", "pyOpenSSL (>=0.14)", "urllib3-secure-extra"] socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] [[package]] @@ -640,8 +640,8 @@ optional = false python-versions = ">=3.7" [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "func-timeout", "jaraco.itertools", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["func-timeout", "jaraco.itertools", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [metadata] lock-version = "1.1" @@ -661,22 +661,22 @@ attrs = [ {file = "attrs-22.1.0-py2.py3-none-any.whl", hash = "sha256:86efa402f67bf2df34f51a335487cf46b1ec130d02b8d39fd248abfd30da551c"}, {file = "attrs-22.1.0.tar.gz", hash = "sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6"}, ] -babel = [ +Babel = [ {file = "Babel-2.10.3-py3-none-any.whl", hash = "sha256:ff56f4892c1c4bf0d814575ea23471c230d544203c7748e8c68f0089478d48eb"}, {file = "Babel-2.10.3.tar.gz", hash = "sha256:7614553711ee97490f732126dc077f8d0ae084ebc6a96e23db1482afabdb2c51"}, ] boto3 = [ - {file = "boto3-1.24.77-py3-none-any.whl", hash = "sha256:fc16e50263c24631d5fe75464e76f3a1b454b4c0015c864948a61691f9702a6e"}, - {file = "boto3-1.24.77.tar.gz", hash = "sha256:16646de3303779d6dc9c192d8a863095244de81d2e0b94f50692fbde767c6f1b"}, + {file = "boto3-1.24.87-py3-none-any.whl", hash = "sha256:bcc579e801774cb2c7dda87ff985feda1ae7e10591d11ef37526363139138bd4"}, + {file = "boto3-1.24.87.tar.gz", hash = "sha256:3dd7ed74d1d29dd8094a078be86ed61c45de6638fe18856f7a1ff9282b4d929e"}, ] botocore = [ - {file = "botocore-1.27.77-py3-none-any.whl", hash = "sha256:d88509ed291b95525205cc06ca87b54d077aae996827039f5e32375949c5aaf7"}, - {file = "botocore-1.27.77.tar.gz", hash = "sha256:77a43e970d0762080b4b79a7e00ea572ef2ae7a9f578c3c8e7f0a344ee4b4e6d"}, + {file = "botocore-1.27.87-py3-none-any.whl", hash = "sha256:c4cbd22056ace4c7aa99e62e8ae629865ab80cc8bbf7c6d68ccf0f768f0034b6"}, + {file = "botocore-1.27.87.tar.gz", hash = "sha256:216de9751116d0d1cc3901e26d95a5c9a30ecb6973ae6147af1cf504858d845a"}, ] c7n = [] certifi = [ - {file = "certifi-2022.9.14-py3-none-any.whl", hash = "sha256:e232343de1ab72c2aa521b625c80f699e356830fd0e2c620b465b304b17b0516"}, - {file = "certifi-2022.9.14.tar.gz", hash = "sha256:36973885b9542e6bd01dea287b2b4b3b21236307c56324fcc3f1160f2d655ed5"}, + {file = "certifi-2022.9.24-py3-none-any.whl", hash = "sha256:90c1a32f1d68f940488354e36370f6cca89f0f106db09518524c88d6ed83f382"}, + {file = "certifi-2022.9.24.tar.gz", hash = "sha256:0d9c601124e5a6ba9712dbc60d9c53c21e34f5f641fe83002317394311bdce14"}, ] charset-normalizer = [ {file = "charset-normalizer-2.1.1.tar.gz", hash = "sha256:5a3d016c7c547f69d6f81fb0db9449ce888b418b5b9952cc5e6e66843e9dd845"}, @@ -707,14 +707,14 @@ imagesize = [ {file = "imagesize-1.4.1.tar.gz", hash = "sha256:69150444affb9cb0d5cc5a92b3676f0b2fb7cd9ae39e947a5e11a36b4497cd4a"}, ] importlib-metadata = [ - {file = "importlib_metadata-4.12.0-py3-none-any.whl", hash = "sha256:7401a975809ea1fdc658c3aa4f78cc2195a0e019c5cbc4c06122884e9ae80c23"}, - {file = "importlib_metadata-4.12.0.tar.gz", hash = "sha256:637245b8bab2b6502fcbc752cc4b7a6f6243bb02b31c5c26156ad103d3d45670"}, + {file = "importlib_metadata-4.13.0-py3-none-any.whl", hash = "sha256:8a8a81bcf996e74fee46f0d16bd3eaa382a7eb20fd82445c3ad11f4090334116"}, + {file = "importlib_metadata-4.13.0.tar.gz", hash = "sha256:dd0173e8f150d6815e098fd354f6414b0f079af4644ddfe90c71e2fc6174346d"}, ] importlib-resources = [ {file = "importlib_resources-5.9.0-py3-none-any.whl", hash = "sha256:f78a8df21a79bcc30cfd400bdc38f314333de7c0fb619763f6b9dabab8268bb7"}, {file = "importlib_resources-5.9.0.tar.gz", hash = "sha256:5481e97fb45af8dcf2f798952625591c58fe599d0735d86b10f54de086a61681"}, ] -jinja2 = [ +Jinja2 = [ {file = "Jinja2-3.1.2-py3-none-any.whl", hash = "sha256:6088930bfe239f0e6710546ab9c19c9ef35e29792895fed6e6e31a023a182a61"}, {file = "Jinja2-3.1.2.tar.gz", hash = "sha256:31351a702a408a9e7595a8fc6150fc3f43bb6bf7e319770cbc0db9df9437e852"}, ] @@ -726,7 +726,7 @@ jsonschema = [ {file = "jsonschema-4.16.0-py3-none-any.whl", hash = "sha256:9e74b8f9738d6a946d70705dc692b74b5429cd0960d58e79ffecfc43b2221eb9"}, {file = "jsonschema-4.16.0.tar.gz", hash = "sha256:165059f076eff6971bae5b742fc029a7b4ef3f9bcf04c14e4776a7605de14b23"}, ] -markdown = [ +Markdown = [ {file = "Markdown-3.0.1-py2.py3-none-any.whl", hash = "sha256:c00429bd503a47ec88d5e30a751e147dcb4c6889663cd3e2ba0afe858e009baa"}, {file = "Markdown-3.0.1.tar.gz", hash = "sha256:d02e0f9b04c500cde6637c11ad7c72671f359b87b9fe924b2383649d8841db7c"}, ] @@ -734,7 +734,7 @@ markdown-it-py = [ {file = "markdown-it-py-2.1.0.tar.gz", hash = "sha256:cf7e59fed14b5ae17c0006eff14a2d9a00ed5f3a846148153899a0224e2c07da"}, {file = "markdown_it_py-2.1.0-py3-none-any.whl", hash = "sha256:93de681e5c021a432c63147656fe21790bc01231e0cd2da73626f1aa3ac0fe27"}, ] -markupsafe = [ +MarkupSafe = [ {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:86b1f75c4e7c2ac2ccdaec2b9022845dbb81880ca318bb7a0a01fbf7813e3812"}, {file = "MarkupSafe-2.1.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f121a1420d4e173a5d96e47e9a0c0dcff965afdf1626d28de1460815f7c4ee7a"}, {file = "MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a49907dd8420c5685cfa064a1335b6754b74541bbb3706c259c02ed65b644b3e"}, @@ -777,26 +777,26 @@ markupsafe = [ {file = "MarkupSafe-2.1.1.tar.gz", hash = "sha256:7f91197cc9e48f989d12e4e6fbc46495c446636dfc81b9ccf50bb0ec74b91d4b"}, ] mdit-py-plugins = [ - {file = "mdit-py-plugins-0.3.0.tar.gz", hash = "sha256:ecc24f51eeec6ab7eecc2f9724e8272c2fb191c2e93cf98109120c2cace69750"}, - {file = "mdit_py_plugins-0.3.0-py3-none-any.whl", hash = "sha256:b1279701cee2dbf50e188d3da5f51fee8d78d038cdf99be57c6b9d1aa93b4073"}, + {file = "mdit-py-plugins-0.3.1.tar.gz", hash = "sha256:3fc13298497d6e04fe96efdd41281bfe7622152f9caa1815ea99b5c893de9441"}, + {file = "mdit_py_plugins-0.3.1-py3-none-any.whl", hash = "sha256:606a7f29cf56dbdfaf914acb21709b8f8ee29d857e8f29dcc33d8cb84c57bfa1"}, ] mdurl = [ {file = "mdurl-0.1.2-py3-none-any.whl", hash = "sha256:84008a41e51615a49fc9966191ff91509e3c40b939176e643fd50a5c2196b8f8"}, {file = "mdurl-0.1.2.tar.gz", hash = "sha256:bb413d29f5eea38f31dd4754dd7377d4465116fb207585f97bf925588687c1ba"}, ] myst-parser = [ - {file = "myst-parser-0.18.0.tar.gz", hash = "sha256:739a4d96773a8e55a2cacd3941ce46a446ee23dcd6b37e06f73f551ad7821d86"}, - {file = "myst_parser-0.18.0-py3-none-any.whl", hash = "sha256:4965e51918837c13bf1c6f6fe2c6bddddf193148360fbdaefe743a4981358f6a"}, + {file = "myst-parser-0.18.1.tar.gz", hash = "sha256:79317f4bb2c13053dd6e64f9da1ba1da6cd9c40c8a430c447a7b146a594c246d"}, + {file = "myst_parser-0.18.1-py3-none-any.whl", hash = "sha256:61b275b85d9f58aa327f370913ae1bec26ebad372cc99f3ab85c8ec3ee8d9fb8"}, ] packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, {file = "packaging-21.3.tar.gz", hash = "sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb"}, ] -pkgutil-resolve-name = [ +pkgutil_resolve_name = [ {file = "pkgutil_resolve_name-1.3.10-py3-none-any.whl", hash = "sha256:ca27cc078d25c5ad71a9de0a7a330146c4e014c2462d9af19c6b828280649c5e"}, {file = "pkgutil_resolve_name-1.3.10.tar.gz", hash = "sha256:357d6c9e6a755653cfd78893817c0853af365dd51ec97f3d358a819373bbd174"}, ] -pygments = [ +Pygments = [ {file = "Pygments-2.13.0-py3-none-any.whl", hash = "sha256:f643f331ab57ba3c9d89212ee4a2dabc6e94f117cf4eefde99a0574720d14c42"}, {file = "Pygments-2.13.0.tar.gz", hash = "sha256:56a8508ae95f98e2b9bdf93a6be5ae3f7d8af858b43e02c5a2ff083726be40c1"}, ] @@ -832,10 +832,10 @@ python-dateutil = [ {file = "python_dateutil-2.8.2-py2.py3-none-any.whl", hash = "sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9"}, ] pytz = [ - {file = "pytz-2022.2.1-py2.py3-none-any.whl", hash = "sha256:220f481bdafa09c3955dfbdddb7b57780e9a94f5127e35456a48589b9e0c0197"}, - {file = "pytz-2022.2.1.tar.gz", hash = "sha256:cea221417204f2d1a2aa03ddae3e867921971d0d76f14d87abb4414415bbdcf5"}, + {file = "pytz-2022.4-py2.py3-none-any.whl", hash = "sha256:2c0784747071402c6e99f0bafdb7da0fa22645f06554c7ae06bf6358897e9c91"}, + {file = "pytz-2022.4.tar.gz", hash = "sha256:48ce799d83b6f8aab2020e369b627446696619e79645419610b9facd909b3174"}, ] -pyyaml = [ +PyYAML = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, @@ -843,6 +843,13 @@ pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782"}, + {file = "PyYAML-6.0-cp311-cp311-win32.whl", hash = "sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7"}, + {file = "PyYAML-6.0-cp311-cp311-win_amd64.whl", hash = "sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf"}, {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, @@ -890,7 +897,7 @@ snowballstemmer = [ {file = "snowballstemmer-2.2.0-py2.py3-none-any.whl", hash = "sha256:c8e1716e83cc398ae16824e5572ae04e0d9fc2c6b985fb0f900f5f0c96ecba1a"}, {file = "snowballstemmer-2.2.0.tar.gz", hash = "sha256:09b16deb8547d3412ad7b590689584cd0fe25ec8db3be37788be3810cbf19cb1"}, ] -sphinx = [ +Sphinx = [ {file = "Sphinx-4.5.0-py3-none-any.whl", hash = "sha256:ebf612653238bcc8f4359627a9b7ce44ede6fdd75d9d30f68255c7383d3a6226"}, {file = "Sphinx-4.5.0.tar.gz", hash = "sha256:7bf8ca9637a4ee15af412d1a1d9689fec70523a68ca9bb9127c2f3eeb344e2e6"}, ] @@ -928,7 +935,6 @@ sphinxcontrib-serializinghtml = [ ] tabulate = [ {file = "tabulate-0.8.10-py3-none-any.whl", hash = "sha256:0ba055423dbaa164b9e456abe7920c5e8ed33fcc16f6d1b2f2d152c8e1e8b4fc"}, - {file = "tabulate-0.8.10-py3.8.egg", hash = "sha256:436f1c768b424654fce8597290d2764def1eea6a77cfa5c33be00b1bc0f4f63d"}, {file = "tabulate-0.8.10.tar.gz", hash = "sha256:6c57f3f3dd7ac2782770155f3adb2db0b1a269637e42f27599925e64b114f519"}, ] typing-extensions = [ diff --git a/tools/c7n_sphinxext/requirements.txt b/tools/c7n_sphinxext/requirements.txt index 2d3452431b3..66bd393374e 100644 --- a/tools/c7n_sphinxext/requirements.txt +++ b/tools/c7n_sphinxext/requirements.txt @@ -1,38 +1,38 @@ -alabaster==0.7.12; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.7" -babel==2.10.3; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.7" -certifi==2022.9.14; python_version >= "3.7" and python_version < "4" -charset-normalizer==2.1.1; python_version >= "3.7" and python_version < "4" and python_full_version >= "3.6.0" -click==8.1.3; python_version >= "3.7" -colorama==0.4.5; python_version >= "3.7" and python_full_version < "3.0.0" and sys_platform == "win32" and platform_system == "Windows" and (python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.6") or sys_platform == "win32" and python_version >= "3.7" and python_full_version >= "3.5.0" and platform_system == "Windows" and (python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.6") -commonmark==0.9.1 -docutils==0.17.1; (python_version >= "2.7" and python_full_version < "3.0.0") or (python_full_version >= "3.5.0") -idna==3.4; python_version >= "3.7" and python_version < "4" -imagesize==1.4.1; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.7" -importlib-metadata==4.12.0; python_version < "3.8" and python_version >= "3.7" and (python_version >= "3.6" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.6") -jinja2==3.1.2; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.7" -markdown-it-py==2.1.0; python_version >= "3.7" and python_version < "4.0" -markdown==3.0.1; python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" -markupsafe==2.1.1; python_version >= "3.7" -mdit-py-plugins==0.3.0; python_version >= "3.7" and python_version < "4.0" -mdurl==0.1.2; python_version >= "3.7" -myst-parser==0.18.0; python_version >= "3.7" -packaging==21.3; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.7" -pygments==2.13.0; python_version >= "3.6" -pyparsing==3.0.9; python_full_version >= "3.6.8" and python_version >= "3.6" -pytz==2022.2.1; python_version >= "3.6" -pyyaml==6.0; python_version >= "3.7" -recommonmark==0.6.0 -requests==2.28.1; python_version >= "3.7" and python_version < "4" and (python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.7") -snowballstemmer==2.2.0; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.7" -sphinx-markdown-tables==0.0.12 -sphinx-rtd-theme==1.0.0; (python_version >= "2.7" and python_full_version < "3.0.0") or (python_full_version >= "3.4.0") -sphinx==4.5.0; python_version >= "3.6" -sphinxcontrib-applehelp==1.0.2; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.7" -sphinxcontrib-devhelp==1.0.2; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.7" -sphinxcontrib-htmlhelp==2.0.0; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.7" -sphinxcontrib-jsmath==1.0.1; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.7" -sphinxcontrib-qthelp==1.0.3; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.7" -sphinxcontrib-serializinghtml==1.1.5; python_version >= "3.7" and python_full_version < "3.0.0" or python_full_version >= "3.4.0" and python_version >= "3.7" -typing-extensions==4.3.0; python_version < "3.8" and python_version >= "3.7" -urllib3==1.26.12; python_version >= "3.7" and python_full_version < "3.0.0" and python_version < "4" or python_full_version >= "3.6.0" and python_version < "4" and python_version >= "3.7" -zipp==3.8.1; python_version < "3.8" and python_version >= "3.7" +alabaster==0.7.12 ; python_version >= "3.7" and python_version < "4.0" +babel==2.10.3 ; python_version >= "3.7" and python_version < "4.0" +certifi==2022.9.24 ; python_version >= "3.7" and python_version < "4" +charset-normalizer==2.1.1 ; python_version >= "3.7" and python_version < "4" +click==8.1.3 ; python_version >= "3.7" and python_version < "4.0" +colorama==0.4.5 ; python_version >= "3.7" and python_version < "4.0" and sys_platform == "win32" or python_version >= "3.7" and python_version < "4.0" and platform_system == "Windows" +commonmark==0.9.1 ; python_version >= "3.7" and python_version < "4.0" +docutils==0.17.1 ; python_version >= "3.7" and python_version < "4.0" +idna==3.4 ; python_version >= "3.7" and python_version < "4" +imagesize==1.4.1 ; python_version >= "3.7" and python_version < "4.0" +importlib-metadata==4.13.0 ; python_version >= "3.7" and python_version < "3.10" +jinja2==3.1.2 ; python_version >= "3.7" and python_version < "4.0" +markdown-it-py==2.1.0 ; python_version >= "3.7" and python_version < "4.0" +markdown==3.0.1 ; python_version >= "3.7" and python_version < "4.0" +markupsafe==2.1.1 ; python_version >= "3.7" and python_version < "4.0" +mdit-py-plugins==0.3.1 ; python_version >= "3.7" and python_version < "4.0" +mdurl==0.1.2 ; python_version >= "3.7" and python_version < "4.0" +myst-parser==0.18.1 ; python_version >= "3.7" and python_version < "4.0" +packaging==21.3 ; python_version >= "3.7" and python_version < "4.0" +pygments==2.13.0 ; python_version >= "3.7" and python_version < "4.0" +pyparsing==3.0.9 ; python_version >= "3.7" and python_version < "4.0" +pytz==2022.4 ; python_version >= "3.7" and python_version < "4.0" +pyyaml==6.0 ; python_version >= "3.7" and python_version < "4.0" +recommonmark==0.6.0 ; python_version >= "3.7" and python_version < "4.0" +requests==2.28.1 ; python_version >= "3.7" and python_version < "4" +snowballstemmer==2.2.0 ; python_version >= "3.7" and python_version < "4.0" +sphinx-markdown-tables==0.0.12 ; python_version >= "3.7" and python_version < "4.0" +sphinx-rtd-theme==1.0.0 ; python_version >= "3.7" and python_version < "4.0" +sphinx==4.5.0 ; python_version >= "3.7" and python_version < "4.0" +sphinxcontrib-applehelp==1.0.2 ; python_version >= "3.7" and python_version < "4.0" +sphinxcontrib-devhelp==1.0.2 ; python_version >= "3.7" and python_version < "4.0" +sphinxcontrib-htmlhelp==2.0.0 ; python_version >= "3.7" and python_version < "4.0" +sphinxcontrib-jsmath==1.0.1 ; python_version >= "3.7" and python_version < "4.0" +sphinxcontrib-qthelp==1.0.3 ; python_version >= "3.7" and python_version < "4.0" +sphinxcontrib-serializinghtml==1.1.5 ; python_version >= "3.7" and python_version < "4.0" +typing-extensions==4.3.0 ; python_version >= "3.7" and python_version < "4.0" +urllib3==1.26.12 ; python_version >= "3.7" and python_version < "4" +zipp==3.8.1 ; python_version >= "3.7" and python_version < "3.10" diff --git a/tools/c7n_sphinxext/setup.py b/tools/c7n_sphinxext/setup.py index d6c8efd4d5d..0085465e675 100644 --- a/tools/c7n_sphinxext/setup.py +++ b/tools/c7n_sphinxext/setup.py @@ -14,18 +14,18 @@ 'Sphinx>=4.2.0,<5.0.0', 'argcomplete (>=2.0.0,<3.0.0)', 'attrs (>=22.1.0,<23.0.0)', - 'boto3 (>=1.24.77,<2.0.0)', - 'botocore (>=1.27.77,<2.0.0)', + 'boto3 (>=1.24.87,<2.0.0)', + 'botocore (>=1.27.87,<2.0.0)', 'c7n (>=0.9.19,<0.10.0)', 'click>=8.0,<9.0', 'docutils (>=0.17.1,<0.18.0)', 'docutils>=0.14,<0.18', - 'importlib-metadata (>=4.12.0,<5.0.0)', + 'importlib-metadata (>=4.13.0,<5.0.0)', 'importlib-resources (>=5.9.0,<6.0.0)', 'jmespath (>=1.0.1,<2.0.0)', 'jsonschema (>=4.16.0,<5.0.0)', 'myst-parser>=0.18.0,<0.19.0', - 'pkgutil-resolve-name (>=1.3.10,<2.0.0)', + 'pkgutil_resolve_name (>=1.3.10,<2.0.0)', 'pyrsistent (>=0.18.1,<0.19.0)', 'python-dateutil (>=2.8.2,<3.0.0)', 'pyyaml (>=6.0,<7.0)', @@ -55,10 +55,13 @@ 'long_description': '# Sphinx Extensions\n\nCustom sphinx extensions for use with Cloud Custodian.\n\n', 'long_description_content_type': 'text/markdown', 'author': 'Cloud Custodian Project', - 'author_email': None, - 'maintainer': None, - 'maintainer_email': None, - 'url': 'https://cloudcustodian.io', + 'author_email': 'cloud-custodian@googlegroups.com', + 'project_urls': { + 'Homepage': 'https://cloudcustodian.io', + 'Documentation': 'https://cloudcustodian.io/docs/', + 'Source': 'https://github.com/cloud-custodian/cloud-custodian', + 'Issue Tracker': 'https://github.com/cloud-custodian/cloud-custodian/issues', + }, 'packages': packages, 'package_data': package_data, 'install_requires': install_requires, diff --git a/tools/c7n_tencentcloud/c7n_tencentcloud/client.py b/tools/c7n_tencentcloud/c7n_tencentcloud/client.py index afe73a8b432..c701bd8c0ba 100644 --- a/tools/c7n_tencentcloud/c7n_tencentcloud/client.py +++ b/tools/c7n_tencentcloud/c7n_tencentcloud/client.py @@ -88,14 +88,21 @@ def execute_paged_query(self, action: str, params: dict, or len(results) > self.MAX_RESPONSE_DATA_COUNT): raise PolicyExecutionError("get too many resources from cloud provider") + # some api Offset and Limit fields are string + if paging_method == PageMethod.Offset and isinstance(paging_def["limit"]["value"], str): + params[PageMethod.Offset.name] = str(params[PageMethod.Offset.name]) + result = self.execute_query(action, params) query_counter += 1 items = jmespath.search(jsonpath, result) if len(items) > 0: results.extend(items) if paging_method == PageMethod.Offset: - params[PageMethod.Offset.name] = params[PageMethod.Offset.name] +\ - paging_def["limit"]["value"] + if len(items) < int(paging_def["limit"]["value"]): + # no more data + break + params[PageMethod.Offset.name] = int(params[PageMethod.Offset.name]) +\ + int(paging_def["limit"]["value"]) else: token = jmespath.search(pagination_token_path, result) if token == "": diff --git a/tools/c7n_tencentcloud/c7n_tencentcloud/filters/__init__.py b/tools/c7n_tencentcloud/c7n_tencentcloud/filters/__init__.py index ff2d798899d..0fec1454267 100644 --- a/tools/c7n_tencentcloud/c7n_tencentcloud/filters/__init__.py +++ b/tools/c7n_tencentcloud/c7n_tencentcloud/filters/__init__.py @@ -1,2 +1,5 @@ # Copyright The Cloud Custodian Authors. # SPDX-License-Identifier: Apache-2.0 + +from .metrics import MetricsFilter + diff --git a/tools/c7n_tencentcloud/c7n_tencentcloud/filters/metrics.py b/tools/c7n_tencentcloud/c7n_tencentcloud/filters/metrics.py new file mode 100644 index 00000000000..7f09a5f27ec --- /dev/null +++ b/tools/c7n_tencentcloud/c7n_tencentcloud/filters/metrics.py @@ -0,0 +1,157 @@ +# Copyright The Cloud Custodian Authors. +# SPDX-License-Identifier: Apache-2.0 + +""" +Monitoring Metrics filters suppport for resources +""" +import jmespath +import logging +from statistics import mean +from datetime import datetime, timedelta, timezone +from c7n.exceptions import PolicyValidationError, PolicyExecutionError +from c7n.manager import ResourceManager +from c7n.filters.core import Filter, OPERATORS +from c7n.utils import type_schema, chunks, local_session +from c7n_tencentcloud.provider import resources as provider_resources +from c7n_tencentcloud.query import ResourceTypeInfo + + +log = logging.getLogger("custodian.tencentcloud.filter") + + +STATISTICS_OPERATORS = { + "Average": mean, + "Sum": sum, + "Maximum": max, + "Minimum": min +} + + +class MetricsFilter(Filter): + """MetricsFilter""" + name = "metrics" + schema = type_schema( + name, + **{ + "name": {"type": "string"}, + "namespace": {"type": "string"}, + "statistics": {"type": "string", "enum": list(STATISTICS_OPERATORS.keys())}, + "days": {"type": "number"}, + "op": {"type": "string", "enum": list(OPERATORS.keys())}, # TODO, remove unsupported op + "value": {"type": "number"}, + "missing-value": {"type": "number"}, + "period": {"type": "number"}, + "required": ("value", "name") + } + ) + schema_alias = True + permissions = () + + DEFAULT_NAMESPACE = { + "cvm": "QCE/CVM", + } + + def __init__(self, data, manager=None): + super().__init__(data, manager) + self.days = self.data.get("days", 0) + self.start_time, self.end_time = self.get_metric_window() + self.metric_name = self.data["name"] + self.period = self.data.get("period", 300) + self.statistics = self.data.get("statistics", "Average") + self.op = self.data.get("op", "less-than") + self.missing_value = self.data.get("missing-value") + self.value = self.data["value"] + self.resource_metadata: ResourceTypeInfo = self.manager.get_model() + ns = self.data.get("namespace") + if not ns: + ns = self.resource_metadata.metrics_namespace + if not ns: + ns = self.DEFAULT_NAMESPACE[self.resource_metadata.service] + self.namespace = ns + + def get_metric_window(self): + """get_metric_window""" + duration = timedelta(days=self.days) + # delete microsecond to meet SKD api + now = datetime.now(timezone.utc).replace(microsecond=0) + start = now - duration + return start.isoformat(), now.isoformat() + + def _get_request_params(self, resources): + ids = [res[self.resource_metadata.id] for res in resources] + dimensions = [] + for iter_id in ids: + dimensions.append({ + "Dimensions": [{ + "Name": self.resource_metadata.metrics_instance_id_name, + "Value": iter_id + }] + }) + return { + "Namespace": self.namespace, + "MetricName": self.metric_name, + "Period": self.period, + "StartTime": self.start_time, + "EndTime": self.end_time, + "Instances": dimensions + } + + def validate(self): + """validate""" + if self.statistics not in STATISTICS_OPERATORS: + raise PolicyValidationError(f"unknown statistics: {self.statistics}") + self.statistics = STATISTICS_OPERATORS[self.statistics] + if self.op not in OPERATORS: + raise PolicyValidationError(f"unknown op: f{self.op}") + self.op = OPERATORS[self.op] + if self.days == 0: + raise PolicyValidationError("metrics filter days value cannot be 0") + + def process(self, resources, event=None): + """process""" + log.debug("[metrics filter]start_time=%s, end_time=%s", self.start_time, self.end_time) + region = self.manager.config.region + + cli = local_session(self.manager.session_factory).client("monitor.tencentcloudapi.com", + "service", + "2018-07-24", + region) + matched_resource_ids = [] + for batch in chunks(resources, self.resource_metadata.metrics_batch_size): + params = self._get_request_params(batch) + # - get metrics + + resp = cli.execute_query("GetMonitorData", params) + data_points = jmespath.search("Response.DataPoints[]", resp) + for point in data_points: + # - do calc according to statistics + values = point["Values"] + if not values and self.missing_value is None: + raise PolicyExecutionError("there is no metrics, but not set missing-value") + if not values: + metric_value = self.missing_value + else: + metric_value = self.statistics(point["Values"]) + # - compare + if self.op(metric_value, self.value): + + # the response format: {"Dimensions":["Name": "InstanceId", "Value": "xxx"]} + matched_resource_ids.append(point["Dimensions"][0]["Value"]) + else: + log.debug("[metrics filter]drop resource=%s, metric_value=%s, want_value=%s", + point["Dimensions"][0]["Value"], metric_value, self.value) + matched_resources = [] + if len(matched_resource_ids) > 0: + for res in resources: + if res[self.resource_metadata.id] in matched_resource_ids: + matched_resources.append(res) + return matched_resources + + @classmethod + def register_resources(cls, registry, resource_class: ResourceManager): + """register_resources""" + resource_class.filter_registry.register(cls.name, cls) + + +# finish to register metrics filter to resources +provider_resources.subscribe(MetricsFilter.register_resources) diff --git a/tools/c7n_tencentcloud/c7n_tencentcloud/provider.py b/tools/c7n_tencentcloud/c7n_tencentcloud/provider.py index 9e4ac72f894..9cea36e8f0c 100644 --- a/tools/c7n_tencentcloud/c7n_tencentcloud/provider.py +++ b/tools/c7n_tencentcloud/c7n_tencentcloud/provider.py @@ -42,7 +42,7 @@ def initialize(self, options): options.region = options.regions[0] if not options.account_id: session = self.get_session_factory(options) - options.account_id = session.client( + options.account_id = session().client( endpoint='sts.tencentcloudapi.com', service='sts', version='2018-08-13', diff --git a/tools/c7n_tencentcloud/c7n_tencentcloud/query.py b/tools/c7n_tencentcloud/c7n_tencentcloud/query.py index 5ef4ffa26de..520d2f4e036 100644 --- a/tools/c7n_tencentcloud/c7n_tencentcloud/query.py +++ b/tools/c7n_tencentcloud/c7n_tencentcloud/query.py @@ -28,7 +28,7 @@ def __repr__(cls) -> str: class ResourceTypeInfo(metaclass=TypeMeta): """ResourceTypeInfo""" # used to construct tencentcloud client - id: str = "" # requried, the field name to get resource instance id + id: str = "" # required, the field name to get resource instance id endpoint: str = "" service: str = "" version: str = "" @@ -182,7 +182,7 @@ def get_resource_qcs(self, resources): get_resource_qcs resource description https://cloud.tencent.com/document/product/598/10606 """ - # qcs::${ServiceType}:${Region}:${Account}:${ResourcePreifx}/${ResourceId} + # qcs::${ServiceType}:${Region}:${Account}:${ResourcePrefix}/${ResourceId} # qcs::cvm:ap-singapore::instance/ins-ibu7wp2a qcs_list = [] for r in resources: @@ -280,7 +280,7 @@ def resources(self): params = self.get_resource_query_params() resources = self.source.resources(params) - # filter resoures + # filter resources resources = self.filter_resources(resources) self.check_resource_limit(resources) diff --git a/tools/c7n_tencentcloud/poetry.lock b/tools/c7n_tencentcloud/poetry.lock index d8e42e0d7f6..1659476e1db 100644 --- a/tools/c7n_tencentcloud/poetry.lock +++ b/tools/c7n_tencentcloud/poetry.lock @@ -10,7 +10,7 @@ python-versions = ">=3.6" importlib-metadata = {version = ">=0.23,<5", markers = "python_version == \"3.7\""} [package.extras] -test = ["wheel", "pexpect", "flake8", "coverage"] +test = ["coverage", "flake8", "pexpect", "wheel"] [[package]] name = "attrs" @@ -21,21 +21,21 @@ optional = false python-versions = ">=3.5" [package.extras] -dev = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "furo", "sphinx", "sphinx-notfound-page", "pre-commit", "cloudpickle"] -docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] -tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] -tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "cloudpickle"] +dev = ["cloudpickle", "coverage[toml] (>=5.0.2)", "furo", "hypothesis", "mypy (>=0.900,!=0.940)", "pre-commit", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "sphinx", "sphinx-notfound-page", "zope.interface"] +docs = ["furo", "sphinx", "sphinx-notfound-page", "zope.interface"] +tests = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "zope.interface"] +tests_no_zope = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins"] [[package]] name = "boto3" -version = "1.24.81" +version = "1.24.87" description = "The AWS SDK for Python" category = "dev" optional = false python-versions = ">= 3.7" [package.dependencies] -botocore = ">=1.27.81,<1.28.0" +botocore = ">=1.27.87,<1.28.0" jmespath = ">=0.7.1,<2.0.0" s3transfer = ">=0.6.0,<0.7.0" @@ -44,7 +44,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "botocore" -version = "1.27.81" +version = "1.27.87" description = "Low-level, data-driven core of boto 3." category = "dev" optional = false @@ -110,7 +110,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" [[package]] name = "coverage" -version = "6.4.4" +version = "6.5.0" description = "Code coverage measurement for Python" category = "dev" optional = false @@ -151,7 +151,7 @@ python-versions = ">=3.5" [[package]] name = "importlib-metadata" -version = "4.12.0" +version = "4.13.0" description = "Read metadata from Python packages" category = "dev" optional = false @@ -162,9 +162,9 @@ typing-extensions = {version = ">=3.6.4", markers = "python_version < \"3.8\""} zipp = ">=0.5" [package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)"] perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.3)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] +testing = ["flake8 (<5)", "flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] [[package]] name = "importlib-resources" @@ -178,8 +178,8 @@ python-versions = ">=3.7" zipp = {version = ">=3.1.0", markers = "python_version < \"3.10\""} [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [[package]] name = "iniconfig" @@ -237,7 +237,7 @@ python-versions = ">=3.6" pyparsing = ">=2.0.2,<3.0.5 || >3.0.5" [[package]] -name = "pkgutil-resolve-name" +name = "pkgutil_resolve_name" version = "1.3.10" description = "Resolve a name to an object." category = "dev" @@ -264,8 +264,8 @@ python-versions = ">=3.6" importlib-metadata = {version = ">=0.12", markers = "python_version < \"3.8\""} [package.extras] -testing = ["pytest-benchmark", "pytest"] -dev = ["tox", "pre-commit"] +dev = ["pre-commit", "tox"] +testing = ["pytest", "pytest-benchmark"] [[package]] name = "py" @@ -284,7 +284,7 @@ optional = false python-versions = ">=3.6.8" [package.extras] -diagrams = ["railroad-diagrams", "jinja2"] +diagrams = ["jinja2", "railroad-diagrams"] [[package]] name = "pyrsistent" @@ -328,7 +328,7 @@ coverage = {version = ">=5.2.1", extras = ["toml"]} pytest = ">=4.6" [package.extras] -testing = ["virtualenv", "pytest-xdist", "six", "process-tests", "hunter", "fields"] +testing = ["fields", "hunter", "process-tests", "pytest-xdist", "six", "virtualenv"] [[package]] name = "pytest-recording" @@ -356,14 +356,14 @@ six = ">=1.5" [[package]] name = "pytz" -version = "2022.2.1" +version = "2022.4" description = "World timezone definitions, modern and historical" category = "main" optional = false python-versions = "*" [[package]] -name = "pyyaml" +name = "PyYAML" version = "6.0" description = "YAML parser and emitter for Python" category = "dev" @@ -434,7 +434,7 @@ widechars = ["wcwidth"] [[package]] name = "tencentcloud-sdk-python" -version = "3.0.741" +version = "3.0.745" description = "Tencent Cloud SDK for Python" category = "main" optional = false @@ -468,8 +468,8 @@ optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*, <4" [package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "urllib3-secure-extra", "ipaddress"] +brotli = ["brotli (>=1.0.9)", "brotlicffi (>=0.8.0)", "brotlipy (>=0.6.0)"] +secure = ["certifi", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "ipaddress", "pyOpenSSL (>=0.14)", "urllib3-secure-extra"] socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] [[package]] @@ -516,8 +516,8 @@ optional = false python-versions = ">=3.7" [package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)", "jaraco.tidelift (>=1.4)"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.3)", "jaraco.itertools", "func-timeout", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["func-timeout", "jaraco.itertools", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [metadata] lock-version = "1.1" @@ -525,31 +525,195 @@ python-versions = "^3.7" content-hash = "be80a80509e59944bc991d8e98a0314b09f64a9db8ed8b0901fea8a73b2fbd1d" [metadata.files] -argcomplete = [] -attrs = [] -boto3 = [] -botocore = [] +argcomplete = [ + {file = "argcomplete-2.0.0-py2.py3-none-any.whl", hash = "sha256:cffa11ea77999bb0dd27bb25ff6dc142a6796142f68d45b1a26b11f58724561e"}, + {file = "argcomplete-2.0.0.tar.gz", hash = "sha256:6372ad78c89d662035101418ae253668445b391755cfe94ea52f1b9d22425b20"}, +] +attrs = [ + {file = "attrs-22.1.0-py2.py3-none-any.whl", hash = "sha256:86efa402f67bf2df34f51a335487cf46b1ec130d02b8d39fd248abfd30da551c"}, + {file = "attrs-22.1.0.tar.gz", hash = "sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6"}, +] +boto3 = [ + {file = "boto3-1.24.87-py3-none-any.whl", hash = "sha256:bcc579e801774cb2c7dda87ff985feda1ae7e10591d11ef37526363139138bd4"}, + {file = "boto3-1.24.87.tar.gz", hash = "sha256:3dd7ed74d1d29dd8094a078be86ed61c45de6638fe18856f7a1ff9282b4d929e"}, +] +botocore = [ + {file = "botocore-1.27.87-py3-none-any.whl", hash = "sha256:c4cbd22056ace4c7aa99e62e8ae629865ab80cc8bbf7c6d68ccf0f768f0034b6"}, + {file = "botocore-1.27.87.tar.gz", hash = "sha256:216de9751116d0d1cc3901e26d95a5c9a30ecb6973ae6147af1cf504858d845a"}, +] c7n = [] -certifi = [] -charset-normalizer = [] -colorama = [] -coverage = [] -docutils = [] -freezegun = [] -idna = [] -importlib-metadata = [] -importlib-resources = [] -iniconfig = [] -jmespath = [] -jsonschema = [] -multidict = [] +certifi = [ + {file = "certifi-2022.9.24-py3-none-any.whl", hash = "sha256:90c1a32f1d68f940488354e36370f6cca89f0f106db09518524c88d6ed83f382"}, + {file = "certifi-2022.9.24.tar.gz", hash = "sha256:0d9c601124e5a6ba9712dbc60d9c53c21e34f5f641fe83002317394311bdce14"}, +] +charset-normalizer = [ + {file = "charset-normalizer-2.1.1.tar.gz", hash = "sha256:5a3d016c7c547f69d6f81fb0db9449ce888b418b5b9952cc5e6e66843e9dd845"}, + {file = "charset_normalizer-2.1.1-py3-none-any.whl", hash = "sha256:83e9a75d1911279afd89352c68b45348559d1fc0506b054b346651b5e7fee29f"}, +] +colorama = [ + {file = "colorama-0.4.5-py2.py3-none-any.whl", hash = "sha256:854bf444933e37f5824ae7bfc1e98d5bce2ebe4160d46b5edf346a89358e99da"}, + {file = "colorama-0.4.5.tar.gz", hash = "sha256:e6c6b4334fc50988a639d9b98aa429a0b57da6e17b9a44f0451f930b6967b7a4"}, +] +coverage = [ + {file = "coverage-6.5.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:ef8674b0ee8cc11e2d574e3e2998aea5df5ab242e012286824ea3c6970580e53"}, + {file = "coverage-6.5.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:784f53ebc9f3fd0e2a3f6a78b2be1bd1f5575d7863e10c6e12504f240fd06660"}, + {file = "coverage-6.5.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b4a5be1748d538a710f87542f22c2cad22f80545a847ad91ce45e77417293eb4"}, + {file = "coverage-6.5.0-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:83516205e254a0cb77d2d7bb3632ee019d93d9f4005de31dca0a8c3667d5bc04"}, + {file = "coverage-6.5.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:af4fffaffc4067232253715065e30c5a7ec6faac36f8fc8d6f64263b15f74db0"}, + {file = "coverage-6.5.0-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:97117225cdd992a9c2a5515db1f66b59db634f59d0679ca1fa3fe8da32749cae"}, + {file = "coverage-6.5.0-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:a1170fa54185845505fbfa672f1c1ab175446c887cce8212c44149581cf2d466"}, + {file = "coverage-6.5.0-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:11b990d520ea75e7ee8dcab5bc908072aaada194a794db9f6d7d5cfd19661e5a"}, + {file = "coverage-6.5.0-cp310-cp310-win32.whl", hash = "sha256:5dbec3b9095749390c09ab7c89d314727f18800060d8d24e87f01fb9cfb40b32"}, + {file = "coverage-6.5.0-cp310-cp310-win_amd64.whl", hash = "sha256:59f53f1dc5b656cafb1badd0feb428c1e7bc19b867479ff72f7a9dd9b479f10e"}, + {file = "coverage-6.5.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:4a5375e28c5191ac38cca59b38edd33ef4cc914732c916f2929029b4bfb50795"}, + {file = "coverage-6.5.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c4ed2820d919351f4167e52425e096af41bfabacb1857186c1ea32ff9983ed75"}, + {file = "coverage-6.5.0-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:33a7da4376d5977fbf0a8ed91c4dffaaa8dbf0ddbf4c8eea500a2486d8bc4d7b"}, + {file = "coverage-6.5.0-cp311-cp311-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:a8fb6cf131ac4070c9c5a3e21de0f7dc5a0fbe8bc77c9456ced896c12fcdad91"}, + {file = "coverage-6.5.0-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:a6b7d95969b8845250586f269e81e5dfdd8ff828ddeb8567a4a2eaa7313460c4"}, + {file = "coverage-6.5.0-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:1ef221513e6f68b69ee9e159506d583d31aa3567e0ae84eaad9d6ec1107dddaa"}, + {file = "coverage-6.5.0-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:cca4435eebea7962a52bdb216dec27215d0df64cf27fc1dd538415f5d2b9da6b"}, + {file = "coverage-6.5.0-cp311-cp311-win32.whl", hash = "sha256:98e8a10b7a314f454d9eff4216a9a94d143a7ee65018dd12442e898ee2310578"}, + {file = "coverage-6.5.0-cp311-cp311-win_amd64.whl", hash = "sha256:bc8ef5e043a2af066fa8cbfc6e708d58017024dc4345a1f9757b329a249f041b"}, + {file = "coverage-6.5.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:4433b90fae13f86fafff0b326453dd42fc9a639a0d9e4eec4d366436d1a41b6d"}, + {file = "coverage-6.5.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f4f05d88d9a80ad3cac6244d36dd89a3c00abc16371769f1340101d3cb899fc3"}, + {file = "coverage-6.5.0-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:94e2565443291bd778421856bc975d351738963071e9b8839ca1fc08b42d4bef"}, + {file = "coverage-6.5.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:027018943386e7b942fa832372ebc120155fd970837489896099f5cfa2890f79"}, + {file = "coverage-6.5.0-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:255758a1e3b61db372ec2736c8e2a1fdfaf563977eedbdf131de003ca5779b7d"}, + {file = "coverage-6.5.0-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:851cf4ff24062c6aec510a454b2584f6e998cada52d4cb58c5e233d07172e50c"}, + {file = "coverage-6.5.0-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:12adf310e4aafddc58afdb04d686795f33f4d7a6fa67a7a9d4ce7d6ae24d949f"}, + {file = "coverage-6.5.0-cp37-cp37m-win32.whl", hash = "sha256:b5604380f3415ba69de87a289a2b56687faa4fe04dbee0754bfcae433489316b"}, + {file = "coverage-6.5.0-cp37-cp37m-win_amd64.whl", hash = "sha256:4a8dbc1f0fbb2ae3de73eb0bdbb914180c7abfbf258e90b311dcd4f585d44bd2"}, + {file = "coverage-6.5.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:d900bb429fdfd7f511f868cedd03a6bbb142f3f9118c09b99ef8dc9bf9643c3c"}, + {file = "coverage-6.5.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:2198ea6fc548de52adc826f62cb18554caedfb1d26548c1b7c88d8f7faa8f6ba"}, + {file = "coverage-6.5.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6c4459b3de97b75e3bd6b7d4b7f0db13f17f504f3d13e2a7c623786289dd670e"}, + {file = "coverage-6.5.0-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:20c8ac5386253717e5ccc827caad43ed66fea0efe255727b1053a8154d952398"}, + {file = "coverage-6.5.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6b07130585d54fe8dff3d97b93b0e20290de974dc8177c320aeaf23459219c0b"}, + {file = "coverage-6.5.0-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:dbdb91cd8c048c2b09eb17713b0c12a54fbd587d79adcebad543bc0cd9a3410b"}, + {file = "coverage-6.5.0-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:de3001a203182842a4630e7b8d1a2c7c07ec1b45d3084a83d5d227a3806f530f"}, + {file = "coverage-6.5.0-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:e07f4a4a9b41583d6eabec04f8b68076ab3cd44c20bd29332c6572dda36f372e"}, + {file = "coverage-6.5.0-cp38-cp38-win32.whl", hash = "sha256:6d4817234349a80dbf03640cec6109cd90cba068330703fa65ddf56b60223a6d"}, + {file = "coverage-6.5.0-cp38-cp38-win_amd64.whl", hash = "sha256:7ccf362abd726b0410bf8911c31fbf97f09f8f1061f8c1cf03dfc4b6372848f6"}, + {file = "coverage-6.5.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:633713d70ad6bfc49b34ead4060531658dc6dfc9b3eb7d8a716d5873377ab745"}, + {file = "coverage-6.5.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:95203854f974e07af96358c0b261f1048d8e1083f2de9b1c565e1be4a3a48cfc"}, + {file = "coverage-6.5.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b9023e237f4c02ff739581ef35969c3739445fb059b060ca51771e69101efffe"}, + {file = "coverage-6.5.0-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:265de0fa6778d07de30bcf4d9dc471c3dc4314a23a3c6603d356a3c9abc2dfcf"}, + {file = "coverage-6.5.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8f830ed581b45b82451a40faabb89c84e1a998124ee4212d440e9c6cf70083e5"}, + {file = "coverage-6.5.0-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:7b6be138d61e458e18d8e6ddcddd36dd96215edfe5f1168de0b1b32635839b62"}, + {file = "coverage-6.5.0-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:42eafe6778551cf006a7c43153af1211c3aaab658d4d66fa5fcc021613d02518"}, + {file = "coverage-6.5.0-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:723e8130d4ecc8f56e9a611e73b31219595baa3bb252d539206f7bbbab6ffc1f"}, + {file = "coverage-6.5.0-cp39-cp39-win32.whl", hash = "sha256:d9ecf0829c6a62b9b573c7bb6d4dcd6ba8b6f80be9ba4fc7ed50bf4ac9aecd72"}, + {file = "coverage-6.5.0-cp39-cp39-win_amd64.whl", hash = "sha256:fc2af30ed0d5ae0b1abdb4ebdce598eafd5b35397d4d75deb341a614d333d987"}, + {file = "coverage-6.5.0-pp36.pp37.pp38-none-any.whl", hash = "sha256:1431986dac3923c5945271f169f59c45b8802a114c8f548d611f2015133df77a"}, + {file = "coverage-6.5.0.tar.gz", hash = "sha256:f642e90754ee3e06b0e7e51bce3379590e76b7f76b708e1a71ff043f87025c84"}, +] +docutils = [ + {file = "docutils-0.17.1-py2.py3-none-any.whl", hash = "sha256:cf316c8370a737a022b72b56874f6602acf974a37a9fba42ec2876387549fc61"}, + {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, +] +freezegun = [ + {file = "freezegun-1.2.2-py3-none-any.whl", hash = "sha256:ea1b963b993cb9ea195adbd893a48d573fda951b0da64f60883d7e988b606c9f"}, + {file = "freezegun-1.2.2.tar.gz", hash = "sha256:cd22d1ba06941384410cd967d8a99d5ae2442f57dfafeff2fda5de8dc5c05446"}, +] +idna = [ + {file = "idna-3.4-py3-none-any.whl", hash = "sha256:90b77e79eaa3eba6de819a0c442c0b4ceefc341a7a2ab77d7562bf49f425c5c2"}, + {file = "idna-3.4.tar.gz", hash = "sha256:814f528e8dead7d329833b91c5faa87d60bf71824cd12a7530b5526063d02cb4"}, +] +importlib-metadata = [ + {file = "importlib_metadata-4.13.0-py3-none-any.whl", hash = "sha256:8a8a81bcf996e74fee46f0d16bd3eaa382a7eb20fd82445c3ad11f4090334116"}, + {file = "importlib_metadata-4.13.0.tar.gz", hash = "sha256:dd0173e8f150d6815e098fd354f6414b0f079af4644ddfe90c71e2fc6174346d"}, +] +importlib-resources = [ + {file = "importlib_resources-5.9.0-py3-none-any.whl", hash = "sha256:f78a8df21a79bcc30cfd400bdc38f314333de7c0fb619763f6b9dabab8268bb7"}, + {file = "importlib_resources-5.9.0.tar.gz", hash = "sha256:5481e97fb45af8dcf2f798952625591c58fe599d0735d86b10f54de086a61681"}, +] +iniconfig = [ + {file = "iniconfig-1.1.1-py2.py3-none-any.whl", hash = "sha256:011e24c64b7f47f6ebd835bb12a743f2fbe9a26d4cecaa7f53bc4f35ee9da8b3"}, + {file = "iniconfig-1.1.1.tar.gz", hash = "sha256:bc3af051d7d14b2ee5ef9969666def0cd1a000e121eaea580d4a313df4b37f32"}, +] +jmespath = [ + {file = "jmespath-1.0.1-py3-none-any.whl", hash = "sha256:02e2e4cc71b5bcab88332eebf907519190dd9e6e82107fa7f83b1003a6252980"}, + {file = "jmespath-1.0.1.tar.gz", hash = "sha256:90261b206d6defd58fdd5e85f478bf633a2901798906be2ad389150c5c60edbe"}, +] +jsonschema = [ + {file = "jsonschema-4.16.0-py3-none-any.whl", hash = "sha256:9e74b8f9738d6a946d70705dc692b74b5429cd0960d58e79ffecfc43b2221eb9"}, + {file = "jsonschema-4.16.0.tar.gz", hash = "sha256:165059f076eff6971bae5b742fc029a7b4ef3f9bcf04c14e4776a7605de14b23"}, +] +multidict = [ + {file = "multidict-6.0.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:0b9e95a740109c6047602f4db4da9949e6c5945cefbad34a1299775ddc9a62e2"}, + {file = "multidict-6.0.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:ac0e27844758d7177989ce406acc6a83c16ed4524ebc363c1f748cba184d89d3"}, + {file = "multidict-6.0.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:041b81a5f6b38244b34dc18c7b6aba91f9cdaf854d9a39e5ff0b58e2b5773b9c"}, + {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5fdda29a3c7e76a064f2477c9aab1ba96fd94e02e386f1e665bca1807fc5386f"}, + {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3368bf2398b0e0fcbf46d85795adc4c259299fec50c1416d0f77c0a843a3eed9"}, + {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:f4f052ee022928d34fe1f4d2bc743f32609fb79ed9c49a1710a5ad6b2198db20"}, + {file = "multidict-6.0.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:225383a6603c086e6cef0f2f05564acb4f4d5f019a4e3e983f572b8530f70c88"}, + {file = "multidict-6.0.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:50bd442726e288e884f7be9071016c15a8742eb689a593a0cac49ea093eef0a7"}, + {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:47e6a7e923e9cada7c139531feac59448f1f47727a79076c0b1ee80274cd8eee"}, + {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:0556a1d4ea2d949efe5fd76a09b4a82e3a4a30700553a6725535098d8d9fb672"}, + {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:626fe10ac87851f4cffecee161fc6f8f9853f0f6f1035b59337a51d29ff3b4f9"}, + {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:8064b7c6f0af936a741ea1efd18690bacfbae4078c0c385d7c3f611d11f0cf87"}, + {file = "multidict-6.0.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:2d36e929d7f6a16d4eb11b250719c39560dd70545356365b494249e2186bc389"}, + {file = "multidict-6.0.2-cp310-cp310-win32.whl", hash = "sha256:fcb91630817aa8b9bc4a74023e4198480587269c272c58b3279875ed7235c293"}, + {file = "multidict-6.0.2-cp310-cp310-win_amd64.whl", hash = "sha256:8cbf0132f3de7cc6c6ce00147cc78e6439ea736cee6bca4f068bcf892b0fd658"}, + {file = "multidict-6.0.2-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:05f6949d6169878a03e607a21e3b862eaf8e356590e8bdae4227eedadacf6e51"}, + {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e2c2e459f7050aeb7c1b1276763364884595d47000c1cddb51764c0d8976e608"}, + {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:d0509e469d48940147e1235d994cd849a8f8195e0bca65f8f5439c56e17872a3"}, + {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:514fe2b8d750d6cdb4712346a2c5084a80220821a3e91f3f71eec11cf8d28fd4"}, + {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:19adcfc2a7197cdc3987044e3f415168fc5dc1f720c932eb1ef4f71a2067e08b"}, + {file = "multidict-6.0.2-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:b9d153e7f1f9ba0b23ad1568b3b9e17301e23b042c23870f9ee0522dc5cc79e8"}, + {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:aef9cc3d9c7d63d924adac329c33835e0243b5052a6dfcbf7732a921c6e918ba"}, + {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:4571f1beddff25f3e925eea34268422622963cd8dc395bb8778eb28418248e43"}, + {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:d48b8ee1d4068561ce8033d2c344cf5232cb29ee1a0206a7b828c79cbc5982b8"}, + {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:45183c96ddf61bf96d2684d9fbaf6f3564d86b34cb125761f9a0ef9e36c1d55b"}, + {file = "multidict-6.0.2-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:75bdf08716edde767b09e76829db8c1e5ca9d8bb0a8d4bd94ae1eafe3dac5e15"}, + {file = "multidict-6.0.2-cp37-cp37m-win32.whl", hash = "sha256:a45e1135cb07086833ce969555df39149680e5471c04dfd6a915abd2fc3f6dbc"}, + {file = "multidict-6.0.2-cp37-cp37m-win_amd64.whl", hash = "sha256:6f3cdef8a247d1eafa649085812f8a310e728bdf3900ff6c434eafb2d443b23a"}, + {file = "multidict-6.0.2-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:0327292e745a880459ef71be14e709aaea2f783f3537588fb4ed09b6c01bca60"}, + {file = "multidict-6.0.2-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:e875b6086e325bab7e680e4316d667fc0e5e174bb5611eb16b3ea121c8951b86"}, + {file = "multidict-6.0.2-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:feea820722e69451743a3d56ad74948b68bf456984d63c1a92e8347b7b88452d"}, + {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9cc57c68cb9139c7cd6fc39f211b02198e69fb90ce4bc4a094cf5fe0d20fd8b0"}, + {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:497988d6b6ec6ed6f87030ec03280b696ca47dbf0648045e4e1d28b80346560d"}, + {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:89171b2c769e03a953d5969b2f272efa931426355b6c0cb508022976a17fd376"}, + {file = "multidict-6.0.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:684133b1e1fe91eda8fa7447f137c9490a064c6b7f392aa857bba83a28cfb693"}, + {file = "multidict-6.0.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:fd9fc9c4849a07f3635ccffa895d57abce554b467d611a5009ba4f39b78a8849"}, + {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:e07c8e79d6e6fd37b42f3250dba122053fddb319e84b55dd3a8d6446e1a7ee49"}, + {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:4070613ea2227da2bfb2c35a6041e4371b0af6b0be57f424fe2318b42a748516"}, + {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:47fbeedbf94bed6547d3aa632075d804867a352d86688c04e606971595460227"}, + {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:5774d9218d77befa7b70d836004a768fb9aa4fdb53c97498f4d8d3f67bb9cfa9"}, + {file = "multidict-6.0.2-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:2957489cba47c2539a8eb7ab32ff49101439ccf78eab724c828c1a54ff3ff98d"}, + {file = "multidict-6.0.2-cp38-cp38-win32.whl", hash = "sha256:e5b20e9599ba74391ca0cfbd7b328fcc20976823ba19bc573983a25b32e92b57"}, + {file = "multidict-6.0.2-cp38-cp38-win_amd64.whl", hash = "sha256:8004dca28e15b86d1b1372515f32eb6f814bdf6f00952699bdeb541691091f96"}, + {file = "multidict-6.0.2-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:2e4a0785b84fb59e43c18a015ffc575ba93f7d1dbd272b4cdad9f5134b8a006c"}, + {file = "multidict-6.0.2-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:6701bf8a5d03a43375909ac91b6980aea74b0f5402fbe9428fc3f6edf5d9677e"}, + {file = "multidict-6.0.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:a007b1638e148c3cfb6bf0bdc4f82776cef0ac487191d093cdc316905e504071"}, + {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:07a017cfa00c9890011628eab2503bee5872f27144936a52eaab449be5eaf032"}, + {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c207fff63adcdf5a485969131dc70e4b194327666b7e8a87a97fbc4fd80a53b2"}, + {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:373ba9d1d061c76462d74e7de1c0c8e267e9791ee8cfefcf6b0b2495762c370c"}, + {file = "multidict-6.0.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bfba7c6d5d7c9099ba21f84662b037a0ffd4a5e6b26ac07d19e423e6fdf965a9"}, + {file = "multidict-6.0.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:19d9bad105dfb34eb539c97b132057a4e709919ec4dd883ece5838bcbf262b80"}, + {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:de989b195c3d636ba000ee4281cd03bb1234635b124bf4cd89eeee9ca8fcb09d"}, + {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:7c40b7bbece294ae3a87c1bc2abff0ff9beef41d14188cda94ada7bcea99b0fb"}, + {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:d16cce709ebfadc91278a1c005e3c17dd5f71f5098bfae1035149785ea6e9c68"}, + {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:a2c34a93e1d2aa35fbf1485e5010337c72c6791407d03aa5f4eed920343dd360"}, + {file = "multidict-6.0.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:feba80698173761cddd814fa22e88b0661e98cb810f9f986c54aa34d281e4937"}, + {file = "multidict-6.0.2-cp39-cp39-win32.whl", hash = "sha256:23b616fdc3c74c9fe01d76ce0d1ce872d2d396d8fa8e4899398ad64fb5aa214a"}, + {file = "multidict-6.0.2-cp39-cp39-win_amd64.whl", hash = "sha256:4bae31803d708f6f15fd98be6a6ac0b6958fcf68fda3c77a048a4f9073704aae"}, + {file = "multidict-6.0.2.tar.gz", hash = "sha256:5ff3bd75f38e4c43f1f470f2df7a4d430b821c4ce22be384e1459cb57d6bb013"}, +] packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, {file = "packaging-21.3.tar.gz", hash = "sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb"}, ] -pkgutil-resolve-name = [] -placebo = [] -pluggy = [] +pkgutil_resolve_name = [ + {file = "pkgutil_resolve_name-1.3.10-py3-none-any.whl", hash = "sha256:ca27cc078d25c5ad71a9de0a7a330146c4e014c2462d9af19c6b828280649c5e"}, + {file = "pkgutil_resolve_name-1.3.10.tar.gz", hash = "sha256:357d6c9e6a755653cfd78893817c0853af365dd51ec97f3d358a819373bbd174"}, +] +placebo = [ + {file = "placebo-0.9.0.tar.gz", hash = "sha256:03157f8527bbc2965b71b88f4a139ef8038618b346787f20d63e3c5da541b047"}, +] +pluggy = [ + {file = "pluggy-1.0.0-py2.py3-none-any.whl", hash = "sha256:74134bbf457f031a36d68416e1509f34bd5ccc019f0bcc952c7b909d06b37bd3"}, + {file = "pluggy-1.0.0.tar.gz", hash = "sha256:4224373bacce55f955a878bf9cfa763c1e360858e330072059e10bad68531159"}, +] py = [ {file = "py-1.11.0-py2.py3-none-any.whl", hash = "sha256:607c53218732647dff4acdfcd50cb62615cedf612e72d1724fb1a0cc6405b378"}, {file = "py-1.11.0.tar.gz", hash = "sha256:51c75c4126074b472f746a24399ad32f6053d1b34b68d2fa41e558e6f4a98719"}, @@ -558,29 +722,258 @@ pyparsing = [ {file = "pyparsing-3.0.9-py3-none-any.whl", hash = "sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc"}, {file = "pyparsing-3.0.9.tar.gz", hash = "sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb"}, ] -pyrsistent = [] -pytest = [] -pytest-cov = [] -pytest-recording = [] +pyrsistent = [ + {file = "pyrsistent-0.18.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:df46c854f490f81210870e509818b729db4488e1f30f2a1ce1698b2295a878d1"}, + {file = "pyrsistent-0.18.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:5d45866ececf4a5fff8742c25722da6d4c9e180daa7b405dc0a2a2790d668c26"}, + {file = "pyrsistent-0.18.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:4ed6784ceac462a7d6fcb7e9b663e93b9a6fb373b7f43594f9ff68875788e01e"}, + {file = "pyrsistent-0.18.1-cp310-cp310-win32.whl", hash = "sha256:e4f3149fd5eb9b285d6bfb54d2e5173f6a116fe19172686797c056672689daf6"}, + {file = "pyrsistent-0.18.1-cp310-cp310-win_amd64.whl", hash = "sha256:636ce2dc235046ccd3d8c56a7ad54e99d5c1cd0ef07d9ae847306c91d11b5fec"}, + {file = "pyrsistent-0.18.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:e92a52c166426efbe0d1ec1332ee9119b6d32fc1f0bbfd55d5c1088070e7fc1b"}, + {file = "pyrsistent-0.18.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d7a096646eab884bf8bed965bad63ea327e0d0c38989fc83c5ea7b8a87037bfc"}, + {file = "pyrsistent-0.18.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:cdfd2c361b8a8e5d9499b9082b501c452ade8bbf42aef97ea04854f4a3f43b22"}, + {file = "pyrsistent-0.18.1-cp37-cp37m-win32.whl", hash = "sha256:7ec335fc998faa4febe75cc5268a9eac0478b3f681602c1f27befaf2a1abe1d8"}, + {file = "pyrsistent-0.18.1-cp37-cp37m-win_amd64.whl", hash = "sha256:6455fc599df93d1f60e1c5c4fe471499f08d190d57eca040c0ea182301321286"}, + {file = "pyrsistent-0.18.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:fd8da6d0124efa2f67d86fa70c851022f87c98e205f0594e1fae044e7119a5a6"}, + {file = "pyrsistent-0.18.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7bfe2388663fd18bd8ce7db2c91c7400bf3e1a9e8bd7d63bf7e77d39051b85ec"}, + {file = "pyrsistent-0.18.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:0e3e1fcc45199df76053026a51cc59ab2ea3fc7c094c6627e93b7b44cdae2c8c"}, + {file = "pyrsistent-0.18.1-cp38-cp38-win32.whl", hash = "sha256:b568f35ad53a7b07ed9b1b2bae09eb15cdd671a5ba5d2c66caee40dbf91c68ca"}, + {file = "pyrsistent-0.18.1-cp38-cp38-win_amd64.whl", hash = "sha256:d1b96547410f76078eaf66d282ddca2e4baae8964364abb4f4dcdde855cd123a"}, + {file = "pyrsistent-0.18.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:f87cc2863ef33c709e237d4b5f4502a62a00fab450c9e020892e8e2ede5847f5"}, + {file = "pyrsistent-0.18.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6bc66318fb7ee012071b2792024564973ecc80e9522842eb4e17743604b5e045"}, + {file = "pyrsistent-0.18.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:914474c9f1d93080338ace89cb2acee74f4f666fb0424896fcfb8d86058bf17c"}, + {file = "pyrsistent-0.18.1-cp39-cp39-win32.whl", hash = "sha256:1b34eedd6812bf4d33814fca1b66005805d3640ce53140ab8bbb1e2651b0d9bc"}, + {file = "pyrsistent-0.18.1-cp39-cp39-win_amd64.whl", hash = "sha256:e24a828f57e0c337c8d8bb9f6b12f09dfdf0273da25fda9e314f0b684b415a07"}, + {file = "pyrsistent-0.18.1.tar.gz", hash = "sha256:d4d61f8b993a7255ba714df3aca52700f8125289f84f704cf80916517c46eb96"}, +] +pytest = [ + {file = "pytest-7.1.3-py3-none-any.whl", hash = "sha256:1377bda3466d70b55e3f5cecfa55bb7cfcf219c7964629b967c37cf0bda818b7"}, + {file = "pytest-7.1.3.tar.gz", hash = "sha256:4f365fec2dff9c1162f834d9f18af1ba13062db0c708bf7b946f8a5c76180c39"}, +] +pytest-cov = [ + {file = "pytest-cov-3.0.0.tar.gz", hash = "sha256:e7f0f5b1617d2210a2cabc266dfe2f4c75a8d32fb89eafb7ad9d06f6d076d470"}, + {file = "pytest_cov-3.0.0-py3-none-any.whl", hash = "sha256:578d5d15ac4a25e5f961c938b85a05b09fdaae9deef3bb6de9a6e766622ca7a6"}, +] +pytest-recording = [ + {file = "pytest-recording-0.12.1.tar.gz", hash = "sha256:0d1f36d10dea5090cab8ecd230e5dc937c97b9fed193874b330d2926ddea028f"}, + {file = "pytest_recording-0.12.1-py3-none-any.whl", hash = "sha256:6b5546b822b270b8d7338f70950453be45e4aa5bfd884d97583dfa47288380f9"}, +] python-dateutil = [ {file = "python-dateutil-2.8.2.tar.gz", hash = "sha256:0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86"}, {file = "python_dateutil-2.8.2-py2.py3-none-any.whl", hash = "sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9"}, ] -pytz = [] -pyyaml = [] -requests = [] -retrying = [] -s3transfer = [] +pytz = [ + {file = "pytz-2022.4-py2.py3-none-any.whl", hash = "sha256:2c0784747071402c6e99f0bafdb7da0fa22645f06554c7ae06bf6358897e9c91"}, + {file = "pytz-2022.4.tar.gz", hash = "sha256:48ce799d83b6f8aab2020e369b627446696619e79645419610b9facd909b3174"}, +] +PyYAML = [ + {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, + {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:a80a78046a72361de73f8f395f1f1e49f956c6be882eed58505a15f3e430962b"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, + {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, + {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782"}, + {file = "PyYAML-6.0-cp311-cp311-win32.whl", hash = "sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7"}, + {file = "PyYAML-6.0-cp311-cp311-win_amd64.whl", hash = "sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf"}, + {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:98c4d36e99714e55cfbaaee6dd5badbc9a1ec339ebfc3b1f52e293aee6bb71a4"}, + {file = "PyYAML-6.0-cp36-cp36m-win32.whl", hash = "sha256:0283c35a6a9fbf047493e3a0ce8d79ef5030852c51e9d911a27badfde0605293"}, + {file = "PyYAML-6.0-cp36-cp36m-win_amd64.whl", hash = "sha256:07751360502caac1c067a8132d150cf3d61339af5691fe9e87803040dbc5db57"}, + {file = "PyYAML-6.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:819b3830a1543db06c4d4b865e70ded25be52a2e0631ccd2f6a47a2822f2fd7c"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:473f9edb243cb1935ab5a084eb238d842fb8f404ed2193a915d1784b5a6b5fc0"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:0ce82d761c532fe4ec3f87fc45688bdd3a4c1dc5e0b4a19814b9009a29baefd4"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:231710d57adfd809ef5d34183b8ed1eeae3f76459c18fb4a0b373ad56bedcdd9"}, + {file = "PyYAML-6.0-cp37-cp37m-win32.whl", hash = "sha256:c5687b8d43cf58545ade1fe3e055f70eac7a5a1a0bf42824308d868289a95737"}, + {file = "PyYAML-6.0-cp37-cp37m-win_amd64.whl", hash = "sha256:d15a181d1ecd0d4270dc32edb46f7cb7733c7c508857278d3d378d14d606db2d"}, + {file = "PyYAML-6.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0b4624f379dab24d3725ffde76559cff63d9ec94e1736b556dacdfebe5ab6d4b"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:213c60cd50106436cc818accf5baa1aba61c0189ff610f64f4a3e8c6726218ba"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:9fa600030013c4de8165339db93d182b9431076eb98eb40ee068700c9c813e34"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:277a0ef2981ca40581a47093e9e2d13b3f1fbbeffae064c1d21bfceba2030287"}, + {file = "PyYAML-6.0-cp38-cp38-win32.whl", hash = "sha256:d4eccecf9adf6fbcc6861a38015c2a64f38b9d94838ac1810a9023a0609e1b78"}, + {file = "PyYAML-6.0-cp38-cp38-win_amd64.whl", hash = "sha256:1e4747bc279b4f613a09eb64bba2ba602d8a6664c6ce6396a4d0cd413a50ce07"}, + {file = "PyYAML-6.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:055d937d65826939cb044fc8c9b08889e8c743fdc6a32b33e2390f66013e449b"}, + {file = "PyYAML-6.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:e61ceaab6f49fb8bdfaa0f92c4b57bcfbea54c09277b1b4f7ac376bfb7a7c174"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d67d839ede4ed1b28a4e8909735fc992a923cdb84e618544973d7dfc71540803"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:cba8c411ef271aa037d7357a2bc8f9ee8b58b9965831d9e51baf703280dc73d3"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:40527857252b61eacd1d9af500c3337ba8deb8fc298940291486c465c8b46ec0"}, + {file = "PyYAML-6.0-cp39-cp39-win32.whl", hash = "sha256:b5b9eccad747aabaaffbc6064800670f0c297e52c12754eb1d976c57e4f74dcb"}, + {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, + {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, +] +requests = [ + {file = "requests-2.28.1-py3-none-any.whl", hash = "sha256:8fefa2a1a1365bf5520aac41836fbee479da67864514bdb821f31ce07ce65349"}, + {file = "requests-2.28.1.tar.gz", hash = "sha256:7c5599b102feddaa661c826c56ab4fee28bfd17f5abca1ebbe3e7f19d7c97983"}, +] +retrying = [ + {file = "retrying-1.3.3.tar.gz", hash = "sha256:08c039560a6da2fe4f2c426d0766e284d3b736e355f8dd24b37367b0bb41973b"}, +] +s3transfer = [ + {file = "s3transfer-0.6.0-py3-none-any.whl", hash = "sha256:06176b74f3a15f61f1b4f25a1fc29a4429040b7647133a463da8fa5bd28d5ecd"}, + {file = "s3transfer-0.6.0.tar.gz", hash = "sha256:2ed07d3866f523cc561bf4a00fc5535827981b117dd7876f036b0c1aca42c947"}, +] six = [ {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, ] -tabulate = [] -tencentcloud-sdk-python = [] -tomli = [] -typing-extensions = [] -urllib3 = [] -vcrpy = [] -wrapt = [] -yarl = [] -zipp = [] +tabulate = [ + {file = "tabulate-0.8.10-py3-none-any.whl", hash = "sha256:0ba055423dbaa164b9e456abe7920c5e8ed33fcc16f6d1b2f2d152c8e1e8b4fc"}, + {file = "tabulate-0.8.10.tar.gz", hash = "sha256:6c57f3f3dd7ac2782770155f3adb2db0b1a269637e42f27599925e64b114f519"}, +] +tencentcloud-sdk-python = [ + {file = "tencentcloud-sdk-python-3.0.745.tar.gz", hash = "sha256:829f6e5dfe54e1361e148d7297b4731ca9f32841e98d208fb791fd9ab4fce69b"}, + {file = "tencentcloud_sdk_python-3.0.745-py2.py3-none-any.whl", hash = "sha256:26d5a2d754683dd088ff38c655c225bb81fcecee68593e4f2e0520cdf2dd62d2"}, +] +tomli = [ + {file = "tomli-2.0.1-py3-none-any.whl", hash = "sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc"}, + {file = "tomli-2.0.1.tar.gz", hash = "sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f"}, +] +typing-extensions = [ + {file = "typing_extensions-4.3.0-py3-none-any.whl", hash = "sha256:25642c956049920a5aa49edcdd6ab1e06d7e5d467fc00e0506c44ac86fbfca02"}, + {file = "typing_extensions-4.3.0.tar.gz", hash = "sha256:e6d2677a32f47fc7eb2795db1dd15c1f34eff616bcaf2cfb5e997f854fa1c4a6"}, +] +urllib3 = [ + {file = "urllib3-1.26.12-py2.py3-none-any.whl", hash = "sha256:b930dd878d5a8afb066a637fbb35144fe7901e3b209d1cd4f524bd0e9deee997"}, + {file = "urllib3-1.26.12.tar.gz", hash = "sha256:3fa96cf423e6987997fc326ae8df396db2a8b7c667747d47ddd8ecba91f4a74e"}, +] +vcrpy = [ + {file = "vcrpy-4.2.1-py2.py3-none-any.whl", hash = "sha256:efac3e2e0b2af7686f83a266518180af7a048619b2f696e7bad9520f5e2eac09"}, + {file = "vcrpy-4.2.1.tar.gz", hash = "sha256:7cd3e81a2c492e01c281f180bcc2a86b520b173d2b656cb5d89d99475423e013"}, +] +wrapt = [ + {file = "wrapt-1.14.1-cp27-cp27m-macosx_10_9_x86_64.whl", hash = "sha256:1b376b3f4896e7930f1f772ac4b064ac12598d1c38d04907e696cc4d794b43d3"}, + {file = "wrapt-1.14.1-cp27-cp27m-manylinux1_i686.whl", hash = "sha256:903500616422a40a98a5a3c4ff4ed9d0066f3b4c951fa286018ecdf0750194ef"}, + {file = "wrapt-1.14.1-cp27-cp27m-manylinux1_x86_64.whl", hash = "sha256:5a9a0d155deafd9448baff28c08e150d9b24ff010e899311ddd63c45c2445e28"}, + {file = "wrapt-1.14.1-cp27-cp27m-manylinux2010_i686.whl", hash = "sha256:ddaea91abf8b0d13443f6dac52e89051a5063c7d014710dcb4d4abb2ff811a59"}, + {file = "wrapt-1.14.1-cp27-cp27m-manylinux2010_x86_64.whl", hash = "sha256:36f582d0c6bc99d5f39cd3ac2a9062e57f3cf606ade29a0a0d6b323462f4dd87"}, + {file = "wrapt-1.14.1-cp27-cp27mu-manylinux1_i686.whl", hash = "sha256:7ef58fb89674095bfc57c4069e95d7a31cfdc0939e2a579882ac7d55aadfd2a1"}, + {file = "wrapt-1.14.1-cp27-cp27mu-manylinux1_x86_64.whl", hash = "sha256:e2f83e18fe2f4c9e7db597e988f72712c0c3676d337d8b101f6758107c42425b"}, + {file = "wrapt-1.14.1-cp27-cp27mu-manylinux2010_i686.whl", hash = "sha256:ee2b1b1769f6707a8a445162ea16dddf74285c3964f605877a20e38545c3c462"}, + {file = "wrapt-1.14.1-cp27-cp27mu-manylinux2010_x86_64.whl", hash = "sha256:833b58d5d0b7e5b9832869f039203389ac7cbf01765639c7309fd50ef619e0b1"}, + {file = "wrapt-1.14.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:80bb5c256f1415f747011dc3604b59bc1f91c6e7150bd7db03b19170ee06b320"}, + {file = "wrapt-1.14.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:07f7a7d0f388028b2df1d916e94bbb40624c59b48ecc6cbc232546706fac74c2"}, + {file = "wrapt-1.14.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:02b41b633c6261feff8ddd8d11c711df6842aba629fdd3da10249a53211a72c4"}, + {file = "wrapt-1.14.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:2fe803deacd09a233e4762a1adcea5db5d31e6be577a43352936179d14d90069"}, + {file = "wrapt-1.14.1-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:257fd78c513e0fb5cdbe058c27a0624c9884e735bbd131935fd49e9fe719d310"}, + {file = "wrapt-1.14.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:4fcc4649dc762cddacd193e6b55bc02edca674067f5f98166d7713b193932b7f"}, + {file = "wrapt-1.14.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:11871514607b15cfeb87c547a49bca19fde402f32e2b1c24a632506c0a756656"}, + {file = "wrapt-1.14.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:8ad85f7f4e20964db4daadcab70b47ab05c7c1cf2a7c1e51087bfaa83831854c"}, + {file = "wrapt-1.14.1-cp310-cp310-win32.whl", hash = "sha256:a9a52172be0b5aae932bef82a79ec0a0ce87288c7d132946d645eba03f0ad8a8"}, + {file = "wrapt-1.14.1-cp310-cp310-win_amd64.whl", hash = "sha256:6d323e1554b3d22cfc03cd3243b5bb815a51f5249fdcbb86fda4bf62bab9e164"}, + {file = "wrapt-1.14.1-cp35-cp35m-manylinux1_i686.whl", hash = "sha256:43ca3bbbe97af00f49efb06e352eae40434ca9d915906f77def219b88e85d907"}, + {file = "wrapt-1.14.1-cp35-cp35m-manylinux1_x86_64.whl", hash = "sha256:6b1a564e6cb69922c7fe3a678b9f9a3c54e72b469875aa8018f18b4d1dd1adf3"}, + {file = "wrapt-1.14.1-cp35-cp35m-manylinux2010_i686.whl", hash = "sha256:00b6d4ea20a906c0ca56d84f93065b398ab74b927a7a3dbd470f6fc503f95dc3"}, + {file = "wrapt-1.14.1-cp35-cp35m-manylinux2010_x86_64.whl", hash = "sha256:a85d2b46be66a71bedde836d9e41859879cc54a2a04fad1191eb50c2066f6e9d"}, + {file = "wrapt-1.14.1-cp35-cp35m-win32.whl", hash = "sha256:dbcda74c67263139358f4d188ae5faae95c30929281bc6866d00573783c422b7"}, + {file = "wrapt-1.14.1-cp35-cp35m-win_amd64.whl", hash = "sha256:b21bb4c09ffabfa0e85e3a6b623e19b80e7acd709b9f91452b8297ace2a8ab00"}, + {file = "wrapt-1.14.1-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:9e0fd32e0148dd5dea6af5fee42beb949098564cc23211a88d799e434255a1f4"}, + {file = "wrapt-1.14.1-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9736af4641846491aedb3c3f56b9bc5568d92b0692303b5a305301a95dfd38b1"}, + {file = "wrapt-1.14.1-cp36-cp36m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:5b02d65b9ccf0ef6c34cba6cf5bf2aab1bb2f49c6090bafeecc9cd81ad4ea1c1"}, + {file = "wrapt-1.14.1-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:21ac0156c4b089b330b7666db40feee30a5d52634cc4560e1905d6529a3897ff"}, + {file = "wrapt-1.14.1-cp36-cp36m-musllinux_1_1_aarch64.whl", hash = "sha256:9f3e6f9e05148ff90002b884fbc2a86bd303ae847e472f44ecc06c2cd2fcdb2d"}, + {file = "wrapt-1.14.1-cp36-cp36m-musllinux_1_1_i686.whl", hash = "sha256:6e743de5e9c3d1b7185870f480587b75b1cb604832e380d64f9504a0535912d1"}, + {file = "wrapt-1.14.1-cp36-cp36m-musllinux_1_1_x86_64.whl", hash = "sha256:d79d7d5dc8a32b7093e81e97dad755127ff77bcc899e845f41bf71747af0c569"}, + {file = "wrapt-1.14.1-cp36-cp36m-win32.whl", hash = "sha256:81b19725065dcb43df02b37e03278c011a09e49757287dca60c5aecdd5a0b8ed"}, + {file = "wrapt-1.14.1-cp36-cp36m-win_amd64.whl", hash = "sha256:b014c23646a467558be7da3d6b9fa409b2c567d2110599b7cf9a0c5992b3b471"}, + {file = "wrapt-1.14.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:88bd7b6bd70a5b6803c1abf6bca012f7ed963e58c68d76ee20b9d751c74a3248"}, + {file = "wrapt-1.14.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b5901a312f4d14c59918c221323068fad0540e34324925c8475263841dbdfe68"}, + {file = "wrapt-1.14.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:d77c85fedff92cf788face9bfa3ebaa364448ebb1d765302e9af11bf449ca36d"}, + {file = "wrapt-1.14.1-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8d649d616e5c6a678b26d15ece345354f7c2286acd6db868e65fcc5ff7c24a77"}, + {file = "wrapt-1.14.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:7d2872609603cb35ca513d7404a94d6d608fc13211563571117046c9d2bcc3d7"}, + {file = "wrapt-1.14.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:ee6acae74a2b91865910eef5e7de37dc6895ad96fa23603d1d27ea69df545015"}, + {file = "wrapt-1.14.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:2b39d38039a1fdad98c87279b48bc5dce2c0ca0d73483b12cb72aa9609278e8a"}, + {file = "wrapt-1.14.1-cp37-cp37m-win32.whl", hash = "sha256:60db23fa423575eeb65ea430cee741acb7c26a1365d103f7b0f6ec412b893853"}, + {file = "wrapt-1.14.1-cp37-cp37m-win_amd64.whl", hash = "sha256:709fe01086a55cf79d20f741f39325018f4df051ef39fe921b1ebe780a66184c"}, + {file = "wrapt-1.14.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:8c0ce1e99116d5ab21355d8ebe53d9460366704ea38ae4d9f6933188f327b456"}, + {file = "wrapt-1.14.1-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:e3fb1677c720409d5f671e39bac6c9e0e422584e5f518bfd50aa4cbbea02433f"}, + {file = "wrapt-1.14.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:642c2e7a804fcf18c222e1060df25fc210b9c58db7c91416fb055897fc27e8cc"}, + {file = "wrapt-1.14.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:7b7c050ae976e286906dd3f26009e117eb000fb2cf3533398c5ad9ccc86867b1"}, + {file = "wrapt-1.14.1-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ef3f72c9666bba2bab70d2a8b79f2c6d2c1a42a7f7e2b0ec83bb2f9e383950af"}, + {file = "wrapt-1.14.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:01c205616a89d09827986bc4e859bcabd64f5a0662a7fe95e0d359424e0e071b"}, + {file = "wrapt-1.14.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:5a0f54ce2c092aaf439813735584b9537cad479575a09892b8352fea5e988dc0"}, + {file = "wrapt-1.14.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:2cf71233a0ed05ccdabe209c606fe0bac7379fdcf687f39b944420d2a09fdb57"}, + {file = "wrapt-1.14.1-cp38-cp38-win32.whl", hash = "sha256:aa31fdcc33fef9eb2552cbcbfee7773d5a6792c137b359e82879c101e98584c5"}, + {file = "wrapt-1.14.1-cp38-cp38-win_amd64.whl", hash = "sha256:d1967f46ea8f2db647c786e78d8cc7e4313dbd1b0aca360592d8027b8508e24d"}, + {file = "wrapt-1.14.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:3232822c7d98d23895ccc443bbdf57c7412c5a65996c30442ebe6ed3df335383"}, + {file = "wrapt-1.14.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:988635d122aaf2bdcef9e795435662bcd65b02f4f4c1ae37fbee7401c440b3a7"}, + {file = "wrapt-1.14.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9cca3c2cdadb362116235fdbd411735de4328c61425b0aa9f872fd76d02c4e86"}, + {file = "wrapt-1.14.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:d52a25136894c63de15a35bc0bdc5adb4b0e173b9c0d07a2be9d3ca64a332735"}, + {file = "wrapt-1.14.1-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:40e7bc81c9e2b2734ea4bc1aceb8a8f0ceaac7c5299bc5d69e37c44d9081d43b"}, + {file = "wrapt-1.14.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:b9b7a708dd92306328117d8c4b62e2194d00c365f18eff11a9b53c6f923b01e3"}, + {file = "wrapt-1.14.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:6a9a25751acb379b466ff6be78a315e2b439d4c94c1e99cb7266d40a537995d3"}, + {file = "wrapt-1.14.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:34aa51c45f28ba7f12accd624225e2b1e5a3a45206aa191f6f9aac931d9d56fe"}, + {file = "wrapt-1.14.1-cp39-cp39-win32.whl", hash = "sha256:dee0ce50c6a2dd9056c20db781e9c1cfd33e77d2d569f5d1d9321c641bb903d5"}, + {file = "wrapt-1.14.1-cp39-cp39-win_amd64.whl", hash = "sha256:dee60e1de1898bde3b238f18340eec6148986da0455d8ba7848d50470a7a32fb"}, + {file = "wrapt-1.14.1.tar.gz", hash = "sha256:380a85cf89e0e69b7cfbe2ea9f765f004ff419f34194018a6827ac0e3edfed4d"}, +] +yarl = [ + {file = "yarl-1.8.1-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:abc06b97407868ef38f3d172762f4069323de52f2b70d133d096a48d72215d28"}, + {file = "yarl-1.8.1-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:07b21e274de4c637f3e3b7104694e53260b5fc10d51fb3ec5fed1da8e0f754e3"}, + {file = "yarl-1.8.1-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9de955d98e02fab288c7718662afb33aab64212ecb368c5dc866d9a57bf48880"}, + {file = "yarl-1.8.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7ec362167e2c9fd178f82f252b6d97669d7245695dc057ee182118042026da40"}, + {file = "yarl-1.8.1-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:20df6ff4089bc86e4a66e3b1380460f864df3dd9dccaf88d6b3385d24405893b"}, + {file = "yarl-1.8.1-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:5999c4662631cb798496535afbd837a102859568adc67d75d2045e31ec3ac497"}, + {file = "yarl-1.8.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ed19b74e81b10b592084a5ad1e70f845f0aacb57577018d31de064e71ffa267a"}, + {file = "yarl-1.8.1-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:1e4808f996ca39a6463f45182e2af2fae55e2560be586d447ce8016f389f626f"}, + {file = "yarl-1.8.1-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:2d800b9c2eaf0684c08be5f50e52bfa2aa920e7163c2ea43f4f431e829b4f0fd"}, + {file = "yarl-1.8.1-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:6628d750041550c5d9da50bb40b5cf28a2e63b9388bac10fedd4f19236ef4957"}, + {file = "yarl-1.8.1-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:f5af52738e225fcc526ae64071b7e5342abe03f42e0e8918227b38c9aa711e28"}, + {file = "yarl-1.8.1-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:76577f13333b4fe345c3704811ac7509b31499132ff0181f25ee26619de2c843"}, + {file = "yarl-1.8.1-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:0c03f456522d1ec815893d85fccb5def01ffaa74c1b16ff30f8aaa03eb21e453"}, + {file = "yarl-1.8.1-cp310-cp310-win32.whl", hash = "sha256:ea30a42dc94d42f2ba4d0f7c0ffb4f4f9baa1b23045910c0c32df9c9902cb272"}, + {file = "yarl-1.8.1-cp310-cp310-win_amd64.whl", hash = "sha256:9130ddf1ae9978abe63808b6b60a897e41fccb834408cde79522feb37fb72fb0"}, + {file = "yarl-1.8.1-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:0ab5a138211c1c366404d912824bdcf5545ccba5b3ff52c42c4af4cbdc2c5035"}, + {file = "yarl-1.8.1-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a0fb2cb4204ddb456a8e32381f9a90000429489a25f64e817e6ff94879d432fc"}, + {file = "yarl-1.8.1-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:85cba594433915d5c9a0d14b24cfba0339f57a2fff203a5d4fd070e593307d0b"}, + {file = "yarl-1.8.1-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:1ca7e596c55bd675432b11320b4eacc62310c2145d6801a1f8e9ad160685a231"}, + {file = "yarl-1.8.1-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:d0f77539733e0ec2475ddcd4e26777d08996f8cd55d2aef82ec4d3896687abda"}, + {file = "yarl-1.8.1-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:29e256649f42771829974e742061c3501cc50cf16e63f91ed8d1bf98242e5507"}, + {file = "yarl-1.8.1-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:7fce6cbc6c170ede0221cc8c91b285f7f3c8b9fe28283b51885ff621bbe0f8ee"}, + {file = "yarl-1.8.1-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:59ddd85a1214862ce7c7c66457f05543b6a275b70a65de366030d56159a979f0"}, + {file = "yarl-1.8.1-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:12768232751689c1a89b0376a96a32bc7633c08da45ad985d0c49ede691f5c0d"}, + {file = "yarl-1.8.1-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:b19255dde4b4f4c32e012038f2c169bb72e7f081552bea4641cab4d88bc409dd"}, + {file = "yarl-1.8.1-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:6c8148e0b52bf9535c40c48faebb00cb294ee577ca069d21bd5c48d302a83780"}, + {file = "yarl-1.8.1-cp37-cp37m-win32.whl", hash = "sha256:de839c3a1826a909fdbfe05f6fe2167c4ab033f1133757b5936efe2f84904c07"}, + {file = "yarl-1.8.1-cp37-cp37m-win_amd64.whl", hash = "sha256:dd032e8422a52e5a4860e062eb84ac94ea08861d334a4bcaf142a63ce8ad4802"}, + {file = "yarl-1.8.1-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:19cd801d6f983918a3f3a39f3a45b553c015c5aac92ccd1fac619bd74beece4a"}, + {file = "yarl-1.8.1-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:6347f1a58e658b97b0a0d1ff7658a03cb79bdbda0331603bed24dd7054a6dea1"}, + {file = "yarl-1.8.1-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:7c0da7e44d0c9108d8b98469338705e07f4bb7dab96dbd8fa4e91b337db42548"}, + {file = "yarl-1.8.1-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:5587bba41399854703212b87071c6d8638fa6e61656385875f8c6dff92b2e461"}, + {file = "yarl-1.8.1-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:31a9a04ecccd6b03e2b0e12e82131f1488dea5555a13a4d32f064e22a6003cfe"}, + {file = "yarl-1.8.1-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:205904cffd69ae972a1707a1bd3ea7cded594b1d773a0ce66714edf17833cdae"}, + {file = "yarl-1.8.1-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ea513a25976d21733bff523e0ca836ef1679630ef4ad22d46987d04b372d57fc"}, + {file = "yarl-1.8.1-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:d0b51530877d3ad7a8d47b2fff0c8df3b8f3b8deddf057379ba50b13df2a5eae"}, + {file = "yarl-1.8.1-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:d2b8f245dad9e331540c350285910b20dd913dc86d4ee410c11d48523c4fd546"}, + {file = "yarl-1.8.1-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:ab2a60d57ca88e1d4ca34a10e9fb4ab2ac5ad315543351de3a612bbb0560bead"}, + {file = "yarl-1.8.1-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:449c957ffc6bc2309e1fbe67ab7d2c1efca89d3f4912baeb8ead207bb3cc1cd4"}, + {file = "yarl-1.8.1-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:a165442348c211b5dea67c0206fc61366212d7082ba8118c8c5c1c853ea4d82e"}, + {file = "yarl-1.8.1-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:b3ded839a5c5608eec8b6f9ae9a62cb22cd037ea97c627f38ae0841a48f09eae"}, + {file = "yarl-1.8.1-cp38-cp38-win32.whl", hash = "sha256:c1445a0c562ed561d06d8cbc5c8916c6008a31c60bc3655cdd2de1d3bf5174a0"}, + {file = "yarl-1.8.1-cp38-cp38-win_amd64.whl", hash = "sha256:56c11efb0a89700987d05597b08a1efcd78d74c52febe530126785e1b1a285f4"}, + {file = "yarl-1.8.1-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:e80ed5a9939ceb6fda42811542f31c8602be336b1fb977bccb012e83da7e4936"}, + {file = "yarl-1.8.1-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:6afb336e23a793cd3b6476c30f030a0d4c7539cd81649683b5e0c1b0ab0bf350"}, + {file = "yarl-1.8.1-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:4c322cbaa4ed78a8aac89b2174a6df398faf50e5fc12c4c191c40c59d5e28357"}, + {file = "yarl-1.8.1-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:fae37373155f5ef9b403ab48af5136ae9851151f7aacd9926251ab26b953118b"}, + {file = "yarl-1.8.1-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:5395da939ffa959974577eff2cbfc24b004a2fb6c346918f39966a5786874e54"}, + {file = "yarl-1.8.1-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:076eede537ab978b605f41db79a56cad2e7efeea2aa6e0fa8f05a26c24a034fb"}, + {file = "yarl-1.8.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3d1a50e461615747dd93c099f297c1994d472b0f4d2db8a64e55b1edf704ec1c"}, + {file = "yarl-1.8.1-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:7de89c8456525650ffa2bb56a3eee6af891e98f498babd43ae307bd42dca98f6"}, + {file = "yarl-1.8.1-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:4a88510731cd8d4befaba5fbd734a7dd914de5ab8132a5b3dde0bbd6c9476c64"}, + {file = "yarl-1.8.1-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:2d93a049d29df172f48bcb09acf9226318e712ce67374f893b460b42cc1380ae"}, + {file = "yarl-1.8.1-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:21ac44b763e0eec15746a3d440f5e09ad2ecc8b5f6dcd3ea8cb4773d6d4703e3"}, + {file = "yarl-1.8.1-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:d0272228fabe78ce00a3365ffffd6f643f57a91043e119c289aaba202f4095b0"}, + {file = "yarl-1.8.1-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:99449cd5366fe4608e7226c6cae80873296dfa0cde45d9b498fefa1de315a09e"}, + {file = "yarl-1.8.1-cp39-cp39-win32.whl", hash = "sha256:8b0af1cf36b93cee99a31a545fe91d08223e64390c5ecc5e94c39511832a4bb6"}, + {file = "yarl-1.8.1-cp39-cp39-win_amd64.whl", hash = "sha256:de49d77e968de6626ba7ef4472323f9d2e5a56c1d85b7c0e2a190b2173d3b9be"}, + {file = "yarl-1.8.1.tar.gz", hash = "sha256:af887845b8c2e060eb5605ff72b6f2dd2aab7a761379373fd89d314f4752abbf"}, +] +zipp = [ + {file = "zipp-3.8.1-py3-none-any.whl", hash = "sha256:47c40d7fe183a6f21403a199b3e4192cca5774656965b0a4988ad2f8feb5f009"}, + {file = "zipp-3.8.1.tar.gz", hash = "sha256:05b45f1ee8f807d0cc928485ca40a07cb491cf092ff587c0df9cb1fd154848d2"}, +] diff --git a/tools/c7n_tencentcloud/readme.md b/tools/c7n_tencentcloud/readme.md index 818bba5af37..7993176ec18 100644 --- a/tools/c7n_tencentcloud/readme.md +++ b/tools/c7n_tencentcloud/readme.md @@ -1,2 +1,32 @@ -tencentcloud for custodian - +# Tencent Cloud + +a provider for cloud custodian for usage with Tencent Cloud. + +# Installation + + +```shell + +pip install c7n_tencentcloud +``` + + +# Usage + +To execute policies against tencent cloud you'll need to provide api +credentials for custodian to interact with the cloud apis. + +as a best practice create a sub account / cam user with api keys in the console. + + +```shell + +export TENCENTCLOUD_SECRET_ID="xyz" +export TENCENTCLOUD_SECRET_KEY="abc123" +export TENCENTCLOUD_REGION="na-ashburn" +custodian run -v policy.yml +``` + +region can also be passed on the cli via the `--region` flag, complete list of regions is here +https://www.tencentcloud.com/document/product/213/6091 + diff --git a/tools/c7n_tencentcloud/requirements.txt b/tools/c7n_tencentcloud/requirements.txt index 6dbf60837b0..a31e938ac7a 100644 --- a/tools/c7n_tencentcloud/requirements.txt +++ b/tools/c7n_tencentcloud/requirements.txt @@ -1,9 +1,9 @@ -certifi==2022.9.14; python_version >= "3.7" and python_version < "4" -charset-normalizer==2.1.1; python_version >= "3.7" and python_version < "4" and python_full_version >= "3.6.0" -idna==3.4; python_version >= "3.7" and python_version < "4" -pytz==2022.2.1 -requests==2.28.1; python_version >= "3.7" and python_version < "4" -retrying==1.3.3 -six==1.16.0; python_version >= "2.7" and python_full_version < "3.0.0" or python_full_version >= "3.3.0" -tencentcloud-sdk-python==3.0.737 -urllib3==1.26.12; python_version >= "3.7" and python_full_version < "3.0.0" and python_version < "4" or python_full_version >= "3.6.0" and python_version < "4" and python_version >= "3.7" +certifi==2022.9.24 ; python_version >= "3.7" and python_version < "4" +charset-normalizer==2.1.1 ; python_version >= "3.7" and python_version < "4" +idna==3.4 ; python_version >= "3.7" and python_version < "4" +pytz==2022.4 ; python_version >= "3.7" and python_version < "4.0" +requests==2.28.1 ; python_version >= "3.7" and python_version < "4" +retrying==1.3.3 ; python_version >= "3.7" and python_version < "4.0" +six==1.16.0 ; python_version >= "3.7" and python_version < "4.0" +tencentcloud-sdk-python==3.0.745 ; python_version >= "3.7" and python_version < "4.0" +urllib3==1.26.12 ; python_version >= "3.7" and python_version < "4" diff --git a/tools/c7n_tencentcloud/setup.py b/tools/c7n_tencentcloud/setup.py index d29d2c92531..45cd2b36ece 100644 --- a/tools/c7n_tencentcloud/setup.py +++ b/tools/c7n_tencentcloud/setup.py @@ -15,18 +15,17 @@ install_requires = \ ['argcomplete (>=2.0.0,<3.0.0)', 'attrs (>=22.1.0,<23.0.0)', - 'boto3 (>=1.24.77,<2.0.0)', - 'botocore (>=1.27.77,<2.0.0)', + 'boto3 (>=1.24.87,<2.0.0)', + 'botocore (>=1.27.87,<2.0.0)', 'c7n (>=0.9.19,<0.10.0)', 'docutils (>=0.17.1,<0.18.0)', - 'importlib-metadata (>=4.12.0,<5.0.0)', + 'importlib-metadata (>=4.13.0,<5.0.0)', 'importlib-resources (>=5.9.0,<6.0.0)', 'jmespath (>=1.0.1,<2.0.0)', 'jsonschema (>=4.16.0,<5.0.0)', - 'pkgutil-resolve-name (>=1.3.10,<2.0.0)', + 'pkgutil_resolve_name (>=1.3.10,<2.0.0)', 'pyrsistent (>=0.18.1,<0.19.0)', 'python-dateutil (>=2.8.2,<3.0.0)', - 'python-linq>=2.0.4,<3.0.0', 'pytz>=2022.1', 'pyyaml (>=6.0,<7.0)', 'retrying>=1.3.3,<2.0.0', @@ -48,13 +47,16 @@ 'Topic :: System :: Systems Administration', 'Topic :: System :: Distributed Computing' ], - 'long_description': None, + 'long_description': 'None', 'long_description_content_type': 'text/markdown', - 'author': 'Tencent Cloud', - 'author_email': None, - 'maintainer': None, - 'maintainer_email': None, - 'url': None, + 'author': 'Cloud Custodian Project', + 'author_email': 'cloud-custodian@googlegroups.com', + 'project_urls': { + 'Homepage': 'None', + 'Documentation': 'https://cloudcustodian.io/docs/', + 'Source': 'https://github.com/cloud-custodian/cloud-custodian', + 'Issue Tracker': 'https://github.com/cloud-custodian/cloud-custodian/issues', + }, 'packages': packages, 'package_data': package_data, 'install_requires': install_requires, diff --git a/tools/c7n_tencentcloud/tests/cassettes/test_filter_metrics/TestFilterMetrics.test_average.yaml b/tools/c7n_tencentcloud/tests/cassettes/test_filter_metrics/TestFilterMetrics.test_average.yaml new file mode 100644 index 00000000000..9fbc715a236 --- /dev/null +++ b/tools/c7n_tencentcloud/tests/cassettes/test_filter_metrics/TestFilterMetrics.test_average.yaml @@ -0,0 +1,134 @@ +interactions: +- request: + body: '{"InstanceIds": ["ins-dq1dmpgk", "ins-n198q4gc"], "Offset": 0, "Limit": + 20}' + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '75' + Content-Type: + - application/json + Host: + - cvm.ap-singapore.tencentcloudapi.com + User-Agent: + - python-requests/2.28.1 + X-TC-Action: + - DescribeInstances + X-TC-Region: + - ap-singapore + X-TC-Version: + - '2017-03-12' + method: POST + uri: https://cvm.ap-singapore.tencentcloudapi.com/ + response: + body: + string: "{\"Response\": {\"TotalCount\": 2, \"InstanceSet\": [{\"Placement\": + {\"Zone\": \"ap-singapore-4\", \"HostId\": null, \"ProjectId\": 0}, \"InstanceId\": + \"ins-dq1dmpgk\", \"Uuid\": \"2e56464f-5d8c-4449-960f-75ad37e5a625\", \"OperatorUin\": + \"\", \"InstanceState\": \"RUNNING\", \"RestrictState\": \"NORMAL\", \"InstanceType\": + \"SA2.MEDIUM4\", \"CPU\": 2, \"Memory\": 4, \"InstanceName\": \"arron_cvm\", + \"InstanceChargeType\": \"POSTPAID_BY_HOUR\", \"SystemDisk\": {\"DiskType\": + \"CLOUD_BSSD\", \"DiskId\": \"disk-86s0fjos\", \"DiskSize\": 50, \"Encrypt\": + false, \"KmsKeyId\": null, \"ThroughputPerformance\": 0, \"CdcId\": null}, + \"DataDisks\": [], \"PrivateIpAddresses\": [\"192.168.0.11\"], \"PublicIpAddresses\": + [\"43.156.31.218\"], \"IPv6Addresses\": null, \"InternetAccessible\": {\"InternetMaxBandwidthOut\": + 10, \"InternetChargeType\": \"TRAFFIC_POSTPAID_BY_HOUR\"}, \"VirtualPrivateCloud\": + {\"VpcId\": \"vpc-rdsfj6ot\", \"SubnetId\": \"subnet-9hl8a56w\", \"AsVpcGateway\": + false}, \"SecurityGroupIds\": [\"sg-0tifsp1w\", \"sg-cj259yog\"], \"LoginSettings\": + {\"KeyIds\": [\"skey-0uvvu4xh\"]}, \"ImageId\": \"img-eb30mz89\", \"OsName\": + \"TencentOS Server 3.1 (TK4)\", \"DefaultLoginUser\": \"root\", \"DefaultLoginPort\": + 22, \"RenewFlag\": null, \"CreatedTime\": \"2022-09-14T02:09:47Z\", \"ExpiredTime\": + null, \"Tags\": [], \"PlatformProjectId\": null, \"DisasterRecoverGroupId\": + \"\", \"DedicatedClusterId\": \"\", \"CamRoleName\": \"\", \"LatestOperation\": + \"ModifyInstancesAttribute.SecurityGroups\", \"LatestOperationState\": \"SUCCESS\", + \"LatestOperationRequestId\": \"76438a01-31a9-4e8e-a112-8acf49ff4aca\", \"IsolatedSource\": + \"NOTISOLATED\", \"HpcClusterId\": \"\", \"DisableApiTermination\": false, + \"RdmaIpAddresses\": null, \"LicenseType\": \"TencentCloud\", \"StopChargingMode\": + \"NOT_APPLICABLE\"}, {\"Placement\": {\"Zone\": \"ap-singapore-1\", \"HostId\": + null, \"ProjectId\": 1000000511}, \"InstanceId\": \"ins-n198q4gc\", \"Uuid\": + \"507d7ee0-bb64-48ff-82b1-960f03ad904f\", \"OperatorUin\": \"\", \"InstanceState\": + \"RUNNING\", \"RestrictState\": \"NORMAL\", \"InstanceType\": \"S5.LARGE8\", + \"CPU\": 4, \"Memory\": 8, \"InstanceName\": \"Unnamed\", \"InstanceChargeType\": + \"POSTPAID_BY_HOUR\", \"SystemDisk\": {\"DiskType\": \"CLOUD_PREMIUM\", \"DiskId\": + \"disk-2xu821gm\", \"DiskSize\": 50, \"Encrypt\": false, \"KmsKeyId\": null, + \"ThroughputPerformance\": 0, \"CdcId\": null}, \"DataDisks\": [], \"PrivateIpAddresses\": + [\"10.0.1.8\"], \"PublicIpAddresses\": [\"43.156.4.43\"], \"IPv6Addresses\": + null, \"InternetAccessible\": {\"InternetMaxBandwidthOut\": 5, \"InternetChargeType\": + \"TRAFFIC_POSTPAID_BY_HOUR\"}, \"VirtualPrivateCloud\": {\"VpcId\": \"vpc-aik1957f\", + \"SubnetId\": \"subnet-5k1ixnpo\", \"AsVpcGateway\": false}, \"SecurityGroupIds\": + [\"sg-b3fnpwk6\"], \"LoginSettings\": {\"KeyIds\": null}, \"ImageId\": \"img-9id7emv7\", + \"OsName\": \"Windows Server 2016 \u6570\u636E\u4E2D\u5FC3\u7248 64\u4F4D\u4E2D\u6587\u7248\", + \"DefaultLoginUser\": \"Administrator\", \"DefaultLoginPort\": 3389, \"RenewFlag\": + null, \"CreatedTime\": \"2022-06-20T06:24:35Z\", \"ExpiredTime\": null, \"Tags\": + [], \"PlatformProjectId\": null, \"DisasterRecoverGroupId\": \"\", \"DedicatedClusterId\": + \"\", \"CamRoleName\": \"\", \"LatestOperation\": null, \"LatestOperationState\": + null, \"LatestOperationRequestId\": null, \"IsolatedSource\": \"NOTISOLATED\", + \"HpcClusterId\": \"\", \"DisableApiTermination\": false, \"RdmaIpAddresses\": + null, \"LicenseType\": \"TencentCloud\", \"StopChargingMode\": \"NOT_APPLICABLE\"}], + \"RequestId\": \"28e7ea01-0ee3-4de0-9b43-1ae77317f8b5\"}}" + headers: + Connection: + - keep-alive + Content-Length: + - '3235' + Content-Type: + - application/json + Date: + - Thu, 29 Sep 2022 01:59:31 GMT + Server: + - nginx + status: + code: 200 + message: OK +- request: + body: '{"Namespace": "QCE/CVM", "MetricName": "CPUUsage", "Period": 3600, "StartTime": + "2022-09-26T09:59:29+08:00", "EndTime": "2022-09-29T09:59:29+08:00", "Instances": + [{"Dimensions": [{"Name": "InstanceId", "Value": "ins-dq1dmpgk"}]}, {"Dimensions": + [{"Name": "InstanceId", "Value": "ins-n198q4gc"}]}]}' + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '297' + Content-Type: + - application/json + Host: + - monitor.ap-singapore.tencentcloudapi.com + User-Agent: + - python-requests/2.28.1 + X-TC-Action: + - GetMonitorData + X-TC-Region: + - ap-singapore + X-TC-Version: + - '2018-07-24' + method: POST + uri: https://monitor.ap-singapore.tencentcloudapi.com/ + response: + body: + string: '{"Response":{"StartTime":"2022-09-26 09:00:00","EndTime":"2022-09-29 + 09:00:00","Period":3600,"MetricName":"CPUUsage","DataPoints":[{"Dimensions":[{"Name":"InstanceId","Value":"ins-dq1dmpgk"}],"Timestamps":[1664154000,1664157600,1664161200,1664164800,1664168400,1664172000,1664175600,1664179200,1664182800,1664186400,1664190000,1664193600,1664197200,1664200800,1664204400,1664208000,1664211600,1664215200,1664218800,1664222400,1664226000,1664229600,1664233200,1664236800,1664240400,1664244000,1664247600,1664251200,1664254800,1664258400,1664262000,1664265600,1664269200,1664272800,1664276400,1664280000,1664283600,1664287200,1664290800,1664294400,1664298000,1664301600,1664305200,1664308800,1664312400,1664316000,1664319600,1664323200,1664326800,1664330400,1664334000,1664337600,1664341200,1664344800,1664348400,1664352000,1664355600,1664359200,1664362800,1664366400,1664370000,1664373600,1664377200,1664380800,1664384400,1664388000,1664391600,1664395200,1664398800,1664402400,1664406000,1664409600],"Values":[1.05,0.966,1.366,0.816,1.316,0.816,0.866,0.833,0.983,0.916,0.95,0.933,0.9,0.85,0.883,1.25,2.266,2.35,0.966,0.833,0.883,0.85,1.033,0.85,0.833,0.866,1.25,0.966,0.916,0.866,0.883,0.983,0.85,0.85,0.85,1.316,1.449,1.216,0.883,0.916,2.166,0.916,0.833,0.916,0.866,0.9,0.85,1.333,0.85,0.866,1.166,0.883,0.866,0.833,0.833,0.866,0.933,0.933,0.85,0.883,1.1,0.866,1.033,0.966,2.366,0.9,0.85,0.833,0.866,0.883,0.833,0.8]},{"Dimensions":[{"Name":"InstanceId","Value":"ins-n198q4gc"}],"Timestamps":[1664154000,1664157600,1664161200,1664164800,1664168400,1664172000,1664175600,1664179200,1664182800,1664186400,1664190000,1664193600,1664197200,1664200800,1664204400,1664208000,1664211600,1664215200,1664218800,1664222400,1664226000,1664229600,1664233200,1664236800,1664240400,1664244000,1664247600,1664251200,1664254800,1664258400,1664262000,1664265600,1664269200,1664272800,1664276400,1664280000,1664283600,1664287200,1664290800,1664294400,1664298000,1664301600,1664305200,1664308800,1664312400,1664316000,1664319600,1664323200,1664326800,1664330400,1664334000,1664337600,1664341200,1664344800,1664348400,1664352000,1664355600,1664359200,1664362800,1664366400,1664370000,1664373600,1664377200,1664380800,1664384400,1664388000,1664391600,1664395200,1664398800,1664402400,1664406000,1664409600],"Values":[0,0.333,0.166,0,0,0.5,0.166,0.166,0,0,0,0.166,0,0,0.166,1.833,1.666,0.166,0.333,0.166,0.166,0.166,0.166,0.333,0.166,0,0.166,0.166,0,0,0,0.166,0,0.333,0.166,0,0.166,0.166,0,1.833,0.166,1.833,0.166,0.166,0,0.166,0,0.166,0,0.166,0.166,0,0.166,0.166,0,0.166,0,0,0,0,0.166,0,0.166,1.833,1.666,0,0.166,0.333,0.166,0.166,0.333,0.166]}],"RequestId":"9711a757-5e97-4246-92fe-c07df39aceef"}}' + headers: + Connection: + - keep-alive + Content-Length: + - '2677' + Content-Type: + - application/json + Date: + - Thu, 29 Sep 2022 01:59:40 GMT + Server: + - nginx + status: + code: 200 + message: OK +version: 1 diff --git a/tools/c7n_tencentcloud/tests/cassettes/test_filter_metrics/TestFilterMetrics.test_max.yaml b/tools/c7n_tencentcloud/tests/cassettes/test_filter_metrics/TestFilterMetrics.test_max.yaml new file mode 100644 index 00000000000..5d7299653c4 --- /dev/null +++ b/tools/c7n_tencentcloud/tests/cassettes/test_filter_metrics/TestFilterMetrics.test_max.yaml @@ -0,0 +1,134 @@ +interactions: +- request: + body: '{"InstanceIds": ["ins-dq1dmpgk", "ins-n198q4gc"], "Offset": 0, "Limit": + 20}' + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '75' + Content-Type: + - application/json + Host: + - cvm.ap-singapore.tencentcloudapi.com + User-Agent: + - python-requests/2.28.1 + X-TC-Action: + - DescribeInstances + X-TC-Region: + - ap-singapore + X-TC-Version: + - '2017-03-12' + method: POST + uri: https://cvm.ap-singapore.tencentcloudapi.com/ + response: + body: + string: "{\"Response\": {\"TotalCount\": 2, \"InstanceSet\": [{\"Placement\": + {\"Zone\": \"ap-singapore-4\", \"HostId\": null, \"ProjectId\": 0}, \"InstanceId\": + \"ins-dq1dmpgk\", \"Uuid\": \"2e56464f-5d8c-4449-960f-75ad37e5a625\", \"OperatorUin\": + \"\", \"InstanceState\": \"RUNNING\", \"RestrictState\": \"NORMAL\", \"InstanceType\": + \"SA2.MEDIUM4\", \"CPU\": 2, \"Memory\": 4, \"InstanceName\": \"arron_cvm\", + \"InstanceChargeType\": \"POSTPAID_BY_HOUR\", \"SystemDisk\": {\"DiskType\": + \"CLOUD_BSSD\", \"DiskId\": \"disk-86s0fjos\", \"DiskSize\": 50, \"Encrypt\": + false, \"KmsKeyId\": null, \"ThroughputPerformance\": 0, \"CdcId\": null}, + \"DataDisks\": [], \"PrivateIpAddresses\": [\"192.168.0.11\"], \"PublicIpAddresses\": + [\"43.156.31.218\"], \"IPv6Addresses\": null, \"InternetAccessible\": {\"InternetMaxBandwidthOut\": + 10, \"InternetChargeType\": \"TRAFFIC_POSTPAID_BY_HOUR\"}, \"VirtualPrivateCloud\": + {\"VpcId\": \"vpc-rdsfj6ot\", \"SubnetId\": \"subnet-9hl8a56w\", \"AsVpcGateway\": + false}, \"SecurityGroupIds\": [\"sg-0tifsp1w\", \"sg-cj259yog\"], \"LoginSettings\": + {\"KeyIds\": [\"skey-0uvvu4xh\"]}, \"ImageId\": \"img-eb30mz89\", \"OsName\": + \"TencentOS Server 3.1 (TK4)\", \"DefaultLoginUser\": \"root\", \"DefaultLoginPort\": + 22, \"RenewFlag\": null, \"CreatedTime\": \"2022-09-14T02:09:47Z\", \"ExpiredTime\": + null, \"Tags\": [], \"PlatformProjectId\": null, \"DisasterRecoverGroupId\": + \"\", \"DedicatedClusterId\": \"\", \"CamRoleName\": \"\", \"LatestOperation\": + \"ModifyInstancesAttribute.SecurityGroups\", \"LatestOperationState\": \"SUCCESS\", + \"LatestOperationRequestId\": \"76438a01-31a9-4e8e-a112-8acf49ff4aca\", \"IsolatedSource\": + \"NOTISOLATED\", \"HpcClusterId\": \"\", \"DisableApiTermination\": false, + \"RdmaIpAddresses\": null, \"LicenseType\": \"TencentCloud\", \"StopChargingMode\": + \"NOT_APPLICABLE\"}, {\"Placement\": {\"Zone\": \"ap-singapore-1\", \"HostId\": + null, \"ProjectId\": 1000000511}, \"InstanceId\": \"ins-n198q4gc\", \"Uuid\": + \"507d7ee0-bb64-48ff-82b1-960f03ad904f\", \"OperatorUin\": \"\", \"InstanceState\": + \"RUNNING\", \"RestrictState\": \"NORMAL\", \"InstanceType\": \"S5.LARGE8\", + \"CPU\": 4, \"Memory\": 8, \"InstanceName\": \"Unnamed\", \"InstanceChargeType\": + \"POSTPAID_BY_HOUR\", \"SystemDisk\": {\"DiskType\": \"CLOUD_PREMIUM\", \"DiskId\": + \"disk-2xu821gm\", \"DiskSize\": 50, \"Encrypt\": false, \"KmsKeyId\": null, + \"ThroughputPerformance\": 0, \"CdcId\": null}, \"DataDisks\": [], \"PrivateIpAddresses\": + [\"10.0.1.8\"], \"PublicIpAddresses\": [\"43.156.4.43\"], \"IPv6Addresses\": + null, \"InternetAccessible\": {\"InternetMaxBandwidthOut\": 5, \"InternetChargeType\": + \"TRAFFIC_POSTPAID_BY_HOUR\"}, \"VirtualPrivateCloud\": {\"VpcId\": \"vpc-aik1957f\", + \"SubnetId\": \"subnet-5k1ixnpo\", \"AsVpcGateway\": false}, \"SecurityGroupIds\": + [\"sg-b3fnpwk6\"], \"LoginSettings\": {\"KeyIds\": null}, \"ImageId\": \"img-9id7emv7\", + \"OsName\": \"Windows Server 2016 \u6570\u636E\u4E2D\u5FC3\u7248 64\u4F4D\u4E2D\u6587\u7248\", + \"DefaultLoginUser\": \"Administrator\", \"DefaultLoginPort\": 3389, \"RenewFlag\": + null, \"CreatedTime\": \"2022-06-20T06:24:35Z\", \"ExpiredTime\": null, \"Tags\": + [], \"PlatformProjectId\": null, \"DisasterRecoverGroupId\": \"\", \"DedicatedClusterId\": + \"\", \"CamRoleName\": \"\", \"LatestOperation\": null, \"LatestOperationState\": + null, \"LatestOperationRequestId\": null, \"IsolatedSource\": \"NOTISOLATED\", + \"HpcClusterId\": \"\", \"DisableApiTermination\": false, \"RdmaIpAddresses\": + null, \"LicenseType\": \"TencentCloud\", \"StopChargingMode\": \"NOT_APPLICABLE\"}], + \"RequestId\": \"98de9ef0-cbf9-43a6-b446-9d43b137e18a\"}}" + headers: + Connection: + - keep-alive + Content-Length: + - '3235' + Content-Type: + - application/json + Date: + - Thu, 29 Sep 2022 01:59:41 GMT + Server: + - nginx + status: + code: 200 + message: OK +- request: + body: '{"Namespace": "QCE/CVM", "MetricName": "CvmDiskUsage", "Period": 300, "StartTime": + "2022-09-28T09:59:40+08:00", "EndTime": "2022-09-29T09:59:40+08:00", "Instances": + [{"Dimensions": [{"Name": "InstanceId", "Value": "ins-dq1dmpgk"}]}, {"Dimensions": + [{"Name": "InstanceId", "Value": "ins-n198q4gc"}]}]}' + headers: + Accept: + - '*/*' + Accept-Encoding: + - gzip, deflate + Connection: + - keep-alive + Content-Length: + - '300' + Content-Type: + - application/json + Host: + - monitor.ap-singapore.tencentcloudapi.com + User-Agent: + - python-requests/2.28.1 + X-TC-Action: + - GetMonitorData + X-TC-Region: + - ap-singapore + X-TC-Version: + - '2018-07-24' + method: POST + uri: https://monitor.ap-singapore.tencentcloudapi.com/ + response: + body: + string: '{"Response":{"StartTime":"2022-09-28 09:55:00","EndTime":"2022-09-29 + 09:55:00","Period":300,"MetricName":"CvmDiskUsage","DataPoints":[{"Dimensions":[{"Name":"InstanceId","Value":"ins-dq1dmpgk"}],"Timestamps":[1664330100,1664330400,1664330700,1664331000,1664331300,1664331600,1664331900,1664332200,1664332500,1664332800,1664333100,1664333400,1664333700,1664334000,1664334300,1664334600,1664334900,1664335200,1664335500,1664335800,1664336100,1664336400,1664336700,1664337000,1664337300,1664337600,1664337900,1664338200,1664338500,1664338800,1664339100,1664339400,1664339700,1664340000,1664340300,1664340600,1664340900,1664341200,1664341500,1664341800,1664342100,1664342400,1664342700,1664343000,1664343300,1664343600,1664343900,1664344200,1664344500,1664344800,1664345100,1664345400,1664345700,1664346000,1664346300,1664346600,1664346900,1664347200,1664347500,1664347800,1664348100,1664348400,1664348700,1664349000,1664349300,1664349600,1664349900,1664350200,1664350500,1664350800,1664351100,1664351400,1664351700,1664352000,1664352300,1664352600,1664352900,1664353200,1664353500,1664353800,1664354100,1664354400,1664354700,1664355000,1664355300,1664355600,1664355900,1664356200,1664356500,1664356800,1664357100,1664357400,1664357700,1664358000,1664358300,1664358600,1664358900,1664359200,1664359500,1664359800,1664360100,1664360400,1664360700,1664361000,1664361300,1664361600,1664361900,1664362200,1664362500,1664362800,1664363100,1664363400,1664363700,1664364000,1664364300,1664364600,1664364900,1664365200,1664365500,1664365800,1664366100,1664366400,1664366700,1664367000,1664367300,1664367600,1664367900,1664368200,1664368500,1664368800,1664369100,1664369400,1664369700,1664370000,1664370300,1664370600,1664370900,1664371200,1664371500,1664371800,1664372100,1664372400,1664372700,1664373000,1664373300,1664373600,1664373900,1664374200,1664374500,1664374800,1664375100,1664375400,1664375700,1664376000,1664376300,1664376600,1664376900,1664377200,1664377500,1664377800,1664378100,1664378400,1664378700,1664379000,1664379300,1664379600,1664379900,1664380200,1664380500,1664380800,1664381100,1664381400,1664381700,1664382000,1664382300,1664382600,1664382900,1664383200,1664383500,1664383800,1664384100,1664384400,1664384700,1664385000,1664385300,1664385600,1664385900,1664386200,1664386500,1664386800,1664387100,1664387400,1664387700,1664388000,1664388300,1664388600,1664388900,1664389200,1664389500,1664389800,1664390100,1664390400,1664390700,1664391000,1664391300,1664391600,1664391900,1664392200,1664392500,1664392800,1664393100,1664393400,1664393700,1664394000,1664394300,1664394600,1664394900,1664395200,1664395500,1664395800,1664396100,1664396400,1664396700,1664397000,1664397300,1664397600,1664397900,1664398200,1664398500,1664398800,1664399100,1664399400,1664399700,1664400000,1664400300,1664400600,1664400900,1664401200,1664401500,1664401800,1664402100,1664402400,1664402700,1664403000,1664403300,1664403600,1664403900,1664404200,1664404500,1664404800,1664405100,1664405400,1664405700,1664406000,1664406300,1664406600,1664406900,1664407200,1664407500,1664407800,1664408100,1664408400,1664408700,1664409000,1664409300,1664409600,1664409900,1664410200,1664410500,1664410800,1664411100,1664411400,1664411700,1664412000,1664412300,1664412600,1664412900,1664413200,1664413500,1664413800,1664414100,1664414400,1664414700,1664415000,1664415300,1664415600,1664415900,1664416200,1664416500],"Values":[9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.41,9.41,9.41,9.41,9.41,9.41,9.41,9.41,9.41,9.339,9.339,9.339,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.39,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.4,9.339,9.339,9.339,9.339,9.339,9.339,9.339,9.339,9.339,9.339,9.339,9.339,9.339,9.339,9.339,9.339,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.349,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.359,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.369,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.38,9.32,9.32,9.32,9.32,9.32,9.32,9.32,9.32,9.32,9.32,9.32]},{"Dimensions":[{"Name":"InstanceId","Value":"ins-n198q4gc"}],"Timestamps":[1664330100,1664330400,1664330700,1664331000,1664331300,1664331600,1664331900,1664332200,1664332500,1664332800,1664333100,1664333400,1664333700,1664334000,1664334300,1664334600,1664334900,1664335200,1664335500,1664335800,1664336100,1664336400,1664336700,1664337000,1664337300,1664337600,1664337900,1664338200,1664338500,1664338800,1664339100,1664339400,1664339700,1664340000,1664340300,1664340600,1664340900,1664341200,1664341500,1664341800,1664342100,1664342400,1664342700,1664343000,1664343300,1664343600,1664343900,1664344200,1664344500,1664344800,1664345100,1664345400,1664345700,1664346000,1664346300,1664346600,1664346900,1664347200,1664347500,1664347800,1664348100,1664348400,1664348700,1664349000,1664349300,1664349600,1664349900,1664350200,1664350500,1664350800,1664351100,1664351400,1664351700,1664352000,1664352300,1664352600,1664352900,1664353200,1664353500,1664353800,1664354100,1664354400,1664354700,1664355000,1664355300,1664355600,1664355900,1664356200,1664356500,1664356800,1664357100,1664357400,1664357700,1664358000,1664358300,1664358600,1664358900,1664359200,1664359500,1664359800,1664360100,1664360400,1664360700,1664361000,1664361300,1664361600,1664361900,1664362200,1664362500,1664362800,1664363100,1664363400,1664363700,1664364000,1664364300,1664364600,1664364900,1664365200,1664365500,1664365800,1664366100,1664366400,1664366700,1664367000,1664367300,1664367600,1664367900,1664368200,1664368500,1664368800,1664369100,1664369400,1664369700,1664370000,1664370300,1664370600,1664370900,1664371200,1664371500,1664371800,1664372100,1664372400,1664372700,1664373000,1664373300,1664373600,1664373900,1664374200,1664374500,1664374800,1664375100,1664375400,1664375700,1664376000,1664376300,1664376600,1664376900,1664377200,1664377500,1664377800,1664378100,1664378400,1664378700,1664379000,1664379300,1664379600,1664379900,1664380200,1664380500,1664380800,1664381100,1664381400,1664381700,1664382000,1664382300,1664382600,1664382900,1664383200,1664383500,1664383800,1664384100,1664384400,1664384700,1664385000,1664385300,1664385600,1664385900,1664386200,1664386500,1664386800,1664387100,1664387400,1664387700,1664388000,1664388300,1664388600,1664388900,1664389200,1664389500,1664389800,1664390100,1664390400,1664390700,1664391000,1664391300,1664391600,1664391900,1664392200,1664392500,1664392800,1664393100,1664393400,1664393700,1664394000,1664394300,1664394600,1664394900,1664395200,1664395500,1664395800,1664396100,1664396400,1664396700,1664397000,1664397300,1664397600,1664397900,1664398200,1664398500,1664398800,1664399100,1664399400,1664399700,1664400000,1664400300,1664400600,1664400900,1664401200,1664401500,1664401800,1664402100,1664402400,1664402700,1664403000,1664403300,1664403600,1664403900,1664404200,1664404500,1664404800,1664405100,1664405400,1664405700,1664406000,1664406300,1664406600,1664406900,1664407200,1664407500,1664407800,1664408100,1664408400,1664408700,1664409000,1664409300,1664409600,1664409900,1664410200,1664410500,1664410800,1664411100,1664411400,1664411700,1664412000,1664412300,1664412600,1664412900,1664413200,1664413500,1664413800,1664414100,1664414400,1664414700,1664415000,1664415300,1664415600,1664415900,1664416200,1664416500],"Values":[32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.69,32.69,32.674,32.674,32.674,32.674,32.674,32.674,32.674,32.674,32.674,32.674,32.674,32.674,32.676,32.676,32.676,32.676,32.676,32.676,32.676,32.676,32.676,32.678,32.678,32.678,32.678,32.678,32.678,32.678,32.678,32.678,32.678,32.678,32.678,32.678,32.678,32.678,32.678,32.678,32.678,32.68,32.68,32.68,32.68,32.68,32.68,32.68,32.68,32.68,32.68,32.68,32.68,32.68,32.68,32.68,32.68,32.68,32.68,32.682,32.682,32.682,32.682,32.682,32.682,32.682,32.682,32.682,32.682,32.682,32.682,32.682,32.682,32.682,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.69,32.69,32.69,32.69,32.69,32.69,32.69,32.69,32.69,32.69,32.69,32.69,32.69,32.69,32.69,32.69,32.692,32.692,32.692,32.692,32.692,32.692,32.692,32.692,32.692,32.692,32.692,32.692,32.692,32.692,32.692,32.692,32.694,33.065,32.694,32.694,32.694,32.694,32.694,32.694,32.694,32.694,32.694,32.694,32.694,32.696,32.696,32.696,32.696,32.698,32.7,32.7,32.7,32.7,32.7,32.7,32.7,32.7,32.7,32.7,32.7,32.7,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.702,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.684,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.686,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.688,32.69,32.69,32.69,32.69,32.69,32.69,32.69,32.69,32.69,32.69]}],"RequestId":"e8cfb32d-4409-4b67-a2d9-59a1cdb4aff3"}}' + headers: + Connection: + - keep-alive + Content-Length: + - '10245' + Content-Type: + - application/json + Date: + - Thu, 29 Sep 2022 01:59:43 GMT + Server: + - nginx + status: + code: 200 + message: OK +version: 1 diff --git a/tools/c7n_tencentcloud/tests/cassettes/test_tc_cvm/TestCvmAction.test_cvm_start.yaml b/tools/c7n_tencentcloud/tests/cassettes/test_tc_cvm/TestCvmAction.test_cvm_start.yaml index 10966520e2e..474b9a06f69 100644 --- a/tools/c7n_tencentcloud/tests/cassettes/test_tc_cvm/TestCvmAction.test_cvm_start.yaml +++ b/tools/c7n_tencentcloud/tests/cassettes/test_tc_cvm/TestCvmAction.test_cvm_start.yaml @@ -62,48 +62,6 @@ interactions: status: code: 200 message: OK -- request: - body: '{"InstanceIds": ["ins-00lycyy6"], "Offset": 20, "Limit": 20}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '60' - Content-Type: - - application/json - Host: - - cvm.ap-singapore.tencentcloudapi.com - User-Agent: - - python-requests/2.28.1 - X-TC-Action: - - DescribeInstances - X-TC-Region: - - ap-singapore - X-TC-Version: - - '2017-03-12' - method: POST - uri: https://cvm.ap-singapore.tencentcloudapi.com/ - response: - body: - string: '{"Response": {"TotalCount": 1, "InstanceSet": [], "RequestId": "578f9163-5fd9-4989-a6be-1a04bfa5a8ef"}}' - headers: - Connection: - - keep-alive - Content-Length: - - '103' - Content-Type: - - application/json - Date: - - Fri, 16 Sep 2022 03:22:06 GMT - Server: - - nginx - status: - code: 200 - message: OK - request: body: '{"InstanceIds": ["ins-00lycyy6"]}' headers: @@ -210,46 +168,3 @@ interactions: status: code: 200 message: OK -- request: - body: '{"InstanceIds": ["ins-00lycyy6"], "Offset": 20, "Limit": 20}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '60' - Content-Type: - - application/json - Host: - - cvm.ap-singapore.tencentcloudapi.com - User-Agent: - - python-requests/2.28.1 - X-TC-Action: - - DescribeInstances - X-TC-Region: - - ap-singapore - X-TC-Version: - - '2017-03-12' - method: POST - uri: https://cvm.ap-singapore.tencentcloudapi.com/ - response: - body: - string: '{"Response": {"TotalCount": 1, "InstanceSet": [], "RequestId": "0fe8473b-f363-47d0-94bb-621f89b1a89d"}}' - headers: - Connection: - - keep-alive - Content-Length: - - '103' - Content-Type: - - application/json - Date: - - Fri, 16 Sep 2022 03:22:18 GMT - Server: - - nginx - status: - code: 200 - message: OK -version: 1 diff --git a/tools/c7n_tencentcloud/tests/cassettes/test_tc_cvm/TestCvmAction.test_cvm_stop.yaml b/tools/c7n_tencentcloud/tests/cassettes/test_tc_cvm/TestCvmAction.test_cvm_stop.yaml index 8cc477a8160..94302476fc7 100644 --- a/tools/c7n_tencentcloud/tests/cassettes/test_tc_cvm/TestCvmAction.test_cvm_stop.yaml +++ b/tools/c7n_tencentcloud/tests/cassettes/test_tc_cvm/TestCvmAction.test_cvm_stop.yaml @@ -65,48 +65,6 @@ interactions: status: code: 200 message: OK -- request: - body: '{"InstanceIds": ["ins-00lycyy6"], "Offset": 20, "Limit": 20}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '60' - Content-Type: - - application/json - Host: - - cvm.ap-singapore.tencentcloudapi.com - User-Agent: - - python-requests/2.28.1 - X-TC-Action: - - DescribeInstances - X-TC-Region: - - ap-singapore - X-TC-Version: - - '2017-03-12' - method: POST - uri: https://cvm.ap-singapore.tencentcloudapi.com/ - response: - body: - string: '{"Response": {"TotalCount": 1, "InstanceSet": [], "RequestId": "c8abd2aa-0451-4c27-84de-277e4de4d2db"}}' - headers: - Connection: - - keep-alive - Content-Length: - - '103' - Content-Type: - - application/json - Date: - - Fri, 16 Sep 2022 08:33:15 GMT - Server: - - nginx - status: - code: 200 - message: OK - request: body: '{"InstanceIds": ["ins-00lycyy6"], "StopType": "SOFT", "StoppedMode": "STOP_CHARGING"}' headers: @@ -214,46 +172,3 @@ interactions: status: code: 200 message: OK -- request: - body: '{"InstanceIds": ["ins-00lycyy6"], "Offset": 20, "Limit": 20}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '60' - Content-Type: - - application/json - Host: - - cvm.ap-singapore.tencentcloudapi.com - User-Agent: - - python-requests/2.28.1 - X-TC-Action: - - DescribeInstances - X-TC-Region: - - ap-singapore - X-TC-Version: - - '2017-03-12' - method: POST - uri: https://cvm.ap-singapore.tencentcloudapi.com/ - response: - body: - string: '{"Response": {"TotalCount": 1, "InstanceSet": [], "RequestId": "052076dd-5d78-4df8-ad94-9212eb9392bc"}}' - headers: - Connection: - - keep-alive - Content-Length: - - '103' - Content-Type: - - application/json - Date: - - Fri, 16 Sep 2022 08:33:27 GMT - Server: - - nginx - status: - code: 200 - message: OK -version: 1 diff --git a/tools/c7n_tencentcloud/tests/cassettes/test_tc_cvm/TestCvmAction.test_cvm_terminate.yaml b/tools/c7n_tencentcloud/tests/cassettes/test_tc_cvm/TestCvmAction.test_cvm_terminate.yaml index 5f3ec81365a..f145f3b3650 100644 --- a/tools/c7n_tencentcloud/tests/cassettes/test_tc_cvm/TestCvmAction.test_cvm_terminate.yaml +++ b/tools/c7n_tencentcloud/tests/cassettes/test_tc_cvm/TestCvmAction.test_cvm_terminate.yaml @@ -60,48 +60,6 @@ interactions: status: code: 200 message: OK -- request: - body: '{"InstanceIds": ["ins-8ktxnl0g"], "Offset": 20, "Limit": 20}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '60' - Content-Type: - - application/json - Host: - - cvm.ap-singapore.tencentcloudapi.com - User-Agent: - - python-requests/2.28.1 - X-TC-Action: - - DescribeInstances - X-TC-Region: - - ap-singapore - X-TC-Version: - - '2017-03-12' - method: POST - uri: https://cvm.ap-singapore.tencentcloudapi.com/ - response: - body: - string: '{"Response": {"TotalCount": 1, "InstanceSet": [], "RequestId": "40c0162e-be05-4f9c-8067-a9bc7ec8281c"}}' - headers: - Connection: - - keep-alive - Content-Length: - - '103' - Content-Type: - - application/json - Date: - - Fri, 16 Sep 2022 03:27:41 GMT - Server: - - nginx - status: - code: 200 - message: OK - request: body: '{"InstanceIds": ["ins-8ktxnl0g"]}' headers: diff --git a/tools/c7n_tencentcloud/tests/cassettes/test_tc_tags/TestCvmTagAction.test_cvm_marked_op_stop.yaml b/tools/c7n_tencentcloud/tests/cassettes/test_tc_tags/TestCvmTagAction.test_cvm_marked_op_stop.yaml index bade1c1f61f..884952a81be 100644 --- a/tools/c7n_tencentcloud/tests/cassettes/test_tc_tags/TestCvmTagAction.test_cvm_marked_op_stop.yaml +++ b/tools/c7n_tencentcloud/tests/cassettes/test_tc_tags/TestCvmTagAction.test_cvm_marked_op_stop.yaml @@ -63,48 +63,6 @@ interactions: status: code: 200 message: OK -- request: - body: '{"InstanceIds": ["ins-00lycyy6"], "Offset": 20, "Limit": 20}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '60' - Content-Type: - - application/json - Host: - - cvm.ap-singapore.tencentcloudapi.com - User-Agent: - - python-requests/2.28.1 - X-TC-Action: - - DescribeInstances - X-TC-Region: - - ap-singapore - X-TC-Version: - - '2017-03-12' - method: POST - uri: https://cvm.ap-singapore.tencentcloudapi.com/ - response: - body: - string: '{"Response": {"TotalCount": 1, "InstanceSet": [], "RequestId": "5add7970-38b2-45ac-ad02-9fa9e4c34018"}}' - headers: - Connection: - - keep-alive - Content-Length: - - '103' - Content-Type: - - application/json - Date: - - Fri, 16 Sep 2022 03:59:45 GMT - Server: - - nginx - status: - code: 200 - message: OK - request: body: '{"InstanceIds": ["ins-00lycyy6"], "StopType": "SOFT", "StoppedMode": "STOP_CHARGING"}' headers: @@ -211,46 +169,3 @@ interactions: status: code: 200 message: OK -- request: - body: '{"InstanceIds": ["ins-00lycyy6"], "Offset": 20, "Limit": 20}' - headers: - Accept: - - '*/*' - Accept-Encoding: - - gzip, deflate - Connection: - - keep-alive - Content-Length: - - '60' - Content-Type: - - application/json - Host: - - cvm.ap-singapore.tencentcloudapi.com - User-Agent: - - python-requests/2.28.1 - X-TC-Action: - - DescribeInstances - X-TC-Region: - - ap-singapore - X-TC-Version: - - '2017-03-12' - method: POST - uri: https://cvm.ap-singapore.tencentcloudapi.com/ - response: - body: - string: '{"Response": {"TotalCount": 1, "InstanceSet": [], "RequestId": "e70aa5d5-f26c-4638-90b5-ed8a98c7937c"}}' - headers: - Connection: - - keep-alive - Content-Length: - - '103' - Content-Type: - - application/json - Date: - - Fri, 16 Sep 2022 03:59:52 GMT - Server: - - nginx - status: - code: 200 - message: OK -version: 1 diff --git a/tools/c7n_tencentcloud/tests/conftest.py b/tools/c7n_tencentcloud/tests/conftest.py index 80ed3481e9b..85fd359c130 100644 --- a/tools/c7n_tencentcloud/tests/conftest.py +++ b/tools/c7n_tencentcloud/tests/conftest.py @@ -7,6 +7,13 @@ from c7n_tencentcloud.client import Session +@pytest.fixture(autouse=True) +def credential_env_vars(monkeypatch): + monkeypatch.setenv("TENCENTCLOUD_SECRET_ID", "xyz") + monkeypatch.setenv("TENCENTCLOUD_SECRET_KEY", "abc123") + monkeypatch.setenv("TENCENTCLOUD_REGION", "na-ashburn") + + @pytest.fixture(scope="package") def vcr_config(): return { diff --git a/tools/c7n_tencentcloud/tests/test_filter_metrics.py b/tools/c7n_tencentcloud/tests/test_filter_metrics.py new file mode 100644 index 00000000000..e4ad27217e5 --- /dev/null +++ b/tools/c7n_tencentcloud/tests/test_filter_metrics.py @@ -0,0 +1,77 @@ +# Copyright The Cloud Custodian Authors. +# SPDX-License-Identifier: Apache-2.0 +from freezegun import freeze_time +import pytest +from tc_common import BaseTest +from c7n_tencentcloud.filters import MetricsFilter +from c7n_tencentcloud.query import QueryResourceManager + + +class TestFilterMetrics(BaseTest): + instance_ids = ["ins-dq1dmpgk", "ins-n198q4gc"] + + @pytest.mark.vcr + def test_average(self): + policy = self.load_policy( + { + "name": "filter-metrics-average", + "resource": "tencentcloud.cvm", + "query": [{ + "InstanceIds": self.instance_ids + }], + "filters": [{ + "type": "metrics", + "name": "CPUUsage", + "statistics": "Average", + "days": 3, + "op": "less-than", + "value": 1.5, + "missing-value": 0, + "period": 3600 + }] + } + ) + resources = policy.run() + assert len(resources) == 2 + + @pytest.mark.vcr + def test_max(self): + policy = self.load_policy( + { + "name": "filter-metrics-max", + "resource": "tencentcloud.cvm", + "query": [{ + "InstanceIds": self.instance_ids + }], + "filters": [{ + "type": "metrics", + "name": "CvmDiskUsage", + "statistics": "Maximum", + "days": 1, + "op": "less-than", + "value": 20, + "missing-value": 0, + "period": 300 + }] + } + ) + resources = policy.run() + assert len(resources) == 1 + + @freeze_time("2022-08-01 00:00:00") + def test_time_window(self, ctx): + class Resource(QueryResourceManager): + resource_type = None + + filter_config = { + "type": "metrics", + "name": "time_window_test", + "namespace": "QCE/CVM", + "statistics": "Maximum", + "value": 0, + "days": 1, + } + metrics_filter = MetricsFilter(filter_config, Resource(ctx, {})) + start_time, end_time = metrics_filter.get_metric_window() + assert start_time == "2022-07-31T00:00:00+00:00" + assert end_time == "2022-08-01T00:00:00+00:00" diff --git a/tools/c7n_tencentcloud/tests/test_tc_provider.py b/tools/c7n_tencentcloud/tests/test_tc_provider.py index b5fa50356e2..d9ebf7c69a7 100644 --- a/tools/c7n_tencentcloud/tests/test_tc_provider.py +++ b/tools/c7n_tencentcloud/tests/test_tc_provider.py @@ -1,12 +1,11 @@ # Copyright The Cloud Custodian Authors. # SPDX-License-Identifier: Apache-2.0 -import os import pytest from c7n.config import Config from c7n_tencentcloud.client import Session -from c7n_tencentcloud.provider import TencentCloud, DEFAULT_REGION +from c7n_tencentcloud.provider import TencentCloud from tencentcloud.common.exception.tencent_cloud_sdk_exception import TencentCloudSDKException @@ -31,7 +30,8 @@ def test_get_session_factory(tc_provider): test_cases = [ - ([], os.environ.get('TENCENTCLOUD_REGION', DEFAULT_REGION)), + # Default region matches the TENCENTCLOUD_REGION configured in conftest.py + ([], "na-ashburn"), (["ap-shanghai"], "ap-shanghai"), (["ap-shanghai", "others"], "ap-shanghai") ] diff --git a/tools/c7n_terraform/poetry.lock b/tools/c7n_terraform/poetry.lock index b6ae835e725..5fc6660ad2c 100644 --- a/tools/c7n_terraform/poetry.lock +++ b/tools/c7n_terraform/poetry.lock @@ -21,21 +21,21 @@ optional = false python-versions = ">=3.5" [package.extras] -dev = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "furo", "sphinx", "sphinx-notfound-page", "pre-commit", "cloudpickle"] -docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] -tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] -tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "cloudpickle"] +dev = ["cloudpickle", "coverage[toml] (>=5.0.2)", "furo", "hypothesis", "mypy (>=0.900,!=0.940)", "pre-commit", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "sphinx", "sphinx-notfound-page", "zope.interface"] +docs = ["furo", "sphinx", "sphinx-notfound-page", "zope.interface"] +tests = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "zope.interface"] +tests_no_zope = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins"] [[package]] name = "boto3" -version = "1.24.77" +version = "1.24.87" description = "The AWS SDK for Python" category = "dev" optional = false python-versions = ">= 3.7" [package.dependencies] -botocore = ">=1.27.77,<1.28.0" +botocore = ">=1.27.87,<1.28.0" jmespath = ">=0.7.1,<2.0.0" s3transfer = ">=0.6.0,<0.7.0" @@ -44,7 +44,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "botocore" -version = "1.27.77" +version = "1.27.87" description = "Low-level, data-driven core of boto 3." category = "dev" optional = false @@ -111,7 +111,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" [[package]] name = "importlib-metadata" -version = "4.12.0" +version = "4.13.0" description = "Read metadata from Python packages" category = "main" optional = false @@ -122,9 +122,9 @@ typing-extensions = {version = ">=3.6.4", markers = "python_version < \"3.8\""} zipp = ">=0.5" [package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)"] perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.3)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] +testing = ["flake8 (<5)", "flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] [[package]] name = "importlib-resources" @@ -138,8 +138,8 @@ python-versions = ">=3.7" zipp = {version = ">=3.1.0", markers = "python_version < \"3.10\""} [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [[package]] name = "iniconfig" @@ -201,7 +201,7 @@ python-versions = ">=3.6" pyparsing = ">=2.0.2,<3.0.5 || >3.0.5" [[package]] -name = "pkgutil-resolve-name" +name = "pkgutil_resolve_name" version = "1.3.10" description = "Resolve a name to an object." category = "dev" @@ -240,7 +240,7 @@ optional = false python-versions = ">=3.6.8" [package.extras] -diagrams = ["railroad-diagrams", "jinja2"] +diagrams = ["jinja2", "railroad-diagrams"] [[package]] name = "pyrsistent" @@ -294,7 +294,7 @@ python-versions = ">=3.6.0" lark-parser = ">=0.10.0,<0.11.0" [[package]] -name = "pyyaml" +name = "PyYAML" version = "6.0" description = "YAML parser and emitter for Python" category = "dev" @@ -359,8 +359,8 @@ optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*, <4" [package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "urllib3-secure-extra", "ipaddress"] +brotli = ["brotli (>=1.0.9)", "brotlicffi (>=0.8.0)", "brotlipy (>=0.6.0)"] +secure = ["certifi", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "ipaddress", "pyOpenSSL (>=0.14)", "urllib3-secure-extra"] socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] [[package]] @@ -372,8 +372,8 @@ optional = false python-versions = ">=3.7" [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "func-timeout", "jaraco.itertools", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["func-timeout", "jaraco.itertools", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [metadata] lock-version = "1.1" @@ -390,12 +390,12 @@ attrs = [ {file = "attrs-22.1.0.tar.gz", hash = "sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6"}, ] boto3 = [ - {file = "boto3-1.24.77-py3-none-any.whl", hash = "sha256:fc16e50263c24631d5fe75464e76f3a1b454b4c0015c864948a61691f9702a6e"}, - {file = "boto3-1.24.77.tar.gz", hash = "sha256:16646de3303779d6dc9c192d8a863095244de81d2e0b94f50692fbde767c6f1b"}, + {file = "boto3-1.24.87-py3-none-any.whl", hash = "sha256:bcc579e801774cb2c7dda87ff985feda1ae7e10591d11ef37526363139138bd4"}, + {file = "boto3-1.24.87.tar.gz", hash = "sha256:3dd7ed74d1d29dd8094a078be86ed61c45de6638fe18856f7a1ff9282b4d929e"}, ] botocore = [ - {file = "botocore-1.27.77-py3-none-any.whl", hash = "sha256:d88509ed291b95525205cc06ca87b54d077aae996827039f5e32375949c5aaf7"}, - {file = "botocore-1.27.77.tar.gz", hash = "sha256:77a43e970d0762080b4b79a7e00ea572ef2ae7a9f578c3c8e7f0a344ee4b4e6d"}, + {file = "botocore-1.27.87-py3-none-any.whl", hash = "sha256:c4cbd22056ace4c7aa99e62e8ae629865ab80cc8bbf7c6d68ccf0f768f0034b6"}, + {file = "botocore-1.27.87.tar.gz", hash = "sha256:216de9751116d0d1cc3901e26d95a5c9a30ecb6973ae6147af1cf504858d845a"}, ] c7n = [] click = [ @@ -411,8 +411,8 @@ docutils = [ {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, ] importlib-metadata = [ - {file = "importlib_metadata-4.12.0-py3-none-any.whl", hash = "sha256:7401a975809ea1fdc658c3aa4f78cc2195a0e019c5cbc4c06122884e9ae80c23"}, - {file = "importlib_metadata-4.12.0.tar.gz", hash = "sha256:637245b8bab2b6502fcbc752cc4b7a6f6243bb02b31c5c26156ad103d3d45670"}, + {file = "importlib_metadata-4.13.0-py3-none-any.whl", hash = "sha256:8a8a81bcf996e74fee46f0d16bd3eaa382a7eb20fd82445c3ad11f4090334116"}, + {file = "importlib_metadata-4.13.0.tar.gz", hash = "sha256:dd0173e8f150d6815e098fd354f6414b0f079af4644ddfe90c71e2fc6174346d"}, ] importlib-resources = [ {file = "importlib_resources-5.9.0-py3-none-any.whl", hash = "sha256:f78a8df21a79bcc30cfd400bdc38f314333de7c0fb619763f6b9dabab8268bb7"}, @@ -437,7 +437,7 @@ packaging = [ {file = "packaging-21.3-py3-none-any.whl", hash = "sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522"}, {file = "packaging-21.3.tar.gz", hash = "sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb"}, ] -pkgutil-resolve-name = [ +pkgutil_resolve_name = [ {file = "pkgutil_resolve_name-1.3.10-py3-none-any.whl", hash = "sha256:ca27cc078d25c5ad71a9de0a7a330146c4e014c2462d9af19c6b828280649c5e"}, {file = "pkgutil_resolve_name-1.3.10.tar.gz", hash = "sha256:357d6c9e6a755653cfd78893817c0853af365dd51ec97f3d358a819373bbd174"}, ] @@ -487,7 +487,7 @@ python-dateutil = [ python-hcl2 = [ {file = "python-hcl2-2.0.3.tar.gz", hash = "sha256:62bfe6a152e794700abd125bfb5c53913af8c8bc98eeef37bd30f87e3f19bfc2"}, ] -pyyaml = [ +PyYAML = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, @@ -495,6 +495,13 @@ pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782"}, + {file = "PyYAML-6.0-cp311-cp311-win32.whl", hash = "sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7"}, + {file = "PyYAML-6.0-cp311-cp311-win_amd64.whl", hash = "sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf"}, {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, @@ -532,7 +539,6 @@ six = [ ] tabulate = [ {file = "tabulate-0.8.10-py3-none-any.whl", hash = "sha256:0ba055423dbaa164b9e456abe7920c5e8ed33fcc16f6d1b2f2d152c8e1e8b4fc"}, - {file = "tabulate-0.8.10-py3.8.egg", hash = "sha256:436f1c768b424654fce8597290d2764def1eea6a77cfa5c33be00b1bc0f4f63d"}, {file = "tabulate-0.8.10.tar.gz", hash = "sha256:6c57f3f3dd7ac2782770155f3adb2db0b1a269637e42f27599925e64b114f519"}, ] tomli = [ diff --git a/tools/c7n_terraform/requirements.txt b/tools/c7n_terraform/requirements.txt index 2be96024259..4f81cd8883d 100644 --- a/tools/c7n_terraform/requirements.txt +++ b/tools/c7n_terraform/requirements.txt @@ -1,7 +1,7 @@ -click==8.1.3; python_version >= "3.7" -colorama==0.4.5; python_version >= "3.7" and python_full_version < "3.0.0" and platform_system == "Windows" or platform_system == "Windows" and python_version >= "3.7" and python_full_version >= "3.5.0" -importlib-metadata==4.12.0; python_version < "3.8" and python_version >= "3.7" -lark-parser==0.10.1; python_full_version >= "3.6.0" -python-hcl2==2.0.3; python_full_version >= "3.6.0" -typing-extensions==4.3.0; python_version < "3.8" and python_version >= "3.7" -zipp==3.8.1; python_version < "3.8" and python_version >= "3.7" +click==8.1.3 ; python_version >= "3.7" and python_version < "4.0" +colorama==0.4.5 ; python_version >= "3.7" and python_version < "4.0" and platform_system == "Windows" +importlib-metadata==4.13.0 ; python_version >= "3.7" and python_version < "3.8" +lark-parser==0.10.1 ; python_version >= "3.7" and python_version < "4.0" +python-hcl2==2.0.3 ; python_version >= "3.7" and python_version < "4.0" +typing-extensions==4.3.0 ; python_version >= "3.7" and python_version < "3.8" +zipp==3.8.1 ; python_version >= "3.7" and python_version < "3.8" diff --git a/tools/c7n_terraform/setup.py b/tools/c7n_terraform/setup.py index ed0c31fa9b8..d5c31166533 100644 --- a/tools/c7n_terraform/setup.py +++ b/tools/c7n_terraform/setup.py @@ -12,16 +12,16 @@ install_requires = \ ['argcomplete (>=2.0.0,<3.0.0)', 'attrs (>=22.1.0,<23.0.0)', - 'boto3 (>=1.24.77,<2.0.0)', - 'botocore (>=1.27.77,<2.0.0)', + 'boto3 (>=1.24.87,<2.0.0)', + 'botocore (>=1.27.87,<2.0.0)', 'c7n (>=0.9.19,<0.10.0)', 'click>=8.0,<9.0', 'docutils (>=0.17.1,<0.18.0)', - 'importlib-metadata (>=4.12.0,<5.0.0)', + 'importlib-metadata (>=4.13.0,<5.0.0)', 'importlib-resources (>=5.9.0,<6.0.0)', 'jmespath (>=1.0.1,<2.0.0)', 'jsonschema (>=4.16.0,<5.0.0)', - 'pkgutil-resolve-name (>=1.3.10,<2.0.0)', + 'pkgutil_resolve_name (>=1.3.10,<2.0.0)', 'pyrsistent (>=0.18.1,<0.19.0)', 'python-dateutil (>=2.8.2,<3.0.0)', 'python-hcl2>=2.0,<3.0', @@ -46,10 +46,13 @@ 'long_description': "\n# Cloud Custodian Terraform Provider\n\nCustodian's terraform provider enables writing and evaluating\ncustodian policies against Terraform IaaC modules.\n\n\ntldr: we want to enable writing custodian policies against IaaC assets (terraform, cfn, etc) directly in devops/ci pipelines.\n\n# Purpose\n\nThe primary purpose of this is to integrate with ci/cd pipelines to\nevaluate compliance and governance early in the deployment\nlifecycle. Custodian cloud providers provide for realtime detection\nand remediation as a detective control against infrastructure already\ndeployed in the environment regardless of how it was provisioned. As\nan initial target, the terraform provider is designed to complement\nthat with preventive enforcement earlier in the\nlifecycle. ie. enabling a shift-left to policy enforcement.\n\n\n# Pipeline CLI\n\nIn looking at expanding out to shift-left pipeline use cases, one\nthing that becomes clearer is that custodian's default cli ux isn't\nperhaps the best fit for the target audience. When we're operating\nagainst cloud resources we have to deal with cardinalities in the\nthousands to millions. When we're operating in the pipelines we're\ntypically dealing with resource cardinalities in the 10s. Additionally\nthere is a goal expectation of having rich output that correlates to\nthe ci tooling (github annotations, etc) or pinpointing the issue for\na developer, as well as color'd output and other niceties. we could\nincorporate that as a new subcommand into the main custodian cli\n(dependent on presence of iaac providers installed), or have a\ndedicated subcommand associated.\n\nThe other main deficiency with the cli is that we're not able to pass\ndirectly the iaac files as data sets we want to consider. Typically\npolicies have expressed this as query parameterization within the\npolicy as being able to specify the exact target set. But the use case\nhere is more typically command line driven with specification of both\npolicy files and target IaaC files, as well as other possible vcs\nintegrations (policystream style wrt delta files) or ci integrations.\n\n# Resources\n\nwrt to the iaac provider we can either operate loosely typed or strongly typed. with strong typing we can spec out exact attributes and potentially do additional possibly validation wrt to user specified attributes, but it requires keeping an up to date store of all iaac provider assets, which could be both fairly large and rapidly changing (terraform has over 150 providers all release independently). for now, I think it would be good to keep to loose typing on resources. .. and perhaps document provider addressable resource attributes as part of documentation.\n\nLoose typing would enable working out of the box with extant providers, but policy authors would have to consult reference docs for their respective providers on available attributes or even provider resource type existence. From a custodian perspective we would use a common resource implementation across provider resource types.\n\n# Examples\n\n```yaml\n- resource: terraform.aws_dynamodb_table\n name: ensure encryption\n filters:\n server_side_encryption.enabled: true\n kms_key_arn: key_alias\n```\n\n\n\n# \n\n custodian run terraform.yml\n \n custodian report --format=\n \n# dedicated cli\n\n\n custodian run-source terraform.yml\n", 'long_description_content_type': 'text/markdown', 'author': 'Cloud Custodian Project', - 'author_email': None, - 'maintainer': None, - 'maintainer_email': None, - 'url': 'https://cloudcustodian.io', + 'author_email': 'cloud-custodian@googlegroups.com', + 'project_urls': { + 'Homepage': 'https://cloudcustodian.io', + 'Documentation': 'https://cloudcustodian.io/docs/', + 'Source': 'https://github.com/cloud-custodian/cloud-custodian', + 'Issue Tracker': 'https://github.com/cloud-custodian/cloud-custodian/issues', + }, 'packages': packages, 'package_data': package_data, 'install_requires': install_requires, diff --git a/tools/c7n_trailcreator/poetry.lock b/tools/c7n_trailcreator/poetry.lock index 7ad5709d93e..36a053fdbab 100644 --- a/tools/c7n_trailcreator/poetry.lock +++ b/tools/c7n_trailcreator/poetry.lock @@ -21,21 +21,21 @@ optional = false python-versions = ">=3.5" [package.extras] -dev = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "furo", "sphinx", "sphinx-notfound-page", "pre-commit", "cloudpickle"] -docs = ["furo", "sphinx", "zope.interface", "sphinx-notfound-page"] -tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "zope.interface", "cloudpickle"] -tests_no_zope = ["coverage[toml] (>=5.0.2)", "hypothesis", "pympler", "pytest (>=4.3.0)", "mypy (>=0.900,!=0.940)", "pytest-mypy-plugins", "cloudpickle"] +dev = ["cloudpickle", "coverage[toml] (>=5.0.2)", "furo", "hypothesis", "mypy (>=0.900,!=0.940)", "pre-commit", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "sphinx", "sphinx-notfound-page", "zope.interface"] +docs = ["furo", "sphinx", "sphinx-notfound-page", "zope.interface"] +tests = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins", "zope.interface"] +tests_no_zope = ["cloudpickle", "coverage[toml] (>=5.0.2)", "hypothesis", "mypy (>=0.900,!=0.940)", "pympler", "pytest (>=4.3.0)", "pytest-mypy-plugins"] [[package]] name = "boto3" -version = "1.24.77" +version = "1.24.87" description = "The AWS SDK for Python" category = "dev" optional = false python-versions = ">= 3.7" [package.dependencies] -botocore = ">=1.27.77,<1.28.0" +botocore = ">=1.27.87,<1.28.0" jmespath = ">=0.7.1,<2.0.0" s3transfer = ">=0.6.0,<0.7.0" @@ -44,7 +44,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "botocore" -version = "1.27.77" +version = "1.27.87" description = "Low-level, data-driven core of boto 3." category = "dev" optional = false @@ -127,7 +127,7 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" [[package]] name = "importlib-metadata" -version = "4.12.0" +version = "4.13.0" description = "Read metadata from Python packages" category = "main" optional = false @@ -138,9 +138,9 @@ typing-extensions = {version = ">=3.6.4", markers = "python_version < \"3.8\""} zipp = ">=0.5" [package.extras] -docs = ["sphinx", "jaraco.packaging (>=9)", "rst.linker (>=1.9)"] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx (>=3.5)"] perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "pytest-cov", "pytest-enabler (>=1.3)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] +testing = ["flake8 (<5)", "flufl.flake8", "importlib-resources (>=1.3)", "packaging", "pyfakefs", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf (>=0.9.2)"] [[package]] name = "importlib-resources" @@ -154,8 +154,8 @@ python-versions = ">=3.7" zipp = {version = ">=3.1.0", markers = "python_version < \"3.10\""} [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [[package]] name = "jmespath" @@ -186,7 +186,7 @@ format = ["fqdn", "idna", "isoduration", "jsonpointer (>1.13)", "rfc3339-validat format-nongpl = ["fqdn", "idna", "isoduration", "jsonpointer (>1.13)", "rfc3339-validator", "rfc3986-validator (>0.1.0)", "uri-template", "webcolors (>=1.11)"] [[package]] -name = "pkgutil-resolve-name" +name = "pkgutil_resolve_name" version = "1.3.10" description = "Resolve a name to an object." category = "dev" @@ -213,7 +213,7 @@ python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,>=2.7" six = ">=1.5" [[package]] -name = "pyyaml" +name = "PyYAML" version = "6.0" description = "YAML parser and emitter for Python" category = "dev" @@ -270,8 +270,8 @@ optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*, <4" [package.extras] -brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] -secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "urllib3-secure-extra", "ipaddress"] +brotli = ["brotli (>=1.0.9)", "brotlicffi (>=0.8.0)", "brotlipy (>=0.6.0)"] +secure = ["certifi", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "ipaddress", "pyOpenSSL (>=0.14)", "urllib3-secure-extra"] socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] [[package]] @@ -283,8 +283,8 @@ optional = false python-versions = ">=3.7" [package.extras] -testing = ["pytest-mypy (>=0.9.1)", "pytest-black (>=0.3.7)", "func-timeout", "jaraco.itertools", "pytest-enabler (>=1.3)", "pytest-cov", "pytest-flake8", "pytest-checkdocs (>=2.4)", "pytest (>=6)"] -docs = ["jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "jaraco.packaging (>=9)", "sphinx"] +docs = ["jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "rst.linker (>=1.9)", "sphinx"] +testing = ["func-timeout", "jaraco.itertools", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)"] [metadata] lock-version = "1.1" @@ -301,12 +301,12 @@ attrs = [ {file = "attrs-22.1.0.tar.gz", hash = "sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6"}, ] boto3 = [ - {file = "boto3-1.24.77-py3-none-any.whl", hash = "sha256:fc16e50263c24631d5fe75464e76f3a1b454b4c0015c864948a61691f9702a6e"}, - {file = "boto3-1.24.77.tar.gz", hash = "sha256:16646de3303779d6dc9c192d8a863095244de81d2e0b94f50692fbde767c6f1b"}, + {file = "boto3-1.24.87-py3-none-any.whl", hash = "sha256:bcc579e801774cb2c7dda87ff985feda1ae7e10591d11ef37526363139138bd4"}, + {file = "boto3-1.24.87.tar.gz", hash = "sha256:3dd7ed74d1d29dd8094a078be86ed61c45de6638fe18856f7a1ff9282b4d929e"}, ] botocore = [ - {file = "botocore-1.27.77-py3-none-any.whl", hash = "sha256:d88509ed291b95525205cc06ca87b54d077aae996827039f5e32375949c5aaf7"}, - {file = "botocore-1.27.77.tar.gz", hash = "sha256:77a43e970d0762080b4b79a7e00ea572ef2ae7a9f578c3c8e7f0a344ee4b4e6d"}, + {file = "botocore-1.27.87-py3-none-any.whl", hash = "sha256:c4cbd22056ace4c7aa99e62e8ae629865ab80cc8bbf7c6d68ccf0f768f0034b6"}, + {file = "botocore-1.27.87.tar.gz", hash = "sha256:216de9751116d0d1cc3901e26d95a5c9a30ecb6973ae6147af1cf504858d845a"}, ] c7n = [] c7n-org = [] @@ -323,8 +323,8 @@ docutils = [ {file = "docutils-0.17.1.tar.gz", hash = "sha256:686577d2e4c32380bb50cbb22f575ed742d58168cee37e99117a854bcd88f125"}, ] importlib-metadata = [ - {file = "importlib_metadata-4.12.0-py3-none-any.whl", hash = "sha256:7401a975809ea1fdc658c3aa4f78cc2195a0e019c5cbc4c06122884e9ae80c23"}, - {file = "importlib_metadata-4.12.0.tar.gz", hash = "sha256:637245b8bab2b6502fcbc752cc4b7a6f6243bb02b31c5c26156ad103d3d45670"}, + {file = "importlib_metadata-4.13.0-py3-none-any.whl", hash = "sha256:8a8a81bcf996e74fee46f0d16bd3eaa382a7eb20fd82445c3ad11f4090334116"}, + {file = "importlib_metadata-4.13.0.tar.gz", hash = "sha256:dd0173e8f150d6815e098fd354f6414b0f079af4644ddfe90c71e2fc6174346d"}, ] importlib-resources = [ {file = "importlib_resources-5.9.0-py3-none-any.whl", hash = "sha256:f78a8df21a79bcc30cfd400bdc38f314333de7c0fb619763f6b9dabab8268bb7"}, @@ -338,7 +338,7 @@ jsonschema = [ {file = "jsonschema-4.16.0-py3-none-any.whl", hash = "sha256:9e74b8f9738d6a946d70705dc692b74b5429cd0960d58e79ffecfc43b2221eb9"}, {file = "jsonschema-4.16.0.tar.gz", hash = "sha256:165059f076eff6971bae5b742fc029a7b4ef3f9bcf04c14e4776a7605de14b23"}, ] -pkgutil-resolve-name = [ +pkgutil_resolve_name = [ {file = "pkgutil_resolve_name-1.3.10-py3-none-any.whl", hash = "sha256:ca27cc078d25c5ad71a9de0a7a330146c4e014c2462d9af19c6b828280649c5e"}, {file = "pkgutil_resolve_name-1.3.10.tar.gz", hash = "sha256:357d6c9e6a755653cfd78893817c0853af365dd51ec97f3d358a819373bbd174"}, ] @@ -369,7 +369,7 @@ python-dateutil = [ {file = "python-dateutil-2.8.2.tar.gz", hash = "sha256:0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86"}, {file = "python_dateutil-2.8.2-py2.py3-none-any.whl", hash = "sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9"}, ] -pyyaml = [ +PyYAML = [ {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, @@ -377,6 +377,13 @@ pyyaml = [ {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782"}, + {file = "PyYAML-6.0-cp311-cp311-win32.whl", hash = "sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7"}, + {file = "PyYAML-6.0-cp311-cp311-win_amd64.whl", hash = "sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf"}, {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, @@ -414,7 +421,6 @@ six = [ ] tabulate = [ {file = "tabulate-0.8.10-py3-none-any.whl", hash = "sha256:0ba055423dbaa164b9e456abe7920c5e8ed33fcc16f6d1b2f2d152c8e1e8b4fc"}, - {file = "tabulate-0.8.10-py3.8.egg", hash = "sha256:436f1c768b424654fce8597290d2764def1eea6a77cfa5c33be00b1bc0f4f63d"}, {file = "tabulate-0.8.10.tar.gz", hash = "sha256:6c57f3f3dd7ac2782770155f3adb2db0b1a269637e42f27599925e64b114f519"}, ] typing-extensions = [ diff --git a/tools/c7n_trailcreator/requirements.txt b/tools/c7n_trailcreator/requirements.txt index 5c3125c119c..4b53288a517 100644 --- a/tools/c7n_trailcreator/requirements.txt +++ b/tools/c7n_trailcreator/requirements.txt @@ -1,5 +1,5 @@ -click==8.1.3; python_version >= "3.7" -colorama==0.4.5; python_version >= "3.7" and python_full_version < "3.0.0" and platform_system == "Windows" or platform_system == "Windows" and python_version >= "3.7" and python_full_version >= "3.5.0" -importlib-metadata==4.12.0; python_version < "3.8" and python_version >= "3.7" -typing-extensions==4.3.0; python_version < "3.8" and python_version >= "3.7" -zipp==3.8.1; python_version < "3.8" and python_version >= "3.7" +click==8.1.3 ; python_version >= "3.7" and python_version < "4.0" +colorama==0.4.5 ; python_version >= "3.7" and python_version < "4.0" and platform_system == "Windows" +importlib-metadata==4.13.0 ; python_version >= "3.7" and python_version < "3.8" +typing-extensions==4.3.0 ; python_version >= "3.7" and python_version < "3.8" +zipp==3.8.1 ; python_version >= "3.7" and python_version < "3.8" diff --git a/tools/c7n_trailcreator/setup.py b/tools/c7n_trailcreator/setup.py index 2fa5546bc68..9f7e226f336 100644 --- a/tools/c7n_trailcreator/setup.py +++ b/tools/c7n_trailcreator/setup.py @@ -12,19 +12,19 @@ install_requires = \ ['argcomplete (>=2.0.0,<3.0.0)', 'attrs (>=22.1.0,<23.0.0)', - 'boto3 (>=1.24.77,<2.0.0)', - 'botocore (>=1.27.77,<2.0.0)', + 'boto3 (>=1.24.87,<2.0.0)', + 'botocore (>=1.27.87,<2.0.0)', 'c7n (>=0.9.19,<0.10.0)', 'c7n-org (>=0.6.18,<0.7.0)', 'click (>=8.1.3,<9.0.0)', 'click>=8.0,<9.0', 'colorama (>=0.4.5,<0.5.0)', 'docutils (>=0.17.1,<0.18.0)', - 'importlib-metadata (>=4.12.0,<5.0.0)', + 'importlib-metadata (>=4.13.0,<5.0.0)', 'importlib-resources (>=5.9.0,<6.0.0)', 'jmespath (>=1.0.1,<2.0.0)', 'jsonschema (>=4.16.0,<5.0.0)', - 'pkgutil-resolve-name (>=1.3.10,<2.0.0)', + 'pkgutil_resolve_name (>=1.3.10,<2.0.0)', 'pyrsistent (>=0.18.1,<0.19.0)', 'python-dateutil (>=2.8.2,<3.0.0)', 'pyyaml (>=6.0,<7.0)', @@ -51,10 +51,13 @@ 'long_description': '# c7n-trailcreator: Retroactive Resource Creator Tagging\n\nThis script will process cloudtrail records to create a sqlite db of\nresources and their creators, and then use that sqlitedb to tag\nthe resources with their creator\'s name.\n\nIn processing cloudtrail it can use either Athena or S3 Select. A\nconfig file of the events and resources of interest is required.\n\n## Install\n\n```shell\n$ pip install c7n_trailcreator\n\n$ c7n-trailcreator --help\n```\n\n## Config File\n\nThe config file format here is similiar to what custodian requires\nfor lambda policies on cloudtrail api events as an event selector.\n\nFirst for each resource, the custodian resource-type is required\nto be specified, and then for each event, we need to know the\nname of the service, the event name, and a jmespath expression\nto get the resource ids.\n\nHere\'s a a few examples, covering iam-user, iam-role, and and an s3 bucket.\n\n\n```json\n{\n "resources": [\n {\n "resource": "iam-role",\n "events": [\n {\n "event": "CreateRole",\n "ids": "requestParameters.roleName",\n "service": "iam.amazonaws.com"\n }\n ]\n },\n {\n "resource": "s3",\n "events": [\n {\n "ids": "requestParameters.bucketName",\n "event": "CreateBucket",\n "service": "s3.amazonaws.com"\n }\n ]\n },\n {\n "resource": "iam-user",\n "events": [\n {\n "event": "CreateUser",\n "ids": "requestParameters.userName",\n "service": "iam.amazonaws.com"\n }\n ]\n }]\n}\n```\n\n## Athena Usage\n\nTrail creators supports loading data from s3 using s3 select or from cloudtrail s3 using athena.\n\nNote you\'ll have to pre-created the athena table for cloudtrail previously per\nhttps://docs.aws.amazon.com/athena/latest/ug/cloudtrail-logs.html\n\nLet\'s use the example config file to load up data for all the roles, buckets, and users created in 2019\n\n```\nc7n-trailcreator load-athena \\\n --region us-east-1 \\\n\t--resource-map resource_map.json \\\n\t--table cloudtrail_logs_custodian_skunk_trails \\\n\t--db "creators.db" \\\n\t--year 2019\n```\n\nBy default we\'ll use the default s3 athena output used by the console,\nand the default db and primary workgroup, you can pass all of these in\non the cli to be more explicit.\n\nYou can also specify to just process a month with `--month 2019/11` or\nan individual day with `--day 2019/02/01`\n\n```\nINFO:c7n_trailowner:Athena query:569712dc-d1e9-4474-b86f-6579c53b5b46\nINFO:c7n_trailowner:Polling athena query progress scanned:489.24 Mb qexec:28.62s\nINFO:c7n_trailowner:Polling athena query progress scanned:1.29 Gb qexec:88.96s\nINFO:c7n_trailowner:Polling athena query progress scanned:2.17 Gb qexec:141.16s\nINFO:c7n_trailowner:processing athena result page 78 records\nINFO:c7n_trailowner:Athena Processed 78 records\n```\n\nNote you can reprocess a completed query\'s results, by passing in `--query-id` on the cli.\n\n## Tagging\n\nIt supports this across all the resources that custodian supports.\n\n```\n$ c7n-trailcreator tag \\\n\t--db creators.db \\\n\t--creator-tag Owner \\\n\t--region us-east-1\nINFO:c7n_trailowner:account:644160558196 region:us-east-1 tag 13 iam-role resources users:5 population:97 not-found:84 records:124\nINFO:c7n_trailowner:account:644160558196 region:us-east-1 tag 5 iam-user resources users:4 population:6 not-found:1 records:18\nINFO:c7n_trailowner:account:644160558196 region:us-east-1 tag 9 s3 resources users:4 population:14 not-found:5 records:20\nINFO:c7n_trailowner:auto tag summary account:644160558196 region:us-east-1\n iam-role-not-found: 84\n iam-role: 13\n iam-user-not-found: 1\n iam-user: 5\n s3-not-found: 5\n s3: 9\nINFO:c7n_trailowner:Total resources tagged: 27\n```\n\nlet\'s break down one of these log messages\n\n```\nINFO:c7n_trailowner:account:644160558196 region:us-east-1 tag 13 iam-role resources users:5 population:97 not-found:84 records:124\n```\n\n- records: the count of database create events we have for this resource type.\n- users: the number of unique users for whom we have create events.\n- not-found: the number of resources for whom we do not have create events, ie created before or after our trail analysis period.\n- population: the total number of resources in the account region.\n\n## Multi Account / Multi Region\n\nc7n-trailcreator supports executing across multiple accounts and regions when tagging\nusing the same file format that c7n-org uses to denote accounts. See `tag-org` subcommand.\n\n', 'long_description_content_type': 'text/markdown', 'author': 'Cloud Custodian Project', - 'author_email': None, - 'maintainer': None, - 'maintainer_email': None, - 'url': 'https://cloudcustodian.io', + 'author_email': 'cloud-custodian@googlegroups.com', + 'project_urls': { + 'Homepage': 'https://cloudcustodian.io', + 'Documentation': 'https://cloudcustodian.io/docs/', + 'Source': 'https://github.com/cloud-custodian/cloud-custodian', + 'Issue Tracker': 'https://github.com/cloud-custodian/cloud-custodian/issues', + }, 'packages': packages, 'package_data': package_data, 'install_requires': install_requires, diff --git a/tools/dev/dockerpkg.py b/tools/dev/dockerpkg.py index 3cd007c904b..b67608a0c48 100644 --- a/tools/dev/dockerpkg.py +++ b/tools/dev/dockerpkg.py @@ -59,9 +59,11 @@ RUN rm -R tools/c7n_kube/tests ADD tools/c7n_openstack /src/tools/c7n_openstack RUN rm -R tools/c7n_openstack/tests +ADD tools/c7n_tencentcloud /src/tools/c7n_tencentcloud +RUN rm -R tools/c7n_tencentcloud/tests # Install requested providers -ARG providers="gcp kube openstack azure" +ARG providers="gcp kube openstack tencentcloud azure" RUN . /usr/local/bin/activate && \\ for pkg in $providers; do cd tools/c7n_$pkg && \\ poetry install && cd ../../; done diff --git a/tools/dev/poetrypkg.py b/tools/dev/poetrypkg.py index f08a1d0b2aa..a6c345ef28e 100644 --- a/tools/dev/poetrypkg.py +++ b/tools/dev/poetrypkg.py @@ -93,11 +93,14 @@ def cli(): ], 'long_description': {long_description!r}, 'long_description_content_type': 'text/markdown', - 'author': {author!r}, - 'author_email': {author_email!r}, - 'maintainer': {maintainer!r}, - 'maintainer_email': {maintainer_email!r}, - 'url': {url!r}, + 'author': 'Cloud Custodian Project', + 'author_email': 'cloud-custodian@googlegroups.com', + 'project_urls': {{ + 'Homepage': {url!r}, + 'Documentation': 'https://cloudcustodian.io/docs/', + 'Source': 'https://github.com/cloud-custodian/cloud-custodian', + 'Issue Tracker': 'https://github.com/cloud-custodian/cloud-custodian/issues', + }}, {extra} }} {after} @@ -198,15 +201,19 @@ def resolve_source_deps(poetry, package, reqs, frozen=False): from poetry.core.packages.dependency import Dependency - dep_map = {d['name']: d for d in poetry.locker.lock_data['package']} + # normalize deps by lowercasing all the keys + dep_map = {d['name'].lower(): d for d in poetry.locker.lock_data['package']} seen = set(source_deps) seen.add('setuptools') prefix = '' if frozen else '^' while source_deps: dep = source_deps.pop() + dep = dep.lower() if dep not in dep_map: dep = dep.replace('_', '-') + if dep not in dep_map: + dep = dep.replace('-', '_') version = dep_map[dep]['version'] reqs.append(Dependency(dep, '{}{}'.format(prefix, version)).to_pep_508()) for cdep, cversion in dep_map[dep].get('dependencies', {}).items(): @@ -217,10 +224,14 @@ def resolve_source_deps(poetry, package, reqs, frozen=False): def locked_deps(package, poetry, exclude=(), remove=()): + from poetry_plugin_export.walker import get_project_dependency_packages + reqs = [] - deps = poetry.locker.get_project_dependency_packages( + deps = get_project_dependency_packages( + locker=poetry._locker, project_requires=package.all_requires, - dev=False, extras=[]) + project_python_marker=package.python_marker, + extras=[]) project_deps = {r.name: r for r in poetry.package.requires} for dep_pkg in deps: diff --git a/tools/dev/tests/test_poetrypkg.py b/tools/dev/tests/test_poetrypkg.py new file mode 100644 index 00000000000..f00e30a842d --- /dev/null +++ b/tools/dev/tests/test_poetrypkg.py @@ -0,0 +1,91 @@ +import subprocess +import sys + +import pytest + +from pathlib import Path + +from click.testing import CliRunner + +cli = Path(__file__).parent.parent / "poetrypkg.py" +with open(cli, encoding='utf-8') as f: + exec(f.read()) + +PKG_SET = ( + '.', + 'tools/c7n_gcp', + 'tools/c7n_kube', + 'tools/c7n_openstack', + 'tools/c7n_mailer', + 'tools/c7n_logexporter', + 'tools/c7n_policystream', + 'tools/c7n_trailcreator', + 'tools/c7n_org', + 'tools/c7n_sphinxext', + 'tools/c7n_terraform', + 'tools/c7n_awscc', + 'tools/c7n_tencentcloud', + 'tools/c7n_azure', +) + + +def _assert_pkg_ok( + runner, pkg, command='gen-frozensetup', check_file='setup.py', + cached=False, check_diff=True +): + base = Path(__file__).parent.parent.parent.parent / pkg + + with open(base / check_file) as f: + original = f.read() + + result = runner.invoke(cli, [command, '-p', base]) + assert result.exit_code == 0 + cached = ' --cached ' if cached else ' ' + + if not check_diff: + return + + git_diff_command = list(f"git diff{cached}{base}/{check_file}".split(' ')) + diff = subprocess.check_output( + git_diff_command, + stderr=subprocess.STDOUT, + ) + # we should get a git diff as a result of running the command + assert diff + + if cached == ' --cached': + # clean up the git diff + subprocess.run(f'git rm --cached {check_file}'.split(' ')) + + # clean up the setup.py file for a clean diff + with open(base / check_file, "w") as f: + f.write(original) + + +@pytest.mark.skipif(sys.version_info <= (3, 8), reason="Developer Python minimum is 3.8") +@pytest.mark.skipif(sys.platform == 'win32', reason="No Windows support") +def test_generate_frozen_deps(): + """ + Ensures that the gen-frozendeps command works and creates a git diff + """ + + runner = CliRunner() + + for pkg in PKG_SET: + _assert_pkg_ok(runner, pkg) + + +@pytest.mark.skipif(sys.version_info <= (3, 8), reason="Developer Python minimum is 3.8") +@pytest.mark.skipif(sys.platform == 'win32', reason="No Windows support") +def test_generate_setup(): + """ + Ensures that the gen-setup command works + """ + + runner = CliRunner() + + for pkg in PKG_SET: + _assert_pkg_ok( + runner, pkg, check_file='poetry.lock', + command='gen-setup', cached=True, check_diff=False + ) diff --git a/tox.ini b/tox.ini index 9a505266abf..0d520629760 100644 --- a/tox.ini +++ b/tox.ini @@ -68,13 +68,3 @@ commands = make sphinx deps = -rrequirements-dev.txt -rrequirements-docs.txt - -[pytest] -junit_family=xunit1 -; for travis, we set this up as env var that we can override to limit concurrency -addopts= --tb=native -markers = - functional - skiplive -python_files = test_*.py -norecursedirs = data cassettes templates