Logging AWS Snowball Edge API Calls with AWS CloudTrail - AWS Snowball Edge Developer Guide

Logging AWS Snowball Edge API Calls with AWS CloudTrail

The AWS Snowball or Snow Family service integrates with AWS CloudTrail, a service that provides a record of actions taken by a user, role, or service. CloudTrail captures all API calls for AWS Snow Family service. The calls captured include calls from the AWS Snowball Family console and code calls to the AWS Snowball Family Job Management API. If you create a trail, you can enable continuous delivery of CloudTrail events to an Amazon S3 bucket, including events for AWS Snowball Family API calls. If you don't configure a trail, you can still view the most recent events in the CloudTrail console in Event history. Using the information collected by CloudTrail, you can determine the request made with AWS Snowball Family API, the IP address of the request made, who made the request, when it was made, and additional details.

To learn more about CloudTrail, see the AWS CloudTrail User Guide.

AWS Snowball Edge Information in CloudTrail

CloudTrail is enabled on your AWS account when you create the account. When activity occurs in AWS Snowball Edge, that activity is recorded in a CloudTrail event along with other AWS service events in Event history. You can view, search, and download recent events in your AWS account. For more information, see Viewing Events with CloudTrail Event History in the AWS CloudTrail User Guide.

For an ongoing record of events in your AWS account, including events for AWS Snowball Edge, create a trail. A trail enables CloudTrail to deliver log files to an Amazon S3 bucket. By default, when you create a trail in the console, the trail applies to all AWS Regions. The trail logs events from all AWS Regions in the AWS partition and delivers the log files to the Amazon S3 bucket that you specify. Additionally, you can configure other AWS services to further analyze and act upon the event data collected in CloudTrail logs. For more information, see the following topics in the AWS CloudTrail User Guide:

All job management actions are documented in the AWS Snowball API Reference and are logged by CloudTrail with the following exceptions:

  • The CreateAddress operation is not logged to protect customer sensitive information.

  • All read-only API calls (for API operations beginning with the prefix of Get, Describe, or List) don't record response elements.

Every event or log entry contains information about who generated the request. The identity information helps you determine the following:

  • Whether the request was made with root or AWS Identity and Access Management (IAM user) credentials.

  • Whether the request was made with temporary security credentials for a role or federated user.

  • Whether the request was made by another AWS service.

For more information, see the CloudTrail userIdentity Element in the AWS CloudTrail User Guide.

Understanding Log File Entries for AWS Snowball Edge

A trail is a configuration that enables delivery of events as log files to an Amazon S3 bucket that you specify. CloudTrail log files contain one or more log entries. An event represents a single request from any source and includes information about the requested action, the date and time of the action, request parameters, and so on. CloudTrail log files aren't an ordered stack trace of the public API calls, so they don't appear in any specific order.

The following example shows a CloudTrail log entry that demonstrates the DescribeJob operation.

{"Records": [ { "eventVersion": "1.05", "userIdentity": { "type": "Root", "principalId": "111122223333", "arn": "arn:aws:iam::111122223333:root", "accountId": "111122223333", "accessKeyId": "AKIAIOSFODNN7EXAMPLE", "sessionContext": {"attributes": { "mfaAuthenticated": "false", "creationDate": "2019-01-22T21:58:38Z" }}, "invokedBy": "signin.amazonaws.com" }, "eventTime": "2019-01-22T22:02:21Z", "eventSource": "snowball.amazonaws.com", "eventName": "DescribeJob", "awsRegion": "eu-west-1", "sourceIPAddress": "192.0.2.0", "userAgent": "signin.amazonaws.com", "requestParameters": {"jobId": "JIDa1b2c3d4-0123-abcd-1234-0123456789ab"}, "responseElements": null, "requestID": "12345678-abcd-1234-abcd-ab0123456789", "eventID": "33c7ff7c-3efa-4d81-801e-7489fe6fff62", "eventType": "AwsApiCall", "recipientAccountId": "444455556666" } ]}