This commit is contained in:
Javier Casares 2026-09-18 15:20:16 +00:00
commit 7d59203323
7063 changed files with 92 additions and 3038598 deletions

View file

@ -1,5 +1,29 @@
== Changelog == == Changelog ==
= 1.5.0 =
_Release date: 2026-09-18_
**Highlights**
* Multisite uninstall now cleans up every site, not just the current one
**Fixed**
* Multisite uninstall scope (KI-005): `uninstall.php` iterates all network sites via `get_sites()` + `switch_to_blog()`, so post meta, options, and cron events are removed from subsites too. Each site's own opt-in setting decides; single-site flow unchanged
**Compatibility**
* WordPress: 5.3 - 7.1 (new symbols used — `get_sites()`, `switch_to_blog()` — predate the 5.3 floor)
* PHP: 8.1 - 8.5
**Tests**
* PHP Coding Standards: 3.13.6 (0 errors)
* WordPress Coding Standards: 3.4.1 (0 violations)
* PHPStan: Level 9, 0 errors
* PHPUnit: 88 tests, 164 assertions (6 new uninstall tests: single-site opt-in/opt-out/corrupt, multisite per-site cleanup, empty site-list fallback)
= 1.4.4 = = 1.4.4 =
_Release date: 2026-09-18_ _Release date: 2026-09-18_

View file

