@aws-sdk/client-accessanalyzer 3.592.0 → 3.596.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +24 -0
- package/dist-cjs/index.js +241 -1
- package/dist-es/AccessAnalyzer.js +6 -0
- package/dist-es/commands/CheckNoPublicAccessCommand.js +25 -0
- package/dist-es/commands/GenerateFindingRecommendationCommand.js +24 -0
- package/dist-es/commands/GetFindingRecommendationCommand.js +24 -0
- package/dist-es/commands/index.js +3 -0
- package/dist-es/models/models_0.js +49 -0
- package/dist-es/pagination/GetFindingRecommendationPaginator.js +4 -0
- package/dist-es/pagination/index.js +1 -0
- package/dist-es/protocols/Aws_restJson1.js +111 -0
- package/dist-types/AccessAnalyzer.d.ts +21 -0
- package/dist-types/AccessAnalyzerClient.d.ts +5 -2
- package/dist-types/commands/CheckAccessNotGrantedCommand.d.ts +86 -1
- package/dist-types/commands/CheckNoPublicAccessCommand.d.ts +131 -0
- package/dist-types/commands/GenerateFindingRecommendationCommand.d.ts +95 -0
- package/dist-types/commands/GetFindingRecommendationCommand.d.ts +194 -0
- package/dist-types/commands/index.d.ts +3 -0
- package/dist-types/models/models_0.d.ts +308 -5
- package/dist-types/pagination/GetFindingRecommendationPaginator.d.ts +7 -0
- package/dist-types/pagination/index.d.ts +1 -0
- package/dist-types/protocols/Aws_restJson1.d.ts +27 -0
- package/dist-types/ts3.4/AccessAnalyzer.d.ts +51 -0
- package/dist-types/ts3.4/AccessAnalyzerClient.d.ts +18 -0
- package/dist-types/ts3.4/commands/CheckNoPublicAccessCommand.d.ts +40 -0
- package/dist-types/ts3.4/commands/GenerateFindingRecommendationCommand.d.ts +36 -0
- package/dist-types/ts3.4/commands/GetFindingRecommendationCommand.d.ts +40 -0
- package/dist-types/ts3.4/commands/index.d.ts +3 -0
- package/dist-types/ts3.4/models/models_0.d.ts +110 -1
- package/dist-types/ts3.4/pagination/GetFindingRecommendationPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/index.d.ts +1 -0
- package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +36 -0
- package/package.json +4 -4
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
import { Command as $Command } from "@smithy/smithy-client";
|
|
2
|
+
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
+
import { AccessAnalyzerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../AccessAnalyzerClient";
|
|
4
|
+
import { GenerateFindingRecommendationRequest } from "../models/models_0";
|
|
5
|
+
/**
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
8
|
+
export type { __MetadataBearer };
|
|
9
|
+
export { $Command };
|
|
10
|
+
/**
|
|
11
|
+
* @public
|
|
12
|
+
*
|
|
13
|
+
* The input for {@link GenerateFindingRecommendationCommand}.
|
|
14
|
+
*/
|
|
15
|
+
export interface GenerateFindingRecommendationCommandInput extends GenerateFindingRecommendationRequest {
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* @public
|
|
19
|
+
*
|
|
20
|
+
* The output of {@link GenerateFindingRecommendationCommand}.
|
|
21
|
+
*/
|
|
22
|
+
export interface GenerateFindingRecommendationCommandOutput extends __MetadataBearer {
|
|
23
|
+
}
|
|
24
|
+
declare const GenerateFindingRecommendationCommand_base: {
|
|
25
|
+
new (input: GenerateFindingRecommendationCommandInput): import("@smithy/smithy-client").CommandImpl<GenerateFindingRecommendationCommandInput, GenerateFindingRecommendationCommandOutput, AccessAnalyzerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
|
|
26
|
+
new (__0_0: GenerateFindingRecommendationCommandInput): import("@smithy/smithy-client").CommandImpl<GenerateFindingRecommendationCommandInput, GenerateFindingRecommendationCommandOutput, AccessAnalyzerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
|
|
27
|
+
getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
|
|
28
|
+
};
|
|
29
|
+
/**
|
|
30
|
+
* <p>Creates a recommendation for an unused permissions finding.</p>
|
|
31
|
+
* @example
|
|
32
|
+
* Use a bare-bones client and the command you need to make an API call.
|
|
33
|
+
* ```javascript
|
|
34
|
+
* import { AccessAnalyzerClient, GenerateFindingRecommendationCommand } from "@aws-sdk/client-accessanalyzer"; // ES Modules import
|
|
35
|
+
* // const { AccessAnalyzerClient, GenerateFindingRecommendationCommand } = require("@aws-sdk/client-accessanalyzer"); // CommonJS import
|
|
36
|
+
* const client = new AccessAnalyzerClient(config);
|
|
37
|
+
* const input = { // GenerateFindingRecommendationRequest
|
|
38
|
+
* analyzerArn: "STRING_VALUE", // required
|
|
39
|
+
* id: "STRING_VALUE", // required
|
|
40
|
+
* };
|
|
41
|
+
* const command = new GenerateFindingRecommendationCommand(input);
|
|
42
|
+
* const response = await client.send(command);
|
|
43
|
+
* // {};
|
|
44
|
+
*
|
|
45
|
+
* ```
|
|
46
|
+
*
|
|
47
|
+
* @param GenerateFindingRecommendationCommandInput - {@link GenerateFindingRecommendationCommandInput}
|
|
48
|
+
* @returns {@link GenerateFindingRecommendationCommandOutput}
|
|
49
|
+
* @see {@link GenerateFindingRecommendationCommandInput} for command's `input` shape.
|
|
50
|
+
* @see {@link GenerateFindingRecommendationCommandOutput} for command's `response` shape.
|
|
51
|
+
* @see {@link AccessAnalyzerClientResolvedConfig | config} for AccessAnalyzerClient's `config` shape.
|
|
52
|
+
*
|
|
53
|
+
* @throws {@link AccessDeniedException} (client fault)
|
|
54
|
+
* <p>You do not have sufficient access to perform this action.</p>
|
|
55
|
+
*
|
|
56
|
+
* @throws {@link InternalServerException} (server fault)
|
|
57
|
+
* <p>Internal server error.</p>
|
|
58
|
+
*
|
|
59
|
+
* @throws {@link ThrottlingException} (client fault)
|
|
60
|
+
* <p>Throttling limit exceeded error.</p>
|
|
61
|
+
*
|
|
62
|
+
* @throws {@link ValidationException} (client fault)
|
|
63
|
+
* <p>Validation exception error.</p>
|
|
64
|
+
*
|
|
65
|
+
* @throws {@link AccessAnalyzerServiceException}
|
|
66
|
+
* <p>Base exception class for all service exceptions from AccessAnalyzer service.</p>
|
|
67
|
+
*
|
|
68
|
+
* @public
|
|
69
|
+
* @example Successfully started generating finding recommendation
|
|
70
|
+
* ```javascript
|
|
71
|
+
* //
|
|
72
|
+
* const input = {
|
|
73
|
+
* "analyzerArn": "arn:aws:access-analyzer:us-east-1:111122223333:analyzer/a",
|
|
74
|
+
* "id": "finding-id"
|
|
75
|
+
* };
|
|
76
|
+
* const command = new GenerateFindingRecommendationCommand(input);
|
|
77
|
+
* await client.send(command);
|
|
78
|
+
* // example id: example-1
|
|
79
|
+
* ```
|
|
80
|
+
*
|
|
81
|
+
* @example Failed field validation for id value
|
|
82
|
+
* ```javascript
|
|
83
|
+
* //
|
|
84
|
+
* const input = {
|
|
85
|
+
* "analyzerArn": "arn:aws:access-analyzer:us-east-1:111122223333:analyzer/a",
|
|
86
|
+
* "id": "!"
|
|
87
|
+
* };
|
|
88
|
+
* const command = new GenerateFindingRecommendationCommand(input);
|
|
89
|
+
* await client.send(command);
|
|
90
|
+
* // example id: example-2
|
|
91
|
+
* ```
|
|
92
|
+
*
|
|
93
|
+
*/
|
|
94
|
+
export declare class GenerateFindingRecommendationCommand extends GenerateFindingRecommendationCommand_base {
|
|
95
|
+
}
|
|
@@ -0,0 +1,194 @@
|
|
|
1
|
+
import { Command as $Command } from "@smithy/smithy-client";
|
|
2
|
+
import { MetadataBearer as __MetadataBearer } from "@smithy/types";
|
|
3
|
+
import { AccessAnalyzerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../AccessAnalyzerClient";
|
|
4
|
+
import { GetFindingRecommendationRequest, GetFindingRecommendationResponse } from "../models/models_0";
|
|
5
|
+
/**
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
8
|
+
export type { __MetadataBearer };
|
|
9
|
+
export { $Command };
|
|
10
|
+
/**
|
|
11
|
+
* @public
|
|
12
|
+
*
|
|
13
|
+
* The input for {@link GetFindingRecommendationCommand}.
|
|
14
|
+
*/
|
|
15
|
+
export interface GetFindingRecommendationCommandInput extends GetFindingRecommendationRequest {
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* @public
|
|
19
|
+
*
|
|
20
|
+
* The output of {@link GetFindingRecommendationCommand}.
|
|
21
|
+
*/
|
|
22
|
+
export interface GetFindingRecommendationCommandOutput extends GetFindingRecommendationResponse, __MetadataBearer {
|
|
23
|
+
}
|
|
24
|
+
declare const GetFindingRecommendationCommand_base: {
|
|
25
|
+
new (input: GetFindingRecommendationCommandInput): import("@smithy/smithy-client").CommandImpl<GetFindingRecommendationCommandInput, GetFindingRecommendationCommandOutput, AccessAnalyzerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
|
|
26
|
+
new (__0_0: GetFindingRecommendationCommandInput): import("@smithy/smithy-client").CommandImpl<GetFindingRecommendationCommandInput, GetFindingRecommendationCommandOutput, AccessAnalyzerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
|
|
27
|
+
getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
|
|
28
|
+
};
|
|
29
|
+
/**
|
|
30
|
+
* <p>Retrieves information about a finding recommendation for the specified analyzer.</p>
|
|
31
|
+
* @example
|
|
32
|
+
* Use a bare-bones client and the command you need to make an API call.
|
|
33
|
+
* ```javascript
|
|
34
|
+
* import { AccessAnalyzerClient, GetFindingRecommendationCommand } from "@aws-sdk/client-accessanalyzer"; // ES Modules import
|
|
35
|
+
* // const { AccessAnalyzerClient, GetFindingRecommendationCommand } = require("@aws-sdk/client-accessanalyzer"); // CommonJS import
|
|
36
|
+
* const client = new AccessAnalyzerClient(config);
|
|
37
|
+
* const input = { // GetFindingRecommendationRequest
|
|
38
|
+
* analyzerArn: "STRING_VALUE", // required
|
|
39
|
+
* id: "STRING_VALUE", // required
|
|
40
|
+
* maxResults: Number("int"),
|
|
41
|
+
* nextToken: "STRING_VALUE",
|
|
42
|
+
* };
|
|
43
|
+
* const command = new GetFindingRecommendationCommand(input);
|
|
44
|
+
* const response = await client.send(command);
|
|
45
|
+
* // { // GetFindingRecommendationResponse
|
|
46
|
+
* // startedAt: new Date("TIMESTAMP"), // required
|
|
47
|
+
* // completedAt: new Date("TIMESTAMP"),
|
|
48
|
+
* // nextToken: "STRING_VALUE",
|
|
49
|
+
* // error: { // RecommendationError
|
|
50
|
+
* // code: "STRING_VALUE", // required
|
|
51
|
+
* // message: "STRING_VALUE", // required
|
|
52
|
+
* // },
|
|
53
|
+
* // resourceArn: "STRING_VALUE", // required
|
|
54
|
+
* // recommendedSteps: [ // RecommendedStepList
|
|
55
|
+
* // { // RecommendedStep Union: only one key present
|
|
56
|
+
* // unusedPermissionsRecommendedStep: { // UnusedPermissionsRecommendedStep
|
|
57
|
+
* // policyUpdatedAt: new Date("TIMESTAMP"),
|
|
58
|
+
* // recommendedAction: "STRING_VALUE", // required
|
|
59
|
+
* // recommendedPolicy: "STRING_VALUE",
|
|
60
|
+
* // existingPolicyId: "STRING_VALUE",
|
|
61
|
+
* // },
|
|
62
|
+
* // },
|
|
63
|
+
* // ],
|
|
64
|
+
* // recommendationType: "STRING_VALUE", // required
|
|
65
|
+
* // status: "STRING_VALUE", // required
|
|
66
|
+
* // };
|
|
67
|
+
*
|
|
68
|
+
* ```
|
|
69
|
+
*
|
|
70
|
+
* @param GetFindingRecommendationCommandInput - {@link GetFindingRecommendationCommandInput}
|
|
71
|
+
* @returns {@link GetFindingRecommendationCommandOutput}
|
|
72
|
+
* @see {@link GetFindingRecommendationCommandInput} for command's `input` shape.
|
|
73
|
+
* @see {@link GetFindingRecommendationCommandOutput} for command's `response` shape.
|
|
74
|
+
* @see {@link AccessAnalyzerClientResolvedConfig | config} for AccessAnalyzerClient's `config` shape.
|
|
75
|
+
*
|
|
76
|
+
* @throws {@link AccessDeniedException} (client fault)
|
|
77
|
+
* <p>You do not have sufficient access to perform this action.</p>
|
|
78
|
+
*
|
|
79
|
+
* @throws {@link InternalServerException} (server fault)
|
|
80
|
+
* <p>Internal server error.</p>
|
|
81
|
+
*
|
|
82
|
+
* @throws {@link ResourceNotFoundException} (client fault)
|
|
83
|
+
* <p>The specified resource could not be found.</p>
|
|
84
|
+
*
|
|
85
|
+
* @throws {@link ThrottlingException} (client fault)
|
|
86
|
+
* <p>Throttling limit exceeded error.</p>
|
|
87
|
+
*
|
|
88
|
+
* @throws {@link ValidationException} (client fault)
|
|
89
|
+
* <p>Validation exception error.</p>
|
|
90
|
+
*
|
|
91
|
+
* @throws {@link AccessAnalyzerServiceException}
|
|
92
|
+
* <p>Base exception class for all service exceptions from AccessAnalyzer service.</p>
|
|
93
|
+
*
|
|
94
|
+
* @public
|
|
95
|
+
* @example Successfully fetched finding recommendation
|
|
96
|
+
* ```javascript
|
|
97
|
+
* //
|
|
98
|
+
* const input = {
|
|
99
|
+
* "analyzerArn": "arn:aws:access-analyzer:us-east-1:111122223333:analyzer/a",
|
|
100
|
+
* "id": "finding-id",
|
|
101
|
+
* "maxResults": 3,
|
|
102
|
+
* "nextToken": "token"
|
|
103
|
+
* };
|
|
104
|
+
* const command = new GetFindingRecommendationCommand(input);
|
|
105
|
+
* const response = await client.send(command);
|
|
106
|
+
* /* response ==
|
|
107
|
+
* {
|
|
108
|
+
* "completedAt": "2000-01-01T00:00:01Z",
|
|
109
|
+
* "recommendationType": "UnusedPermissionRecommendation",
|
|
110
|
+
* "recommendedSteps": [
|
|
111
|
+
* {
|
|
112
|
+
* "unusedPermissionsRecommendedStep": {
|
|
113
|
+
* "existingPolicyId": "policy-id",
|
|
114
|
+
* "recommendedAction": "DETACH_POLICY"
|
|
115
|
+
* }
|
|
116
|
+
* },
|
|
117
|
+
* {
|
|
118
|
+
* "unusedPermissionsRecommendedStep": {
|
|
119
|
+
* "existingPolicyId": "policy-id",
|
|
120
|
+
* "recommendedAction": "CREATE_POLICY",
|
|
121
|
+
* "recommendedPolicy": "policy-content"
|
|
122
|
+
* }
|
|
123
|
+
* }
|
|
124
|
+
* ],
|
|
125
|
+
* "resourceArn": "arn:aws:iam::111122223333:role/test",
|
|
126
|
+
* "startedAt": "2000-01-01T00:00:00Z",
|
|
127
|
+
* "status": "SUCCEEDED"
|
|
128
|
+
* }
|
|
129
|
+
* *\/
|
|
130
|
+
* // example id: example-1
|
|
131
|
+
* ```
|
|
132
|
+
*
|
|
133
|
+
* @example In progress finding recommendation
|
|
134
|
+
* ```javascript
|
|
135
|
+
* //
|
|
136
|
+
* const input = {
|
|
137
|
+
* "analyzerArn": "arn:aws:access-analyzer:us-east-1:111122223333:analyzer/a",
|
|
138
|
+
* "id": "finding-id",
|
|
139
|
+
* "maxResults": 3
|
|
140
|
+
* };
|
|
141
|
+
* const command = new GetFindingRecommendationCommand(input);
|
|
142
|
+
* const response = await client.send(command);
|
|
143
|
+
* /* response ==
|
|
144
|
+
* {
|
|
145
|
+
* "recommendationType": "UnusedPermissionRecommendation",
|
|
146
|
+
* "resourceArn": "arn:aws:iam::111122223333:role/test",
|
|
147
|
+
* "startedAt": "2000-01-01T00:00:00Z",
|
|
148
|
+
* "status": "IN_PROGRESS"
|
|
149
|
+
* }
|
|
150
|
+
* *\/
|
|
151
|
+
* // example id: example-2
|
|
152
|
+
* ```
|
|
153
|
+
*
|
|
154
|
+
* @example Failed finding recommendation
|
|
155
|
+
* ```javascript
|
|
156
|
+
* //
|
|
157
|
+
* const input = {
|
|
158
|
+
* "analyzerArn": "arn:aws:access-analyzer:us-east-1:111122223333:analyzer/a",
|
|
159
|
+
* "id": "finding-id",
|
|
160
|
+
* "maxResults": 3
|
|
161
|
+
* };
|
|
162
|
+
* const command = new GetFindingRecommendationCommand(input);
|
|
163
|
+
* const response = await client.send(command);
|
|
164
|
+
* /* response ==
|
|
165
|
+
* {
|
|
166
|
+
* "completedAt": "2000-01-01T00:00:01Z",
|
|
167
|
+
* "error": {
|
|
168
|
+
* "code": "SERVICE_ERROR",
|
|
169
|
+
* "message": "Service error. Please try again."
|
|
170
|
+
* },
|
|
171
|
+
* "recommendationType": "UnusedPermissionRecommendation",
|
|
172
|
+
* "resourceArn": "arn:aws:iam::111122223333:role/test",
|
|
173
|
+
* "startedAt": "2000-01-01T00:00:00Z",
|
|
174
|
+
* "status": "FAILED"
|
|
175
|
+
* }
|
|
176
|
+
* *\/
|
|
177
|
+
* // example id: example-3
|
|
178
|
+
* ```
|
|
179
|
+
*
|
|
180
|
+
* @example Failed field validation for id value
|
|
181
|
+
* ```javascript
|
|
182
|
+
* //
|
|
183
|
+
* const input = {
|
|
184
|
+
* "analyzerArn": "arn:aws:access-analyzer:us-east-1:111122223333:analyzer/a",
|
|
185
|
+
* "id": "!"
|
|
186
|
+
* };
|
|
187
|
+
* const command = new GetFindingRecommendationCommand(input);
|
|
188
|
+
* await client.send(command);
|
|
189
|
+
* // example id: example-4
|
|
190
|
+
* ```
|
|
191
|
+
*
|
|
192
|
+
*/
|
|
193
|
+
export declare class GetFindingRecommendationCommand extends GetFindingRecommendationCommand_base {
|
|
194
|
+
}
|
|
@@ -2,16 +2,19 @@ export * from "./ApplyArchiveRuleCommand";
|
|
|
2
2
|
export * from "./CancelPolicyGenerationCommand";
|
|
3
3
|
export * from "./CheckAccessNotGrantedCommand";
|
|
4
4
|
export * from "./CheckNoNewAccessCommand";
|
|
5
|
+
export * from "./CheckNoPublicAccessCommand";
|
|
5
6
|
export * from "./CreateAccessPreviewCommand";
|
|
6
7
|
export * from "./CreateAnalyzerCommand";
|
|
7
8
|
export * from "./CreateArchiveRuleCommand";
|
|
8
9
|
export * from "./DeleteAnalyzerCommand";
|
|
9
10
|
export * from "./DeleteArchiveRuleCommand";
|
|
11
|
+
export * from "./GenerateFindingRecommendationCommand";
|
|
10
12
|
export * from "./GetAccessPreviewCommand";
|
|
11
13
|
export * from "./GetAnalyzedResourceCommand";
|
|
12
14
|
export * from "./GetAnalyzerCommand";
|
|
13
15
|
export * from "./GetArchiveRuleCommand";
|
|
14
16
|
export * from "./GetFindingCommand";
|
|
17
|
+
export * from "./GetFindingRecommendationCommand";
|
|
15
18
|
export * from "./GetFindingV2Command";
|
|
16
19
|
export * from "./GetGeneratedPolicyCommand";
|
|
17
20
|
export * from "./ListAccessPreviewFindingsCommand";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { ExceptionOptionType as __ExceptionOptionType } from "@smithy/smithy-client";
|
|
2
2
|
import { AccessAnalyzerServiceException as __BaseException } from "./AccessAnalyzerServiceException";
|
|
3
3
|
/**
|
|
4
|
-
* <p>Contains information about actions that define permissions to check
|
|
5
|
-
* policy.</p>
|
|
4
|
+
* <p>Contains information about actions and resources that define permissions to check
|
|
5
|
+
* against a policy.</p>
|
|
6
6
|
* @public
|
|
7
7
|
*/
|
|
8
8
|
export interface Access {
|
|
@@ -11,7 +11,13 @@ export interface Access {
|
|
|
11
11
|
* in an IAM policy can be used in the list of actions to check.</p>
|
|
12
12
|
* @public
|
|
13
13
|
*/
|
|
14
|
-
actions
|
|
14
|
+
actions?: string[];
|
|
15
|
+
/**
|
|
16
|
+
* <p>A list of resources for the access permissions. Any strings that can be used as a
|
|
17
|
+
* resource in an IAM policy can be used in the list of resources to check.</p>
|
|
18
|
+
* @public
|
|
19
|
+
*/
|
|
20
|
+
resources?: string[];
|
|
15
21
|
}
|
|
16
22
|
/**
|
|
17
23
|
* <p>You do not have sufficient access to perform this action.</p>
|
|
@@ -206,6 +212,7 @@ export interface ValidationExceptionField {
|
|
|
206
212
|
export declare const ValidationExceptionReason: {
|
|
207
213
|
readonly CANNOT_PARSE: "cannotParse";
|
|
208
214
|
readonly FIELD_VALIDATION_FAILED: "fieldValidationFailed";
|
|
215
|
+
readonly NOT_SUPPORTED: "notSupported";
|
|
209
216
|
readonly OTHER: "other";
|
|
210
217
|
readonly UNKNOWN_OPERATION: "unknownOperation";
|
|
211
218
|
};
|
|
@@ -720,7 +727,11 @@ export interface CheckAccessNotGrantedRequest {
|
|
|
720
727
|
policyDocument: string | undefined;
|
|
721
728
|
/**
|
|
722
729
|
* <p>An access object containing the permissions that shouldn't be granted by the specified
|
|
723
|
-
* policy
|
|
730
|
+
* policy. If only actions are specified, IAM Access Analyzer checks for access of the actions on
|
|
731
|
+
* all resources in the policy. If only resources are specified, then IAM Access Analyzer checks
|
|
732
|
+
* which actions have access to the specified resources. If both actions and resources are
|
|
733
|
+
* specified, then IAM Access Analyzer checks which of the specified actions have access to the
|
|
734
|
+
* specified resources.</p>
|
|
724
735
|
* @public
|
|
725
736
|
*/
|
|
726
737
|
access: Access[] | undefined;
|
|
@@ -876,6 +887,90 @@ export interface CheckNoNewAccessResponse {
|
|
|
876
887
|
*/
|
|
877
888
|
reasons?: ReasonSummary[];
|
|
878
889
|
}
|
|
890
|
+
/**
|
|
891
|
+
* @public
|
|
892
|
+
* @enum
|
|
893
|
+
*/
|
|
894
|
+
export declare const AccessCheckResourceType: {
|
|
895
|
+
readonly DYNAMODB_STREAM: "AWS::DynamoDB::Stream";
|
|
896
|
+
readonly DYNAMODB_TABLE: "AWS::DynamoDB::Table";
|
|
897
|
+
readonly EFS_FILESYSTEM: "AWS::EFS::FileSystem";
|
|
898
|
+
readonly KINESIS_DATA_STREAM: "AWS::Kinesis::Stream";
|
|
899
|
+
readonly KINESIS_STREAM_CONSUMER: "AWS::Kinesis::StreamConsumer";
|
|
900
|
+
readonly KMS_KEY: "AWS::KMS::Key";
|
|
901
|
+
readonly LAMBDA_FUNCTION: "AWS::Lambda::Function";
|
|
902
|
+
readonly OPENSEARCHSERVICE_DOMAIN: "AWS::OpenSearchService::Domain";
|
|
903
|
+
readonly ROLE_TRUST: "AWS::IAM::AssumeRolePolicyDocument";
|
|
904
|
+
readonly S3EXPRESS_DIRECTORYBUCKET: "AWS::S3Express::DirectoryBucket";
|
|
905
|
+
readonly S3_ACCESS_POINT: "AWS::S3::AccessPoint";
|
|
906
|
+
readonly S3_BUCKET: "AWS::S3::Bucket";
|
|
907
|
+
readonly S3_GLACIER: "AWS::S3::Glacier";
|
|
908
|
+
readonly S3_OUTPOSTS_ACCESS_POINT: "AWS::S3Outposts::AccessPoint";
|
|
909
|
+
readonly S3_OUTPOSTS_BUCKET: "AWS::S3Outposts::Bucket";
|
|
910
|
+
readonly SECRETSMANAGER_SECRET: "AWS::SecretsManager::Secret";
|
|
911
|
+
readonly SNS_TOPIC: "AWS::SNS::Topic";
|
|
912
|
+
readonly SQS_QUEUE: "AWS::SQS::Queue";
|
|
913
|
+
};
|
|
914
|
+
/**
|
|
915
|
+
* @public
|
|
916
|
+
*/
|
|
917
|
+
export type AccessCheckResourceType = (typeof AccessCheckResourceType)[keyof typeof AccessCheckResourceType];
|
|
918
|
+
/**
|
|
919
|
+
* @public
|
|
920
|
+
*/
|
|
921
|
+
export interface CheckNoPublicAccessRequest {
|
|
922
|
+
/**
|
|
923
|
+
* <p>The JSON policy document to evaluate for public access.</p>
|
|
924
|
+
* @public
|
|
925
|
+
*/
|
|
926
|
+
policyDocument: string | undefined;
|
|
927
|
+
/**
|
|
928
|
+
* <p>The type of resource to evaluate for public access. For example, to check for public
|
|
929
|
+
* access to Amazon S3 buckets, you can choose <code>AWS::S3::Bucket</code> for the resource
|
|
930
|
+
* type.</p>
|
|
931
|
+
* <p>For resource types not supported as valid values, IAM Access Analyzer will return an
|
|
932
|
+
* error.</p>
|
|
933
|
+
* @public
|
|
934
|
+
*/
|
|
935
|
+
resourceType: AccessCheckResourceType | undefined;
|
|
936
|
+
}
|
|
937
|
+
/**
|
|
938
|
+
* @public
|
|
939
|
+
* @enum
|
|
940
|
+
*/
|
|
941
|
+
export declare const CheckNoPublicAccessResult: {
|
|
942
|
+
readonly FAIL: "FAIL";
|
|
943
|
+
readonly PASS: "PASS";
|
|
944
|
+
};
|
|
945
|
+
/**
|
|
946
|
+
* @public
|
|
947
|
+
*/
|
|
948
|
+
export type CheckNoPublicAccessResult = (typeof CheckNoPublicAccessResult)[keyof typeof CheckNoPublicAccessResult];
|
|
949
|
+
/**
|
|
950
|
+
* @public
|
|
951
|
+
*/
|
|
952
|
+
export interface CheckNoPublicAccessResponse {
|
|
953
|
+
/**
|
|
954
|
+
* <p>The result of the check for public access to the specified resource type. If the result
|
|
955
|
+
* is <code>PASS</code>, the policy doesn't allow public access to the specified resource
|
|
956
|
+
* type. If the result is <code>FAIL</code>, the policy might allow public access to the
|
|
957
|
+
* specified resource type.</p>
|
|
958
|
+
* @public
|
|
959
|
+
*/
|
|
960
|
+
result?: CheckNoPublicAccessResult;
|
|
961
|
+
/**
|
|
962
|
+
* <p>The message indicating whether the specified policy allows public access to
|
|
963
|
+
* resources.</p>
|
|
964
|
+
* @public
|
|
965
|
+
*/
|
|
966
|
+
message?: string;
|
|
967
|
+
/**
|
|
968
|
+
* <p>A list of reasons why the specified resource policy grants public access for the
|
|
969
|
+
* resource type.</p>
|
|
970
|
+
* @public
|
|
971
|
+
*/
|
|
972
|
+
reasons?: ReasonSummary[];
|
|
973
|
+
}
|
|
879
974
|
/**
|
|
880
975
|
* <p>The proposed access control configuration for a DynamoDB stream. You can propose a
|
|
881
976
|
* configuration for a new DynamoDB stream or an existing DynamoDB stream that you own by specifying
|
|
@@ -2075,6 +2170,22 @@ export interface CreateAccessPreviewResponse {
|
|
|
2075
2170
|
*/
|
|
2076
2171
|
id: string | undefined;
|
|
2077
2172
|
}
|
|
2173
|
+
/**
|
|
2174
|
+
* @public
|
|
2175
|
+
*/
|
|
2176
|
+
export interface GenerateFindingRecommendationRequest {
|
|
2177
|
+
/**
|
|
2178
|
+
* <p>The <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access-analyzer-getting-started.html#permission-resources">ARN of
|
|
2179
|
+
* the analyzer</a> used to generate the finding recommendation.</p>
|
|
2180
|
+
* @public
|
|
2181
|
+
*/
|
|
2182
|
+
analyzerArn: string | undefined;
|
|
2183
|
+
/**
|
|
2184
|
+
* <p>The unique ID for the finding recommendation.</p>
|
|
2185
|
+
* @public
|
|
2186
|
+
*/
|
|
2187
|
+
id: string | undefined;
|
|
2188
|
+
}
|
|
2078
2189
|
/**
|
|
2079
2190
|
* @public
|
|
2080
2191
|
*/
|
|
@@ -2442,6 +2553,194 @@ export interface GetFindingResponse {
|
|
|
2442
2553
|
*/
|
|
2443
2554
|
finding?: Finding;
|
|
2444
2555
|
}
|
|
2556
|
+
/**
|
|
2557
|
+
* @public
|
|
2558
|
+
*/
|
|
2559
|
+
export interface GetFindingRecommendationRequest {
|
|
2560
|
+
/**
|
|
2561
|
+
* <p>The <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access-analyzer-getting-started.html#permission-resources">ARN of
|
|
2562
|
+
* the analyzer</a> used to generate the finding recommendation.</p>
|
|
2563
|
+
* @public
|
|
2564
|
+
*/
|
|
2565
|
+
analyzerArn: string | undefined;
|
|
2566
|
+
/**
|
|
2567
|
+
* <p>The unique ID for the finding recommendation.</p>
|
|
2568
|
+
* @public
|
|
2569
|
+
*/
|
|
2570
|
+
id: string | undefined;
|
|
2571
|
+
/**
|
|
2572
|
+
* <p>The maximum number of results to return in the response.</p>
|
|
2573
|
+
* @public
|
|
2574
|
+
*/
|
|
2575
|
+
maxResults?: number;
|
|
2576
|
+
/**
|
|
2577
|
+
* <p>A token used for pagination of results returned.</p>
|
|
2578
|
+
* @public
|
|
2579
|
+
*/
|
|
2580
|
+
nextToken?: string;
|
|
2581
|
+
}
|
|
2582
|
+
/**
|
|
2583
|
+
* <p>Contains information about the reason that the retrieval of a recommendation for a
|
|
2584
|
+
* finding failed.</p>
|
|
2585
|
+
* @public
|
|
2586
|
+
*/
|
|
2587
|
+
export interface RecommendationError {
|
|
2588
|
+
/**
|
|
2589
|
+
* <p>The error code for a failed retrieval of a recommendation for a finding.</p>
|
|
2590
|
+
* @public
|
|
2591
|
+
*/
|
|
2592
|
+
code: string | undefined;
|
|
2593
|
+
/**
|
|
2594
|
+
* <p>The error message for a failed retrieval of a recommendation for a finding.</p>
|
|
2595
|
+
* @public
|
|
2596
|
+
*/
|
|
2597
|
+
message: string | undefined;
|
|
2598
|
+
}
|
|
2599
|
+
/**
|
|
2600
|
+
* @public
|
|
2601
|
+
* @enum
|
|
2602
|
+
*/
|
|
2603
|
+
export declare const RecommendationType: {
|
|
2604
|
+
readonly UNUSED_PERMISSION_RECOMMENDATION: "UnusedPermissionRecommendation";
|
|
2605
|
+
};
|
|
2606
|
+
/**
|
|
2607
|
+
* @public
|
|
2608
|
+
*/
|
|
2609
|
+
export type RecommendationType = (typeof RecommendationType)[keyof typeof RecommendationType];
|
|
2610
|
+
/**
|
|
2611
|
+
* @public
|
|
2612
|
+
* @enum
|
|
2613
|
+
*/
|
|
2614
|
+
export declare const RecommendedRemediationAction: {
|
|
2615
|
+
readonly CREATE_POLICY: "CREATE_POLICY";
|
|
2616
|
+
readonly DETACH_POLICY: "DETACH_POLICY";
|
|
2617
|
+
};
|
|
2618
|
+
/**
|
|
2619
|
+
* @public
|
|
2620
|
+
*/
|
|
2621
|
+
export type RecommendedRemediationAction = (typeof RecommendedRemediationAction)[keyof typeof RecommendedRemediationAction];
|
|
2622
|
+
/**
|
|
2623
|
+
* <p>Contains information about the action to take for a policy in an unused permissions
|
|
2624
|
+
* finding.</p>
|
|
2625
|
+
* @public
|
|
2626
|
+
*/
|
|
2627
|
+
export interface UnusedPermissionsRecommendedStep {
|
|
2628
|
+
/**
|
|
2629
|
+
* <p>The time at which the existing policy for the unused permissions finding was last
|
|
2630
|
+
* updated.</p>
|
|
2631
|
+
* @public
|
|
2632
|
+
*/
|
|
2633
|
+
policyUpdatedAt?: Date;
|
|
2634
|
+
/**
|
|
2635
|
+
* <p>A recommendation of whether to create or detach a policy for an unused permissions
|
|
2636
|
+
* finding.</p>
|
|
2637
|
+
* @public
|
|
2638
|
+
*/
|
|
2639
|
+
recommendedAction: RecommendedRemediationAction | undefined;
|
|
2640
|
+
/**
|
|
2641
|
+
* <p>If the recommended action for the unused permissions finding is to replace the existing
|
|
2642
|
+
* policy, the contents of the recommended policy to replace the policy specified in the
|
|
2643
|
+
* <code>existingPolicyId</code> field.</p>
|
|
2644
|
+
* @public
|
|
2645
|
+
*/
|
|
2646
|
+
recommendedPolicy?: string;
|
|
2647
|
+
/**
|
|
2648
|
+
* <p>If the recommended action for the unused permissions finding is to detach a policy, the
|
|
2649
|
+
* ID of an existing policy to be detached.</p>
|
|
2650
|
+
* @public
|
|
2651
|
+
*/
|
|
2652
|
+
existingPolicyId?: string;
|
|
2653
|
+
}
|
|
2654
|
+
/**
|
|
2655
|
+
* <p>Contains information about a recommended step for an unused access analyzer
|
|
2656
|
+
* finding.</p>
|
|
2657
|
+
* @public
|
|
2658
|
+
*/
|
|
2659
|
+
export type RecommendedStep = RecommendedStep.UnusedPermissionsRecommendedStepMember | RecommendedStep.$UnknownMember;
|
|
2660
|
+
/**
|
|
2661
|
+
* @public
|
|
2662
|
+
*/
|
|
2663
|
+
export declare namespace RecommendedStep {
|
|
2664
|
+
/**
|
|
2665
|
+
* <p>A recommended step for an unused permissions finding.</p>
|
|
2666
|
+
* @public
|
|
2667
|
+
*/
|
|
2668
|
+
interface UnusedPermissionsRecommendedStepMember {
|
|
2669
|
+
unusedPermissionsRecommendedStep: UnusedPermissionsRecommendedStep;
|
|
2670
|
+
$unknown?: never;
|
|
2671
|
+
}
|
|
2672
|
+
/**
|
|
2673
|
+
* @public
|
|
2674
|
+
*/
|
|
2675
|
+
interface $UnknownMember {
|
|
2676
|
+
unusedPermissionsRecommendedStep?: never;
|
|
2677
|
+
$unknown: [string, any];
|
|
2678
|
+
}
|
|
2679
|
+
interface Visitor<T> {
|
|
2680
|
+
unusedPermissionsRecommendedStep: (value: UnusedPermissionsRecommendedStep) => T;
|
|
2681
|
+
_: (name: string, value: any) => T;
|
|
2682
|
+
}
|
|
2683
|
+
const visit: <T>(value: RecommendedStep, visitor: Visitor<T>) => T;
|
|
2684
|
+
}
|
|
2685
|
+
/**
|
|
2686
|
+
* @public
|
|
2687
|
+
* @enum
|
|
2688
|
+
*/
|
|
2689
|
+
export declare const Status: {
|
|
2690
|
+
readonly FAILED: "FAILED";
|
|
2691
|
+
readonly IN_PROGRESS: "IN_PROGRESS";
|
|
2692
|
+
readonly SUCCEEDED: "SUCCEEDED";
|
|
2693
|
+
};
|
|
2694
|
+
/**
|
|
2695
|
+
* @public
|
|
2696
|
+
*/
|
|
2697
|
+
export type Status = (typeof Status)[keyof typeof Status];
|
|
2698
|
+
/**
|
|
2699
|
+
* @public
|
|
2700
|
+
*/
|
|
2701
|
+
export interface GetFindingRecommendationResponse {
|
|
2702
|
+
/**
|
|
2703
|
+
* <p>The time at which the retrieval of the finding recommendation was started.</p>
|
|
2704
|
+
* @public
|
|
2705
|
+
*/
|
|
2706
|
+
startedAt: Date | undefined;
|
|
2707
|
+
/**
|
|
2708
|
+
* <p>The time at which the retrieval of the finding recommendation was completed.</p>
|
|
2709
|
+
* @public
|
|
2710
|
+
*/
|
|
2711
|
+
completedAt?: Date;
|
|
2712
|
+
/**
|
|
2713
|
+
* <p>A token used for pagination of results returned.</p>
|
|
2714
|
+
* @public
|
|
2715
|
+
*/
|
|
2716
|
+
nextToken?: string;
|
|
2717
|
+
/**
|
|
2718
|
+
* <p>Detailed information about the reason that the retrieval of a recommendation for the
|
|
2719
|
+
* finding failed.</p>
|
|
2720
|
+
* @public
|
|
2721
|
+
*/
|
|
2722
|
+
error?: RecommendationError;
|
|
2723
|
+
/**
|
|
2724
|
+
* <p>The ARN of the resource of the finding.</p>
|
|
2725
|
+
* @public
|
|
2726
|
+
*/
|
|
2727
|
+
resourceArn: string | undefined;
|
|
2728
|
+
/**
|
|
2729
|
+
* <p>A group of recommended steps for the finding.</p>
|
|
2730
|
+
* @public
|
|
2731
|
+
*/
|
|
2732
|
+
recommendedSteps?: RecommendedStep[];
|
|
2733
|
+
/**
|
|
2734
|
+
* <p>The type of recommendation for the finding.</p>
|
|
2735
|
+
* @public
|
|
2736
|
+
*/
|
|
2737
|
+
recommendationType: RecommendationType | undefined;
|
|
2738
|
+
/**
|
|
2739
|
+
* <p>The status of the retrieval of the finding recommendation.</p>
|
|
2740
|
+
* @public
|
|
2741
|
+
*/
|
|
2742
|
+
status: Status | undefined;
|
|
2743
|
+
}
|
|
2445
2744
|
/**
|
|
2446
2745
|
* @public
|
|
2447
2746
|
*/
|
|
@@ -2587,7 +2886,7 @@ export interface UnusedPermissionDetails {
|
|
|
2587
2886
|
*/
|
|
2588
2887
|
serviceNamespace: string | undefined;
|
|
2589
2888
|
/**
|
|
2590
|
-
* <p>The time at which the permission last accessed.</p>
|
|
2889
|
+
* <p>The time at which the permission was last accessed.</p>
|
|
2591
2890
|
* @public
|
|
2592
2891
|
*/
|
|
2593
2892
|
lastAccessed?: Date;
|
|
@@ -4202,3 +4501,7 @@ export declare const CheckAccessNotGrantedRequestFilterSensitiveLog: (obj: Check
|
|
|
4202
4501
|
* @internal
|
|
4203
4502
|
*/
|
|
4204
4503
|
export declare const CheckNoNewAccessRequestFilterSensitiveLog: (obj: CheckNoNewAccessRequest) => any;
|
|
4504
|
+
/**
|
|
4505
|
+
* @internal
|
|
4506
|
+
*/
|
|
4507
|
+
export declare const CheckNoPublicAccessRequestFilterSensitiveLog: (obj: CheckNoPublicAccessRequest) => any;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Paginator } from "@smithy/types";
|
|
2
|
+
import { GetFindingRecommendationCommandInput, GetFindingRecommendationCommandOutput } from "../commands/GetFindingRecommendationCommand";
|
|
3
|
+
import { AccessAnalyzerPaginationConfiguration } from "./Interfaces";
|
|
4
|
+
/**
|
|
5
|
+
* @public
|
|
6
|
+
*/
|
|
7
|
+
export declare const paginateGetFindingRecommendation: (config: AccessAnalyzerPaginationConfiguration, input: GetFindingRecommendationCommandInput, ...rest: any[]) => Paginator<GetFindingRecommendationCommandOutput>;
|