Skip to content

Commit c1da60a

Browse files
author
awstools
committed
feat(client-securitylake): Log sources are now versioned. AWS log sources and custom sources will now come with a version identifier that enables producers to vend multiple schema versions to subscribers. Security Lake API have been refactored to more closely align with AWS API conventions.
1 parent bbff135 commit c1da60a

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+6198
-6653
lines changed

clients/client-securitylake/README.md

Lines changed: 39 additions & 60 deletions
Large diffs are not rendered by default.

clients/client-securitylake/src/SecurityLake.ts

Lines changed: 271 additions & 318 deletions
Large diffs are not rendered by default.

clients/client-securitylake/src/SecurityLakeClient.ts

Lines changed: 84 additions & 101 deletions
Original file line numberDiff line numberDiff line change
@@ -56,82 +56,74 @@ import {
5656
CreateCustomLogSourceCommandInput,
5757
CreateCustomLogSourceCommandOutput,
5858
} from "./commands/CreateCustomLogSourceCommand";
59+
import { CreateDataLakeCommandInput, CreateDataLakeCommandOutput } from "./commands/CreateDataLakeCommand";
5960
import {
60-
CreateDatalakeAutoEnableCommandInput,
61-
CreateDatalakeAutoEnableCommandOutput,
62-
} from "./commands/CreateDatalakeAutoEnableCommand";
63-
import { CreateDatalakeCommandInput, CreateDatalakeCommandOutput } from "./commands/CreateDatalakeCommand";
61+
CreateDataLakeExceptionSubscriptionCommandInput,
62+
CreateDataLakeExceptionSubscriptionCommandOutput,
63+
} from "./commands/CreateDataLakeExceptionSubscriptionCommand";
6464
import {
65-
CreateDatalakeDelegatedAdminCommandInput,
66-
CreateDatalakeDelegatedAdminCommandOutput,
67-
} from "./commands/CreateDatalakeDelegatedAdminCommand";
68-
import {
69-
CreateDatalakeExceptionsSubscriptionCommandInput,
70-
CreateDatalakeExceptionsSubscriptionCommandOutput,
71-
} from "./commands/CreateDatalakeExceptionsSubscriptionCommand";
65+
CreateDataLakeOrganizationConfigurationCommandInput,
66+
CreateDataLakeOrganizationConfigurationCommandOutput,
67+
} from "./commands/CreateDataLakeOrganizationConfigurationCommand";
7268
import { CreateSubscriberCommandInput, CreateSubscriberCommandOutput } from "./commands/CreateSubscriberCommand";
7369
import {
74-
CreateSubscriptionNotificationConfigurationCommandInput,
75-
CreateSubscriptionNotificationConfigurationCommandOutput,
76-
} from "./commands/CreateSubscriptionNotificationConfigurationCommand";
70+
CreateSubscriberNotificationCommandInput,
71+
CreateSubscriberNotificationCommandOutput,
72+
} from "./commands/CreateSubscriberNotificationCommand";
7773
import { DeleteAwsLogSourceCommandInput, DeleteAwsLogSourceCommandOutput } from "./commands/DeleteAwsLogSourceCommand";
7874
import {
7975
DeleteCustomLogSourceCommandInput,
8076
DeleteCustomLogSourceCommandOutput,
8177
} from "./commands/DeleteCustomLogSourceCommand";
78+
import { DeleteDataLakeCommandInput, DeleteDataLakeCommandOutput } from "./commands/DeleteDataLakeCommand";
8279
import {
83-
DeleteDatalakeAutoEnableCommandInput,
84-
DeleteDatalakeAutoEnableCommandOutput,
85-
} from "./commands/DeleteDatalakeAutoEnableCommand";
86-
import { DeleteDatalakeCommandInput, DeleteDatalakeCommandOutput } from "./commands/DeleteDatalakeCommand";
87-
import {
88-
DeleteDatalakeDelegatedAdminCommandInput,
89-
DeleteDatalakeDelegatedAdminCommandOutput,
90-
} from "./commands/DeleteDatalakeDelegatedAdminCommand";
80+
DeleteDataLakeExceptionSubscriptionCommandInput,
81+
DeleteDataLakeExceptionSubscriptionCommandOutput,
82+
} from "./commands/DeleteDataLakeExceptionSubscriptionCommand";
9183
import {
92-
DeleteDatalakeExceptionsSubscriptionCommandInput,
93-
DeleteDatalakeExceptionsSubscriptionCommandOutput,
94-
} from "./commands/DeleteDatalakeExceptionsSubscriptionCommand";
84+
DeleteDataLakeOrganizationConfigurationCommandInput,
85+
DeleteDataLakeOrganizationConfigurationCommandOutput,
86+
} from "./commands/DeleteDataLakeOrganizationConfigurationCommand";
9587
import { DeleteSubscriberCommandInput, DeleteSubscriberCommandOutput } from "./commands/DeleteSubscriberCommand";
9688
import {
97-
DeleteSubscriptionNotificationConfigurationCommandInput,
98-
DeleteSubscriptionNotificationConfigurationCommandOutput,
99-
} from "./commands/DeleteSubscriptionNotificationConfigurationCommand";
89+
DeleteSubscriberNotificationCommandInput,
90+
DeleteSubscriberNotificationCommandOutput,
91+
} from "./commands/DeleteSubscriberNotificationCommand";
10092
import {
101-
GetDatalakeAutoEnableCommandInput,
102-
GetDatalakeAutoEnableCommandOutput,
103-
} from "./commands/GetDatalakeAutoEnableCommand";
104-
import { GetDatalakeCommandInput, GetDatalakeCommandOutput } from "./commands/GetDatalakeCommand";
93+
DeregisterDataLakeDelegatedAdministratorCommandInput,
94+
DeregisterDataLakeDelegatedAdministratorCommandOutput,
95+
} from "./commands/DeregisterDataLakeDelegatedAdministratorCommand";
10596
import {
106-
GetDatalakeExceptionsExpiryCommandInput,
107-
GetDatalakeExceptionsExpiryCommandOutput,
108-
} from "./commands/GetDatalakeExceptionsExpiryCommand";
97+
GetDataLakeExceptionSubscriptionCommandInput,
98+
GetDataLakeExceptionSubscriptionCommandOutput,
99+
} from "./commands/GetDataLakeExceptionSubscriptionCommand";
109100
import {
110-
GetDatalakeExceptionsSubscriptionCommandInput,
111-
GetDatalakeExceptionsSubscriptionCommandOutput,
112-
} from "./commands/GetDatalakeExceptionsSubscriptionCommand";
113-
import { GetDatalakeStatusCommandInput, GetDatalakeStatusCommandOutput } from "./commands/GetDatalakeStatusCommand";
101+
GetDataLakeOrganizationConfigurationCommandInput,
102+
GetDataLakeOrganizationConfigurationCommandOutput,
103+
} from "./commands/GetDataLakeOrganizationConfigurationCommand";
104+
import { GetDataLakeSourcesCommandInput, GetDataLakeSourcesCommandOutput } from "./commands/GetDataLakeSourcesCommand";
114105
import { GetSubscriberCommandInput, GetSubscriberCommandOutput } from "./commands/GetSubscriberCommand";
115106
import {
116-
ListDatalakeExceptionsCommandInput,
117-
ListDatalakeExceptionsCommandOutput,
118-
} from "./commands/ListDatalakeExceptionsCommand";
107+
ListDataLakeExceptionsCommandInput,
108+
ListDataLakeExceptionsCommandOutput,
109+
} from "./commands/ListDataLakeExceptionsCommand";
110+
import { ListDataLakesCommandInput, ListDataLakesCommandOutput } from "./commands/ListDataLakesCommand";
119111
import { ListLogSourcesCommandInput, ListLogSourcesCommandOutput } from "./commands/ListLogSourcesCommand";
120112
import { ListSubscribersCommandInput, ListSubscribersCommandOutput } from "./commands/ListSubscribersCommand";
121-
import { UpdateDatalakeCommandInput, UpdateDatalakeCommandOutput } from "./commands/UpdateDatalakeCommand";
122113
import {
123-
UpdateDatalakeExceptionsExpiryCommandInput,
124-
UpdateDatalakeExceptionsExpiryCommandOutput,
125-
} from "./commands/UpdateDatalakeExceptionsExpiryCommand";
114+
RegisterDataLakeDelegatedAdministratorCommandInput,
115+
RegisterDataLakeDelegatedAdministratorCommandOutput,
116+
} from "./commands/RegisterDataLakeDelegatedAdministratorCommand";
117+
import { UpdateDataLakeCommandInput, UpdateDataLakeCommandOutput } from "./commands/UpdateDataLakeCommand";
126118
import {
127-
UpdateDatalakeExceptionsSubscriptionCommandInput,
128-
UpdateDatalakeExceptionsSubscriptionCommandOutput,
129-
} from "./commands/UpdateDatalakeExceptionsSubscriptionCommand";
119+
UpdateDataLakeExceptionSubscriptionCommandInput,
120+
UpdateDataLakeExceptionSubscriptionCommandOutput,
121+
} from "./commands/UpdateDataLakeExceptionSubscriptionCommand";
130122
import { UpdateSubscriberCommandInput, UpdateSubscriberCommandOutput } from "./commands/UpdateSubscriberCommand";
131123
import {
132-
UpdateSubscriptionNotificationConfigurationCommandInput,
133-
UpdateSubscriptionNotificationConfigurationCommandOutput,
134-
} from "./commands/UpdateSubscriptionNotificationConfigurationCommand";
124+
UpdateSubscriberNotificationCommandInput,
125+
UpdateSubscriberNotificationCommandOutput,
126+
} from "./commands/UpdateSubscriberNotificationCommand";
135127
import {
136128
ClientInputEndpointParameters,
137129
ClientResolvedEndpointParameters,
@@ -148,69 +140,65 @@ export { __Client };
148140
export type ServiceInputTypes =
149141
| CreateAwsLogSourceCommandInput
150142
| CreateCustomLogSourceCommandInput
151-
| CreateDatalakeAutoEnableCommandInput
152-
| CreateDatalakeCommandInput
153-
| CreateDatalakeDelegatedAdminCommandInput
154-
| CreateDatalakeExceptionsSubscriptionCommandInput
143+
| CreateDataLakeCommandInput
144+
| CreateDataLakeExceptionSubscriptionCommandInput
145+
| CreateDataLakeOrganizationConfigurationCommandInput
155146
| CreateSubscriberCommandInput
156-
| CreateSubscriptionNotificationConfigurationCommandInput
147+
| CreateSubscriberNotificationCommandInput
157148
| DeleteAwsLogSourceCommandInput
158149
| DeleteCustomLogSourceCommandInput
159-
| DeleteDatalakeAutoEnableCommandInput
160-
| DeleteDatalakeCommandInput
161-
| DeleteDatalakeDelegatedAdminCommandInput
162-
| DeleteDatalakeExceptionsSubscriptionCommandInput
150+
| DeleteDataLakeCommandInput
151+
| DeleteDataLakeExceptionSubscriptionCommandInput
152+
| DeleteDataLakeOrganizationConfigurationCommandInput
163153
| DeleteSubscriberCommandInput
164-
| DeleteSubscriptionNotificationConfigurationCommandInput
165-
| GetDatalakeAutoEnableCommandInput
166-
| GetDatalakeCommandInput
167-
| GetDatalakeExceptionsExpiryCommandInput
168-
| GetDatalakeExceptionsSubscriptionCommandInput
169-
| GetDatalakeStatusCommandInput
154+
| DeleteSubscriberNotificationCommandInput
155+
| DeregisterDataLakeDelegatedAdministratorCommandInput
156+
| GetDataLakeExceptionSubscriptionCommandInput
157+
| GetDataLakeOrganizationConfigurationCommandInput
158+
| GetDataLakeSourcesCommandInput
170159
| GetSubscriberCommandInput
171-
| ListDatalakeExceptionsCommandInput
160+
| ListDataLakeExceptionsCommandInput
161+
| ListDataLakesCommandInput
172162
| ListLogSourcesCommandInput
173163
| ListSubscribersCommandInput
174-
| UpdateDatalakeCommandInput
175-
| UpdateDatalakeExceptionsExpiryCommandInput
176-
| UpdateDatalakeExceptionsSubscriptionCommandInput
164+
| RegisterDataLakeDelegatedAdministratorCommandInput
165+
| UpdateDataLakeCommandInput
166+
| UpdateDataLakeExceptionSubscriptionCommandInput
177167
| UpdateSubscriberCommandInput
178-
| UpdateSubscriptionNotificationConfigurationCommandInput;
168+
| UpdateSubscriberNotificationCommandInput;
179169

180170
/**
181171
* @public
182172
*/
183173
export type ServiceOutputTypes =
184174
| CreateAwsLogSourceCommandOutput
185175
| CreateCustomLogSourceCommandOutput
186-
| CreateDatalakeAutoEnableCommandOutput
187-
| CreateDatalakeCommandOutput
188-
| CreateDatalakeDelegatedAdminCommandOutput
189-
| CreateDatalakeExceptionsSubscriptionCommandOutput
176+
| CreateDataLakeCommandOutput
177+
| CreateDataLakeExceptionSubscriptionCommandOutput
178+
| CreateDataLakeOrganizationConfigurationCommandOutput
190179
| CreateSubscriberCommandOutput
191-
| CreateSubscriptionNotificationConfigurationCommandOutput
180+
| CreateSubscriberNotificationCommandOutput
192181
| DeleteAwsLogSourceCommandOutput
193182
| DeleteCustomLogSourceCommandOutput
194-
| DeleteDatalakeAutoEnableCommandOutput
195-
| DeleteDatalakeCommandOutput
196-
| DeleteDatalakeDelegatedAdminCommandOutput
197-
| DeleteDatalakeExceptionsSubscriptionCommandOutput
183+
| DeleteDataLakeCommandOutput
184+
| DeleteDataLakeExceptionSubscriptionCommandOutput
185+
| DeleteDataLakeOrganizationConfigurationCommandOutput
198186
| DeleteSubscriberCommandOutput
199-
| DeleteSubscriptionNotificationConfigurationCommandOutput
200-
| GetDatalakeAutoEnableCommandOutput
201-
| GetDatalakeCommandOutput
202-
| GetDatalakeExceptionsExpiryCommandOutput
203-
| GetDatalakeExceptionsSubscriptionCommandOutput
204-
| GetDatalakeStatusCommandOutput
187+
| DeleteSubscriberNotificationCommandOutput
188+
| DeregisterDataLakeDelegatedAdministratorCommandOutput
189+
| GetDataLakeExceptionSubscriptionCommandOutput
190+
| GetDataLakeOrganizationConfigurationCommandOutput
191+
| GetDataLakeSourcesCommandOutput
205192
| GetSubscriberCommandOutput
206-
| ListDatalakeExceptionsCommandOutput
193+
| ListDataLakeExceptionsCommandOutput
194+
| ListDataLakesCommandOutput
207195
| ListLogSourcesCommandOutput
208196
| ListSubscribersCommandOutput
209-
| UpdateDatalakeCommandOutput
210-
| UpdateDatalakeExceptionsExpiryCommandOutput
211-
| UpdateDatalakeExceptionsSubscriptionCommandOutput
197+
| RegisterDataLakeDelegatedAdministratorCommandOutput
198+
| UpdateDataLakeCommandOutput
199+
| UpdateDataLakeExceptionSubscriptionCommandOutput
212200
| UpdateSubscriberCommandOutput
213-
| UpdateSubscriptionNotificationConfigurationCommandOutput;
201+
| UpdateSubscriberNotificationCommandOutput;
214202

215203
/**
216204
* @public
@@ -376,24 +364,19 @@ export interface SecurityLakeClientResolvedConfig extends SecurityLakeClientReso
376364

377365
/**
378366
* @public
379-
* <note>
380-
* <p>Amazon Security Lake is in preview release. Your use of the Security Lake preview is subject to
381-
* Section 2 of the <a href="http://aws.amazon.com/service-terms/">Amazon Web Services Service
382-
* Terms</a>("Betas and Previews").</p>
383-
* </note>
384-
* <p>Amazon Security Lake is a fully managed security data lake service. You can use Security Lake to
367+
* <p>Amazon Security Lake is a fully managed security data lake service. You can use Security Lake to
385368
* automatically centralize security data from cloud, on-premises, and custom sources into a
386-
* data lake that's stored in your Amazon Web Servicesaccount. Amazon Web Services Organizations
369+
* data lake that's stored in your Amazon Web Services account. Amazon Web Services Organizations
387370
* is an account management service that lets you consolidate multiple Amazon Web Services
388371
* accounts into an organization that you create and centrally manage. With Organizations, you
389372
* can create member accounts and invite existing accounts to join your organization.
390373
* Security Lake helps you analyze security data for a more complete understanding of your
391374
* security posture across the entire organization. It can also help you improve the
392375
* protection of your workloads, applications, and data.</p>
393376
* <p>The data lake is backed by Amazon Simple Storage Service (Amazon S3) buckets, and you
394-
* retain ownership over your data. </p>
377+
* retain ownership over your data.</p>
395378
* <p>Amazon Security Lake integrates with CloudTrail, a service that provides a record of
396-
* actions taken by a user, role, or an Amazon Web Services service in Security Lake CloudTrail captures API calls for Security Lake as events. The calls captured include calls
379+
* actions taken by a user, role, or an Amazon Web Services service. In Security Lake, CloudTrail captures API calls for Security Lake as events. The calls captured include calls
397380
* from the Security Lake console and code calls to the Security Lake API operations. If you create a
398381
* trail, you can enable continuous delivery of CloudTrail events to an Amazon S3 bucket, including events for Security Lake. If you don't configure a trail, you can still
399382
* view the most recent events in the CloudTrail console in Event history. Using the

clients/client-securitylake/src/commands/CreateAwsLogSourceCommand.ts

Lines changed: 22 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -39,51 +39,34 @@ export interface CreateAwsLogSourceCommandOutput extends CreateAwsLogSourceRespo
3939
* <p>Adds a natively supported Amazon Web Service as an Amazon Security Lake source. Enables
4040
* source types for member accounts in required Amazon Web Services Regions, based on the
4141
* parameters you specify. You can choose any source type in any Region for either accounts
42-
* that are part of a trusted organization or standalone accounts. At least one of the three
43-
* dimensions is a mandatory input to this API. However, you can supply any combination of the
44-
* three dimensions to this API. </p>
45-
* <p>By default, a dimension refers to the entire set. When you don't provide a dimension,
46-
* Security Lake assumes that the missing dimension refers to the entire set. This is overridden
47-
* when you supply any one of the inputs. For instance, when you do not specify members, the
48-
* API enables all Security Lake member accounts for all sources. Similarly, when you do not
49-
* specify Regions, Security Lake is enabled for all the Regions where Security Lake is available as a
50-
* service.</p>
42+
* that are part of a trusted organization or standalone accounts. Once you add an Amazon Web Service as a source, Security Lake starts collecting logs and events from it, </p>
5143
* <p>You can use this API only to enable natively supported Amazon Web Services as a
5244
* source. Use <code>CreateCustomLogSource</code> to enable data collection from a custom
53-
* source. </p>
45+
* source.</p>
5446
* @example
5547
* Use a bare-bones client and the command you need to make an API call.
5648
* ```javascript
5749
* import { SecurityLakeClient, CreateAwsLogSourceCommand } from "@aws-sdk/client-securitylake"; // ES Modules import
5850
* // const { SecurityLakeClient, CreateAwsLogSourceCommand } = require("@aws-sdk/client-securitylake"); // CommonJS import
5951
* const client = new SecurityLakeClient(config);
6052
* const input = { // CreateAwsLogSourceRequest
61-
* inputOrder: [ // DimensionSet // required
62-
* "STRING_VALUE",
63-
* ],
64-
* enableAllDimensions: { // AllDimensionsMap
65-
* "<keys>": { // TwoDimensionsMap
66-
* "<keys>": [ // ValueSet
53+
* sources: [ // AwsLogSourceConfigurationList // required
54+
* { // AwsLogSourceConfiguration
55+
* accounts: [ // AccountList
56+
* "STRING_VALUE",
57+
* ],
58+
* regions: [ // RegionList // required
6759
* "STRING_VALUE",
6860
* ],
61+
* sourceName: "ROUTE53" || "VPC_FLOW" || "SH_FINDINGS" || "CLOUD_TRAIL_MGMT" || "LAMBDA_EXECUTION" || "S3_DATA", // required
62+
* sourceVersion: "STRING_VALUE",
6963
* },
70-
* },
71-
* enableTwoDimensions: {
72-
* "<keys>": [
73-
* "STRING_VALUE",
74-
* ],
75-
* },
76-
* enableSingleDimension: [ // InputSet
77-
* "STRING_VALUE",
7864
* ],
7965
* };
8066
* const command = new CreateAwsLogSourceCommand(input);
8167
* const response = await client.send(command);
8268
* // { // CreateAwsLogSourceResponse
83-
* // processing: [ // AccountList
84-
* // "STRING_VALUE",
85-
* // ],
86-
* // failed: [
69+
* // failed: [ // AccountList
8770
* // "STRING_VALUE",
8871
* // ],
8972
* // };
@@ -102,26 +85,24 @@ export interface CreateAwsLogSourceCommandOutput extends CreateAwsLogSourceRespo
10285
* Amazon Web Services action. An implicit denial occurs when there is no applicable Deny statement and also
10386
* no applicable Allow statement.</p>
10487
*
105-
* @throws {@link AccountNotFoundException} (client fault)
106-
* <p>Amazon Security Lake cannot find an Amazon Web Services account with the accountID that you
107-
* specified, or the account whose credentials you used to make this request isn't a member of
108-
* an organization.</p>
88+
* @throws {@link BadRequestException} (client fault)
89+
* <p>The request is malformed or contains an error such as an invalid parameter value or a missing required parameter.</p>
90+
*
91+
* @throws {@link ConflictException} (client fault)
92+
* <p>Occurs when a conflict with a previous successful write is detected. This generally
93+
* occurs when the previous write did not have time to propagate to the host serving the
94+
* current request. A retry (with appropriate backoff logic) is the recommended response to
95+
* this exception.</p>
10996
*
11097
* @throws {@link InternalServerException} (server fault)
11198
* <p>Internal service exceptions are sometimes caused by transient issues. Before you start
112-
* troubleshooting, perform the operation again. </p>
99+
* troubleshooting, perform the operation again.</p>
113100
*
114101
* @throws {@link ResourceNotFoundException} (client fault)
115102
* <p>The resource could not be found.</p>
116103
*
117-
* @throws {@link S3Exception} (client fault)
118-
* <p>Provides an extension of the AmazonServiceException for errors reported by Amazon S3 while processing a request. In particular, this class provides access to the
119-
* Amazon S3 extended request ID. If Amazon S3 is incorrectly handling a
120-
* request and you need to contact Amazon, this extended request ID may provide useful
121-
* debugging information. </p>
122-
*
123-
* @throws {@link ValidationException} (client fault)
124-
* <p>Your signing certificate could not be validated. </p>
104+
* @throws {@link ThrottlingException} (client fault)
105+
* <p>The limit on the number of requests per second was exceeded.</p>
125106
*
126107
* @throws {@link SecurityLakeServiceException}
127108
* <p>Base exception class for all service exceptions from SecurityLake service.</p>

0 commit comments

Comments
 (0)