@ -4,7 +4,7 @@
* Plugin URI: https://www.robotstxt.software/plugins/idrivee2-media-upload/ * Plugin URI: https://www.robotstxt.software/plugins/idrivee2-media-upload/
* Update URI: https://www.robotstxt.software/plugins/idrivee2-media-upload/ * Update URI: https://www.robotstxt.software/plugins/idrivee2-media-upload/
* Description: Uploads media files to iDrivee2 (S3-compatible) with enterprise-grade security and logging. * Description: Uploads media files to iDrivee2 (S3-compatible) with enterprise-grade security and logging.
* Version: 1.4.4 * Version: 1.5.0
* Requires at least: 5.3 * Requires at least: 5.3
* Requires PHP: 8.1 * Requires PHP: 8.1
* Author: ROBOTSTXT * Author: ROBOTSTXT
@ -35,7 +35,7 @@ if ( ! defined( 'ABSPATH' ) ) {
* *
* @since 1.1.4 * @since 1.1.4
*/ */
define( 'IDRIVEE2_MEDIA_VERSION', '1.4.4' ); define( 'IDRIVEE2_MEDIA_VERSION', '1.5.0' );
/** /**
* Load Composer autoloader if available. * Load Composer autoloader if available.

View file

@ -3,9 +3,9 @@ Contributors: robotstxt, javiercasares
Tags: media, upload, s3, cdn, storage, idrivee2, cloud Tags: media, upload, s3, cdn, storage, idrivee2, cloud
Requires at least: 5.3 Requires at least: 5.3
Tested up to: 7.1 Tested up to: 7.1
Stable tag: 1.4.4 Stable tag: 1.5.0
Requires PHP: 8.1 Requires PHP: 8.1
Version: 1.4.4 Version: 1.5.0
License: GPL-3.0-or-later License: GPL-3.0-or-later
License URI: https://www.gnu.org/licenses/gpl-3.0.txt License URI: https://www.gnu.org/licenses/gpl-3.0.txt
@ -215,6 +215,26 @@ Updates are delivered through the [ROBOTSTXT Manager](https://www.robotstxt.soft
== Changelog == == Changelog ==
= 1.5.0 =
_Release date: 2026-09-18_
**Fixed**
* Multisite uninstall now cleans up all network sites (options, post meta, cron), honoring each site's own opt-in setting
**Compatibility**
* WordPress: 5.3 - 7.1
* PHP: 8.1 - 8.5
**Tests**
* PHP Coding Standards: 3.13.6 (0 errors)
* WordPress Coding Standards: 3.4.1 (0 violations)
* PHPStan: Level 9, 0 errors
* PHPUnit: 88 tests, 164 assertions
= 1.4.4 = = 1.4.4 =
_Release date: 2026-09-18_ _Release date: 2026-09-18_
@ -264,38 +284,6 @@ _Release date: 2026-08-24_
* PHPStan: Level 9, 0 errors * PHPStan: Level 9, 0 errors
* PHPUnit: 83 tests, 130 assertions * PHPUnit: 83 tests, 130 assertions
= 1.4.2 =
_Release date: 2026-08-17_
**Added**
* Dismissible admin notice on the Plugins page when the ROBOTSTXT Manager plugin is not installed or active, linking to https://www.robotstxt.software/plugins/robotstxt-manager/
* Persistent (non-dismissible) notice on Settings → iDrivee2 under the same condition
**Changed**
* Removed the bundled Gitea auto-updater (`robotstxt-updater.php` and `update.json`); automatic updates are now handled by the ROBOTSTXT Manager plugin
* Plugin URI and new `Update URI` header point to https://www.robotstxt.software/plugins/idrivee2-media-upload/
* Author URI updated to https://www.robotstxt.software/
* Composer dependencies updated (aws-sdk-php 3.392.3, guzzle 8.0.2, no known CVEs)
**Localization**
* POT regenerated for 1.4.2; Spanish (es_ES) and Catalan (ca) translations updated — 69/69 strings in both locales
**Compatibility**
* WordPress: 5.3 - 7.1
* PHP: 8.1 - 8.5
**Tests**
* PHP Coding Standards: 3.13.6 (0 errors)
* WordPress Coding Standards: 3.4.1 (0 violations)
* PHPStan: Level 9, 0 errors
* PHPUnit: 78 tests, 125 assertions
= Previous versions = = Previous versions =
If you want to see the full changelog, visit the [plugin page](https://www.robotstxt.software/plugins/idrivee2-media-upload/). If you want to see the full changelog, visit the [plugin page](https://www.robotstxt.software/plugins/idrivee2-media-upload/).

View file

@ -7,6 +7,10 @@
* the "Delete all plugin data on uninstall" setting (data preservation * the "Delete all plugin data on uninstall" setting (data preservation
* policy per AGENTS-database-roles-performance-i18n.md). * policy per AGENTS-database-roles-performance-i18n.md).
* *
* On Multisite every site is visited: options, post meta, and cron events
* are site-scoped, so cleaning only the current site would leave subsite
* data behind.
*
* @package iDrivee2Media * @package iDrivee2Media
* @since 0.3.0 * @since 0.3.0
*/ */
@ -20,15 +24,32 @@ if ( ! defined( 'WP_UNINSTALL_PLUGIN' ) ) {
exit; exit;
} }
/** // On Multisite, clean up every site; otherwise just the current one.
* Clean up plugin data. // get_sites() defaults to 100 results, so 'number' => 0 (no limit) is
* // required to reach every site on large networks.
* By default all plugin data (post meta, options, statistics) is preserved. $idrivee2_site_ids = array( get_current_blog_id() );
* Data is only removed when the administrator has explicitly checked the
* "Delete all plugin data on uninstall" option on the settings page. if ( is_multisite() ) {
* $idrivee2_network_sites = get_sites(
* Cron events are always cleared to prevent orphaned scheduled tasks. array(
*/ 'fields' => 'ids',
'number' => 0,
)
);
if ( ! empty( $idrivee2_network_sites ) ) {
$idrivee2_site_ids = array_map( 'intval', $idrivee2_network_sites );
}
}
// switch_to_blog() only exists on Multisite (ms-blogs.php is not loaded on
// single-site installs), so switch only when running Multisite.
$idrivee2_is_multisite = is_multisite();
foreach ( $idrivee2_site_ids as $idrivee2_site_id ) {
if ( $idrivee2_is_multisite ) {
switch_to_blog( $idrivee2_site_id );
}
$idrivee2_settings = get_option( 'idrivee2_media_settings', array() ); $idrivee2_settings = get_option( 'idrivee2_media_settings', array() );
$idrivee2_delete_data = is_array( $idrivee2_settings ) && isset( $idrivee2_settings['delete_on_uninstall'] ) && '1' === $idrivee2_settings['delete_on_uninstall']; $idrivee2_delete_data = is_array( $idrivee2_settings ) && isset( $idrivee2_settings['delete_on_uninstall'] ) && '1' === $idrivee2_settings['delete_on_uninstall'];
@ -47,6 +68,11 @@ if ( $idrivee2_delete_data ) {
// Always clear cron events to prevent orphaned scheduled tasks. // Always clear cron events to prevent orphaned scheduled tasks.
wp_clear_scheduled_hook( 'idrivee2_cleanup_local_files' ); wp_clear_scheduled_hook( 'idrivee2_cleanup_local_files' );
if ( $idrivee2_is_multisite ) {
restore_current_blog();
}
}
/** /**
* Note: Files uploaded to S3 are NOT deleted by this uninstall script. * Note: Files uploaded to S3 are NOT deleted by this uninstall script.
* If you want to delete files from S3, you must do so manually using * If you want to delete files from S3, you must do so manually using

File diff suppressed because it is too large Load diff

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load diff

File diff suppressed because one or more lines are too long

View file

@ -1,212 +0,0 @@
{
"version": "1.1",
"parameters": {
"Region": {
"builtIn": "AWS::Region",
"required": false,
"documentation": "The AWS region used to dispatch the request.",
"type": "string"
},
"UseDualStack": {
"builtIn": "AWS::UseDualStack",
"required": true,
"default": false,
"documentation": "When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error.",
"type": "boolean"
},
"UseFIPS": {
"builtIn": "AWS::UseFIPS",
"required": true,
"default": false,
"documentation": "When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error.",
"type": "boolean"
},
"Endpoint": {
"builtIn": "SDK::Endpoint",
"required": false,
"documentation": "Override the endpoint used to send this request",
"type": "string"
}
},
"conditions": [
{
"fn": "isSet",
"argv": [
{
"ref": "Endpoint"
}
]
},
{
"fn": "isSet",
"argv": [
{
"ref": "Region"
}
]
},
{
"fn": "aws.partition",
"argv": [
{
"ref": "Region"
}
],
"assign": "PartitionResult"
},
{
"fn": "booleanEquals",
"argv": [
{
"ref": "UseFIPS"
},
true
]
},
{
"fn": "booleanEquals",
"argv": [
{
"ref": "UseDualStack"
},
true
]
},
{
"fn": "booleanEquals",
"argv": [
{
"fn": "getAttr",
"argv": [
{
"ref": "PartitionResult"
},
"supportsDualStack"
]
},
true
]
},
{
"fn": "booleanEquals",
"argv": [
{
"fn": "getAttr",
"argv": [
{
"ref": "PartitionResult"
},
"supportsFIPS"
]
},
true
]
},
{
"fn": "stringEquals",
"argv": [
{
"fn": "getAttr",
"argv": [
{
"ref": "PartitionResult"
},
"name"
]
},
"aws-us-gov"
]
}
],
"results": [
{
"conditions": [],
"error": "Invalid Configuration: FIPS and custom endpoint are not supported",
"type": "error"
},
{
"conditions": [],
"error": "Invalid Configuration: Dualstack and custom endpoint are not supported",
"type": "error"
},
{
"conditions": [],
"endpoint": {
"url": {
"ref": "Endpoint"
},
"properties": {},
"headers": {}
},
"type": "endpoint"
},
{
"conditions": [],
"endpoint": {
"url": "https://access-analyzer-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",
"properties": {},
"headers": {}
},
"type": "endpoint"
},
{
"conditions": [],
"error": "FIPS and DualStack are enabled, but this partition does not support one or both",
"type": "error"
},
{
"conditions": [],
"endpoint": {
"url": "https://access-analyzer.{Region}.amazonaws.com",
"properties": {},
"headers": {}
},
"type": "endpoint"
},
{
"conditions": [],
"endpoint": {
"url": "https://access-analyzer-fips.{Region}.{PartitionResult#dnsSuffix}",
"properties": {},
"headers": {}
},
"type": "endpoint"
},
{
"conditions": [],
"error": "FIPS is enabled but this partition does not support FIPS",
"type": "error"
},
{
"conditions": [],
"endpoint": {
"url": "https://access-analyzer.{Region}.{PartitionResult#dualStackDnsSuffix}",
"properties": {},
"headers": {}
},
"type": "endpoint"
},
{
"conditions": [],
"error": "DualStack is enabled but this partition does not support DualStack",
"type": "error"
},
{
"conditions": [],
"endpoint": {
"url": "https://access-analyzer.{Region}.{PartitionResult#dnsSuffix}",
"properties": {},
"headers": {}
},
"type": "endpoint"
},
{
"conditions": [],
"error": "Invalid Configuration: Missing Region",
"type": "error"
}
],
"root": 2,
"nodeCount": 14,
"nodes": "/////wAAAAH/////AAAAAAAAAA0AAAADAAAAAQAAAAQF9eEMAAAAAgAAAAUF9eEMAAAAAwAAAAgAAAAGAAAABAAAAAcF9eELAAAABQX14QkF9eEKAAAABAAAAAsAAAAJAAAABgAAAAoF9eEIAAAABwX14QYF9eEHAAAABQAAAAwF9eEFAAAABgX14QQF9eEFAAAAAwX14QEAAAAOAAAABAX14QIF9eED"
}

View file

@ -1,3 +0,0 @@
<?php
// This file was auto-generated from sdk-root/src/data/accessanalyzer/2019-11-01/endpoint-bdd-1.json
return [ 'version' => '1.1', 'parameters' => [ 'Region' => [ 'builtIn' => 'AWS::Region', 'required' => false, 'documentation' => 'The AWS region used to dispatch the request.', 'type' => 'string', ], 'UseDualStack' => [ 'builtIn' => 'AWS::UseDualStack', 'required' => true, 'default' => false, 'documentation' => 'When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error.', 'type' => 'boolean', ], 'UseFIPS' => [ 'builtIn' => 'AWS::UseFIPS', 'required' => true, 'default' => false, 'documentation' => 'When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error.', 'type' => 'boolean', ], 'Endpoint' => [ 'builtIn' => 'SDK::Endpoint', 'required' => false, 'documentation' => 'Override the endpoint used to send this request', 'type' => 'string', ], ], 'conditions' => [ [ 'fn' => 'isSet', 'argv' => [ [ 'ref' => 'Endpoint', ], ], ], [ 'fn' => 'isSet', 'argv' => [ [ 'ref' => 'Region', ], ], ], [ 'fn' => 'aws.partition', 'argv' => [ [ 'ref' => 'Region', ], ], 'assign' => 'PartitionResult', ], [ 'fn' => 'booleanEquals', 'argv' => [ [ 'ref' => 'UseFIPS', ], true, ], ], [ 'fn' => 'booleanEquals', 'argv' => [ [ 'ref' => 'UseDualStack', ], true, ], ], [ 'fn' => 'booleanEquals', 'argv' => [ [ 'fn' => 'getAttr', 'argv' => [ [ 'ref' => 'PartitionResult', ], 'supportsDualStack', ], ], true, ], ], [ 'fn' => 'booleanEquals', 'argv' => [ [ 'fn' => 'getAttr', 'argv' => [ [ 'ref' => 'PartitionResult', ], 'supportsFIPS', ], ], true, ], ], [ 'fn' => 'stringEquals', 'argv' => [ [ 'fn' => 'getAttr', 'argv' => [ [ 'ref' => 'PartitionResult', ], 'name', ], ], 'aws-us-gov', ], ], ], 'results' => [ [ 'conditions' => [], 'error' => 'Invalid Configuration: FIPS and custom endpoint are not supported', 'type' => 'error', ], [ 'conditions' => [], 'error' => 'Invalid Configuration: Dualstack and custom endpoint are not supported', 'type' => 'error', ], [ 'conditions' => [], 'endpoint' => [ 'url' => [ 'ref' => 'Endpoint', ], 'properties' => [], 'headers' => [], ], 'type' => 'endpoint', ], [ 'conditions' => [], 'endpoint' => [ 'url' => 'https://access-analyzer-fips.{Region}.{PartitionResult#dualStackDnsSuffix}', 'properties' => [], 'headers' => [], ], 'type' => 'endpoint', ], [ 'conditions' => [], 'error' => 'FIPS and DualStack are enabled, but this partition does not support one or both', 'type' => 'error', ], [ 'conditions' => [], 'endpoint' => [ 'url' => 'https://access-analyzer.{Region}.amazonaws.com', 'properties' => [], 'headers' => [], ], 'type' => 'endpoint', ], [ 'conditions' => [], 'endpoint' => [ 'url' => 'https://access-analyzer-fips.{Region}.{PartitionResult#dnsSuffix}', 'properties' => [], 'headers' => [], ], 'type' => 'endpoint', ], [ 'conditions' => [], 'error' => 'FIPS is enabled but this partition does not support FIPS', 'type' => 'error', ], [ 'conditions' => [], 'endpoint' => [ 'url' => 'https://access-analyzer.{Region}.{PartitionResult#dualStackDnsSuffix}', 'properties' => [], 'headers' => [], ], 'type' => 'endpoint', ], [ 'conditions' => [], 'error' => 'DualStack is enabled but this partition does not support DualStack', 'type' => 'error', ], [ 'conditions' => [], 'endpoint' => [ 'url' => 'https://access-analyzer.{Region}.{PartitionResult#dnsSuffix}', 'properties' => [], 'headers' => [], ], 'type' => 'endpoint', ], [ 'conditions' => [], 'error' => 'Invalid Configuration: Missing Region', 'type' => 'error', ], ], 'root' => 2, 'nodeCount' => 14, 'nodes' => '/////wAAAAH/////AAAAAAAAAA0AAAADAAAAAQAAAAQF9eEMAAAAAgAAAAUF9eEMAAAAAwAAAAgAAAAGAAAABAAAAAcF9eELAAAABQX14QkF9eEKAAAABAAAAAsAAAAJAAAABgAAAAoF9eEIAAAABwX14QYF9eEHAAAABQAAAAwF9eEFAAAABgX14QQF9eEFAAAAAwX14QEAAAAOAAAABAX14QIF9eED',];

View file

@ -1,339 +0,0 @@
{
"version": "1.0",
"parameters": {
"Region": {
"builtIn": "AWS::Region",
"required": false,
"documentation": "The AWS region used to dispatch the request.",
"type": "string"
},
"UseDualStack": {
"builtIn": "AWS::UseDualStack",
"required": true,
"default": false,
"documentation": "When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error.",
"type": "boolean"
},
"UseFIPS": {
"builtIn": "AWS::UseFIPS",
"required": true,
"default": false,
"documentation": "When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error.",
"type": "boolean"
},
"Endpoint": {
"builtIn": "SDK::Endpoint",
"required": false,
"documentation": "Override the endpoint used to send this request",
"type": "string"
}
},
"rules": [
{
"conditions": [
{
"fn": "isSet",
"argv": [
{
"ref": "Endpoint"
}
]
}
],
"rules": [
{
"conditions": [
{
"fn": "booleanEquals",
"argv": [
{
"ref": "UseFIPS"
},
true
]
}
],
"error": "Invalid Configuration: FIPS and custom endpoint are not supported",
"type": "error"
},
{
"conditions": [
{
"fn": "booleanEquals",
"argv": [
{
"ref": "UseDualStack"
},
true
]
}
],
"error": "Invalid Configuration: Dualstack and custom endpoint are not supported",
"type": "error"
},
{
"conditions": [],
"endpoint": {
"url": {
"ref": "Endpoint"
},
"properties": {},
"headers": {}
},
"type": "endpoint"
}
],
"type": "tree"
},
{
"conditions": [
{
"fn": "isSet",
"argv": [
{
"ref": "Region"
}
]
}
],
"rules": [
{
"conditions": [
{
"fn": "aws.partition",
"argv": [
{
"ref": "Region"
}
],
"assign": "PartitionResult"
}
],
"rules": [
{
"conditions": [
{
"fn": "booleanEquals",
"argv": [
{
"ref": "UseFIPS"
},
true
]
},
{
"fn": "booleanEquals",
"argv": [
{
"ref": "UseDualStack"
},
true
]
}
],
"rules": [
{
"conditions": [
{
"fn": "booleanEquals",
"argv": [
true,
{
"fn": "getAttr",
"argv": [
{
"ref": "PartitionResult"
},
"supportsFIPS"
]
}
]
},
{
"fn": "booleanEquals",
"argv": [
true,
{
"fn": "getAttr",
"argv": [
{
"ref": "PartitionResult"
},
"supportsDualStack"
]
}
]
}
],
"rules": [
{
"conditions": [],
"endpoint": {
"url": "https://access-analyzer-fips.{Region}.{PartitionResult#dualStackDnsSuffix}",
"properties": {},
"headers": {}
},
"type": "endpoint"
}
],
"type": "tree"
},
{
"conditions": [],
"error": "FIPS and DualStack are enabled, but this partition does not support one or both",
"type": "error"
}
],
"type": "tree"
},
{
"conditions": [
{
"fn": "booleanEquals",
"argv": [
{
"ref": "UseFIPS"
},
true
]
}
],
"rules": [
{
"conditions": [
{
"fn": "booleanEquals",
"argv": [
{
"fn": "getAttr",
"argv": [
{
"ref": "PartitionResult"
},
"supportsFIPS"
]
},
true
]
}
],
"rules": [
{
"conditions": [
{
"fn": "stringEquals",
"argv": [
{
"fn": "getAttr",
"argv": [
{
"ref": "PartitionResult"
},
"name"
]
},
"aws-us-gov"
]
}
],
"endpoint": {
"url": "https://access-analyzer.{Region}.amazonaws.com",
"properties": {},
"headers": {}
},
"type": "endpoint"
},
{
"conditions": [],
"endpoint": {
"url": "https://access-analyzer-fips.{Region}.{PartitionResult#dnsSuffix}",
"properties": {},
"headers": {}
},
"type": "endpoint"
}
],
"type": "tree"
},
{
"conditions": [],
"error": "FIPS is enabled but this partition does not support FIPS",
"type": "error"
}
],
"type": "tree"
},
{
"conditions": [
{
"fn": "booleanEquals",
"argv": [
{
"ref": "UseDualStack"
},
true
]
}
],
"rules": [
{
"conditions": [
{
"fn": "booleanEquals",
"argv": [
true,
{
"fn": "getAttr",
"argv": [
{
"ref": "PartitionResult"
},
"supportsDualStack"
]
}
]
}
],
"rules": [
{
"conditions": [],
"endpoint": {
"url": "https://access-analyzer.{Region}.{PartitionResult#dualStackDnsSuffix}",
"properties": {},
"headers": {}
},
"type": "endpoint"
}
],
"type": "tree"
},
{
"conditions": [],
"error": "DualStack is enabled but this partition does not support DualStack",
"type": "error"
}
],
"type": "tree"
},
{
"conditions": [],
"endpoint": {
"url": "https://access-analyzer.{Region}.{PartitionResult#dnsSuffix}",
"properties": {},
"headers": {}
},
"type": "endpoint"
}
],
"type": "tree"
}
],
"type": "tree"
},
{
"conditions": [],
"error": "Invalid Configuration: Missing Region",
"type": "error"
}
]
}

View file

@ -1,3 +0,0 @@
<?php
// This file was auto-generated from sdk-root/src/data/accessanalyzer/2019-11-01/endpoint-rule-set-1.json
return [ 'version' => '1.0', 'parameters' => [ 'Region' => [ 'builtIn' => 'AWS::Region', 'required' => false, 'documentation' => 'The AWS region used to dispatch the request.', 'type' => 'string', ], 'UseDualStack' => [ 'builtIn' => 'AWS::UseDualStack', 'required' => true, 'default' => false, 'documentation' => 'When true, use the dual-stack endpoint. If the configured endpoint does not support dual-stack, dispatching the request MAY return an error.', 'type' => 'boolean', ], 'UseFIPS' => [ 'builtIn' => 'AWS::UseFIPS', 'required' => true, 'default' => false, 'documentation' => 'When true, send this request to the FIPS-compliant regional endpoint. If the configured endpoint does not have a FIPS compliant endpoint, dispatching the request will return an error.', 'type' => 'boolean', ], 'Endpoint' => [ 'builtIn' => 'SDK::Endpoint', 'required' => false, 'documentation' => 'Override the endpoint used to send this request', 'type' => 'string', ], ], 'rules' => [ [ 'conditions' => [ [ 'fn' => 'isSet', 'argv' => [ [ 'ref' => 'Endpoint', ], ], ], ], 'rules' => [ [ 'conditions' => [ [ 'fn' => 'booleanEquals', 'argv' => [ [ 'ref' => 'UseFIPS', ], true, ], ], ], 'error' => 'Invalid Configuration: FIPS and custom endpoint are not supported', 'type' => 'error', ], [ 'conditions' => [ [ 'fn' => 'booleanEquals', 'argv' => [ [ 'ref' => 'UseDualStack', ], true, ], ], ], 'error' => 'Invalid Configuration: Dualstack and custom endpoint are not supported', 'type' => 'error', ], [ 'conditions' => [], 'endpoint' => [ 'url' => [ 'ref' => 'Endpoint', ], 'properties' => [], 'headers' => [], ], 'type' => 'endpoint', ], ], 'type' => 'tree', ], [ 'conditions' => [ [ 'fn' => 'isSet', 'argv' => [ [ 'ref' => 'Region', ], ], ], ], 'rules' => [ [ 'conditions' => [ [ 'fn' => 'aws.partition', 'argv' => [ [ 'ref' => 'Region', ], ], 'assign' => 'PartitionResult', ], ], 'rules' => [ [ 'conditions' => [ [ 'fn' => 'booleanEquals', 'argv' => [ [ 'ref' => 'UseFIPS', ], true, ], ], [ 'fn' => 'booleanEquals', 'argv' => [ [ 'ref' => 'UseDualStack', ], true, ], ], ], 'rules' => [ [ 'conditions' => [ [ 'fn' => 'booleanEquals', 'argv' => [ true, [ 'fn' => 'getAttr', 'argv' => [ [ 'ref' => 'PartitionResult', ], 'supportsFIPS', ], ], ], ], [ 'fn' => 'booleanEquals', 'argv' => [ true, [ 'fn' => 'getAttr', 'argv' => [ [ 'ref' => 'PartitionResult', ], 'supportsDualStack', ], ], ], ], ], 'rules' => [ [ 'conditions' => [], 'endpoint' => [ 'url' => 'https://access-analyzer-fips.{Region}.{PartitionResult#dualStackDnsSuffix}', 'properties' => [], 'headers' => [], ], 'type' => 'endpoint', ], ], 'type' => 'tree', ], [ 'conditions' => [], 'error' => 'FIPS and DualStack are enabled, but this partition does not support one or both', 'type' => 'error', ], ], 'type' => 'tree', ], [ 'conditions' => [ [ 'fn' => 'booleanEquals', 'argv' => [ [ 'ref' => 'UseFIPS', ], true, ], ], ], 'rules' => [ [ 'conditions' => [ [ 'fn' => 'booleanEquals', 'argv' => [ [ 'fn' => 'getAttr', 'argv' => [ [ 'ref' => 'PartitionResult', ], 'supportsFIPS', ], ], true, ], ], ], 'rules' => [ [ 'conditions' => [ [ 'fn' => 'stringEquals', 'argv' => [ [ 'fn' => 'getAttr', 'argv' => [ [ 'ref' => 'PartitionResult', ], 'name', ], ], 'aws-us-gov', ], ], ], 'endpoint' => [ 'url' => 'https://access-analyzer.{Region}.amazonaws.com', 'properties' => [], 'headers' => [], ], 'type' => 'endpoint', ], [ 'conditions' => [], 'endpoint' => [ 'url' => 'https://access-analyzer-fips.{Region}.{PartitionResult#dnsSuffix}', 'properties' => [], 'headers' => [], ], 'type' => 'endpoint', ], ], 'type' => 'tree', ], [ 'conditions' => [], 'error' => 'FIPS is enabled but this partition does not support FIPS', 'type' => 'error', ], ], 'type' => 'tree', ], [ 'conditions' => [ [ 'fn' => 'booleanEquals', 'argv' => [ [ 'ref' => 'UseDualStack', ], true, ], ], ], 'rules' => [ [ 'conditions' => [ [ 'fn' => 'booleanEquals', 'argv' => [ true, [ 'fn' => 'getAttr', 'argv' => [ [ 'ref' => 'PartitionResult', ], 'supportsDualStack', ], ], ], ], ], 'rules' => [ [ 'conditions' => [], 'endpoint' => [ 'url' => 'https://access-analyzer.{Region}.{PartitionResult#dualStackDnsSuffix}', 'properties' => [], 'headers' => [], ], 'type' => 'endpoint', ], ], 'type' => 'tree', ], [ 'conditions' => [], 'error' => 'DualStack is enabled but this partition does not support DualStack', 'type' => 'error', ], ], 'type' => 'tree', ], [ 'conditions' => [], 'endpoint' => [ 'url' => 'https://access-analyzer.{Region}.{PartitionResult#dnsSuffix}', 'properties' => [], 'headers' => [], ], 'type' => 'endpoint', ], ], 'type' => 'tree', ], ], 'type' => 'tree', ], [ 'conditions' => [], 'error' => 'Invalid Configuration: Missing Region', 'type' => 'error', ], ],];

View file

@ -1,634 +0,0 @@
{
"testCases": [
{
"documentation": "For region af-south-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.af-south-1.amazonaws.com"
}
},
"params": {
"Region": "af-south-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region ap-east-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.ap-east-1.amazonaws.com"
}
},
"params": {
"Region": "ap-east-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region ap-northeast-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.ap-northeast-1.amazonaws.com"
}
},
"params": {
"Region": "ap-northeast-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region ap-northeast-2 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.ap-northeast-2.amazonaws.com"
}
},
"params": {
"Region": "ap-northeast-2",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region ap-northeast-3 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.ap-northeast-3.amazonaws.com"
}
},
"params": {
"Region": "ap-northeast-3",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region ap-south-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.ap-south-1.amazonaws.com"
}
},
"params": {
"Region": "ap-south-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region ap-southeast-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.ap-southeast-1.amazonaws.com"
}
},
"params": {
"Region": "ap-southeast-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region ap-southeast-2 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.ap-southeast-2.amazonaws.com"
}
},
"params": {
"Region": "ap-southeast-2",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region ap-southeast-3 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.ap-southeast-3.amazonaws.com"
}
},
"params": {
"Region": "ap-southeast-3",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region ca-central-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.ca-central-1.amazonaws.com"
}
},
"params": {
"Region": "ca-central-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region ca-central-1 with FIPS enabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer-fips.ca-central-1.amazonaws.com"
}
},
"params": {
"Region": "ca-central-1",
"UseFIPS": true,
"UseDualStack": false
}
},
{
"documentation": "For region eu-central-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.eu-central-1.amazonaws.com"
}
},
"params": {
"Region": "eu-central-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region eu-north-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.eu-north-1.amazonaws.com"
}
},
"params": {
"Region": "eu-north-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region eu-south-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.eu-south-1.amazonaws.com"
}
},
"params": {
"Region": "eu-south-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region eu-west-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.eu-west-1.amazonaws.com"
}
},
"params": {
"Region": "eu-west-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region eu-west-2 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.eu-west-2.amazonaws.com"
}
},
"params": {
"Region": "eu-west-2",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region eu-west-3 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.eu-west-3.amazonaws.com"
}
},
"params": {
"Region": "eu-west-3",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region me-south-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.me-south-1.amazonaws.com"
}
},
"params": {
"Region": "me-south-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region sa-east-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.sa-east-1.amazonaws.com"
}
},
"params": {
"Region": "sa-east-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region us-east-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.us-east-1.amazonaws.com"
}
},
"params": {
"Region": "us-east-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region us-east-1 with FIPS enabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer-fips.us-east-1.amazonaws.com"
}
},
"params": {
"Region": "us-east-1",
"UseFIPS": true,
"UseDualStack": false
}
},
{
"documentation": "For region us-east-2 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.us-east-2.amazonaws.com"
}
},
"params": {
"Region": "us-east-2",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region us-east-2 with FIPS enabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer-fips.us-east-2.amazonaws.com"
}
},
"params": {
"Region": "us-east-2",
"UseFIPS": true,
"UseDualStack": false
}
},
{
"documentation": "For region us-west-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.us-west-1.amazonaws.com"
}
},
"params": {
"Region": "us-west-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region us-west-1 with FIPS enabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer-fips.us-west-1.amazonaws.com"
}
},
"params": {
"Region": "us-west-1",
"UseFIPS": true,
"UseDualStack": false
}
},
{
"documentation": "For region us-west-2 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.us-west-2.amazonaws.com"
}
},
"params": {
"Region": "us-west-2",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region us-west-2 with FIPS enabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer-fips.us-west-2.amazonaws.com"
}
},
"params": {
"Region": "us-west-2",
"UseFIPS": true,
"UseDualStack": false
}
},
{
"documentation": "For region us-east-1 with FIPS enabled and DualStack enabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer-fips.us-east-1.api.aws"
}
},
"params": {
"Region": "us-east-1",
"UseFIPS": true,
"UseDualStack": true
}
},
{
"documentation": "For region us-east-1 with FIPS disabled and DualStack enabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.us-east-1.api.aws"
}
},
"params": {
"Region": "us-east-1",
"UseFIPS": false,
"UseDualStack": true
}
},
{
"documentation": "For region cn-north-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.cn-north-1.amazonaws.com.cn"
}
},
"params": {
"Region": "cn-north-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region cn-northwest-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.cn-northwest-1.amazonaws.com.cn"
}
},
"params": {
"Region": "cn-northwest-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region cn-north-1 with FIPS enabled and DualStack enabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer-fips.cn-north-1.api.amazonwebservices.com.cn"
}
},
"params": {
"Region": "cn-north-1",
"UseFIPS": true,
"UseDualStack": true
}
},
{
"documentation": "For region cn-north-1 with FIPS enabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer-fips.cn-north-1.amazonaws.com.cn"
}
},
"params": {
"Region": "cn-north-1",
"UseFIPS": true,
"UseDualStack": false
}
},
{
"documentation": "For region cn-north-1 with FIPS disabled and DualStack enabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.cn-north-1.api.amazonwebservices.com.cn"
}
},
"params": {
"Region": "cn-north-1",
"UseFIPS": false,
"UseDualStack": true
}
},
{
"documentation": "For region us-gov-east-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.us-gov-east-1.amazonaws.com"
}
},
"params": {
"Region": "us-gov-east-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region us-gov-east-1 with FIPS enabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.us-gov-east-1.amazonaws.com"
}
},
"params": {
"Region": "us-gov-east-1",
"UseFIPS": true,
"UseDualStack": false
}
},
{
"documentation": "For region us-gov-west-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.us-gov-west-1.amazonaws.com"
}
},
"params": {
"Region": "us-gov-west-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region us-gov-west-1 with FIPS enabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.us-gov-west-1.amazonaws.com"
}
},
"params": {
"Region": "us-gov-west-1",
"UseFIPS": true,
"UseDualStack": false
}
},
{
"documentation": "For region us-gov-east-1 with FIPS enabled and DualStack enabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer-fips.us-gov-east-1.api.aws"
}
},
"params": {
"Region": "us-gov-east-1",
"UseFIPS": true,
"UseDualStack": true
}
},
{
"documentation": "For region us-gov-east-1 with FIPS disabled and DualStack enabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.us-gov-east-1.api.aws"
}
},
"params": {
"Region": "us-gov-east-1",
"UseFIPS": false,
"UseDualStack": true
}
},
{
"documentation": "For region us-iso-east-1 with FIPS enabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer-fips.us-iso-east-1.c2s.ic.gov"
}
},
"params": {
"Region": "us-iso-east-1",
"UseFIPS": true,
"UseDualStack": false
}
},
{
"documentation": "For region us-iso-east-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.us-iso-east-1.c2s.ic.gov"
}
},
"params": {
"Region": "us-iso-east-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For region us-isob-east-1 with FIPS enabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer-fips.us-isob-east-1.sc2s.sgov.gov"
}
},
"params": {
"Region": "us-isob-east-1",
"UseFIPS": true,
"UseDualStack": false
}
},
{
"documentation": "For region us-isob-east-1 with FIPS disabled and DualStack disabled",
"expect": {
"endpoint": {
"url": "https://access-analyzer.us-isob-east-1.sc2s.sgov.gov"
}
},
"params": {
"Region": "us-isob-east-1",
"UseFIPS": false,
"UseDualStack": false
}
},
{
"documentation": "For custom endpoint with region set and fips disabled and dualstack disabled",
"expect": {
"endpoint": {
"url": "https://example.com"
}
},
"params": {
"Region": "us-east-1",
"UseFIPS": false,
"UseDualStack": false,
"Endpoint": "https://example.com"
}
},
{
"documentation": "For custom endpoint with region not set and fips disabled and dualstack disabled",
"expect": {
"endpoint": {
"url": "https://example.com"
}
},
"params": {
"UseFIPS": false,
"UseDualStack": false,
"Endpoint": "https://example.com"
}
},
{
"documentation": "For custom endpoint with fips enabled and dualstack disabled",
"expect": {
"error": "Invalid Configuration: FIPS and custom endpoint are not supported"
},
"params": {
"Region": "us-east-1",
"UseFIPS": true,
"UseDualStack": false,
"Endpoint": "https://example.com"
}
},
{
"documentation": "For custom endpoint with fips disabled and dualstack enabled",
"expect": {
"error": "Invalid Configuration: Dualstack and custom endpoint are not supported"
},
"params": {
"Region": "us-east-1",
"UseFIPS": false,
"UseDualStack": true,
"Endpoint": "https://example.com"
}
},
{
"documentation": "Missing region",
"expect": {
"error": "Invalid Configuration: Missing Region"
}
}
],
"version": "1.0"
}

File diff suppressed because one or more lines are too long

View file

@ -1,200 +0,0 @@
{
"version": "1.0",
"examples": {
"CheckAccessNotGranted": [
{
"input": {
"access": [
{
"actions": [
"s3:PutObject"
]
}
],
"policyDocument": "{\"Version\":\"2012-10-17\",\"Id\":\"123\",\"Statement\":[{\"Sid\":\"AllowJohnDoe\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"arn:aws:iam::123456789012:user/JohnDoe\"},\"Action\":\"s3:GetObject\",\"Resource\":\"*\"}]}",
"policyType": "RESOURCE_POLICY"
},
"output": {
"message": "The policy document does not grant access to perform the listed actions or resources.",
"result": "PASS"
},
"id": "example-1",
"title": "Passing check. Restrictive identity policy."
},
{
"input": {
"access": [
{
"resources": [
"arn:aws:s3:::sensitive-bucket/*"
]
}
],
"policyDocument": "{\"Version\":\"2012-10-17\",\"Id\":\"123\",\"Statement\":[{\"Sid\":\"AllowJohnDoe\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"arn:aws:iam::123456789012:user/JohnDoe\"},\"Action\":\"s3:PutObject\",\"Resource\":\"arn:aws:s3:::non-sensitive-bucket/*\"}]}",
"policyType": "RESOURCE_POLICY"
},
"output": {
"message": "The policy document does not grant access to perform the listed actions or resources.",
"result": "PASS"
},
"id": "example-2",
"title": "Passing check. Restrictive S3 Bucket resource policy."
},
{
"input": {
"access": [
{
"resources": [
"arn:aws:s3:::my-bucket/*"
]
}
],
"policyDocument": "{\"Version\":\"2012-10-17\",\"Id\":\"123\",\"Statement\":[{\"Sid\":\"AllowJohnDoe\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"arn:aws:iam::123456789012:user/JohnDoe\"},\"Action\":\"s3:PutObject\",\"Resource\":\"arn:aws:s3:::my-bucket/*\"}]}",
"policyType": "RESOURCE_POLICY"
},
"output": {
"message": "The policy document grants access to perform one or more of the listed actions or resources.",
"reasons": [
{
"description": "One or more of the listed actions or resources in the statement with sid: AllowJohnDoe.",
"statementId": "AllowJohnDoe",
"statementIndex": 0
}
],
"result": "FAIL"
},
"id": "example-3",
"title": "Failing check. Permissive S3 Bucket resource policy."
}
],
"CheckNoPublicAccess": [
{
"input": {
"policyDocument": "{\"Version\":\"2012-10-17\",\"Statement\":[{\"Sid\":\"Bob\",\"Effect\":\"Allow\",\"Principal\":{\"AWS\":\"arn:aws:iam::111122223333:user/JohnDoe\"},\"Action\":[\"s3:GetObject\"]}]}",
"resourceType": "AWS::S3::Bucket"
},
"output": {
"message": "The resource policy does not grant public access for the given resource type.",
"result": "PASS"
},
"id": "example-1",
"title": "Passing check. S3 Bucket policy without public access."
},
{
"input": {
"policyDocument": "{\"Version\":\"2012-10-17\",\"Statement\":[{\"Sid\":\"Bob\",\"Effect\":\"Allow\",\"Principal\":\"*\",\"Action\":[\"s3:GetObject\"]}]}",
"resourceType": "AWS::S3::Bucket"
},
"output": {
"message": "The resource policy grants public access for the given resource type.",
"reasons": [
{
"description": "Public access granted in the following statement with sid: Bob.",
"statementId": "Bob",
"statementIndex": 0
}
],
"result": "FAIL"
},
"id": "example-2",
"title": "Failing check. S3 Bucket policy with public access."
}
],
"GenerateFindingRecommendation": [
{
"input": {
"analyzerArn": "arn:aws:access-analyzer:us-east-1:111122223333:analyzer/a",
"id": "finding-id"
},
"output": {},
"id": "example-1",
"title": "Successfully started generating finding recommendation"
},
{
"input": {
"analyzerArn": "arn:aws:access-analyzer:us-east-1:111122223333:analyzer/a",
"id": "!"
},
"id": "example-2",
"title": "Failed field validation for id value"
}
],
"GetFindingRecommendation": [
{
"input": {
"analyzerArn": "arn:aws:access-analyzer:us-east-1:111122223333:analyzer/a",
"id": "finding-id",
"maxResults": 3,
"nextToken": "token"
},
"output": {
"completedAt": "2000-01-01T00:00:01Z",
"recommendationType": "UnusedPermissionRecommendation",
"recommendedSteps": [
{
"unusedPermissionsRecommendedStep": {
"existingPolicyId": "policy-id",
"recommendedAction": "DETACH_POLICY"
}
},
{
"unusedPermissionsRecommendedStep": {
"existingPolicyId": "policy-id",
"recommendedAction": "CREATE_POLICY",
"recommendedPolicy": "policy-content"
}
}
],
"resourceArn": "arn:aws:iam::111122223333:role/test",
"startedAt": "2000-01-01T00:00:00Z",
"status": "SUCCEEDED"
},
"id": "example-1",
"title": "Successfully fetched finding recommendation"
},
{
"input": {
"analyzerArn": "arn:aws:access-analyzer:us-east-1:111122223333:analyzer/a",
"id": "finding-id",
"maxResults": 3
},
"output": {
"recommendationType": "UnusedPermissionRecommendation",
"resourceArn": "arn:aws:iam::111122223333:role/test",
"startedAt": "2000-01-01T00:00:00Z",
"status": "IN_PROGRESS"
},
"id": "example-2",
"title": "In progress finding recommendation"
},
{
"input": {
"analyzerArn": "arn:aws:access-analyzer:us-east-1:111122223333:analyzer/a",
"id": "finding-id",
"maxResults": 3
},
"output": {
"completedAt": "2000-01-01T00:00:01Z",
"error": {
"code": "SERVICE_ERROR",
"message": "Service error. Please try again."
},
"recommendationType": "UnusedPermissionRecommendation",
"resourceArn": "arn:aws:iam::111122223333:role/test",
"startedAt": "2000-01-01T00:00:00Z",
"status": "FAILED"
},
"id": "example-3",
"title": "Failed finding recommendation"
},
{
"input": {
"analyzerArn": "arn:aws:access-analyzer:us-east-1:111122223333:analyzer/a",
"id": "!"
},
"id": "example-4",
"title": "Failed field validation for id value"
}
]
}
}

File diff suppressed because one or more lines are too long

View file

@ -1,70 +0,0 @@
{
"pagination": {
"GetFindingRecommendation": {
"input_token": "nextToken",
"output_token": "nextToken",
"limit_key": "maxResults",
"result_key": "recommendedSteps"
},
"GetFindingV2": {
"input_token": "nextToken",
"output_token": "nextToken",
"limit_key": "maxResults",
"result_key": "findingDetails"
},
"ListAccessPreviewFindings": {
"input_token": "nextToken",
"output_token": "nextToken",
"limit_key": "maxResults",
"result_key": "findings"
},
"ListAccessPreviews": {
"input_token": "nextToken",
"output_token": "nextToken",
"limit_key": "maxResults",
"result_key": "accessPreviews"
},
"ListAnalyzedResources": {
"input_token": "nextToken",
"output_token": "nextToken",
"limit_key": "maxResults",
"result_key": "analyzedResources"
},
"ListAnalyzers": {
"input_token": "nextToken",
"output_token": "nextToken",
"limit_key": "maxResults",
"result_key": "analyzers"
},
"ListArchiveRules": {
"input_token": "nextToken",
"output_token": "nextToken",
"limit_key": "maxResults",
"result_key": "archiveRules"
},
"ListFindings": {
"input_token": "nextToken",
"output_token": "nextToken",
"limit_key": "maxResults",
"result_key": "findings"
},
"ListFindingsV2": {
"input_token": "nextToken",
"output_token": "nextToken",
"limit_key": "maxResults",
"result_key": "findings"
},
"ListPolicyGenerations": {
"input_token": "nextToken",
"output_token": "nextToken",
"limit_key": "maxResults",
"result_key": "policyGenerations"
},
"ValidatePolicy": {
"input_token": "nextToken",
"output_token": "nextToken",
"limit_key": "maxResults",
"result_key": "findings"
}
}
}

View file

@ -1,3 +0,0 @@
<?php
// This file was auto-generated from sdk-root/src/data/accessanalyzer/2019-11-01/paginators-1.json
return [ 'pagination' => [ 'GetFindingRecommendation' => [ 'input_token' => 'nextToken', 'output_token' => 'nextToken', 'limit_key' => 'maxResults', 'result_key' => 'recommendedSteps', ], 'GetFindingV2' => [ 'input_token' => 'nextToken', 'output_token' => 'nextToken', 'limit_key' => 'maxResults', 'result_key' => 'findingDetails', ], 'ListAccessPreviewFindings' => [ 'input_token' => 'nextToken', 'output_token' => 'nextToken', 'limit_key' => 'maxResults', 'result_key' => 'findings', ], 'ListAccessPreviews' => [ 'input_token' => 'nextToken', 'output_token' => 'nextToken', 'limit_key' => 'maxResults', 'result_key' => 'accessPreviews', ], 'ListAnalyzedResources' => [ 'input_token' => 'nextToken', 'output_token' => 'nextToken', 'limit_key' => 'maxResults', 'result_key' => 'analyzedResources', ], 'ListAnalyzers' => [ 'input_token' => 'nextToken', 'output_token' => 'nextToken', 'limit_key' => 'maxResults', 'result_key' => 'analyzers', ], 'ListArchiveRules' => [ 'input_token' => 'nextToken', 'output_token' => 'nextToken', 'limit_key' => 'maxResults', 'result_key' => 'archiveRules', ], 'ListFindings' => [ 'input_token' => 'nextToken', 'output_token' => 'nextToken', 'limit_key' => 'maxResults', 'result_key' => 'findings', ], 'ListFindingsV2' => [ 'input_token' => 'nextToken', 'output_token' => 'nextToken', 'limit_key' => 'maxResults', 'result_key' => 'findings', ], 'ListPolicyGenerations' => [ 'input_token' => 'nextToken', 'output_token' => 'nextToken', 'limit_key' => 'maxResults', 'result_key' => 'policyGenerations', ], 'ValidatePolicy' => [ 'input_token' => 'nextToken', 'output_token' => 'nextToken', 'limit_key' => 'maxResults', 'result_key' => 'findings', ], ],];

View file

@ -1,42 +0,0 @@
{
"version" : 2,
"waiters" : {
"PolicyPreviewConfigurationActive" : {
"delay" : 5,
"maxAttempts" : 24,
"operation" : "GetPolicyPreviewConfiguration",
"acceptors" : [ {
"matcher" : "pathAll",
"argument" : "policyPreviewConfigurations[].status",
"state" : "success",
"expected" : "ACTIVE"
}, {
"matcher" : "pathAny",
"argument" : "policyPreviewConfigurations[].status",
"state" : "failure",
"expected" : "FAILED"
} ]
},
"PolicyPreviewJobCompleted" : {
"delay" : 30,
"maxAttempts" : 5,
"operation" : "GetPolicyPreviewJob",
"acceptors" : [ {
"matcher" : "path",
"argument" : "jobDetails.jobStatus",
"state" : "success",
"expected" : "COMPLETED"
}, {
"matcher" : "path",
"argument" : "jobDetails.jobStatus",
"state" : "failure",
"expected" : "FAILED"
}, {
"matcher" : "path",
"argument" : "jobDetails.jobStatus",
"state" : "failure",
"expected" : "CANCELED"
} ]
}
}
}

View file

@ -1,3 +0,0 @@
<?php
// This file was auto-generated from sdk-root/src/data/accessanalyzer/2019-11-01/waiters-2.json
return [ 'version' => 2, 'waiters' => [ 'PolicyPreviewConfigurationActive' => [ 'delay' => 5, 'maxAttempts' => 24, 'operation' => 'GetPolicyPreviewConfiguration', 'acceptors' => [ [ 'matcher' => 'pathAll', 'argument' => 'policyPreviewConfigurations[].status', 'state' => 'success', 'expected' => 'ACTIVE', ], [ 'matcher' => 'pathAny', 'argument' => 'policyPreviewConfigurations[].status', 'state' => 'failure', 'expected' => 'FAILED', ], ], ], 'PolicyPreviewJobCompleted' => [ 'delay' => 30, 'maxAttempts' => 5, 'operation' => 'GetPolicyPreviewJob', 'acceptors' => [ [ 'matcher' => 'path', 'argument' => 'jobDetails.jobStatus', 'state' => 'success', 'expected' => 'COMPLETED', ], [ 'matcher' => 'path', 'argument' => 'jobDetails.jobStatus', 'state' => 'failure', 'expected' => 'FAILED', ], [ 'matcher' => 'path', 'argument' => 'jobDetails.jobStatus', 'state' => 'failure', 'expected' => 'CANCELED', ], ], ], ],];

Some files were not shown because too many files have changed in this diff Show more