id
stringlengths 8
78
| source
stringclasses 743
values | chunk_id
int64 1
5.05k
| text
stringlengths 593
49.7k
|
---|---|---|---|
transferfamily-ug-078
|
transferfamily-ug.pdf
| 78 |
of a successful response from a custom Lambda authentication call. aws transfer test-identity-provider --server-id s-1234567890abcdef0 --user-name myuser { "Url": "https://a1b2c3d4e5.execute-api.us-east-2.amazonaws.com/prod/servers/ s-1234567890abcdef0/users/myuser/config", "Message": "", "Response": "{\"Role\": \"arn:aws:iam::123456789012:role/bob-usa-role\", \"HomeDirectoryType\": \"LOGICAL\",\"HomeDirectoryDetails\": \"[{\\\"Entry\\\":\\\"/ myhome\\\",\\\"Target\\\":\\\"/amzn-s3-demo-bucket/theRealFolder\\\"}]\",\"PublicKeys \": \"[ssh-rsa myrsapubkey]\"}", "StatusCode": 200 } Configure logical directories for Amazon EFS 238 AWS Transfer Family Note User Guide The "Url": line is returned only if you are using an API Gateway method as your custom identity provider. Custom AWS Lambda response 239 AWS Transfer Family User Guide Transfer Family web apps You can create web apps to enable a simple interface for transferring data to and from Amazon Simple Storage Service (S3) over a web browser. This does not require you to create or provision AWS Transfer Family servers. Before the introduction of Transfer Family web apps, end users needed to use a client, custom- built, or a third-party solution to access their data in Amazon S3. This was due to stringent security requirements for customers and partners, and because clients apps are challenging for non- technical users to operate. With the launch of web apps, you can now extend a branded, secure, and highly available portal for your end users to browse, upload, and download data in Amazon S3. Web apps are natively integrated with AWS IAM Identity Center and Amazon S3 Access Grants. This means that only your authenticated users can view the data that they’re authorized to access. Web apps are built using Storage Browser for Amazon S3 and offer the same end user functionalities in a fully managed offering without having to write code or host your own application. For more information about the other AWS services that you use with Transfer Family web apps, see the following documentation: • Managing access with S3 Access Grants in the Amazon Simple Storage Service User Guide • AWS IAM Identity Center User Guide • Amazon S3 Access Grants workshop • Announcing AWS Transfer Family web apps for fully managed Amazon S3 file transfers The following resources are available to help you to get started with Transfer Family web apps. • The user guide offers a detailed, step-by-step walkthrough of setting up a Transfer Family web app here:Setting up a Transfer Family web app. • The AWS Getting Started Resource Center offers a tutorial here: Getting started with AWS Transfer Family web app. • View Getting started with AWS Transfer Family web app. 240 AWS Transfer Family User Guide AWS Regions for Transfer Family web apps AWS Transfer Family web apps are available in all the Transfer Family supported regions, as listed in AWS Transfer Family service endpoints, except for Asia Pacific (Malaysia) and Mexico (Central). Browser compatibility for AWS Transfer Family web apps Transfer Family web apps support the following browsers. Browser Version Compatibility Microsoft Edge Latest 3 versions Compatible Mozilla Firefox Latest 3 versions Compatible Google Chrome Latest 3 versions Compatible Apple Safari Latest 3 versions Compatible How to create a Transfer Family web app The following diagram illustrates the Transfer Family web app architecture. AWS Regions for Transfer Family web apps 241 AWS Transfer Family User Guide Based on the diagram, you can see that Transfer Family web apps interact with the following AWS services: • Amazon S3 for storage and Amazon S3 Access Grants to acquire session credentials. • AWS IAM Identity Center as the federated identity provider. • Amazon CloudFront if you configure a custom URL for your web app. Note the following limitations when using web apps. • Maximum number of search results per query: 10,000 • The Amazon S3 buckets that are used by the Transfer Family web app must be in the same account as the web app itself. Cross-account buckets are not currently supported. • Maximum search breadth per query: 10,000 searched files • Maximum upload size per file: 160 GB (149 GiB) • Maximum size file for copying: 5.36 GB (5 GiB) • Folder names starting or ending with dots (.) are not supported How to create a Transfer Family web app 242 AWS Transfer Family Prerequisites User Guide In AWS Identity and Access Management, configure the necessary roles. Paste in the code blocks that we provide in the instructions. For information about configuring the necessary roles, see Configure IAM roles for Transfer Family web apps. • Create an identity bearer role. • Create an IAM role to be used by S3 Access Grants. S3 Access Grants assumes this IAM role to vend temporary credentials to the grantee for the registered Amazon S3 location. Process to create a Transfer Family web app To create your web app and get your end users up and running, you perform the following tasks: 1. Configure IAM Identity Center to act as your federated identity provider. Perform the following tasks in IAM Identity Center. For more details about configuring IAM Identity Center,
|
transferfamily-ug-079
|
transferfamily-ug.pdf
| 79 |
Configure IAM roles for Transfer Family web apps. • Create an identity bearer role. • Create an IAM role to be used by S3 Access Grants. S3 Access Grants assumes this IAM role to vend temporary credentials to the grantee for the registered Amazon S3 location. Process to create a Transfer Family web app To create your web app and get your end users up and running, you perform the following tasks: 1. Configure IAM Identity Center to act as your federated identity provider. Perform the following tasks in IAM Identity Center. For more details about configuring IAM Identity Center, see Configure your identity provider for Transfer Family web apps. a. Create an IAM Identity Center instance, if you don't already have one. b. Determine your identity source. It can be the default IAM Identity Center directory or a third-party provider (for example Okta). c. d. Create or identify the users or groups that will be using your web app. If you are using the IAM Identity Center directory for your identity source, note the user or group IDs that you create. You need them later when you create an access grant by using S3 Access Grants. 2. In Amazon S3, configure Amazon S3 Access Grants. For more information about S3 Access Grants, see Configure Amazon S3 Access Grants for Transfer Family web apps. • Create an S3 Access Grants instance if you don't already have one in that AWS Region. • Register your location using the IAM role. • Create the access grant. 3. In Transfer Family, perform the following tasks. a. Create the Transfer Family web app. For more information about how to create the Transfer Family web app, see Configure a Transfer Family web app. How to create a Transfer Family web app 243 AWS Transfer Family User Guide Important Set up Cross-origin resource sharing (CORS) for all Amazon S3 buckets that are used by your web app. For information about setting up CORS, see Set up Cross- origin resource sharing (CORS) for your bucket. b. Assign users or groups to the web app. For more information about how to assign users and groups, see Assign or add users or groups to Transfer Family web app. c. (Optional) Update the access endpoint for your web app with a custom URL. For information about creating a custom URL, see Update your access endpoint with a custom URL. d. Provide your end users with the access endpoint URL so that they can log in and interact with your web app. Configure your identity provider for Transfer Family web apps The following section describes how to configure your identity provider. To begin, you must have an identity source. You can use an IAM Identity Center directory, AWS Directory Service for Microsoft Active Directory, or an external identity provider. Transfer Family uses IAM Identity Center as a federated identity provider, which is a system that stores user credentials and authenticates users across multiple organizations. If you're not using an IAM Identity Center directory as your identity source, see the following topics: • Manage an external identity provider • Connect to a Microsoft AD directory • Organization and account instances of IAM Identity Center • IAM Identity Center identity source tutorials Note You can only have one identity source in IAM Identity Center, per AWS Region. Configure your identity provider 244 AWS Transfer Family User Guide If you plan to use the IAM Identity Center directory as your identity source, and want a quick setup, you can skip this topic and go to Create a Transfer Family web app to create an IAM Identity Center instance from the wizard. To configure AWS IAM Identity Center for use with Transfer Family web apps 1. Sign in to the AWS Management Console and open the AWS IAM Identity Center console at https://console.aws.amazon.com/singlesignon/. 2. You can create and use either an account instance or an organization instance of AWS IAM Identity Center. • For details about account instances, see Create an account instance of AWS IAM Identity Center. With an account instance of IAM Identity Center, you can deploy supported AWS managed applications and OpenID Connect (OIDC)-based customer managed applications. Account instances support isolated deployments of applications in a single AWS account, leveraging IAM Identity Center workforce identity and access portal features. • For details about organization instances, see Organization instances of IAM Identity Center. You can centrally manage the access of users and groups with a single organization instance. 3. On the IAM Identity Center Settings page, note down your Instance ARN. You will need this value when you create an Amazon S3 Access Grant instance. 4. Create one or more users and, optionally, groups, to use with your Transfer Family web app. If you're using an IAM Identity Center directory as your identity
|
transferfamily-ug-080
|
transferfamily-ug.pdf
| 80 |
of applications in a single AWS account, leveraging IAM Identity Center workforce identity and access portal features. • For details about organization instances, see Organization instances of IAM Identity Center. You can centrally manage the access of users and groups with a single organization instance. 3. On the IAM Identity Center Settings page, note down your Instance ARN. You will need this value when you create an Amazon S3 Access Grant instance. 4. Create one or more users and, optionally, groups, to use with your Transfer Family web app. If you're using an IAM Identity Center directory as your identity provider, you can also add users directly from the web app itself. For more information, see Assign or add users or groups to Transfer Family web app. Configure your identity provider 245 AWS Transfer Family User Guide Configure IAM roles for Transfer Family web apps You will need two roles: one to use as an identity bearer role for your web app, and a second to use for configuring an access grant. An identity bearer role is a role that includes an authenticated user's identity in its sessions. It's used to make requests to S3 Access Grants for data access on behalf of the user. Note You can skip the procedure for creating an identity bearer role. For information about having the Transfer Family service create the identity bearer role, see Create a Transfer Family web app. You can skip the procedure for creating an access grants role. In the procedure for creating an access grant, in the step where you register an S3 location, choose Create new role. Create an identity bearer role 1. Sign in to the AWS Management Console and open the IAM console at https:// console.aws.amazon.com/iam/. 2. Choose Roles, and then Create role. 3. Choose Custom trust policy and then paste in the following code. { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Principal": { "Service":"transfer.amazonaws.com" }, "Action": [ "sts:AssumeRole", "sts:SetContext" ] } ] } 4. Choose Next and then skip Add permissions and select Next again. Configure IAM roles 246 AWS Transfer Family User Guide 5. Enter a name, for example web-app-identity-bearer. 6. Choose Create role to create the identity bearer role. 7. Choose the role that you just created from the list, then in the Permissions policies panel, choose Add permissions > Create inline policy. 8. In the Policy editor, select JSON and then paste in the following code block. { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": [ "s3:GetDataAccess", "s3:ListCallerAccessGrants", "s3:ListAccessGrantsInstances" ], "Resource": "*" } ] } 9. For the policy name, enter AllowS3AccessGrants, and then select Create policy. Next, you create the role that S3 Access Grants assumes to vend temporary credentials to the grantee. Note If you allow the service to create the identity bearer role for you, that role sets confused deputy protection. Therefore, its code is different from what is displayed here. Create an access grants role 1. Sign in to the AWS Management Console and open the IAM console at https:// console.aws.amazon.com/iam/. 2. Choose Roles, and then Create role. This role should have permission to access your S3 data in the AWS Region. 3. Choose Custom trust policy, and then paste in the following code. Configure IAM roles 247 AWS Transfer Family User Guide { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Principal": { "Service": "access-grants.s3.amazonaws.com" }, "Action": [ "sts:AssumeRole", "sts:SetContext" ] } ] } 4. Choose Next add a minimal policy as described in Register a location. While not recommended, you can add the AmazonS3FullAccess managed policy, which may be too permissive for your needs. 5. Choose Next, and enter a name (for example access-grants-location). 6. Choose Create role to create the role. Note If you allow the service to create the access grants role for you, that role sets confused deputy protection. Therefore, its code is different from what is displayed here. Configure a Transfer Family web app This section describes the procedures for creating a Transfer Family web app and then assigning users and groups that can use it. Configure a Transfer Family web app 248 AWS Transfer Family Note User Guide Repeat these procedures to add additional web apps. You can reuse the IAM roles that you created earlier. Make sure to add the access endpoints for the new web apps to each bucket's Cross-origin resource sharing (CORS) policy. Create a Transfer Family web app Note If you are not using the IAM Identity Center directory for your identity provider, don't attempt to create a web app until you have already set up IAM Identity Center and configured a third party identity provider, as described in Configure your identity provider for Transfer Family web apps. Complete the following steps to create a Transfer Family web app. To create a Transfer Family web app
|
transferfamily-ug-081
|
transferfamily-ug.pdf
| 81 |
IAM roles that you created earlier. Make sure to add the access endpoints for the new web apps to each bucket's Cross-origin resource sharing (CORS) policy. Create a Transfer Family web app Note If you are not using the IAM Identity Center directory for your identity provider, don't attempt to create a web app until you have already set up IAM Identity Center and configured a third party identity provider, as described in Configure your identity provider for Transfer Family web apps. Complete the following steps to create a Transfer Family web app. To create a Transfer Family web app 1. Sign in to the AWS Management Console and open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the left navigation pane, choose Web apps. 3. Choose Create web app. For authentication access, the pane is populated as follows. • If you have already created either an organization or account instance in AWS IAM Identity Center, then you see this message: Your AWS Transfer Family application connected to an account instance of IAM Identity Center. • If you already have an account instance and are a member of an organization instance, you have the option to choose which instance to connect. • If you don't already have an account instance, or are a member in an organization instance, you're presented with the options to create an account instance. 4. In the Permission type pane, you can use a previously created role, or have the service create one for you. Create a Transfer Family web app 249 AWS Transfer Family User Guide • If you have already created an identity bearer role, choose Use an existing role and choose your role from the Select an existing role menu. • To have the service create a role for you, choose Create and use a new service role. 5. In the Web app units pane, choose a value. One web app unit allows web app activity from up to 250 unique sessions. When creating a web app, you provision how many units you need based on your expected peak workload volumes. Changing your web app units has an impact on your billing. For information about pricing, see AWS Transfer Family Pricing. 6. 7. If you are using Transfer Family in an AWS GovCloud (US) Region, you can select the FIPS Enabled endpoint checkbox in the FIPS Enabled pane. For all other AWS Regions, this option is unavailable. (Optional) Add a tag to help you organize your web apps. We suggest that you add a tag with Name as the key and a descriptive name as the value. 8. Choose Next. On this screen, you can optionally provide a title for your web app. If you don't provide a title, the default title of Transfer Web App is supplied. You can also upload image files for your logo and favicon. 9. Choose Next, then choose Create web app. Create a Transfer Family web app 250 AWS Transfer Family Note User Guide Make sure to set up a Cross-origin resource sharing (CORS) policy for all of the buckets that are accessed from the web app endpoint. Assign or add users or groups to Transfer Family web app After you create a Transfer Family web app, you can assign users and groups who can then access the web app. You can either retrieve users that are already created and stored in IAM Identity Center, or you can add new users directly (if you're using an IAM Identity Center directory as your identity provider). If you add new users, they are also added to your IAM Identity Center instance. Note the following: • You can only add new users if you are using the IAM Identity Center directory as your identity source and have the proper permissions. If you are a member of an organization instance, you might not have the necessary permissions to add users. Note If you don't assign users or groups to your application, your users will get an error when they attempt to log into your web app. • If you create a new user, you must also create an S3 access grant for this user so that they can access data on your web app. • After you create a new user, that user receives an onboarding email from IAM Identity Center with directions for how to proceed. To assign users to a Transfer Family web app 1. Navigate to your web app list, and choose the one that you want to edit. 2. Choose Assign users and groups. Assign or add users or groups to Transfer Family web app 251 AWS Transfer Family User Guide 3. To assign users that you previously created in IAM Identity Center, select Assign existing users and groups. To create new users, skip ahead to
|
transferfamily-ug-082
|
transferfamily-ug.pdf
| 82 |
on your web app. • After you create a new user, that user receives an onboarding email from IAM Identity Center with directions for how to proceed. To assign users to a Transfer Family web app 1. Navigate to your web app list, and choose the one that you want to edit. 2. Choose Assign users and groups. Assign or add users or groups to Transfer Family web app 251 AWS Transfer Family User Guide 3. To assign users that you previously created in IAM Identity Center, select Assign existing users and groups. To create new users, skip ahead to step 4. a. An information screen appears. Choose Get started to continue. b. Search for the user. Note that no users appear until you begin entering your search criteria. You must search by the display name, not the username, if different. Only exact matches are returned. If you can't find your user, navigate to the IAM Identity Center management console, find the user, then copy and paste their display name here. Assign or add users or groups to Transfer Family web app 252 AWS Transfer Family User Guide c. Choose the users and groups to add, then choose Assign. 4. To create a new user, select Add and assign new users. a. An information screen appears. Choose Get started to continue. b. Choose Add new users. c. Enter the following user details into the dialog box: username, first and last name, and an email address. Assign or add users or groups to Transfer Family web app 253 AWS Transfer Family User Guide d. Choose Next, then choose Add to add the user and close the dialog box, or Add new user to create another user. Set up Cross-origin resource sharing (CORS) for your bucket You must set up cross-origin resource sharing (CORS) for all buckets that are used by your web app. A CORS configuration is a document that defines rules that identify the origins that you will allow to access your bucket. For more information about CORS, see Configuring cross-origin resource sharing (CORS). Set up Cross-origin resource sharing (CORS) for your bucket 254 AWS Transfer Family Important User Guide If you don't set up CORS, your end users receive an error when they attempt to access a location on your web app. To set up Cross-origin resource sharing (CORS) for your Amazon S3 bucket 1. Sign in to the AWS Management Console and open the Amazon S3 console at https:// console.aws.amazon.com/s3/. 2. Choose Buckets from the left navigation panel and search for your bucket in the search dialog, then choose the Permissions tab. 3. In Cross-origin resource sharing (CORS), choose Edit and paste in the following code. Replace WebAppEndpoint with the actual access endpoint for your web app. This can be either the access endpoint that's created when the web app is created, or a custom access endpoint, if you create one. Make sure not to enter trailing slashes, because doing so causes errors when users attempt to log on to your web app. • Incorrect example: https://webapp-c7bf3423.transfer-webapp.us- east-2.on.aws/ • Correct example: https://webapp-c7bf3423.transfer-webapp.us-east-2.on.aws If you are reusing a bucket for multiple web apps, append their endpoints to the AllowedOrigins list. [ { "AllowedHeaders": [ "*" ], "AllowedMethods": [ "GET", "PUT", "POST", "DELETE", "HEAD" ], "AllowedOrigins": [ "https://WebAppEndpoint" Set up Cross-origin resource sharing (CORS) for your bucket 255 User Guide AWS Transfer Family ], "ExposeHeaders": [ "last-modified", "content-length", "etag", "x-amz-version-id", "content-type", "x-amz-request-id", "x-amz-id-2", "date", "x-amz-cf-id", "x-amz-storage-class", "access-control-expose-headers" ], "MaxAgeSeconds": 3000 } ] 4. Choose Save changes to update the CORS. To test your CORS configuration, see Testing CORS. Configure Amazon S3 Access Grants for Transfer Family web apps This topic describes how to add an access grant using Amazon S3 Access Grants. This access grant defines access to your data directly to your users and groups in your corporate directory and vends just-in-time, least privilege, temporary credentials based on grants. An individual grant in an S3 Access Grants instance allows a specific user or group in a corporate directory—to get access within a location that is registered in your S3 Access Grants instance. For more details, see S3 Access Grants concepts in the Amazon S3 User Guide. Note You can't use the IAM Identity Center directory with S3 Access Grants other than with Transfer Family web apps. You must specify an Amazon S3 access grant for identity propagation. An Amazon S3 access grant stores the data that your end users must access. When your end users sign in to your Transfer Configure Amazon S3 Access Grants 256 AWS Transfer Family User Guide Family web app, S3 Access Grants passes a user's identity to the trusted application. This section describes how to add and configure an Amazon S3 access grant instance and then an access grant for an Amazon S3 bucket.
|
transferfamily-ug-083
|
transferfamily-ug.pdf
| 83 |
use the IAM Identity Center directory with S3 Access Grants other than with Transfer Family web apps. You must specify an Amazon S3 access grant for identity propagation. An Amazon S3 access grant stores the data that your end users must access. When your end users sign in to your Transfer Configure Amazon S3 Access Grants 256 AWS Transfer Family User Guide Family web app, S3 Access Grants passes a user's identity to the trusted application. This section describes how to add and configure an Amazon S3 access grant instance and then an access grant for an Amazon S3 bucket. Note Have your IAM Identity Center instance ARN and user or group ID ready, as you need them to complete setting up your access grant. To create a grant using Amazon S3 Access Grants 1. Sign in to the AWS Management Console and open the Amazon S3 console at https:// console.aws.amazon.com/s3/. 2. Create a bucket, or note an existing bucket to use with your web app. For information on creating buckets, see the Amazon S3 User Guide. 3. From the left navigation pane, choose Access Grants. 4. Choose Create S3 Access Grants instance and provide the following information. • Select Add IAM Identity Center instance in your-Region where your-Region is your AWS Region. Keep this box cleared if you are not using IAM Identity Center as your identity provider. • Paste in your IAM Identity Center instance ARN. Choose Next to continue. Configure Amazon S3 Access Grants 257 AWS Transfer Family User Guide 5. Register S3 Buckets or prefixes as locations. We recommend that you register the default location, s3://, and map it to an IAM role. The location at this default path covers access to all of your Amazon S3 buckets in the AWS Region of your account. When you create an access grant, you can narrow the scope to a bucket, a prefix, or an object within the default location. Provide the following information. • For the Scope, browse for a bucket or enter the name of your bucket, and optionally a prefix. • For the IAM role, choose Create new role to have the service create a role. Alternatively, you can create the role yourself, as described in Configure IAM roles for Transfer Family web apps, and then enter its ARN here. Choose Next to continue. 6. In the Create Grant screen, provide the following details. • For Permissions, select Read and Write. The access grant permissions can be either read- only or read & write, but write-only is not supported. • For Grantee type, choose Directory identity from IAM Identity Center. Configure Amazon S3 Access Grants 258 AWS Transfer Family User Guide • For Directory identity type, select User or Group, depending on which type you want to register now. • In IAM Identity Center user/group ID, paste in the ID for your user or group. This ID is available in the IAM Identity Center console and in your Transfer Family web app in your users and groups table. Choose Next. 7. Review the settings on the screen. If everything is correct, choose Finish to create the access grant. Alternatively, you can choose Cancel or Previous to make changes. Configure Amazon S3 Access Grants 259 AWS Transfer Family User Guide Configure Amazon S3 Access Grants 260 AWS Transfer Family User Guide This completes the setup for your web app. The users and groups that you've configured can visit the web app at the access point, log in, and upload and download files. Update your access endpoint with a custom URL The default access endpoint that is created with your web app contains service-generated identifiers. To provide a branded experience, you may want to provide a custom URL for your users to access your Transfer Family web app. This topic describes how to update your access endpoint with a custom URL. Note The following procedure relies on you using the recommended CloudFormation stack template. You don't need to use the template: you can create the distribution by using the CloudFront console directly. However, the provided template simplifies the process, and makes it easier to avoid misconfiguration. If you don't use the AWS CloudFormation template, make sure to follow these guidelines: • The Origin request policy should forward query strings and cookies to the origin, and should not forward the Host header to the origin. Use a custom URL 261 AWS Transfer Family User Guide • The Cache policy should not include the Host header in the cache key. To customize your web app URL 1. Create a CloudFront distribution by using the Transfer Family supplied AWS CloudFormation template, CloudFormation stack template. a. Open the AWS CloudFormation console at https://console.aws.amazon.com/ cloudformation. b. Choose Create stack and specify the following. • In the Prerequisite - Prepare template section, choose
|
transferfamily-ug-084
|
transferfamily-ug.pdf
| 84 |
follow these guidelines: • The Origin request policy should forward query strings and cookies to the origin, and should not forward the Host header to the origin. Use a custom URL 261 AWS Transfer Family User Guide • The Cache policy should not include the Host header in the cache key. To customize your web app URL 1. Create a CloudFront distribution by using the Transfer Family supplied AWS CloudFormation template, CloudFormation stack template. a. Open the AWS CloudFormation console at https://console.aws.amazon.com/ cloudformation. b. Choose Create stack and specify the following. • In the Prerequisite - Prepare template section, choose Choose an existing template. • In the Specify template section, choose Upload a template file. • Save the CloudFormation stack template file, and then upload it here. c. Choose Next and provide the following information. • WebAppEndpoint: copy the value from your web app • AccessEndpoint: provide the custom domain name that you want to use • AcmCertificateArn: provide the ARN for a public or private SSL/TLS certificate that is stored in AWS Certificate Manager d. Complete the AWS CloudFormation wizard until your new stack is created. 2. In your web app, edit the Access endpoint, updating the Custom URL to the URL that you want to use. Use a custom URL 262 AWS Transfer Family User Guide 3. Create DNS records to route traffic for your custom domain name to the CloudFront distribution. If you're using Route 53 for the zone, you can create an Alias or CNAME record to the CloudFront distribution name (for example, xxxx.cloudfront.net). For information about using Amazon Route 53 with CloudFront, see Configuring Amazon Route 53 to route traffic to a CloudFront distribution. 4. Update your cross-origin resource sharing policy by replacing the default access endpoint with the following line in the AllowedOrigins code block: "https://custom-url" You need to make this change for each bucket used by your web app. After you make your update, the AllowedOrigins section of your CORS policy should look like the following: "AllowedOrigins": [ "https://custom-url"], You need only a single AllowedOrigins entry for each Transfer Family web app. Use a custom URL 263 AWS Transfer Family User Guide See the Set up Cross-origin resource sharing (CORS) for your Amazon S3 bucket procedure for more details. You can now visit your custom access endpoint, and share this link with your end users. CloudTrail logging for Transfer Family web apps CloudTrail is an AWS service that creates a record of actions taken within your AWS account. It continuously monitors and records API operations for activities like console sign-ins, AWS Command Line Interface commands, and SDK/API operations. This allows you to keep a log of who took what action, when, and from where. CloudTrail helps with auditing, access management, and regulatory compliance by providing a history of all activity in your AWS environment. For Transfer Family web apps, see the following documentation for details on how view the logs for your end users' activity. • CloudTrail use cases for IAM Identity Center • Understanding IAM Identity Center sign-in events • CloudTrail userIdentity element • Enabling CloudTrail event logging for S3 buckets and objects • Amazon S3 CloudTrail events Troubleshooting your web apps Note These troubleshooting tips are meant for the web app administrator rather than the end user. For end users, if you encounter any problems, contact your web app administrator. All instances of you in the following paragraphs refer to the web app admin. Troubleshoot network errors Description Your end user sees a network banner Network Error upon loading the web app endpoint. Logging for Transfer Family web apps 264 AWS Transfer Family Cause The most common issues are as follows: User Guide • The admin did not assign the user that is attempting to log on to the new application. • The admin did not add the necessary actions to your IAM roles. • You see a list of S3 Access Grants assigned to your user, but CORS is not configured correctly for your Amazon S3 bucket or buckets. Solution • In IAM Identity Center, make sure to assign the user to the correct application. Or, if you have a group assigned, make sure that the user attempting to log in belongs to the correct group. This is described in Assign or add users or groups to Transfer Family web app. • Check whether your roles contain the necessary actions in the Custom trust policy for both sts:AssumeRole and sts:SetContext actions. This is described in Configure IAM roles for Transfer Family web apps. • Check the CORS policy for all of the buckets used by your web app. This is described in Set up Cross-origin resource sharing (CORS) for your Amazon S3 bucket. Troubleshoot configured bucket not appearing Description Everything appears to be configured correctly, but the Amazon S3 bucket
|
transferfamily-ug-085
|
transferfamily-ug.pdf
| 85 |
in belongs to the correct group. This is described in Assign or add users or groups to Transfer Family web app. • Check whether your roles contain the necessary actions in the Custom trust policy for both sts:AssumeRole and sts:SetContext actions. This is described in Configure IAM roles for Transfer Family web apps. • Check the CORS policy for all of the buckets used by your web app. This is described in Set up Cross-origin resource sharing (CORS) for your Amazon S3 bucket. Troubleshoot configured bucket not appearing Description Everything appears to be configured correctly, but the Amazon S3 bucket doesn't appear in the web app. Cause One possible cause is that the Amazon S3 bucket is not in the same account as the web app. Solution Ensure that the Amazon S3 bucket is in the same account as the web app. Cross-account buckets are not currently supported. Troubleshoot custom URL errors Description Troubleshoot configured bucket not appearing 265 AWS Transfer Family User Guide When your end user signs into the web app, they receive the error message Authorization failed: missing authorization code. Cause If you used CloudFront directly, rather than the supplied AWS CloudFormation template, you have likely misconfigured the origin request policy to not forward query strings. Solution Update your origin request policy to forward query strings and cookies to the origin. Description When your end user attempts to access a Transfer Family web app, they receive a 404 response. Cause If you used CloudFront directly, rather than the supplied AWS CloudFormation template, you have likely misconfigured the cache policy to include the Host header in the cache key or misconfigured the origin request policy to forward the Host header. Solution • Make sure that your cache policy does not include the Host header in the cache key • Make sure that your origin request policy does not forward the Host header. Troubleshoot miscellaneous errors Description Your end user cannot log in, or cannot view any buckets or files, or you receive another error. Cause One possible cause is that the IAM Identity Center instance ARN doesn't match the value for your grants ARN or your web app IAM Identity Center instance ARN. Solution Check the following items to see if they match. Troubleshoot miscellaneous errors 266 AWS Transfer Family User Guide • In IAM Identity Center, navigate to Settings and view the Instance ARN. arn:aws:sso:::instance/ssoins-instance-identifier • In Amazon S3, navigate to Access Grants and view your IAM Identity Center instance ARN. arn:aws:sso::account-id:application/ssoins-instance-identifier/apl-1234567890abcdef0 • In Transfer Family, navigate to your web app details page and view its Instance ARN. arn:aws:sso:::instance/ssoins-instance-identifier The instance-identifier value must be the same in all three of these places. End user instructions for Transfer Family web apps Note In this topic, the information is meant for the end users that are interacting with the web app. All instances of you in this topic refer to end users. This topic describes how to access an AWS Transfer Family web app that you are authorized to use, and describes how you can interact with it. Web app quotas Note the following limitations when using web apps. • Maximum number of search results per query: 10,000 • The Amazon S3 buckets that are used by the Transfer Family web app must be in the same account as the web app itself. Cross-account buckets are not currently supported. • Maximum search breadth per query: 10,000 searched files • Maximum upload size per file: 160 GB (149 GiB) • Maximum size file for copying: 5.36 GB (5 GiB) • Folder names starting or ending with dots (.) are not supported End user instructions 267 AWS Transfer Family User Guide User experience for IAM Identity Center users This section describes the user experience if your organization used IAM Identity Center to configure its users. To access a Transfer Family web app 1. You should receive an email from [email protected] titled “Invitation to join AWS IAM Identity Center.” Accept the invitation to activate your user account. 2. In the message, choose the URL below Your AWS access portal URL. This takes you to the AWS sign in screen. 3. Enter your credentials and choose Sign in. This takes you to the AWS access portal, which shows a list of your available applications. 4. Choose the application for your Transfer Family web app. IAM Identity Center users 268 AWS Transfer Family User Guide User experience for third-party identity provider users If your organization did not use AWS IAM Identity Center to configure its users, your onboarding experience will depend upon the identity provider application that they used to configure their end users. After you authenticate and sign in, your web app interface is the same as that described in the next section. Transfer Family end user interface After you have authenticated and
|
transferfamily-ug-086
|
transferfamily-ug.pdf
| 86 |
AWS access portal, which shows a list of your available applications. 4. Choose the application for your Transfer Family web app. IAM Identity Center users 268 AWS Transfer Family User Guide User experience for third-party identity provider users If your organization did not use AWS IAM Identity Center to configure its users, your onboarding experience will depend upon the identity provider application that they used to configure their end users. After you authenticate and sign in, your web app interface is the same as that described in the next section. Transfer Family end user interface After you have authenticated and signed in, you can interact with the web app. There are four main views. • Home page: Your home page lists the S3 locations, which you can access, as well as the permissions for each. An S3 location is an S3 bucket or prefix, which you can define when using S3 Access Grants. This is the initial view for users that shows the root level S3 resources that your end users have access to and the permissions for each S3 location. • Location details: This view allows users to browse files and folders in S3, and upload or download files. • Location action: After you choose an action (such as Upload), it opens up another view of the file location. Third-party end users 269 AWS Transfer Family User Guide • Vertical ellipsis: The vertical ellipsis icon opens the Actions menu. Available actions Most of the actions are available from the Actions menu. For the other main action, downloading files, you use the download icon after you select a file (currently, you can only download one file at a time). From a folder, use the Actions menu to perform any of the following tasks: • Copy one or more files to another location. • Create a folder. • Delete one or more files. • Upload one or more files. • Upload an entire folder (including subfolders if any). • Select a folder and navigate to it. You can then perform any of the previously listed actions. • Sort by page. • Filter by file or folder name per folder and subfolders. Available actions 270 AWS Transfer Family User Guide Available actions 271 AWS Transfer Family User Guide AWS Transfer Family SFTP connectors An AWS Transfer Family SFTP connector establishes a connection with a remote SFTP server to transfer files between Amazon storage and a remote server, using the SFTP protocol. You can send files from Amazon S3 to an external, partner-owned SFTP server, retrieve files from a partner's SFTP server to Amazon S3 or list, delete, rename or move files on the remote server. Using SFTP connectors, you can build automated, event-driven file transfer workflows in AWS . Note Currently, SFTP connectors can only be used to connect to remote SFTP servers that offer an internet-accessible endpoint. View AWS Transfer Family SFTP connectors for a brief introduction to Transfer Family SFTP connectors. Topics • Creating SFTP connectors • Using SFTP connectors • Monitoring SFTP connectors • Managing SFTP connectors • Scaling and quotas for SFTP connectors • Reference architectures using SFTP connectors Creating SFTP connectors This topic describes how to create SFTP connectors. Each connector provides the ability to connect with one remote SFTP server. You perform the following high-level tasks to configure an SFTP connector. 1. Store the authentication credentials for the connector in AWS Secrets Manager. 2. Create the connector, specifying the secret ARN, the remote server's URL, the security policy containing the algorithms that will be supported by the connector, and other configuration settings. Creating SFTP connectors 272 AWS Transfer Family User Guide 3. After you create the connector, you can test it to ensure that it can establish connections with the remote SFTP server. Topics • Store authentication credentials for SFTP connectors in Secrets Manager • Create an SFTP connector • Test an SFTP connector Store authentication credentials for SFTP connectors in Secrets Manager You can use Secrets Manager to store user credentials for your SFTP connectors. When you create your secret, you must provide a username. Additionally, you can provide either a password, a private key, or both. For details, see Quotas for SFTP connectors. Note When you store secrets in Secrets Manager, your AWS account incurs charges. For information about pricing, see AWS Secrets Manager Pricing. To store user credentials in Secrets Manager for an SFTP connector 1. Sign in to the AWS Management Console and open the AWS Secrets Manager console at https://console.aws.amazon.com/secretsmanager/. 2. In the left navigation pane, choose Secrets. 3. On the Secrets page, choose Store a new secret. 4. On the Choose secret type page, for Secret type, choose Other type of secret. 5. Provide the key/value information for your secret: you need to provide the username, and either a private
|
transferfamily-ug-087
|
transferfamily-ug.pdf
| 87 |
When you store secrets in Secrets Manager, your AWS account incurs charges. For information about pricing, see AWS Secrets Manager Pricing. To store user credentials in Secrets Manager for an SFTP connector 1. Sign in to the AWS Management Console and open the AWS Secrets Manager console at https://console.aws.amazon.com/secretsmanager/. 2. In the left navigation pane, choose Secrets. 3. On the Secrets page, choose Store a new secret. 4. On the Choose secret type page, for Secret type, choose Other type of secret. 5. Provide the key/value information for your secret: you need to provide the username, and either a private key or a password. a. In the Key/value pairs section, choose the Key/value tab. • Key – Enter Username. • value – Enter the name of the user that is authorized to connect to the partner's server. Store credentials in Secrets Manager 273 AWS Transfer Family User Guide b. If you want to provide a key pair, choose Add row, and in the Key/value pairs section, choose the Key/value tab. • Key – Enter PrivateKey. • value – paste in your private key. Tip: The private key data that you enter must correspond to the public key that is stored for this user on the remote SFTP server. For details on how to generate a public/private key pair, see Creating SSH keys on macOS, Linux, or Unix. c. If you want to provide a password, choose Add row, and in the Key/value pairs section, choose the Key/value tab. • Key – Enter Password. • value – Enter the password for the user. 6. Choose Next. 7. On the Configure secret page, enter a name and description for your secret. We recommend that you use a prefix of aws/transfer/ for the name. For example, you could name your secret aws/transfer/connector-1. 8. Choose Next, and then accept the defaults on the Configure rotation page. Then choose Next. 9. On the Review page, choose Store to create and store the secret. Create an SFTP connector This procedure explains how to create SFTP connectors by using the AWS Transfer Family console or AWS CLI. Console To create an SFTP connector 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. 3. In the left navigation pane, choose SFTP Connectors, then choose Create SFTP connector. In the Connector configuration section, provide the following information: Create an SFTP connector 274 AWS Transfer Family User Guide • For the URL, enter the URL for a remote SFTP server. This URL must be formatted as sftp://partner-SFTP-server-url, for example sftp://AnyCompany.com. Note Optionally, you can provide a port number in your URL. The format is sftp://partner-SFTP-server-url:port-number. The default port number (when no port is specified) is port 22. • For the Access role, choose the Amazon Resource Name (ARN) of the AWS Identity and Access Management (IAM) role to use. • Make sure that this role provides read and write access to the parent directory of the file location that's used in the StartFileTransfer request. • Make sure that this role provides permission for secretsmanager:GetSecretValue to access the secret. Note In the policy, you must specify the ARN for the secret. The ARN contains the secret name, but appends the name with six, random, alphanumeric characters. An ARN for a secret has the following format. Create an SFTP connector 275 AWS Transfer Family User Guide arn:aws:secretsmanager:region:account-id:secret:aws/ transfer/SecretName-6RandomCharacters • Make sure this role contains a trust relationship that allows the connector to access your resources when servicing your users' transfer requests. For details on establishing a trust relationship, see To establish a trust relationship. The following example grants the necessary permissions to access the amzn-s3-demo- bucket in Amazon S3, and the specified secret stored in Secrets Manager. { "Version": "2012-10-17", "Statement": [ { "Sid": "AllowListingOfUserFolder", "Action": [ "s3:ListBucket", "s3:GetBucketLocation" ], "Effect": "Allow", "Resource": [ "arn:aws:s3:::amzn-s3-demo-bucket" ] }, { "Sid": "HomeDirObjectAccess", "Effect": "Allow", "Action": [ "s3:PutObject", "s3:GetObject", "s3:DeleteObject", "s3:DeleteObjectVersion", "s3:GetObjectVersion", "s3:GetObjectACL", "s3:PutObjectACL" ], "Resource": "arn:aws:s3:::amzn-s3-demo-bucket/*" }, { "Sid": "GetConnectorSecretValue", "Effect": "Allow", Create an SFTP connector 276 AWS Transfer Family User Guide "Action": [ "secretsmanager:GetSecretValue" ], "Resource": "arn:aws:secretsmanager:region:account-id:secret:aws/ transfer/SecretName-6RandomCharacters" } ] } Note For the access role, the example grants access to a single secret. However, you can use a wildcard character, which can save work if you want to reuse the same IAM role for multiple users and secrets. For example, the following resource statement grants permissions for all secrets that have names beginning with aws/transfer. "Resource": "arn:aws:secretsmanager:region:account-id:secret:aws/ transfer/*" You can also store secrets containing your SFTP credentials in another AWS account. For details on enabling cross-account secret access, see Permissions to AWS Secrets Manager secrets for users in a different account. • (Optional) For the Logging role, choose the IAM role for the connector to use to push events to your CloudWatch logs. The following example policy lists the necessary permissions
|
transferfamily-ug-088
|
transferfamily-ug.pdf
| 88 |
can save work if you want to reuse the same IAM role for multiple users and secrets. For example, the following resource statement grants permissions for all secrets that have names beginning with aws/transfer. "Resource": "arn:aws:secretsmanager:region:account-id:secret:aws/ transfer/*" You can also store secrets containing your SFTP credentials in another AWS account. For details on enabling cross-account secret access, see Permissions to AWS Secrets Manager secrets for users in a different account. • (Optional) For the Logging role, choose the IAM role for the connector to use to push events to your CloudWatch logs. The following example policy lists the necessary permissions to log events for SFTP connectors. { "Version": "2012-10-17", "Statement": [{ "Sid": "SFTPConnectorPermissions", "Effect": "Allow", "Action": [ "logs:CreateLogStream", "logs:DescribeLogStreams", "logs:CreateLogGroup", "logs:PutLogEvents" ], "Resource": [ Create an SFTP connector 277 AWS Transfer Family User Guide "arn:aws:logs:*:*:log-group:/aws/transfer/*" ] }] } 4. In the SFTP Configuration section, provide the following information: • For Connector credentials, from the dropdown list, choose the name of a secret in AWS Secrets Manager that contains the SFTP user's private key or password. You must create a secret and store it in a specific manner. For details, see Store authentication credentials for SFTP connectors in Secrets Manager . • (Optional) ) You have an option to create your connector while leaving the TrustedHostKeys parameter empty. However, your connector will not be able to transfer files with the remote server until you provide this parameter in your connector’s configuration. You can enter the Trusted host key(s) at the time of creating your connector, or update your connector later by using the host key information returned by the TestConnection console action or API command. That is, for the Trusted host keys text box, you can do either of the following: • Provide the Trusted Host Key(s) at the time of creating your connector. Paste in the public portion of the host key that is used to identify the external server. You can add more than one key, by choosing Add trusted host key to add an additional key. You can use the ssh-keyscan command against the SFTP server to retrieve the necessary Create an SFTP connector 278 AWS Transfer Family User Guide key. For details about the format and type of trusted host keys that Transfer Family supports, see SFTPConnectorConfig. • Leave the Trusted Host Key(s) text box empty when creating your connector and update your connector at a later time with this information. If you do not have the host key information at the time of creating your connector, you can leave this parameter empty for now and proceed with creating your connector. After the connector is created, use the new connector's ID to run the TestConnection command, either in the AWS CLI or from the connector's detail page. If successful, TestConnection will return the necessary host key information. You can then edit your connector using the console (or by running the UpdateConnector AWS CLI command) and add the host key information that was returned when you ran TestConnection. Important If you retrieve the remote server's host key by running TestConnection, make sure that you perform out-of-band validation on the key that is returned. You must accept the new key as trusted, or verify the presented fingerprint with a previously known fingerprint that you have received from the owner of the remote SFTP server you are connecting to. • (Optional) For Maximum concurrent connections, from the dropdown list, choose the number of concurrent connections that your connector creates to the remote server. The default selection on the console is 5. This setting specifies the number of active connections that your connector can establish with the remote server at the same time. Creating concurrent connections can enhance connector performance by enabling parallel operations. 5. In the Cryptographic algorithm options section, choose a Security policy from the dropdown list in the Security Policy field. The security policy enables you to select the cryptographic algorithms that your connector supports. For details on the available security policies and algorithms, see Security policies for AWS Transfer Family SFTP connectors. 6. (Optional) In the Tags section, for Key and Value, enter one or more tags as key-value pairs. 7. After you have confirmed all of your settings, choose Create SFTP connector to create the SFTP connector. If the connector is created successfully, a screen appears with a list of Create an SFTP connector 279 AWS Transfer Family User Guide the assigned static IP addresses and a Test connection button. Use the button to test the configuration for your new connector. The Connectors page appears, with the ID of your new SFTP connector added to the list. To view the details for your connectors, see View SFTP connector details. CLI You use the create-connector command to create a connector. To use this command to create an
|
transferfamily-ug-089
|
transferfamily-ug.pdf
| 89 |
your settings, choose Create SFTP connector to create the SFTP connector. If the connector is created successfully, a screen appears with a list of Create an SFTP connector 279 AWS Transfer Family User Guide the assigned static IP addresses and a Test connection button. Use the button to test the configuration for your new connector. The Connectors page appears, with the ID of your new SFTP connector added to the list. To view the details for your connectors, see View SFTP connector details. CLI You use the create-connector command to create a connector. To use this command to create an SFTP connector, you must provide the following information. • The URL for a remote SFTP server. This URL must be formatted as sftp://partner-SFTP- server-url, for example sftp://AnyCompany.com. • The access role. Choose the Amazon Resource Name (ARN) of the AWS Identity and Access Management (IAM) role to use. • Make sure that this role provides read and write access to the parent directory of the file location that's used in the StartFileTransfer request. • Make sure that this role provides permission for secretsmanager:GetSecretValue to access the secret. Create an SFTP connector 280 AWS Transfer Family User Guide Note In the policy, you must specify the ARN for the secret. The ARN contains the secret name, but appends the name with six, random, alphanumeric characters. An ARN for a secret has the following format. arn:aws:secretsmanager:region:account-id:secret:aws/ transfer/SecretName-6RandomCharacters • Make sure this role contains a trust relationship that allows the connector to access your resources when servicing your users' transfer requests. For details on establishing a trust relationship, see To establish a trust relationship. The following example grants the necessary permissions to access the amzn-s3-demo- bucket in Amazon S3, and the specified secret stored in Secrets Manager. { "Version": "2012-10-17", "Statement": [ { "Sid": "AllowListingOfUserFolder", "Action": [ "s3:ListBucket", "s3:GetBucketLocation" ], "Effect": "Allow", "Resource": [ "arn:aws:s3:::amzn-s3-demo-bucket" ] }, { "Sid": "HomeDirObjectAccess", "Effect": "Allow", "Action": [ "s3:PutObject", "s3:GetObject", "s3:DeleteObject", "s3:DeleteObjectVersion", "s3:GetObjectVersion", "s3:GetObjectACL", Create an SFTP connector 281 AWS Transfer Family User Guide "s3:PutObjectACL" ], "Resource": "arn:aws:s3:::amzn-s3-demo-bucket/*" }, { "Sid": "GetConnectorSecretValue", "Effect": "Allow", "Action": [ "secretsmanager:GetSecretValue" ], "Resource": "arn:aws:secretsmanager:region:account-id:secret:aws/ transfer/SecretName-6RandomCharacters" } ] } Note For the access role, the example grants access to a single secret. However, you can use a wildcard character, which can save work if you want to reuse the same IAM role for multiple users and secrets. For example, the following resource statement grants permissions for all secrets that have names beginning with aws/transfer. "Resource": "arn:aws:secretsmanager:region:account-id:secret:aws/transfer/ *" You can also store secrets containing your SFTP credentials in another AWS account. For details on enabling cross-account secret access, see Permissions to AWS Secrets Manager secrets for users in a different account. • (Optional) Choose the IAM role for the connector to use to push events to your CloudWatch logs. The following example policy lists the necessary permissions to log events for SFTP connectors. { "Version": "2012-10-17", "Statement": [{ "Sid": "SFTPConnectorPermissions", "Effect": "Allow", "Action": [ Create an SFTP connector 282 AWS Transfer Family User Guide "logs:CreateLogStream", "logs:DescribeLogStreams", "logs:CreateLogGroup", "logs:PutLogEvents" ], "Resource": [ "arn:aws:logs:*:*:log-group:/aws/transfer/*" ] }] } • Provide the following SFTP configuration information. • The ARN of a secret in AWS Secrets Manager that contains the SFTP user's private key or password. • The public portion of the host key that is used to identify the external server. You can provide multiple trusted host keys if you like. The easiest way to provide the SFTP information is to save it to a file. For example, copy the following example text to a file named testSFTPConfig.json. // Listing for testSFTPConfig.json { "UserSecretId": "arn:aws::secretsmanager:us-east-2:123456789012:secret:aws/ transfer/example-username-key", "TrustedHostKeys": [ "sftp.example.com ssh-rsa AAAAbbbb...EEEE=" ] } • Specify a security policy for your connector, entering the security policy name. Note The SecretId can be either the entire ARN or the name of the secret (example- username-key in the previous listing). Then run the following command to create the connector. aws transfer create-connector --url "sftp://partner-SFTP-server-url" \ Create an SFTP connector 283 AWS Transfer Family User Guide --access-role your-IAM-role-for-bucket-access \ --logging-role arn:aws:iam::your-account-id:role/service-role/ AWSTransferLoggingAccess \ --sftp-config file:///path/to/testSFTPConfig.json --security-policy-name security-policy-name --maximum-concurrent-connections integer-from-1-to-5 Test an SFTP connector After you create an SFTP connector, we recommend that you test it before you attempt to transfer any files using your new connector. To test an SFTP connector 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. 3. In the left navigation pane, choose SFTP Connectors, and select a connector. From the Actions menu, choose Test connection. The system returns a message, indicating whether the test passes or fails. If the test fails, the system provides an error message based on the reason the test failed. Test an SFTP connector 284 AWS Transfer Family User Guide Note To use the API to test your connector, see the TestConnection API documentation. Using SFTP connectors This topic describes how
|
transferfamily-ug-090
|
transferfamily-ug.pdf
| 90 |
files using your new connector. To test an SFTP connector 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. 3. In the left navigation pane, choose SFTP Connectors, and select a connector. From the Actions menu, choose Test connection. The system returns a message, indicating whether the test passes or fails. If the test fails, the system provides an error message based on the reason the test failed. Test an SFTP connector 284 AWS Transfer Family User Guide Note To use the API to test your connector, see the TestConnection API documentation. Using SFTP connectors This topic describes how to perform the supported file operations using your SFTP connector. You can also find example commands to perform these operations by selecting your connector's details on the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. After you have created an SFTP connector, you can use it to perform the following file operations on the remote SFTP server that it's associated with. • Send files from Amazon S3 to the remote SFTP server. Using SFTP connectors 285 AWS Transfer Family User Guide • Retrieve files from the remote SFTP server to Amazon S3. • List files and sub-folders from a directory on the remote SFTP server. • Delete, rename or move files and directories on the remote SFTP server. Note Currently, SFTP connectors can only be used to connect to remote SFTP servers that offer an internet-accessible endpoint. For details on creating connectors, see Creating SFTP connectors. Topics • Transfer files • List contents of a remote directory • Move, rename, or delete files or directories on the remote server Transfer files Topics • Send and retrieve files by using an SFTP connector Send and retrieve files by using an SFTP connector To send and retrieve files by using an SFTP connector, you use the StartFileTransfer API operation and specify the following parameters, depending on whether you're sending files (outbound transfers) or receiving files (inbound transfers). Note that each StartFileTransfer request can contain 10 distinct paths. Note By default, SFTP connectors process one file at a time, transferring files sequentially. You have an option to accelerate transfer performance by having your connectors create concurrent sessions with remote servers that support concurrent sessions from the same user, and process up to 5 files in parallel. Transfer files 286 AWS Transfer Family User Guide To enable concurrent connections for any connector, you can edit the Maximum conncurent connections setting when creating or updating a connector. For details, see Create an SFTP connector. • Outbound transfers • send-file-paths contains from one to ten source file paths, for files to transfer to the partner's SFTP server. • remote-directory-path is the remote path to send a file to on the customer's SFTP server. • Inbound transfers • retrieve-file-paths contains from one to ten remote paths. Each path specifies a location for transferring files from the partner's SFTP server to your Transfer Family server. • local-directory-path is the Amazon S3 location (bucket and optional prefix) where your files are stored. To send files, you specify the send-file-paths and remote-directory-path parameters. You can specify up to 10 files for the send-file-paths parameter. The following example command sends the files named /amzn-s3-demo-source-bucket/file1.txt and /amzn- s3-demo-source-bucket/file2.txt, located in Amazon S3 storage, to the /tmp directory on your partner's SFTP server. To use this example command, replace the amzn-s3-demo-source- bucket with your own bucket. aws transfer start-file-transfer --send-file-paths /amzn-s3-demo-source-bucket/ file1.txt /amzn-s3-demo-source-bucket/file2.txt \ --remote-directory-path /tmp --connector-id c-1111AAAA2222BBBB3 --region us-east-2 To retrieve files, you specify the retrieve-file-paths and local-directory-path parameters. The following example retrieves the files /my/remote/file1.txt and /my/ remote/file2.txt on the partner's SFTP server, and places it in the Amazon S3 location / amzn-s3-demo-bucket/prefix. To use this example command, replace the user input placeholders with your own information. aws transfer start-file-transfer --retrieve-file-paths /my/remote/file1.txt /my/ remote/file2.txt \ --local-directory-path /amzn-s3-demo-bucket/prefix --connector-id c-2222BBBB3333CCCC4 --region us-east-2 Transfer files 287 AWS Transfer Family User Guide The previous examples specify absolute paths on the SFTP server. You can also use relative paths: that is, paths that are relative to the SFTP user's home directory. For example, if the SFTP user is marymajor and their home directory on the SFTP server is /users/marymajor/, the following command sends /amzn-s3-demo-source-bucket/file1.txt to /users/marymajor/test- connectors/file1.txt aws transfer start-file-transfer --send-file-paths /amzn-s3-demo-source-bucket/ file1.txt \ --remote-directory-path test-connectors --connector-id c-2222BBBB3333CCCC4 -- region us-east-2 List contents of a remote directory Before you retrieve files from a remote SFTP server, you can retrieve the contents of a directory on the remote SFTP server. To do this, you use the StartDirectoryListing API operation. The following example lists the contents of the home folder on the remote SFTP server, which is specified in the connector's configuration. The results are placed into the Amazon S3 location /amzn-s3-demo-bucket/connector-files, and into a file named c- AAAA1111BBBB2222C-6666abcd-11aa-22bb-cc33-0000aaaa3333.json. aws transfer start-directory-listing \ --connector-id c-AAAA1111BBBB2222C \ --output-directory-path /amzn-s3-demo-bucket/example/connector-files \
|
transferfamily-ug-091
|
transferfamily-ug.pdf
| 91 |
aws transfer start-file-transfer --send-file-paths /amzn-s3-demo-source-bucket/ file1.txt \ --remote-directory-path test-connectors --connector-id c-2222BBBB3333CCCC4 -- region us-east-2 List contents of a remote directory Before you retrieve files from a remote SFTP server, you can retrieve the contents of a directory on the remote SFTP server. To do this, you use the StartDirectoryListing API operation. The following example lists the contents of the home folder on the remote SFTP server, which is specified in the connector's configuration. The results are placed into the Amazon S3 location /amzn-s3-demo-bucket/connector-files, and into a file named c- AAAA1111BBBB2222C-6666abcd-11aa-22bb-cc33-0000aaaa3333.json. aws transfer start-directory-listing \ --connector-id c-AAAA1111BBBB2222C \ --output-directory-path /amzn-s3-demo-bucket/example/connector-files \ --remote-directory-path /home This AWS CLI command returns a listing ID and the name of the file that contains the results. { "ListingId": "6666abcd-11aa-22bb-cc33-0000aaaa3333", "OutputFileName": "c-AAAA1111BBBB2222C-6666abcd-11aa-22bb-cc33-0000aaaa3333.json" } Note The naming convention for the output file is connector-ID-listing-ID.json. The JSON file contains the following information: List contents of remote directories 288 AWS Transfer Family User Guide • filePath: the complete path of a remote file, relative to the directory of the listing request for your SFTP connector on the remote server. • modifiedTimestamp: the last time the file was modified, in seconds, Coordinated Universal Time (UTC) format. This field is optional. If the remote file attributes don't contain a timestamp, it is omitted from the file listing. • size: the size of the file, in bytes. This field is optional. If the remote file attributes don't contain a file size, it is omitted from the file listing. • path: the complete path of a remote directory, relative to the directory of the listing request for your SFTP connector on the remote server. • truncated: a flag indicating whether the list output contains all of the items contained in the remote directory or not. If your truncated output value is true, you can increase the value provided in the optional max-items input attribute to be able to list more items (up to the maximum allowed list size of 10,000 items). The following is an example of the contents of the output file (c- AAAA1111BBBB2222C-6666abcd-11aa-22bb-cc33-0000aaaa3333.json), where the remote directory contains two files and two sub-directories (paths). { "files": [ { "filePath": "/home/what.txt", "modifiedTimestamp": "2024-01-30T20:34:54Z", "size" : 2323 }, { "filePath": "/home/how.pgp", "modifiedTimestamp": "2024-01-30T20:34:54Z", "size" : 4691 } ], "paths": [ { "path": "/home/magic" }, { "path": "/home/aws" }, ], List contents of remote directories 289 AWS Transfer Family "truncated": "false" } User Guide Move, rename, or delete files or directories on the remote server Topics • Move or rename files or directories on the remote SFTP server • Delete files or directories on the remote SFTP server Move or rename files or directories on the remote SFTP server You can use an SFTP connector to move or rename files and directories on a remote SFTP server. Note that the remote server needs to support these operations for successful processing using connectors. Some common use cases are as follows. • A remote server generates or receives a new file every hour, with the same filename but a different timestamp. To keep the main folder up to date (so that it contains only the latest file), you can use a connector to move older files to an archived folder. • You use a connector to list all of the files in a remote directory, then transfer all of the files to your local storage. You can then use a connector to move the files to an archived folder on the remote server. You must use a StartRemoteMove call for each file or directory you want to process, as the command takes a single source and destination file or directory as arguments. However, you can accelerate performance by having your connectors create concurrent sessions with remote servers that support concurrent sessions from the same user, and move/rename up to 5 files in parallel. The following example moves a file on the remote SFTP server from /source/folder/ sourceFile to /destination/targetFile, and returns a unique identifier for the operation. aws transfer --connector-id c-AAAA1111BBBB2222C start-remote-move \ --source-path /source/folder/sourceFile --target-path /destination/targetFile Move and delete files on the remote server 290 AWS Transfer Family Note User Guide For the move/rename operations, Transfer Family uses the standard SFTP SSH_FXP_RENAME command to do the move/rename operation. Delete files or directories on the remote SFTP server You can use an SFTP connector to delete files or directories on a remote SFTP server. Note that the remote server needs to support these operations for successful processing using connectors. Note Delete operations for remote directories are only supported for empty directories. Some common use cases are as follows. • You use a connector to retrieve a file from a remote SFTP server, store it in your Amazon S3 bucket, then encrypt it. Finally, you can use a connector to delete the unencrypted file on the remote server.
|
transferfamily-ug-092
|
transferfamily-ug.pdf
| 92 |
move/rename operation. Delete files or directories on the remote SFTP server You can use an SFTP connector to delete files or directories on a remote SFTP server. Note that the remote server needs to support these operations for successful processing using connectors. Note Delete operations for remote directories are only supported for empty directories. Some common use cases are as follows. • You use a connector to retrieve a file from a remote SFTP server, store it in your Amazon S3 bucket, then encrypt it. Finally, you can use a connector to delete the unencrypted file on the remote server. • You use a connector to list all of the files in a remote directory, then transfer all of the files to your local storage. You can then use a connector to delete all of the files that you transferred. You could also delete the remote directory if you prefer. You must use a StartRemoteDelete call for each file or directory you want to delete, as the command takes a single file or directory as an argument. However, you can accelerate performance by having your connectors create concurrent sessions with remote servers that support concurrent sessions from the same user, and delete up to 5 files/directories in parallel. The following example deletes a file on the remote SFTP server in the path /delete/folder/ deleteFile, and returns a unique identifier for the operation. aws transfer start-remote-delete --connector-id c-AAAA1111BBBB2222C \ --delete-path /delete/folder/deleteFile Move and delete files on the remote server 291 AWS Transfer Family Note User Guide For the delete operation, Transfer Family uses the standard SSH_FXP_REMOVE command to delete a file, and SSH_FXP_RMDIR to delete a directory. Monitoring SFTP connectors You can monitor the status of your connector operations using any of the following ways. Choose the approach that meet your needs. Use the connector API to query the status of file transfer requests To track the progress of a file transfer operation, you use the ListFileTransferResults API operation, which returns real-time updates and detailed information on the status of each individual file being transferred in a specific file transfer operation. You specify the file transfer by providing its Connector ID and its Transfer ID. The following example returns a list of files for connector ID a-11112222333344444 and transfer-ID aa1b2c3d4-5678-90ab-cdef-EXAMPLE11111. aws transfer list-file-transfer-results --connector-id a-11112222333344444 --transfer- id a1b2c3d4-5678-90ab-cdef-EXAMPLE11111 Note File transfer results are available up to 7 days after you call the ListFileTransferResults API operation. You can also view logs and events for your file transfer requests that use SFTP connectors. Amazon EventBridge events for Transfer Family are described in SFTP connector events. For how to view Transfer Family CloudWatch log entries, see Viewing Transfer Family log streams. View SFTP connector events in Amazon EventBridge For each operation performed by SFTP connectors, Transfer Family automatically generates and sends events to the default event bus in your Amazon EventBridge account. The events contain detailed metadata about the operation, including the operation status. You can subscribe to these events in EventBridge, apply filters on specific event criteria such as operation status, and Monitoring SFTP connectors 292 AWS Transfer Family User Guide automatically trigger downstream actions based on the status. For details on the events generated by SFTP connector operations, see SFTP connector events. View SFTP connector logs in Amazon CloudWatch All SFTP connector operations generate detailed logs in CloudWatch. For example log entries generated by SFTP connectors, see Example log entries for SFTP connectors. Managing SFTP connectors This topic describes how to view and update SFTP connectors. Note Each connector is automatically assigned static IP addresses that remain unchanged over the lifetime of the connector. This allows you to connect with remote SFTP servers that only accept inbound connections from known IP addresses. Your connectors are assigned a set of static IP addresses that are shared by all connectors using the same protocol (SFTP or AS2) in your AWS account. Update SFTP connectors To change the existing parameter values for your connectors, you can run the update-connector command. The following command updates the secret for the connector connector-id, in the Region region-id to secret-ARN. To use this example command, replace the user input placeholders with your own information. aws transfer update-connector --sftp-config '{"UserSecretId":"secret-ARN"}' \ --connector-id connector-id --region region-id View SFTP connector details You can find a list of details and properties for an SFTP connector in the AWS Transfer Family console. To view connector details 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. View SFTP connector logs in Amazon CloudWatch 293 AWS Transfer Family User Guide 2. In the left navigation pane, choose Connectors. 3. Choose the identifier in the Connector ID column to see the details page for the selected connector. You can change the properties for the SFTP connector by choosing Edit on the connector details page. Note You can
|
transferfamily-ug-093
|
transferfamily-ug.pdf
| 93 |
\ --connector-id connector-id --region region-id View SFTP connector details You can find a list of details and properties for an SFTP connector in the AWS Transfer Family console. To view connector details 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. View SFTP connector logs in Amazon CloudWatch 293 AWS Transfer Family User Guide 2. In the left navigation pane, choose Connectors. 3. Choose the identifier in the Connector ID column to see the details page for the selected connector. You can change the properties for the SFTP connector by choosing Edit on the connector details page. Note You can get much of this information, albeit in a different format, by running the following AWS Command Line Interface (AWS CLI) command. To use this example command, replace the user input placeholders with your own information. aws transfer describe-connector --connector-id your-connector-id For more information, see DescribeConnector in the API reference. Scaling and quotas for SFTP connectors Topics • Quotas for SFTP connectors • Scaling your SFTP connectors Quotas for SFTP connectors The following quotas are in place for SFTP connectors. Note More service quotas for SFTP connectors are listed in AWS Transfer Family endpoints and quotas in the Amazon Web Services General Reference. Quotas for SFTP connectors 294 AWS Transfer Family SFTP connector quotas User Guide Name Default Adjustable Maximum test connection transactions per second (TPS) 1 request per second, per account Maximum queue size for pending file transfers 1000 Maximum file size 150 gibibytes (GiB) Maximum transfer time per file 12 hours Maximum request wait time per file 12 hours Maximum bandwidth for connectors per account (both 50 MBps SFTP and AS2 connectors contribute to this value) Maximum number of items for directory listing operation 10,000 s Maximum number of files 10 per StartFileTransfer request No No No No No No No No Note By default, SFTP connectors process one file at a time, transferring files sequentially. You have an option to accelerate transfer performance by having your connectors create concurrent sessions with remote servers that support concurrent sessions from the same user, and process up to 5 files in parallel. Quotas for SFTP connectors 295 AWS Transfer Family User Guide To enable concurrent connections for any connector, you can edit the Maximum conncurent connections setting when creating or updating a connector. For details, see Create an SFTP connector. For storing the credentials for SFTP connectors, there are quotas associated with each Secrets Manager secret. If you use the same secret to store multiple types of keys, for multiple purposes, you may encounter these quotas. • Total length for a single secret: 12,000 characters • Maximum length of the Password string: 1024 characters • Maximum length of the PrivateKey string: 8192 characters • Maximum length of the Username string: 100 characters Scaling your SFTP connectors This section describes considerations for how to scale your AWS Transfer Family SFTP connector workloads. You need to take into account the following three quotas that apply when you want to scale your workloads with SFTP connectors. • The maximum queue size. This refers to the maximum number of pending operations in a connector’s queue that have been requested. A pending operation refers to any previously submitted transfer request that has not yet completed, either successfully or unsuccessfully. The maximum queue depth for pending requests is currently set at 1,000 per connector (as defined in AWS Transfer Family service quotas). Your workloads may exceed this service limit when you request thousands of transfer operations over a short duration, and you will receive a ThrottlingException with the message Exceeded maximum pending requests. If your workloads are subject to this quota, contact the Transfer Family service team via AWS Support or your account team to discuss your scalability requirements. You can also take either or both of the following actions. • Distribute your file volumes across multiple connectors. • Have your connectors create concurrent sessions with the remote server to process multiple requests from the queue in parallel. Scaling your SFTP connectors 296 AWS Transfer Family User Guide • The number of concurrent sessions. By default, an SFTP connector transfers one file at a time, transferring files sequentially from its queue. You have an option to accelerate transfer performance by having your connectors transfer multiple files in parallel. You can create concurrent sessions with remote servers that support concurrent sessions from the same user, and process up to 5 files in parallel. When you create an SFTP connector, choose a value up to 5 for the Maximum concurrent connections setting when you create or update the connector. For details, see Create an SFTP connector. • The rate of StartFileTransfer requests. You can request up to 100 file paths per second for transfer with each SFTP connector. The requested file paths are added to your connectors’ queue for
|
transferfamily-ug-094
|
transferfamily-ug.pdf
| 94 |
transfer performance by having your connectors transfer multiple files in parallel. You can create concurrent sessions with remote servers that support concurrent sessions from the same user, and process up to 5 files in parallel. When you create an SFTP connector, choose a value up to 5 for the Maximum concurrent connections setting when you create or update the connector. For details, see Create an SFTP connector. • The rate of StartFileTransfer requests. You can request up to 100 file paths per second for transfer with each SFTP connector. The requested file paths are added to your connectors’ queue for processing. You can use the StartFileTransfer command recursively to request up to 100 file paths per second per connector, irrespective of the number of files provided in an individual StartFileTransfer command. Reference architectures using SFTP connectors This section lists the reference materials that are available for configuring automated file transfer workflows using SFTP connectors. You can design your own event-driven architectures by using the SFTP connector events in Amazon EventBridge, to orchestrate between your file transfer action and pre- and post-processing actions in AWS. Blog posts The following blog post provides a reference architecture to build an MFT workflow using SFTP connectors, including encryption of files using PGP before sending them to a remote SFTP server using SFTP connectors: Architecting secure and compliant managed file transfers with AWS Transfer Family SFTP connectors and PGP encryption. Workshops • The following workshop provides hands on labs for configuring SFTP connectors and using your connectors to send or retrieve files from remote SFTP servers: Transfer Family - SFTP workshop. • The following workshop provides hands on labs to build fully automated and event-driven workflows involving file transfer to or from external SFTP servers to Amazon S3, and common pre- and post-processing of those files: Event-driven MFT workshop. Reference architectures using SFTP connectors 297 AWS Transfer Family Solutions User Guide AWS Transfer Family provides the following solutions: • The File transfer synchronization solution provides a reference architecture to automate the process of syncing remote SFTP directories—including entire folder structures—with your local Amazon S3 buckets using an SFTP connector. It orchestrates the process of listing remote directories, detecting changes, and transferring new or modified files. • Serverlessland - Selective file transfer between remote SFTP server & S3; using AWS Transfer Family provides a sample pattern for listing files stored on remote SFTP locations, and transferring selective files to Amazon S3. Solutions 298 AWS Transfer Family User Guide AWS Transfer Family for AS2 Applicability Statement 2 (AS2) is an RFC-defined file-transmission specification that includes strong message protection and verification mechanisms. The AS2 protocol is critical to workflows with compliance requirements that rely on having data protection and security features built into the protocol. Note AS2 for Transfer Family is Drummond certified. Customers in industries such as retail, life sciences, manufacturing, financial services, and utilities that rely on AS2 for supply chain, logistics, and payments workflows can use AWS Transfer Family AS2 endpoints to securely transact with their business partners. The transacted data is natively accessible in AWS for processing, analysis, and machine learning. This data is also available for integrations with enterprise resource planning (ERP) and customer relationship management (CRM) systems that run on AWS. With AS2, customers can run their business-to-business (B2B) transactions at scale in AWS while maintaining existing business partner integrations and compliance. If you are a Transfer Family customer who wants to exchange files with a partner who has an AS2-enabled server, the setup involves generating one public-private key pair for encryption and another for signing and exchanging the public keys with the partner. Transfer Family provides a workshop that you can attend, in which you can configure a Transfer Family endpoint with AS2 enabled, and a Transfer Family AS2 connector. You can view the details for this workshop here. Protecting an AS2 payload in transit typically involves the use of Cryptographic Message Syntax (CMS) and commonly uses encryption and a digital signature to provide data protection and peer authentication. A signed Message Disposition Notice (MDN) response payload provides verification (non-repudiation) that a message was received and successfully decrypted. Transport of these CMS payloads and MDN responses occurs over HTTP. 299 AWS Transfer Family Note User Guide HTTPS AS2 server endpoints are not currently supported. TLS termination is currently the responsibility of the customer. For a detailed, step-by-step walkthrough of setting up an Applicability Statement 2 (AS2) configuration, see the tutorial, Setting up an AS2 configuration. The user guide provides instructions for each step in the process of configuring AS2 in Transfer Family. 1. Import AS2 certificates 2. Create AS2 profiles 3. Create an AS2 server 4. Create an AS2 agreement 5. Configure AS2 connectors AS2 use cases If you are an AWS Transfer Family customer who wants to exchange files with
|
transferfamily-ug-095
|
transferfamily-ug.pdf
| 95 |
Transfer Family Note User Guide HTTPS AS2 server endpoints are not currently supported. TLS termination is currently the responsibility of the customer. For a detailed, step-by-step walkthrough of setting up an Applicability Statement 2 (AS2) configuration, see the tutorial, Setting up an AS2 configuration. The user guide provides instructions for each step in the process of configuring AS2 in Transfer Family. 1. Import AS2 certificates 2. Create AS2 profiles 3. Create an AS2 server 4. Create an AS2 agreement 5. Configure AS2 connectors AS2 use cases If you are an AWS Transfer Family customer who wants to exchange files with a partner who has an AS2-enabled server, the most complex part of the setup involves generating one public-private key pair for encryption and another for signing and exchanging the public keys with the partner. AS2 use cases 300 AWS Transfer Family User Guide Consider the following variations for using AWS Transfer Family with AS2. Note Trading partner is the partner associated with that partner profile. All mentions of MDN in the following table assume signed MDNs. AS2 use cases Inbound-only use cases • Transfer encrypted AS2 messages from a trading partner to a Transfer Family server. In this case, you do the following: 1. Create profiles for your trading partner and yourself. 2. Create a Transfer Family server that uses the AS2 protocol. 3. Create an agreement and add it to your server. 4. Import a certificate with a private key and add it to your profile, and then import the public key to your partner profile for encryption. 5. After you have these items, send the public key for your certificate to your trading partner. AS2 use cases 301 AWS Transfer Family User Guide Now your partner can send you encrypted messages and you can decrypt them and store them in your Amazon S3 bucket. • Transfer encrypted AS2 messages from a trading partner to a Transfer Family server and add signing. In this scenario, you are still doing only inbound transfers, but now you want to have your partner sign the messages that they send. In this case, import the trading partner's signing public key (as a signing certificate added to your partner's profile). • Transfer encrypted AS2 messages from a trading partner to a Transfer Family server and add signing and sending an MDN response. In this scenario, you are still doing only inbound transfers, but now, in addition to receiving signed payloads, your trading partner wants to receive a signed MDN response. 1. 2. Import your public and private signing keys (as a signing certificate to your profile). Send the public signing key to your trading partner. AS2 use cases 302 AWS Transfer Family User Guide Outbound-only use cases • Transfer encrypted AS2 messages from a Transfer Family server to a trading partner. This case is similar to the inbound-only transfer use case, except that instead of adding an agreement to your AS2 server, you create a connector. In this case, you import your trading partner's public key to their profile. • Transfer encrypted AS2 messages from a Transfer Family server to a trading partner and add signing. You are still doing only outbound transfers, but now your trading partner wants you to sign the message that you send to them. 1. Import your signing private key (as a signing certificate added to your profile). 2. Send your trading partner your public key. • Transfer encrypted AS2 messages from a Transfer Family server to a trading partner and add signing and send an MDN response. You are still doing only outbound transfers, but now, in addition to sending signed payloads, you want to receive a signed MDN response from your trading partner. 1. Your trading partner sends you their public signing key. 2. Import your trading partner's public key (as a signing certificate added to your partner profile). AS2 use cases 303 AWS Transfer Family User Guide Inbound and outbound use cases • Transfer encrypted AS2 messages in both directions between a Transfer Family server and a trading partner. In this case, you do the following: 1. Create profiles for your trading partner and yourself. 2. Create a Transfer Family server that uses the AS2 protocol. 3. Create an agreement and add it to your server. 4. Create a connector. 5. Import a certificate with a private key and add it to your profile, and then import the public key to your partner profile for encryption. 6. Receive a public key from your trading partner and add it to their profile for encryption. 7. After you have these items, send the public key for your certificate to your trading partner. Now you and your trading partner can exchange encrypted messages, and you can both decrypt them. You can store the messages that you receive in your
|
transferfamily-ug-096
|
transferfamily-ug.pdf
| 96 |
3. Create an agreement and add it to your server. 4. Create a connector. 5. Import a certificate with a private key and add it to your profile, and then import the public key to your partner profile for encryption. 6. Receive a public key from your trading partner and add it to their profile for encryption. 7. After you have these items, send the public key for your certificate to your trading partner. Now you and your trading partner can exchange encrypted messages, and you can both decrypt them. You can store the messages that you receive in your Amazon S3 bucket, and your partner can decrypt and store the messages that you send to them. • Transfer encrypted AS2 messages in both directions between a Transfer Family server and a trading partner and add signing. Now you and your partner want signed messages. 1. Import your signing private key (as a signing certificate added to your profile). 2. Send your trading partner your public key. 3. Import your trading partner's signing public key and add it to their profile. • Transfer encrypted AS2 messages in both directions between a Transfer Family server and a trading partner and add signing and send an MDN response. Now, you want to exchange signed payloads, and both you and your trading partner want MDN responses. 1. Your trading partner sends you their public signing key. 2. 3. Import your trading partner's public key (as a signing certificate to your partner profile). Send your public key to your trading partner. AS2 use cases 304 AWS Transfer Family User Guide AS2 CloudFormation templates This topic provides information about AWS CloudFormation templates that you can use to quickly deploy AS2 servers and configurations for AWS Transfer Family. These templates automate the setup process and help you implement best practices for AS2 file transfers. • The basic AS2 template is described in Use a template to create a demo Transfer Family AS2 stack • The AS2 template for customizing HTTP headers is described in Customize HTTP headers for AS2 messages. Customizing AS2 templates You can customize the provided templates to meet your specific requirements: 1. Download the template from the S3 URL. 2. Modify the YAML code to adjust configurations such as: • Security settings and certificate configurations • Network architecture and VPC settings • Storage options and file handling • Monitoring and notification preferences 3. Upload your modified template to your own S3 bucket. 4. Deploy the customized template using the AWS CloudFormation console or AWS CLI. Important When customizing templates, ensure that you maintain the dependencies between resources and follow security best practices. Testing your AS2 deployment After deploying an AS2 server using a template, you can test the configuration: 1. Check the CloudFormation stack outputs for sample commands and endpoint information. AS2 CloudFormation templates 305 AWS Transfer Family User Guide 2. Use the AWS CLI to send a test file: aws s3api put-object --bucket your-bucket-name --key test.txt --body test.txt aws transfer start-file-transfer --connector-id your-connector-id --send-file- paths /your-bucket-name/test.txt 3. Verify file delivery in the destination S3 bucket. 4. Check CloudWatch logs for successful processing and MDN responses. For more comprehensive testing, consider using third-party AS2 clients to send files to your Transfer Family AS2 server. Best practices for AS2 template deployment Follow these best practices when using AS2 CloudFormation templates: Security Use strong certificates and rotate them regularly. Implement least-privilege IAM policies. Restrict network access using security groups. Reliability Deploy across multiple Availability Zones. Implement monitoring and alerting for failed transfers. Set up automated retries for failed transfers. Performance Choose appropriate instance types for your transfer volume. Implement S3 lifecycle policies for efficient file management. Monitor and optimize network configurations. Cost Optimization Use auto-scaling for variable workloads. Implement S3 storage classes for older files. Best practices for AS2 template deployment 306 AWS Transfer Family User Guide Monitor and adjust resources based on actual usage. Configuring AS2 To create an AS2-enabled server, you must also specify the following components: • Agreements – Bilateral trading partner agreements, or partnerships, define the relationship between the two parties that are exchanging messages (files). To define an agreement, Transfer Family combines server, local profile, partner profile, and certificate information. Transfer Family AS2-inbound processes use agreements. • Certificates – Public key (X.509) certificates are used in AS2 communication for message encryption and verification. Certificates are also used for connector endpoints. • Local profiles and partner profiles – A local profile defines the local (AS2-enabled Transfer Family server) organization or "party." Similarly, a partner profile defines the remote partner organization, external to Transfer Family. While not required for all AS2-enabled servers, for outbound transfers, you need a connector. A connector captures the parameters for an outbound connection. The connector is required for sending files to a customer's external, non AWS server.
|
transferfamily-ug-097
|
transferfamily-ug.pdf
| 97 |
Transfer Family AS2-inbound processes use agreements. • Certificates – Public key (X.509) certificates are used in AS2 communication for message encryption and verification. Certificates are also used for connector endpoints. • Local profiles and partner profiles – A local profile defines the local (AS2-enabled Transfer Family server) organization or "party." Similarly, a partner profile defines the remote partner organization, external to Transfer Family. While not required for all AS2-enabled servers, for outbound transfers, you need a connector. A connector captures the parameters for an outbound connection. The connector is required for sending files to a customer's external, non AWS server. The following diagram shows the relationship between the AS2 objects involved in the inbound and outbound processes. Configure AS2 307 AWS Transfer Family User Guide For an end-to-end example AS2 configuration, see Setting up an AS2 configuration. Topics • AS2 configurations • AS2 quotas and limitations • AS2 features and capabilities AS2 configurations This topic describes the supported configurations, features, and capabilities for transfers that use the Applicability Statement 2 (AS2) protocol, including the accepted ciphers and digests. Signing, encryption, compression, MDN For both inbound and outbound transfers, the following items are either required or optional: • Encryption – Required (for HTTP transport, which is the only transport method currently supported). Unencrypted messages are only accepted if forwarded by a TLS-terminating proxy such as an Application Load Balancer (ALB) and the X-Forwarded-Proto: https header is present. • Signing – Optional • Compression – Optional (the only currently supported compression algorithm is ZLIB) • Message Disposition Notice (MDN) – Optional Ciphers The following ciphers are supported for both inbound and outbound transfers: • AES128_CBC • AES192_CBC • AES256_CBC • 3DES (for backward compatibility only) Digests The following digests are supported: AS2 configurations 308 AWS Transfer Family User Guide • Inbound signing and MDN – SHA1, SHA256, SHA384, SHA512 • Outbound signing and MDN – SHA1, SHA256, SHA384, SHA512 MDN For MDN responses, certain types are supported, as follows: • Inbound transfers – Synchronous and asynchronous • Outbound transfers – Synchronous only • Simple Mail Transfer Protocol (SMTP) (email MDN) – Not supported Transports • Inbound transfers – HTTP is the only currently supported transport, and you must specify it explicitly. Note If you need to use HTTPS for inbound transfers, you can terminate TLS on an Application Load Balancer or a Network Load Balancer. This is described in Receive AS2 messages over HTTPS. • Outbound transfers – If you provide an HTTP URL, you must also specify an encryption algorithm. If you provide an HTTPS URL, you have the option of specifying NONE for your encryption algorithm. AS2 quotas and limitations This section discusses quotas and limitations for AS2 Topics • AS2 quotas • Quotas for handling secrets • Known limitations AS2 quotas 309 AWS Transfer Family AS2 quotas User Guide The following quotas are in place for AS2 file transfers. To request an increase for a quota that's adjustable, see AWS service quotas in the AWS General Reference. AS2 quotas Name Default Adjustable Maximum number of inbound files received per second Maximum number of outbound files sent per second Maximum number of concurrent inbound files Maximum number of concurrent outbound files Maximum size of inbound file (uncompressed) Maximum size of outbound file (uncompressed) 100 100 400 400 1 GB 1 GB Maximum number of files per outbound request 10 Maximum number of outbound requests per second 100 Maximum number of inbound requests per second 100 Maximum outbound bandwidth per account (outbound SFTP and AS2 50 MB per second No No No No No No No No No No AS2 quotas 310 AWS Transfer Family User Guide Name Default Adjustable requests both contribute to this value) Maximum number of agreements per server Maximum number of connectors per account (SFTP and AS2 connectors both contribute to this limit) 100 100 Maximum number of certifica tes per partner profile 10 Maximum number of certifica tes per account 1000 Maximum number of partner profiles per account 1000 Quotas for handling secrets Yes Yes No Yes Yes AWS Transfer Family makes calls to AWS Secrets Manager on behalf of AS2 customers that are using Basic authentication. Additionally Secrets Manager makes calls to AWS KMS. Note These quotas aren't specific to your use of secrets for Transfer Family: they're shared among all the services in your AWS account. For Secrets Manager GetSecretValue, the quota that applies is Combined rate of DescribeSecret and GetSecretValue API requests, as described in AWS Secrets Manager quotas. AS2 quotas 311 AWS Transfer Family User Guide Secrets Manager GetSecretValue Name Value Description Combined rate of DescribeS ecret and GetSecretValue API Each supported Region: 10,000 per second requests The maximum transactions per second for DescribeS ecret and GetSecret Value API operations combined. For AWS KMS, the following quotas apply for Decrypt. For details,
|
transferfamily-ug-098
|
transferfamily-ug.pdf
| 98 |
These quotas aren't specific to your use of secrets for Transfer Family: they're shared among all the services in your AWS account. For Secrets Manager GetSecretValue, the quota that applies is Combined rate of DescribeSecret and GetSecretValue API requests, as described in AWS Secrets Manager quotas. AS2 quotas 311 AWS Transfer Family User Guide Secrets Manager GetSecretValue Name Value Description Combined rate of DescribeS ecret and GetSecretValue API Each supported Region: 10,000 per second requests The maximum transactions per second for DescribeS ecret and GetSecret Value API operations combined. For AWS KMS, the following quotas apply for Decrypt. For details, see Request quotas for each AWS KMS API operation AWS KMS Decrypt Quota name Default value (requests per second) Cryptographic operations (symmetric) request rate These shared quotas vary with the AWS Region and the type of AWS KMS key used in the request. Each quota is calculated separatel y. • 5,500 (shared) • 10,000 (shared) in the following Regions: • US East (Ohio), us-east-2 • Asia Pacific (Singapore), ap-southeast-1 • Asia Pacific (Sydney), ap-southeast-2 • Asia Pacific (Tokyo), ap-northeast-1 • Europe (Frankfurt), eu-central-1 • Europe (London), eu-west-2 • 50,000 (shared) in the following Regions: • US East (N. Virginia), us-east-1 • US West (Oregon), us-west-2 • Europe (Ireland), eu-west-1 AS2 quotas 312 AWS Transfer Family Quota name Custom key store request quotas Note User Guide Default value (requests per second) Custom key store request quotas are calculate d separately for each custom key store. • 1,800 (shared) for each AWS CloudHSM key This quota only applies if you are using store an external key store. • 1,800 (shared) for each external key store Known limitations • Server-side TCP keep-alive is not supported. The connection times out after 350 seconds of inactivity unless the client sends keep-alive packets. • For an active agreement to be accepted by the service and appear in Amazon CloudWatch logs, messages must contain valid AS2 headers. • The server that's receiving messages from AWS Transfer Family for AS2 must support the Cryptographic Message Syntax (CMS) algorithm protection attribute for validating message signatures, as defined in RFC 6211. This attribute is not supported in some older IBM Sterling products. • Duplicate message IDs result in a processed/Warning: duplicate-document message. • The key length for AS2 certificates must be at least 2048 bits, and at most 4096. • When sending AS2 messages or asynchronous MDNs to a trading partner's HTTPS endpoint, the messages or MDNs must use a valid SSL certificate that's signed by a publicly trusted certificate authority (CA). Self-signed certificates are currently supported for outbound transfers only. • The endpoint must support the TLS version 1.2 protocol and a cryptographic algorithm that's permitted by the security policy (as described in Security policies for AWS Transfer Family servers). • Multiple attachments and certificate exchange messaging (CEM) from AS2 version 1.2 is not currently supported. • Basic authentication is currently supported for outbound messages only. • You can attach a file-processing workflow to a Transfer Family server that uses the AS2 protocol: however, AS2 messages don't execute workflows attached to the server. AS2 quotas 313 AWS Transfer Family User Guide AS2 features and capabilities The following tables list the features and capabilities available for Transfer Family resources that use AS2. AS2 features Transfer Family offers the following features for AS2. Feature Supported by AWS Transfer Family Drummond certification AWS CloudFormation support Amazon CloudWatch metrics SHA-2 cryptographic algorithms Support for Amazon S3 Support for Amazon EFS Scheduled Messages AWS Transfer Family Managed Workflows Certificate Exchange Messaging (CEM) Mutual TLS (mTLS) Support for self-signed certificates Yes Yes Yes Yes Yes No Yes 1 No No No Yes 1. Outbound Scheduled Messages available by scheduling AWS Lambda functions using Amazon EventBridge AS2 send and receive capabilities The following table provides a list of AWS Transfer Family AS2 send and receive capabilities. AS2 features and capabilities 314 AWS Transfer Family Capability Inbound: Receiving with server Outbound: Sending with connector User Guide TLS Encrypted Transport (HTTPS) Yes 1 Non-TLS Transport (HTTP) Synchronous MDN Message Compression Asynchronous MDN Static IP Address Bring Your Own IP Address Multiple File Attachments Basic Authentication Yes Yes Yes Yes Yes Yes No No AS2 Restart Not applicable AS2 Reliability No Custom Subject per Message Not applicable Yes Yes 2 Yes Yes No Yes No No Yes No No No 1. Inbound TLS Encrypted Transport available with Network Load Balancer (NLB) or Application Load Balancer (ALB) 2. Outbound non-TLS Transport available only when encryption is enabled Manage AS2 certificates This topic discusses how to import and manage AS2 certificates. Importing certificates is the first step in the AS2 process for Transfer Family. 1. Import certificates 2. Create AS2 profiles Manage AS2 certificates 315 AWS Transfer Family 3. Create an AS2 server 4. Create an AS2 agreement 5. Configure AS2
|
transferfamily-ug-099
|
transferfamily-ug.pdf
| 99 |
Reliability No Custom Subject per Message Not applicable Yes Yes 2 Yes Yes No Yes No No Yes No No No 1. Inbound TLS Encrypted Transport available with Network Load Balancer (NLB) or Application Load Balancer (ALB) 2. Outbound non-TLS Transport available only when encryption is enabled Manage AS2 certificates This topic discusses how to import and manage AS2 certificates. Importing certificates is the first step in the AS2 process for Transfer Family. 1. Import certificates 2. Create AS2 profiles Manage AS2 certificates 315 AWS Transfer Family 3. Create an AS2 server 4. Create an AS2 agreement 5. Configure AS2 connectors Import AS2 certificates User Guide The Transfer Family AS2 process uses certificate keys for both encryption and signing of transferred information. Partners can use the same key for both purposes, or a separate key for each. If you have common encryption keys kept in escrow by a trusted third-party so that data can be decrypted in the event of a disaster or security breach, we recommend having separate signing keys. By using separate signing keys (which you do not escrow), you don't compromise the non- repudiation features of your digital signatures. Note The key length for AS2 certificates must be at least 2048 bits, and at most 4096. The following points detail how AS2 certificates are used during the process. • Inbound AS2 • The trading partner sends their public key for the signing certificate, and this key is imported to the partner profile. • The local party sends the public key for their encryption and signing certificates. The partner then imports the private key or keys. The local party can send separate certificate keys for signing and encryption, or can choose to use the same key for both purposes. • Outbound AS2 • The partner sends the public key for their encryption certificate, and this key is imported to the partner profile. • The local party sends the public key for the certificate for signing, and imports the private key of the certificate for signing. • If you are using HTTPS, you can import a self-signed Transport Layer Security (TLS) certificate. For details on how to create certificates, see the section called “Step 1: Create certificates for AS2”. Import AS2 certificates 316 AWS Transfer Family User Guide This procedure explains how to import certificates by using the Transfer Family console. If you want to use the AWS CLI instead, see the section called “Step 3: Import certificates as Transfer Family certificate resources”. To specify an AS2-enabled certificate 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the left navigation pane, under AS2 Trading Partners, choose Certificates. 3. Choose Import certificate. 4. 5. In the Certificate configuration section, for Certificate description, enter an easily identifiable name for the certificate. Make sure that you can identify the certificate's purpose by its description. Additionally, choose the role for the certificate. In the Certificate usage section, choose the purpose for this certificate. It can be used for encryption, signing, or both. Tip: If you choose Encryption and signing for the usage, Transfer Family creates two identical certificates (each having their own ID): one with a usage value of ENCRYPTION and one with a usage value of SIGNING. 6. In the Certificate contents section, provide a public certificate from a trading partner, or the public and private keys for a local certificate. Fill in the Certificate contents section with the appropriate details. • If you choose Self-signed certificate, you do not provide the certificate chain. • Paste the certificate text and its chain into the Certificate and Certificate chain field. • If this certificate is a local certificate, paste in its private key. 7. Choose Import certificate to complete the process and save the details for the imported certificate. Note TLS certificates can only be imported as a partner's public certificate. If you select Public certificate from a partner, and then select Transport Layer Security (TLS) for the usage, you receive a warning. Also, TLS certificates must be self-signed (that is, you must select Self Signed Certificate to import a TLS certificate). Import AS2 certificates 317 AWS Transfer Family AS2 certificate rotation User Guide Often, certificates are valid for a period of six months to a year. You might have set up profiles that you want to persist for a longer duration. To facilitate this, Transfer Family provides certificate rotation. You can specify multiple certificates for a profile, allowing you to keep using the profile for multiple years. Transfer Family uses certificates for signing (optional) and encryption (mandatory). You can specify a single certificate for both purposes, if you like. Certificate rotation is the process of replacing an old expiring certificate with a newer certificate. The transition is a gradual one to avoid disrupting transfers where a partner in the agreement
|
transferfamily-ug-100
|
transferfamily-ug.pdf
| 100 |
of six months to a year. You might have set up profiles that you want to persist for a longer duration. To facilitate this, Transfer Family provides certificate rotation. You can specify multiple certificates for a profile, allowing you to keep using the profile for multiple years. Transfer Family uses certificates for signing (optional) and encryption (mandatory). You can specify a single certificate for both purposes, if you like. Certificate rotation is the process of replacing an old expiring certificate with a newer certificate. The transition is a gradual one to avoid disrupting transfers where a partner in the agreement has yet to configure a new certificate for outbound transfers or might be sending payloads that are signed or encrypted with an old certificate during a period when a newer certificate might also be in use. The intermediate period where both old and new certificates are valid is referred to as a grace period. X.509 certificates have Not Before and Not After dates. However, these parameters might not provide enough control for administrators. Transfer Family provides Active Date and Inactive Date settings to control which certificate is used for outbound payloads and which is accepted for inbound payloads. Outbound certificate selection uses the maximum value that is prior to the date of the transfer as an Inactive Date. Inbound processes accept certificates within the range of Not Before and Not After and within the range of Active Date and Inactive Date. The following table describes one possible way to configure two certificates for a single profile. Two certificates in rotation Name NOT BEFORE (controlled ACTIVE DATE (set by Transfer INACTIVE DATE (set by Transfer NOT AFTER (set by certificate by certificate Family) Family) authority) authority) Cert1 (older certificate) Cert2 (newer certificate) 2019-11-01 2020-01-01 2020-12-31 2024-01-01 2020-11-01 2020-06-01 2021-06-01 2025-01-01 AS2 certificate rotation 318 AWS Transfer Family Note the following: User Guide • When you specify an Active Date and Inactive Date for a certificate, the range must be inside the range between Not Before and Not After. • We recommend that you configure several certificates for each profile, making sure that the active date range for all the certificates combined covers the amount of time for which you want to use the profile. • We recommend that you specify some grace time between when your older certificate becomes inactive and when your newer certificate becomes active. In the preceding example, the first certificate does not become inactive until 2020-12-31, while the second certificate becomes active on 2020-06-01, providing a 6-month grace period. During the period from 2020-06-01 until 2020-12-31, both certificates are active. Create AS2 profiles This topic discusses how to create profiles for use in the AS2 process. A local profile defines the local (AS2-enabled Transfer Family server) organization or "party." Similarly, a partner profile defines the remote partner organization, external to Transfer Family. 1. Import AS2 certificates 2. Create AS2 profiles 3. Create an AS2 server 4. Create an AS2 agreement 5. Configure AS2 connectors Use this procedure to create both local and partner profiles. This procedure explains how to create AS2 profiles by using the Transfer Family console. If you want to use the AWS CLI instead, see the section called “Step 3: Create profiles for you and your trading partner”. To create an AS2 profile 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the left navigation pane, under AS2 Trading Partners, choose Profiles, then choose Create profile. Create AS2 profiles 319 AWS Transfer Family User Guide 3. In the Profile configuration section, enter the AS2 ID for the profile. This value is used for the AS2 protocol-specific HTTP headers as2-from and as2-to to identify the trading partnership, which determines the certificates to use, and so on. 4. 5. In the Profile type section, choose Local profile or Partner profile. In the Certificates section, choose one or more certificates from the dropdown menu. Tip: If you want to import a certificate that is not listed in the dropdown menu, select Import a new Certificate. This opens a new browser window at the Import certificate screen. For the procedure about importing certificates see Import AS2 certificates. 6. (Optional) In the Tags section, specify one or more key-value pairs to help identify this profile. 7. Choose Create profile to complete the process and save the new profile. Create an AS2 server This topic provides instructions for creating an AS2-enabled Transfer Family server, using either the console or a AWS CloudFormation template. For an end-to-end example AS2 configuration, see Setting up an AS2 configuration. After you create an AS2 server, you can add an agreement to the server. 1. Import AS2 certificates 2. Create AS2 profiles 3. Create an AS2 server 4. Create an AS2 agreement 5. Configure AS2 connectors Topics • Create an AS2 server using
|
transferfamily-ug-101
|
transferfamily-ug.pdf
| 101 |
more key-value pairs to help identify this profile. 7. Choose Create profile to complete the process and save the new profile. Create an AS2 server This topic provides instructions for creating an AS2-enabled Transfer Family server, using either the console or a AWS CloudFormation template. For an end-to-end example AS2 configuration, see Setting up an AS2 configuration. After you create an AS2 server, you can add an agreement to the server. 1. Import AS2 certificates 2. Create AS2 profiles 3. Create an AS2 server 4. Create an AS2 agreement 5. Configure AS2 connectors Topics • Create an AS2 server using the Transfer Family console • Use a template to create a demo Transfer Family AS2 stack • Create an AS2 agreement Create an AS2 server 320 AWS Transfer Family User Guide Create an AS2 server using the Transfer Family console This procedure explains how to create an AS2-enabled server by using the Transfer Family console. If you want to use the AWS CLI instead, see the section called “Step 4: Create a Transfer Family server that uses the AS2 protocol”. Note You can attach a file-processing workflow to a Transfer Family server that uses the AS2 protocol: however, AS2 messages don't execute workflows attached to the server. To create an AS2-enabled server 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the left navigation pane, choose Servers, and then choose Create server. 3. On the Choose protocols page, select AS2 (Applicability Statement 2), and then choose Next. 4. On the Choose an identity provider page, choose Next. Note For AS2, you cannot choose an identity provider because basic authentication is not supported for the AS2 protocol. Instead, you control access through virtual private cloud (VPC) security groups. 5. On the Choose an endpoint page, do the following: Create an AS2 server using the Transfer Family console 321 AWS Transfer Family User Guide a. For Endpoint type, choose VPC hosted to host your server's endpoint. For information about setting up your VPC-hosted endpoint, see Create a server in a virtual private cloud. Note Publicly accessible endpoints are not supported for the AS2 protocol. To make your VPC endpoint accessible over the internet, choose Internet Facing under Access, and then supply your Elastic IP addresses. b. For Access, choose one of the following options: Create an AS2 server using the Transfer Family console 322 AWS Transfer Family User Guide • Internal – Choose this option to provide access from within your VPC and VPC- connected environments, such as an on-premises data center over AWS Direct Connect or VPN. • Internet Facing – Choose this option to provide access over the internet and from within your VPC and VPC-connected environments, such as an on-premises data center over AWS Direct Connect or VPN. If you choose Internet Facing, supply your Elastic IP addresses when prompted. For VPC, either choose an existing VPC or choose Create VPC to create a new VPC. For FIPS Enabled, keep the FIPS Enabled endpoint check box cleared. c. d. Note FIPS-enabled endpoints are not supported for the AS2 protocol. e. Choose Next. 6. On the Choose a domain page, choose Amazon S3 to store and access your files as objects by using the selected protocol. Choose Next. 7. On the Configure additional details page, choose the settings that you need. Note If you are configuring any other protocols along with AS2, all of the additional detail settings apply. However, for the AS2 protocol, the only settings that apply are those in the CloudWatch logging and Tags sections. Even though setting up a CloudWatch logging role is optional, we highly recommend setting it up so that you can see the status of your messages and troubleshoot configuration issues. 8. On the Review and create page, review your choices to make sure they are correct. • If you want to edit any of your settings, choose Edit next to the step that you want to change. Create an AS2 server using the Transfer Family console 323 AWS Transfer Family Note User Guide If you edit a step, we recommend that you review each step after the step that you chose to edit. • If you have no changes, choose Create server to create your server. You are taken to the Servers page, shown following, where your new server is listed. It can take several minutes before the status for your new server changes to Online. At that point, your server can perform file operations for your users. Use a template to create a demo Transfer Family AS2 stack We supply a self-contained, AWS CloudFormation template to quickly create an AS2-enabled Transfer Family server. The template configures the server with a public Amazon VPC endpoint, certificates, local and partner profiles, an agreement, and a connector. The basic AS2 server template
|
transferfamily-ug-102
|
transferfamily-ug.pdf
| 102 |
Create server to create your server. You are taken to the Servers page, shown following, where your new server is listed. It can take several minutes before the status for your new server changes to Online. At that point, your server can perform file operations for your users. Use a template to create a demo Transfer Family AS2 stack We supply a self-contained, AWS CloudFormation template to quickly create an AS2-enabled Transfer Family server. The template configures the server with a public Amazon VPC endpoint, certificates, local and partner profiles, an agreement, and a connector. The basic AS2 server template creates the following resources: • An AS2-enabled Transfer Family server with a VPC endpoint • Local and partner AS2 profiles with certificates • An agreement between the profiles • An Amazon S3 bucket for file storage • Required IAM roles and policies • CloudWatch logging configuration Before using this template, note the following: • If you create a stack from this template, you will be billed for the AWS resources that are used. • The template creates multiple certificates and places them in AWS Secrets Manager to store them securely. You can delete these certificates from Secrets Manager if you want, because you're charged for using this service. Deleting these certificates in Secrets Manager doesn't delete them from the Transfer Family server. Therefore, the functionality of the demo stack isn't affected. However, for certificates that you're going to use with a production AS2 server, you might want to use Secrets Manager to manage and periodically rotate your stored certificates. Create an AS2 server using a template 324 AWS Transfer Family User Guide • We recommend that you use the template as a base only, and mainly for demonstration purposes. If you want to use this demo stack in production, we recommend that you modify the template's YAML code to create a more robust stack. For example, create production-level certificates, and create an AWS Lambda function that you can use in production. To create an AS2-enabled Transfer Family server from a CloudFormation template 1. Open the AWS CloudFormation console at https://console.aws.amazon.com/cloudformation. 2. In the left navigation pane, choose Stacks. 3. Choose Create stack, and then choose With new resources (standard). 4. In the Prerequisite - Prepare template section, choose Choose an existing template. 5. Copy this link, AS2 demo template, and paste it into the Amazon S3 URL field. 6. Choose Next. 7. On the Specify stack details page, name your stack, and then specify the following parameters: • Under AS2, enter values for Local AS2 ID and Partner AS2 ID, or accept the defaults, local and partner, respectively. • Under Network, enter a value for Security group ingress CIDR IP, or accept the default, 0.0.0.0/0. Note This value, in CIDR format, specifies which IP addresses are allowed for incoming traffic to the AS2 server. The default value, 0.0.0.0/0, allows all IP addresses. • Under General, enter a value for Prefix, or accept the default, transfer-as2. This prefix is placed before any resource names that are created by the stack. For example, if you use the default prefix, your Amazon S3 bucket is named transfer-as2-amzn-s3-demo-bucket. 8. Choose Next. On the Configure stack options page, choose Next again. 9. Review the details for the stack that you're creating, and then choose Create stack. Create an AS2 server using a template 325 AWS Transfer Family Note User Guide At the bottom of the page, under Capabilities, you must acknowledge that AWS CloudFormation might create AWS Identity and Access Management (IAM) resources. After the stack is created, you can send a test AS2 message from the partner server to your local Transfer Family server by using the AWS Command Line Interface (AWS CLI). A sample AWS CLI command for sending a test message is created along with all of the other resources in the stack. To use this sample command, go to the Outputs tab of your stack, and copy the TransferExampleAs2Command. You can then run the command by using the AWS CLI. If you haven't already installed the AWS CLI, see Installing or updating the latest version of the AWS CLI in the AWS Command Line Interface User Guide. The sample command has the following format: aws s3api put-object --bucket amzn-s3-demo-bucket --key test.txt && aws transfer start- file-transfer --region aws-region --connector-id TransferConnectorId --send-file- paths /amzn-s3-demo-bucket/test.txt Note Your version of this command contains the actual values for the amzn-s3-demo-bucket and TransferConnectorId resources in your stack. This sample command consists of two separate commands that are chained together by using the && string. The first command creates a new, empty text file in your bucket: aws s3api put-object --bucket amzn-s3-demo-bucket --key test.txt Then, the second command uses the connector to send the file from the partner profile to the local profile. The Transfer Family server
|
transferfamily-ug-103
|
transferfamily-ug.pdf
| 103 |
the following format: aws s3api put-object --bucket amzn-s3-demo-bucket --key test.txt && aws transfer start- file-transfer --region aws-region --connector-id TransferConnectorId --send-file- paths /amzn-s3-demo-bucket/test.txt Note Your version of this command contains the actual values for the amzn-s3-demo-bucket and TransferConnectorId resources in your stack. This sample command consists of two separate commands that are chained together by using the && string. The first command creates a new, empty text file in your bucket: aws s3api put-object --bucket amzn-s3-demo-bucket --key test.txt Then, the second command uses the connector to send the file from the partner profile to the local profile. The Transfer Family server has an agreement set up that allows the local profile to accept messages from the partner profile. Create an AS2 server using a template 326 AWS Transfer Family User Guide aws transfer start-file-transfer --region aws-region --connector-id TransferConnectorId --send-file-paths /amzn-s3-demo-bucket/test.txt After you run the command, you can go to your Amazon S3 bucket (amzn-s3-demo-bucket) and view the contents. If the command is successful, you should see the following objects in your bucket: • processed/ – This folder contains a JSON file that describes the transferred file and the MDN response. • processing/ – This folder temporarily contains files as they are being processed, but after a transfer is completed, this folder should be empty. • server-id/ – This folder is named based on your Transfer Family server ID. It contains from-partner (this folder is dynamically named, based on the partner's AS2 ID), which itself contains failed/, processed/, and processing/ folders. The /server-id/ from-partner/processed/ folder contains a copy of the transferred text file, and the corresponding JSON and MDN files. • test.txt – This object is the (empty) file that was transferred. Create an AS2 agreement Agreements are associated with Transfer Family servers. They specify the details for trading partners that use the AS2 protocol to exchange messages or files by using Transfer Family, for inbound transfers—sending AS2 files from an external, partner-owned source to a Transfer Family server. This procedure explains how to create AS2 agreements by using the Transfer Family console. If you want to use the AWS CLI instead, see the section called “Step 5: Create an agreement between you and your partner”. To create an agreement for a Transfer Family server 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the left navigation pane, choose Servers, and then choose a server that uses the AS2 protocol. As an alternative, as long as you have at least one Transfer Family server that uses the AS2 protocol, select Agreements to receive messages from the AS2 Trading Partners menu. Then, Create an AS2 agreement 327 AWS Transfer Family User Guide in the Create agreement screen, select the AS2 server to which you want to associate this agreement. 3. On the server details page, scroll down to the Agreements section. 4. Choose Add agreement. 5. Fill in the agreement parameters, as follows: a. b. In the Agreement configuration section, enter a descriptive name. Make sure that you can identify the agreement's purpose by its name. Also, set the Status for the agreement: either Active (selected by default) or Inactive. In the Communication configuration section, choose a local profile and a partner profile. Also, choose whether or not to enforce message signing. • By default, Enforce message signing is enabled, which means that Transfer Family rejects unsigned messages from your trading partner for this agreement. • Clear this setting to allow Transfer Family to accept unsigned messages from your trading partner for this agreement. c. In the Inbox directory configuration section, provide the following information. • Determine whether or not to select Specify separate directories to store your AS2 messages, MDN files, and JSON status files. • If you select this option, you specify separate locations for payload files, failed files, MDN files, status files, and temporary files. • If you clear this option, all AS2 files go into the location that you specify for your base directory. • For S3 Bucket, choose an Amazon S3 bucket. • For Prefix, you can enter a prefix (folder) to use for storing files in the bucket. For example, if you enter amzn-s3-demo-bucket for your bucket and incoming for your prefix, your AS2 files are saved to the /amzn-s3-demo-bucket/incoming folder. • For AWS IAM Role, choose a role that can access the bucket you specified. • For Preserve filename, choose whether to preserve original filenames for incoming AS2 message payloads. • If you select this setting, the filename provided by your trading parter is preserved when the file is saved in Amazon S3. Create an AS2 agreement 328 AWS Transfer Family User Guide • If you clear this setting, when Transfer Family saves the file, the filename is adjusted, as described in File names and locations. d. (Optional) Add tags in the Tags section.
|
transferfamily-ug-104
|
transferfamily-ug.pdf
| 104 |
are saved to the /amzn-s3-demo-bucket/incoming folder. • For AWS IAM Role, choose a role that can access the bucket you specified. • For Preserve filename, choose whether to preserve original filenames for incoming AS2 message payloads. • If you select this setting, the filename provided by your trading parter is preserved when the file is saved in Amazon S3. Create an AS2 agreement 328 AWS Transfer Family User Guide • If you clear this setting, when Transfer Family saves the file, the filename is adjusted, as described in File names and locations. d. (Optional) Add tags in the Tags section. e. After you have entered all the information for the agreement, choose Create agreement. The new agreement appears in the Agreements section of the server details page. Configure AS2 connectors The purpose of a connector is to establish a relationship between trading partners for outbound transfers—sending AS2 files from a Transfer Family server to an external, partner-owned destination. For the connector, you specify the local party, the remote partner, and their certificates (by creating local and partner profiles). After you have a connector in place, you can transfer information to your trading partners. Each AS2 server is assigned three static IP addresses. AS2 connectors use these IP addresses for sending asynchronous MDNs to your trading partners over AS2. Note The message size received by a trading partner will not match the object size in Amazon S3. This discrepancy occurs because the AS2 message wraps the file in an envelope prior to sending. So, the file size might increase, even if the file is sent with compression. Therefore, make sure that the trading partner's maximum file size is greater than the size of the file that you are sending. 1. Import AS2 certificates 2. Create AS2 profiles 3. Create an AS2 server 4. Create an AS2 agreement 5. Create an AS2 connector Configure AS2 connectors 329 AWS Transfer Family User Guide Create an AS2 connector This procedure explains how to create AS2 connectors by using the AWS Transfer Family console. If you want to use the AWS CLI instead, see the section called “Step 6: Create a connector between you and your partner”. To create an AS2 connector 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the left navigation pane, choose Connectors to send messages, from the AS2 Trading Partners menu, and then choose Create AS2 connector. 3. In the Connector configuration section, specify the following information: • URL – Enter the URL for outbound connections. • Access role – Choose the Amazon Resource Name (ARN) of the AWS Identity and Access Management (IAM) role to use. Make sure that this role provides read and write access to the parent directory of the file location that's used in the StartFileTransfer request. Additionally, make sure that the role provides read and write access to the parent directory of the files that you intend to send with StartFileTransfer. Note If you're using Basic authentication for your connector, the access role requires the secretsmanager:GetSecretValue permission for the secret. If the secret is encrypted by using a customer managed key instead of the AWS managed key in AWS Secrets Manager, then the role also needs the kms:Decrypt permission for that key. If you name your secret with the prefix aws/transfer/, you can add the necessary permission with a wildcard character (*), as shown in Example permission to create secrets. • Logging role (optional) – Choose the IAM role for the connector to use to push events to your CloudWatch logs. 4. In the AS2 configuration section, choose the local and partner profiles, the encryption and signing algorithms, and whether to compress the transferred information. Note the following: • The Preserve S3 Content-Type parameter is enabled by default. Create an AS2 connector 330 AWS Transfer Family User Guide When set, Transfer Family uses the Amazon S3 Content-Type that is associated with objects in S3 instead of having the content type mapped based on the file extension. Clear this setting if you want the service to map content type for your AS2 messages based on file extension, rather than using the content type from the S3 object. • For the encryption algorithm, do not choose DES_EDE3_CBC unless you must support a legacy client that requires it, as it is a weak encryption algorithm. • The Subject is used as the subject HTTP header attribute in AS2 messages that are being sent with the connector. • If you choose to create a connector without an encryption algorithm, you must specify HTTPS as your protocol. 5. In the Basic authentication section, specify the following information. • To send sign-on credentials along with outbound messages, select Enable Basic authentication. If you don't want to send any credentials with outbound messages, keep Enable Basic authentication cleared. • If
|
transferfamily-ug-105
|
transferfamily-ug.pdf
| 105 |
choose DES_EDE3_CBC unless you must support a legacy client that requires it, as it is a weak encryption algorithm. • The Subject is used as the subject HTTP header attribute in AS2 messages that are being sent with the connector. • If you choose to create a connector without an encryption algorithm, you must specify HTTPS as your protocol. 5. In the Basic authentication section, specify the following information. • To send sign-on credentials along with outbound messages, select Enable Basic authentication. If you don't want to send any credentials with outbound messages, keep Enable Basic authentication cleared. • If you're using authentication, choose or create a secret. • To create a new secret, choose Create a new secret and then enter a username and password. These credentials must match the user that connects to the partner's endpoint. Create an AS2 connector 331 AWS Transfer Family User Guide • To use an existing secret, choose Choose an existing secret, and then choose a secret from the dropdown menu. For the details of creating a correctly formatted secret in Secrets Manager, see Enable Basic authentication for AS2 connectors. 6. In the MDN configuration section, specify the following information: • Request MDN – You have the option to require your trading partner to send you an MDN after they have successfully received your message over AS2. • Signed MDN – You have the option to require that MDNs be signed. This option is available only if you have selected Request MDN. 7. After you've confirmed all of your settings, choose Create AS2 connector to create the connector. The Connectors page appears, with the ID of your new connector added to the list. To view the details for your connectors, see View AS2 connector details. AS2 connector algorithms When you create an AS2 connector, the following security algorithms are attached to the connector. AS2 connector algorithms 332 AWS Transfer Family Type TLS Cipher User Guide Algorithm TLS_ECDHE_ECDSA_WITH_AES_12 8_GCM_SHA256 TLS_ECDHE_RSA_WITH_AES_128_ GCM_SHA256 TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA 256 TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA25 6 TLS_ECDHE_ECDSA_WITH_AES_25 6_GCM_SHA384 TLS_ECDHE_RSA_WITH_AES_256_ GCM_SHA384 TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA 384 TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA38 4 Basic authentication for AS2 connectors When you create or update a Transfer Family server that uses the AS2 protocol, you can add Basic authentication for outbound messages. You do this by adding authentication information to a connector. Note Basic authentication is available only if you're using HTTPS. To use authentication for your connector, select Enable Basic authentication in the Basic authentication section. After you enable Basic authentication, you can choose to create a new Basic authentication for AS2 connectors 333 AWS Transfer Family User Guide secret, or use an existing one. In either case, the credentials in the secret are sent with outbound messages that use this connector. The credentials must match the user that is attempting to connect to the trading partner's remote endpoint. The following screenshot shows Enable Basic authentication selected, and Create a new secret chosen. After making these choices, you can enter a username and password for the secret. The following screenshot shows Enable Basic authentication selected, and Choose an existing secret chosen. Your secret must be in the correct format, as described in Enable Basic authentication for AS2 connectors. Basic authentication for AS2 connectors 334 AWS Transfer Family User Guide Enable Basic authentication for AS2 connectors When you enable Basic authentication for AS2 connectors, you can either create a new secret in the Transfer Family console, or you can use a secret that you create in AWS Secrets Manager. In either case, your secret is stored in Secrets Manager. Topics • Create a new secret in the console • Use an existing secret • Create a secret in AWS Secrets Manager Create a new secret in the console When you're creating a connector in the console, you can create a new secret. To create a new secret, choose Create a new secret and then enter a username and password. These credentials must match the user that connects to the partner's endpoint. Enable Basic authentication for AS2 connectors 335 AWS Transfer Family User Guide Note When you create a new secret in the console, the name of the secret follows this naming convention: /aws/transfer/connector-id, where connector-id is the ID of the connector that you're creating. Consider this when you are trying to locate the secret in AWS Secrets Manager. Use an existing secret When you're creating a connector in the console, you can specify an existing secret. To use an existing secret, choose Choose an existing secret, and then choose a secret from the dropdown menu. For the details of creating a correctly formatted secret in Secrets Manager, see Create a secret in AWS Secrets Manager. Enable Basic authentication for AS2 connectors 336 AWS Transfer Family User Guide Create a secret in AWS Secrets Manager The following procedure describes how to create an appropriate secret for use
|
transferfamily-ug-106
|
transferfamily-ug.pdf
| 106 |
when you are trying to locate the secret in AWS Secrets Manager. Use an existing secret When you're creating a connector in the console, you can specify an existing secret. To use an existing secret, choose Choose an existing secret, and then choose a secret from the dropdown menu. For the details of creating a correctly formatted secret in Secrets Manager, see Create a secret in AWS Secrets Manager. Enable Basic authentication for AS2 connectors 336 AWS Transfer Family User Guide Create a secret in AWS Secrets Manager The following procedure describes how to create an appropriate secret for use with your AS2 connector. Note Basic authentication is available only if you're using HTTPS. To store user credentials in Secrets Manager for AS2 Basic authentication 1. Sign in to the AWS Management Console and open the AWS Secrets Manager console at https://console.aws.amazon.com/secretsmanager/. 2. In the left navigation pane, choose Secrets. 3. On the Secrets page, choose Store a new secret. 4. On the Choose secret type page, for Secret type, choose Other type of secret. 5. In the Key/value pairs section, choose the Key/value tab. • Key – Enter Username. • value – Enter the name of the user that is authorized to connect to the partner' server. Enable Basic authentication for AS2 connectors 337 AWS Transfer Family User Guide 6. If you want to provide a password, choose Add row, and in the Key/value pairs section, choose the Key/value tab. Choose Add row, and in the Key/value pairs section, choose the Key/value tab. • Key – Enter Password. • value – Enter the password for the user. 7. If you want to provide a private key, choose Add row, and in the Key/value pairs section, choose the Key/value tab. • Key – Enter PrivateKey. • value – Enter a private key for the user. This value must be stored in OpenSSH format, and must correspond to the public key that is stored for this user in the remote server. 8. Choose Next. 9. On the Configure secret page, enter a name and description for your secret. We recommend that you use a prefix of aws/transfer/ for the name. For example, you could name your secret aws/transfer/connector-1. 10. Choose Next, and then accept the defaults on the Configure rotation page. Then choose Next. 11. On the Review page, choose Store to create and store the secret. After you create the secret, you can choose it when you are creating a connector (see Configure AS2 connectors). In the step where you enable Basic authentication, choose the secret from the dropdown list of available secrets. View AS2 connector details You can find a list of details and properties for an AS2 AWS Transfer Family connector in the AWS Transfer Family console. An AS2 connector's properties include its URL, roles, profiles, MDNs, tags, and monitoring metrics. This is the procedure for viewing connector details. To view connector details 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the left navigation pane, choose Connectors. View connector details 338 AWS Transfer Family User Guide 3. Choose the identifier in the Connector ID column to see the details page for the selected connector. You can change the properties for the AS2 connector on the connector's details page by choosing Edit. View connector details 339 AWS Transfer Family User Guide Note You can get much of this information, albeit in a different format, by running the following AWS Command Line Interface (AWS CLI command: aws transfer describe-connector --connector-id your-connector-id For more information, see DescribeConnector in the API reference. View connector details 340 AWS Transfer Family User Guide Sending and receiving AS2 messages This section describes the processes for sending and receiving AS2 messages. It also provide details on filenames and locations associated with AS2 messages. The following table lists the available encryption algorithms for AS2 messages, and when you can HTTP HTTPS Notes use them. Encryption algorithm AES128_CBC AES192_CBC AES256_CBC DES_EDE3_CBC Yes Yes Yes Yes Yes Yes Yes Yes NONE No Yes Only use this algorithm if you must support a legacy client that requires it, as it is a weak encryption algorithm. If you are sending messages to a Transfer Family server, you can only select NONE if you are using an Application Load Balancer (ALB). Topics • Receive AS2 message process • Sending and receiving AS2 messages over HTTPS • Transferring files by using an AS2 connector • File names and locations Transfer AS2 messages 341 AWS Transfer Family • Status codes • Sample JSON files Receive AS2 message process User Guide The inbound process is defined as a message or file that's being transferred to your AWS Transfer Family server. The sequence for inbound messages is as follows: 1. An admin or automated process starts an AS2 file transfer on the partner's
|
transferfamily-ug-107
|
transferfamily-ug.pdf
| 107 |
only select NONE if you are using an Application Load Balancer (ALB). Topics • Receive AS2 message process • Sending and receiving AS2 messages over HTTPS • Transferring files by using an AS2 connector • File names and locations Transfer AS2 messages 341 AWS Transfer Family • Status codes • Sample JSON files Receive AS2 message process User Guide The inbound process is defined as a message or file that's being transferred to your AWS Transfer Family server. The sequence for inbound messages is as follows: 1. An admin or automated process starts an AS2 file transfer on the partner's remote AS2 server. 2. The partner's remote AS2 server signs and encrypts the file contents, then sends an HTTP POST request to an AS2 inbound endpoint hosted on Transfer Family. 3. Using the configured values for the server, partners, certificates, and agreement, Transfer Family decrypts and verifies the AS2 payload. The file contents are stored in the configured Amazon S3 file store. 4. The signed MDN response is returned either inline with the HTTP response, or asynchronously through a separate HTTP POST request back to the originating server. 5. An audit trail is written to Amazon CloudWatch with details about the exchange. 6. The decrypted file is available in a folder named inbox/processed. Receive AS2 messages 342 AWS Transfer Family User Guide Sending and receiving AS2 messages over HTTPS This section describes how to configure a Transfer Family server that uses the AS2 protocol to send and receive messages over HTTPS. Topics • Send AS2 messages over HTTPS • Receive AS2 messages over HTTPS Send AS2 messages over HTTPS To send AS2 messages using HTTPS, create a connector with the following information: • For the URL, specify an HTTPS URL • For the encryption algorithm, select any of the available algorithms. Configure HTTPS for AS2 343 AWS Transfer Family Note User Guide To send messages to a Transfer Family server while not using encryption (that is, you select NONE for the encryption algorithm), you must use an Application Load Balancer (ALB). • Provide the remaining values for the connector as described in Configure AS2 connectors. Receive AS2 messages over HTTPS AWS Transfer Family AS2 servers currently only provide HTTP transport over port 5080. However, you can terminate TLS on a network or application load balancer in front of your Transfer Family server VPC endpoint by using a port and certificate of your choosing. With this approach, you can have incoming AS2 messages use HTTPS. Prerequisites • The VPC must be in the same AWS Region as your Transfer Family server. • The subnets of your VPC must be within the Availability Zones that you want to use your server in. Note Each Transfer Family server can support up to three Availability Zones. • Allocate up to three Elastic IP addresses in the same Region as your server. Or, you can choose to bring your own IP address range (BYOIP). Note The number of Elastic IP addresses must match the number of Availability Zones that you use with your server endpoints. You can configure either a Network Load Balance (NLB) or an Application Load Balancer (ALB). The following table lists the pros and cons for each approach. Configure HTTPS for AS2 344 AWS Transfer Family User Guide The table below provides the differences in capabilities when you use an NLB versus an ALB to terminate TLS. Feature Latency Network Load Balancer (NLB) Application Load Balancer (ALB) Lower latency as it operates at the network layer. Higher latency as it operates at the application layer. Static IP support Can attach Elastic IP addresses that can be static. Cannot attach Elastic IP addresses: provides a Advanced routing Doesn't support advanced routing. domain whose underlying IP addresses can change. Supports advanced routing. Can inject X-Forwarded- Proto header required for AS2 without encryption. This header is described in X-Forwarded-Proto on the developer.mozilla.org website. TLS/SSL termination Supports TLS/SSL terminati on Supports TLS/SSL terminati on Mutual TLS (mTLS) Transfer Family doesn't currently support using an NLB for mTLS Support for mTLS Configure NLB This procedure describes how to set up an internet-facing Network Load Balancer (NLB) in your VPC. Configure HTTPS for AS2 345 AWS Transfer Family User Guide To create a Network Load Balancer and define the VPC endpoint of the server as the load balancer's target 1. Open the Amazon Elastic Compute Cloud console at https://console.aws.amazon.com/ ec2/. 2. From the navigation pane, choose Load Balancers, and then choose Create load balancer. 3. Under Network Load Balancer, choose Create. 4. In the Basic configuration section, enter the following information: • For Name, enter a descriptive name for the load balancer. • For Scheme, choose Internet-facing. • For IP address type, choose IPv4. 5. In the Network mapping section, enter the following information: • For VPC, choose
|
transferfamily-ug-108
|
transferfamily-ug.pdf
| 108 |
User Guide To create a Network Load Balancer and define the VPC endpoint of the server as the load balancer's target 1. Open the Amazon Elastic Compute Cloud console at https://console.aws.amazon.com/ ec2/. 2. From the navigation pane, choose Load Balancers, and then choose Create load balancer. 3. Under Network Load Balancer, choose Create. 4. In the Basic configuration section, enter the following information: • For Name, enter a descriptive name for the load balancer. • For Scheme, choose Internet-facing. • For IP address type, choose IPv4. 5. In the Network mapping section, enter the following information: • For VPC, choose the virtual private cloud (VPC) that you created. • Under Mappings, choose the Availability Zones associated with the public subnets that are available in the same VPC that you use with your server endpoints. • For the IPv4 address of each subnet, choose one of the Elastic IP addresses that you allocated. 6. In the Listeners and routing section, enter the following information: • For Protocol, choose TLS. • For Port, enter 5080. • For Default action, choose Create target group. For the details of creating a new target group, see To create a target group. After you create a target group, enter its name in the Default action field. 7. In the Secure listener settings section, choose your certificate in the Default SSL/TLS certificate area. 8. Choose Create load balancer to create your NLB. 9. (Optional, but recommended) Turn on access logs for the Network Load Balancer to maintain a full audit trail, as described in Access logs for your Network Load Balancer. Configure HTTPS for AS2 346 AWS Transfer Family User Guide We recommend this step because the TLS connection is terminated at the NLB. Therefore, the source IP address that's reflected in your Transfer Family AS2 CloudWatch log groups is the NLB's private IP address, instead of your trading partner's external IP address. Configure ALB This procedure describes how to set up an Application Load Balancer (ALB) in your VPC. To create an Application Load Balancer and define the VPC endpoint of the server as the load balancer's target 1. Open the Amazon Elastic Compute Cloud console at https://console.aws.amazon.com/ ec2/. 2. From the navigation pane, choose Load Balancers, and then choose Create load balancer. 3. Under Application Load Balancer, choose Create. 4. 5. In the ALB console, create a new HTTP listener on port 443 (HTTPS). (Optional). If you want to set up mutual authentication (mTLS), configure security settings and a trust store. a. Attach your SSL/TLS certificate to the listener. b. Under Client certificate handling, select Mutual authentication (mTLS). c. Choose Verify with trust store. d. Under Advanced mTLS settings, choose or create a trust store by uploading your CA certificates. 6. Create a new target group and add the private IP addresses of your Transfer Family AS2 server endpoints as targets on port 5080. For the details of creating a new target group, see To create a target group. 7. Configure health checks for the target group to use the HTTP protocol on port 5080. 8. Create a new rule to forward HTTPS traffic from the listener to the target group. 9. Configure the listener to use your SSL/TLS certificate. After you set up the load balancer, clients communicate with the load balancer over the custom port listener. Then, the load balancer communicates with the server over port 5080. Configure HTTPS for AS2 347 AWS Transfer Family To create a target group User Guide 1. After you choose Create target group in the previous procedure, you are taken to the Specify group details page for a new target group. 2. In the Basic configuration section, enter the following information. • For Choose a target type, choose IP addresses. • For Target group name, enter a name for the target group. • For Protocol, your selection is dependent upon whether you are using an ALB or an NLB. • For a Network Load Balancer (NLB), choose TCP • For an Application Load Balancer (ALB), choose HTTP • For Port, enter 5080. • For IP address type, choose IPv4. • For VPC, choose the VPC that you created for your Transfer Family AS2 server. 3. In the Health checks section, choose the Health check protocol. • For an ALB, choose HTTP • For an NLB, choose TCP 4. Choose Next. 5. On the Register targets page, enter the following information: • For Network, confirm that the VPC that you created for your Transfer Family AS2 server is specified. • For IPv4 address, enter the private IPv4 address of your Transfer Family AS2 server's endpoints. If you have more than one endpoint for your server, choose Add IPv4 address to add another row for entering another IPv4 address. Repeat this process until you've entered the private IP addresses
|
transferfamily-ug-109
|
transferfamily-ug.pdf
| 109 |
Health checks section, choose the Health check protocol. • For an ALB, choose HTTP • For an NLB, choose TCP 4. Choose Next. 5. On the Register targets page, enter the following information: • For Network, confirm that the VPC that you created for your Transfer Family AS2 server is specified. • For IPv4 address, enter the private IPv4 address of your Transfer Family AS2 server's endpoints. If you have more than one endpoint for your server, choose Add IPv4 address to add another row for entering another IPv4 address. Repeat this process until you've entered the private IP addresses for all of your server's endpoints. • Make sure that Ports is set to 5080. • Choose Include as pending below to add your entries to the Review targets section. 6. In the Review targets section, review your IP targets. 7. Choose Create target group, then go back to the previous procedure for creating your NLB and enter the new target group where indicated. Configure HTTPS for AS2 348 AWS Transfer Family User Guide Test access to the server from an Elastic IP address Connect to the server over the custom port by using an Elastic IP address or the DNS name of the Network Load Balancer. Important Manage access to your server from client IP addresses by using the network access control lists (network ACLs) for the subnets configured on the load balancer. Network ACL permissions are set at the subnet level, so the rules apply to all resources that are using the subnet. You can't control access from client IP addresses by using security groups, because the load balancer's target type is set to IP addresses instead of Instances. Therefore, the load balancer doesn't preserve source IP addresses. If the Network Load Balancer's health checks fail, this means that the load balancer can't connect to the server endpoint. To troubleshoot this issue, check the following: • Confirm that the server endpoint's associated security group allows inbound connections from the subnets that are configured on the load balancer. The load balancer must be able to connect to the server endpoint over port 5080. • Confirm that the server's State is Online. Transferring files by using an AS2 connector AS2 connectors establish a relationship between trading partners for transfers of AS2 messages from a Transfer Family server to an external, partner-owned destination. You can use Transfer Family to send AS2 messages by referencing the connector ID and the paths to the files, as illustrated in the following start-file-transfer AWS Command Line Interface (AWS CLI) command: aws transfer start-file-transfer --connector-id c-1234567890abcdef0 \ --send-file-paths "/amzn-s3-demo-source-bucket/myfile1.txt" "/amzn-s3-demo-source- bucket/myfile2.txt" To get the details for your connectors, run the following command: aws transfer list-connectors Transfer files with AS2 connectors 349 AWS Transfer Family User Guide The list-connectors command returns the connector IDs, URLs, and Amazon Resource Names (ARNs) for your connectors. To return the properties of a particular connector, run the following command with the ID that you want to use: aws transfer describe-connector --connector-id your-connector-id The describe-connector command returns all of the properties for the connector, including its URL, roles, profiles, Message Disposition Notices (MDNs), tags, and monitoring metrics. You can confirm that the partner successfully received the files by viewing the JSON and MDN files. These files are named according to the conventions described in File names and locations. If you configured a logging role when you created the connector, you can also check your CloudWatch logs for the status of AS2 messages. To view AS2 connector details, see View AS2 connector details. For more information about creating AS2 connectors, see Configure AS2 connectors. To send an AS2 outbound message The outbound process is defined as a message or file being sent from AWS to an external client or service. The sequence for outbound messages is as follows: 1. An admin calls the start-file-transfer AWS Command Line Interface (AWS CLI) command or the StartFileTransfer API operation. This operation references a connector configuration. 2. Transfer Family detects a new file request and locates the file. The file is compressed, signed, and encrypted. 3. A transfer HTTP client performs an HTTP POST request to transmit the payload to the partner's AS2 server. 4. The process returns the signed MDN response, inline with the HTTP response (synchronous MDN). 5. As the file moves between different stages of transmission, the process delivers the MDN response receipt and processing details to the customer. 6. The remote AS2 server makes the decrypted and verified file available to the partner admin. Transfer files with AS2 connectors 350 AWS Transfer Family User Guide AS2 processing supports many of the RFC 4130 protocols, with a focus on common use cases and integration with existing AS2-enabled server implementations. For details of the supported configurations, see AS2 configurations. File names and locations This section
|
transferfamily-ug-110
|
transferfamily-ug.pdf
| 110 |
returns the signed MDN response, inline with the HTTP response (synchronous MDN). 5. As the file moves between different stages of transmission, the process delivers the MDN response receipt and processing details to the customer. 6. The remote AS2 server makes the decrypted and verified file available to the partner admin. Transfer files with AS2 connectors 350 AWS Transfer Family User Guide AS2 processing supports many of the RFC 4130 protocols, with a focus on common use cases and integration with existing AS2-enabled server implementations. For details of the supported configurations, see AS2 configurations. File names and locations This section discusses the file-naming conventions for AS2 transfers. For inbound file transfers, note the following: • You specify the base directory in an agreement. The base directory is the Amazon S3 bucket name combined with a prefix, if any. For example, /amzn-s3-demo-bucket/AS2-folder. • If an incoming file is processed successfully, the file (and the corresponding JSON file) is saved to the /processed folder. For example, /amzn-s3-demo-bucket/AS2-folder/processed. The JSON file contains the following fields: File names and locations 351 User Guide AWS Transfer Family • agreement-id • as2-from • as2-to • as2-message-id • transfer-id • client-ip • connector-id • failure-message • file-path • message-subject • mdn-message-id • mdn-subject • requester-file-name • requester-content-type • server-id • status-code • failure-code • transfer-size • If an incoming file cannot be processed successfully, the file (and the corresponding JSON file) is saved to the /failed folder. For example, /amzn-s3-demo-bucket/AS2-folder/failed. • The transferred file is stored in the processed folder as original_filename.messageId.original_extension. That is, the message ID for the transfer is appended to the name of the file, before its original extension. • A JSON file is created and saved as original_filename.messageId.original_extension.json. In addition to the message ID being added, the string .json is appended to the transferred file's name. • A Message Disposition Notice (MDN) file is created and saved as original_filename.messageId.original_extension.mdn. In addition to the message ID being added, the string .mdn is appended to the transferred file's name. • If there is an inbound file named ExampleFileInS3Payload.dat, the following files are created: File names and locations 352 AWS Transfer Family • File – User Guide ExampleFileInS3Payload.c4d6b6c7-23ea-4b8c-9ada-0cb811dc8b35@44313c54b0a46a36.dat • JSON – ExampleFileInS3Payload.c4d6b6c7-23ea-4b8c-9ada-0cb811dc8b35@44313c54b0a46a36.dat.json • MDN – ExampleFileInS3Payload.c4d6b6c7-23ea-4b8c-9ada-0cb811dc8b35@44313c54b0a46a36.dat.mdn For outbound transfers, the naming is similar, with the difference that there is no incoming message file, and also, the transfer ID for the transferred message is added to the file name. The transfer ID is returned by the StartFileTransfer API operation (or when another process or script calls this operation). • The transfer-id is an identifier that is associated with a file transfer. All requests that are part of a StartFileTransfer call share a transfer-id. • The base directory is the same as the path that you use for the source file. That is, the base directory is the path that you specify in the StartFileTransfer API operation or start- file-transfer AWS CLI command. For example: aws transfer start-file-transfer --send-file-paths /amzn-s3-demo-bucket/AS2-folder/ file-to-send.txt If you run this command, MDN and JSON files are saved in /amzn-s3-demo-bucket/AS2- folder/processed (for successful transfers), or /amzn-s3-demo-bucket/AS2-folder/ failed (for unsuccessful transfers). • A JSON file is created and saved as original_filename.transferId.messageId.original_extension.json. • An MDN file is created and saved as original_filename.transferId.messageId.original_extension.mdn. • If there is an outbound file named ExampleFileOutTestOutboundSyncMdn.dat, the following files are created: • JSON – ExampleFileOutTestOutboundSyncMdn.dedf4601-4e90-4043- b16b-579af35e0d83.fbe18db8-7361-42ff-8ab6-49ec1e435f34@c9c705f0baaaabaa.dat.json • MDN – ExampleFileOutTestOutboundSyncMdn.dedf4601-4e90-4043- b16b-579af35e0d83.fbe18db8-7361-42ff-8ab6-49ec1e435f34@c9c705f0baaaabaa.dat.mdn File names and locations 353 AWS Transfer Family User Guide You can also check the CloudWatch logs to view the details of your transfers, including any that failed. Status codes The following table lists all of the status codes that can be logged to CloudWatch logs when you or your partner send an AS2 message. Different message processing steps apply to different message types and are intended for monitoring only. The COMPLETED and FAILED states represent the final step in processing, and are visible in JSON files. Code Description Processing completed? PROCESSING MDN_TRANSMIT MDN_RECEIVE COMPLETED FAILED The message is in the process of being converted to its No final format. For example, decompression and decryptio n steps both have this status. Message processing is sending an MDN response. Message processing is receiving an MDN response. Message processing has completed successfully. This state includes when an MDN is sent for an inbound message or for MDN verificat ion of outbound messages. The message processing has failed. For a list of error codes, see AS2 error codes. No No Yes Yes Status codes 354 AWS Transfer Family Sample JSON files User Guide This section lists sample JSON files for both inbound and outbound transfers, including sample files for successful transfers and transfers that fail. Sample outbound file that is successfully transferred: { "requester-content-type": "application/octet-stream", "message-subject": "File xyzTest from MyCompany_OID to partner YourCompany", "requester-file-name": "TestOutboundSyncMdn-9lmCr79hV.dat", "as2-from": "MyCompany_OID", "connector-id": "c-c21c63ceaaf34d99b", "status-code": "COMPLETED", "disposition": "automatic-action/MDN-sent-automatically;
|
transferfamily-ug-111
|
transferfamily-ug.pdf
| 111 |
This state includes when an MDN is sent for an inbound message or for MDN verificat ion of outbound messages. The message processing has failed. For a list of error codes, see AS2 error codes. No No Yes Yes Status codes 354 AWS Transfer Family Sample JSON files User Guide This section lists sample JSON files for both inbound and outbound transfers, including sample files for successful transfers and transfers that fail. Sample outbound file that is successfully transferred: { "requester-content-type": "application/octet-stream", "message-subject": "File xyzTest from MyCompany_OID to partner YourCompany", "requester-file-name": "TestOutboundSyncMdn-9lmCr79hV.dat", "as2-from": "MyCompany_OID", "connector-id": "c-c21c63ceaaf34d99b", "status-code": "COMPLETED", "disposition": "automatic-action/MDN-sent-automatically; processed", "transfer-size": 3198, "mdn-message-id": "OPENAS2-11072022063009+0000-df865189-1450-435b-9b8d- d8bc0cee97fd@PartnerA_OID_MyCompany_OID", "mdn-subject": "Message be18db8-7361-42ff-8ab6-49ec1e435f34@c9c705f0baaaabaa has been accepted", "as2-to": "PartnerA_OID", "transfer-id": "dedf4601-4e90-4043-b16b-579af35e0d83", "file-path": "/amzn-s3-demo-bucket/as2testcell0000/openAs2/ TestOutboundSyncMdn-9lmCr79hV.dat", "as2-message-id": "fbe18db8-7361-42ff-8ab6-49ec1e435f34@c9c705f0baaaabaa", "timestamp": "2022-07-11T06:30:10.791274Z" } Sample outbound file that is unsuccessfully transferred: { "failure-code": "HTTP_ERROR_RESPONSE_FROM_PARTNER", "status-code": "FAILED", "requester-content-type": "application/octet-stream", "subject": "Test run from Id da86e74d6e57464aae1a55b8596bad0a to partner 9f8474d7714e476e8a46ce8c93a48c6c", "transfer-size": 3198, "requester-file-name": "openAs2TestOutboundWrongAs2Ids-necco-3VYn5n8wE.dat", "as2-message-id": "9a9cc9ab-7893-4cb6-992a-5ed8b90775ff@718de4cec1374598", "failure-message": "http://Test123456789.us-east-1.elb.amazonaws.com:10080 returned status 500 for message with ID 9a9cc9ab-7893-4cb6-992a-5ed8b90775ff@718de4cec1374598", "transfer-id": "07bd3e07-a652-4cc6-9412-73ffdb97ab92", Sample JSON files 355 AWS Transfer Family User Guide "connector-id": "c-056e15cc851f4b2e9", "file-path": "/amzn-s3-demo-bucket-4c1tq6ohjt9y/as2IntegCell0002/openAs2/ openAs2TestOutboundWrongAs2Ids-necco-3VYn5n8wE.dat", "timestamp": "2022-07-11T21:17:24.802378Z" } Sample inbound file that is successfully transferred: { "requester-content-type": "application/EDI-X12", "subject": "File openAs2TestInboundAsyncMdn-necco-5Ab6bTfCO.dat sent from MyCompany to PartnerA", "client-ip": "10.0.109.105", "requester-file-name": "openAs2TestInboundAsyncMdn-necco-5Ab6bTfCO.dat", "as2-from": "MyCompany_OID", "status-code": "COMPLETED", "disposition": "automatic-action/MDN-sent-automatically; processed", "transfer-size": 1050, "mdn-subject": "Message Disposition Notification", "as2-message-id": "OPENAS2-11072022233606+0000-5dab0452-0ca1-4f9b-b622- fba84effff3c@MyCompany_OID_PartnerA_OID", "as2-to": "PartnerA_OID", "agreement-id": "a-f5c5cbea5f7741988", "file-path": "processed/openAs2TestInboundAsyncMdn- necco-5Ab6bTfCO.OPENAS2-11072022233606+0000-5dab0452-0ca1-4f9b-b622- fba84effff3c@MyCompany_OID_PartnerA_OID.dat", "server-id": "s-5f7422b04c2447ef9", "timestamp": "2022-07-11T23:36:36.105030Z" } Sample inbound file that is unsuccessfully transferred: { "failure-code": "INVALID_REQUEST", "status-code": "FAILED", "subject": "Sending a request from InboundHttpClientTests", "client-ip": "10.0.117.27", "as2-message-id": "testFailedLogs-TestRunConfig-Default-inbound-direct- integ-0c97ee55-af56-4988-b7b4-a3e0576f8f9c@necco", "as2-to": "0beff6af56c548f28b0e78841dce44f9", "failure-message": "Unsupported date format: 2022/123/456T", "agreement-id": "a-0ceec8ca0a3348d6a", "as2-from": "ab91a398aed0422d9dd1362710213880", Sample JSON files 356 AWS Transfer Family User Guide "file-path": "failed/01187f15-523c-43ac-9fd6-51b5ad2b08f3.testFailedLogs- TestRunConfig-Default-inbound-direct-integ-0c97ee55-af56-4988-b7b4-a3e0576f8f9c@necco", "server-id": "s-0582af12e44540b9b", "timestamp": "2022-07-11T06:30:03.662939Z" } Customize HTTP headers for AS2 messages When sending AS2 messages to trading partners, you may need to customize the HTTP headers to meet specific requirements or enhance compatibility with your partner's AS2 server configuration. This AWS CloudFormation template creates an infrastructure to enable customized HTTP headers for AS2 messages sent through AWS Transfer Family. It sets up an Amazon API Gateway and Lambda function to act as a proxy, allowing dynamic modification of headers required by trading partners' AS2 servers. Use this template to do the following: • Add custom HTTP headers to outbound AS2 messages • Override default header values with custom values Important Be careful when overriding default header values, as it can cause send failures: some AS2 headers are required. • Ensure compatibility with trading partners that have specific header requirements Template Overview The template creates the following main components: • A Lambda function that processes and forwards AS2 messages • An Amazon API Gateway to expose the Lambda function • IAM roles and permissions for the Lambda function • Conditional resources for HTTPS support The template file is available here: Dynamic HTTP headers template. Custom HTTP Headers for AS2 357 AWS Transfer Family How It Works User Guide 1. The Amazon API Gateway receives incoming AS2 messages from AWS Transfer Family. 2. The request is forwarded to the Lambda function. 3. The Lambda function processes the request, adding or modifying headers as needed. 4. The modified request is then forwarded to the partner's AS2 server. 5. The response from the partner's server is returned through the Lambda and Amazon API Gateway back to AWS Transfer Family. Key Features • Dynamic Header Modification: Allows customization of the Subject header and addition of other required headers. • Protocol Support: Works with both HTTP and HTTPS protocols. • Flexible Configuration: Allows specification of partner host, port, and path. Implementation Details The template implements the following key components: Lambda Function The core of the solution is a Node.js Lambda function that: • Receives requests from the Amazon API Gateway • Modifies headers based on configuration and incoming request data • Forwards the modified request to the partner's AS2 server • Handles both HTTP and HTTPS protocols • Includes error handling and logging Amazon API Gateway An HTTP API is set up to: • Receive incoming AS2 messages How It Works 358 AWS Transfer Family User Guide • Route requests to the Lambda function • Return responses back to AWS Transfer Family Template parameters Enter information for the template parameters as follows. Note that all of these parameters are strings. • Environment: this parameter is used to name the resources that the template creates: whether they are intended for a development or production environment. Valid values are dev and prod. • PartnerHost: the IP address or hostname of the AS2 partner server. • PartnerPort: the port number for the AS2 partner server. If not specified, defaults to 80 for HTTP and 443 for HTTPS. • PartnerPath: the path to the AS2 endpoint on the partner server • ProtocolType: the protocol to use for the AS2 communication: valid
|
transferfamily-ug-112
|
transferfamily-ug.pdf
| 112 |
the template parameters as follows. Note that all of these parameters are strings. • Environment: this parameter is used to name the resources that the template creates: whether they are intended for a development or production environment. Valid values are dev and prod. • PartnerHost: the IP address or hostname of the AS2 partner server. • PartnerPort: the port number for the AS2 partner server. If not specified, defaults to 80 for HTTP and 443 for HTTPS. • PartnerPath: the path to the AS2 endpoint on the partner server • ProtocolType: the protocol to use for the AS2 communication: valid values are HTTP and HTTPS. Conditional Resources For HTTPS support, the template conditionally creates: • A Lambda Layer for CA certificates • HTTPS-specific configuration in the Lambda function Deployment and Usage To customize AS2 HTTP headers using a CloudFormation template 1. Open the AWS CloudFormation console at https://console.aws.amazon.com/cloudformation. 2. In the left navigation pane, choose Stacks. 3. Choose Create stack, and then choose With new resources (standard). 4. In the Prerequisite - Prepare template section, choose Choose an existing template. 5. Copy this link, Dynamic HTTP headers template, and paste it into the Amazon S3 URL field. 6. Choose Next. Deployment and Usage 359 AWS Transfer Family User Guide 7. Fill in the parameter details with your information. These are detailed in Template parameters. 8. Choose Next. On the Configure stack options page, choose Next again. 9. Review the details for the stack that you're creating, and then choose Create stack. Note At the bottom of the page, under Capabilities, you must acknowledge that AWS CloudFormation might create AWS Identity and Access Management (IAM) resources. After deploying this AWS CloudFormation stack: 1. Note the Amazon API Gateway endpoint URL provided in the stack outputs. 2. Update your existing AWS Transfer Family Connector to use this new Amazon API Gateway endpoint. 3. The solution will now handle AS2 messages, adding or modifying headers as configured. Warning Only modify the Subject header or add headers that your partner explicitly expects. Changing other headers may cause transfer failures. Monitoring AS2 usage You can monitor AS2 activity using Amazon CloudWatch and AWS CloudTrail. To view other Transfer Family server metrics, see Amazon CloudWatch logging for AWS Transfer Family servers AS2 metrics Metric InboundMessage Description The total number of AS2 messages successfu lly received from a trading partner. Units: Count Period: 5 minutes Monitor AS2 360 AWS Transfer Family Metric InboundFailedMessage User Guide Description The total number of AS2 messages that were unsuccessfully received from a trading partner. That is, a trading partner sent a message, but the Transfer Family server was not able to successfully process it. Units: Count Period: 5 minutes OutboundMessage The total number of AS2 messages successfu lly sent from the Transfer Family server to a OutboundFailedMessage trading partner. Units: Count Period: 5 minute The total number of AS2 messages that were unsuccessfully sent to a trading partner. That is, they were sent from the Transfer Family server, but were not successfully received by the trading partner. Units: Count Period: 5 minutes AS2 Status codes The following table lists all of the status codes that can be logged to CloudWatch logs when you or your partner send an AS2 message. Different message processing steps apply to different message types and are intended for monitoring only. The COMPLETED and FAILED states represent the final step in processing, and are visible in JSON files. AS2 Status codes 361 AWS Transfer Family User Guide Code Description Processing completed? PROCESSING MDN_TRANSMIT MDN_RECEIVE COMPLETED FAILED AS2 error codes The message is in the process of being converted to its No final format. For example, decompression and decryptio n steps both have this status. Message processing is sending an MDN response. Message processing is receiving an MDN response. Message processing has completed successfully. This state includes when an MDN is sent for an inbound message or for MDN verificat ion of outbound messages. The message processing has failed. For a list of error codes, see AS2 error codes. No No Yes Yes The following table lists and describes error codes that you might receive from AS2 file transfers. AS2 error codes Code Error Description and resolution ACCESS_DENIED • Access denied. Check if your access role has necessary permissions. Occurs when handling a StartFileTransfer request where any of the • Invalid file path send- file-path SendFilePaths are not valid or malformed. That AS2 error codes 362 AWS Transfer Family User Guide Code Error Description and resolution • Failed to get credentials is, the path is missing the with ErrorCode: error- code AGREEMENT_NOT_FOUND Agreement was not found. Amazon S3 bucket name, or the path includes characters that aren't valid. Also occurs if Transfer Family fails to assume the access role or logging role. Ensure that the path contains a
|
transferfamily-ug-113
|
transferfamily-ug.pdf
| 113 |
• Access denied. Check if your access role has necessary permissions. Occurs when handling a StartFileTransfer request where any of the • Invalid file path send- file-path SendFilePaths are not valid or malformed. That AS2 error codes 362 AWS Transfer Family User Guide Code Error Description and resolution • Failed to get credentials is, the path is missing the with ErrorCode: error- code AGREEMENT_NOT_FOUND Agreement was not found. Amazon S3 bucket name, or the path includes characters that aren't valid. Also occurs if Transfer Family fails to assume the access role or logging role. Ensure that the path contains a valid Amazon S3 bucket name and key name. Either the agreement was not found, or the agreement is associated with an inactive profile. Update the agreement within the Transfer Family server to include active profiles. CONNECTOR_NOT_FOUND Connector or related configuration was not found. Either the connector was not found, or the connector is associated with an inactive profile. Update the connector to include active profiles. AS2 error codes 363 AWS Transfer Family User Guide Code Error Description and resolution CREDENTIALS_RETRIE 1. Secret not found in Secrets VAL_FAILED Manager. 2. Cannot access Secrets Manager. 3. Failed to decrypt secret in Secrets Manager. For AS2 Basic authentication, the secret must be formatted correctly. The following resolutions correspond to the errors listed in the previous column. 4. Cannot get secret value 1. Ensure that the secret ID is due to throttling. correct. 2. Ensure that the access role has the appropria te permissions to read the secret. The access role must provide read and write access to the parent directory of the file location used in the StartFileTransfer request. Additionally, make sure that the role provides read and write access to the parent directory of the files that you intend to send with StartFile Transfer . 3. If a customer managed key is being used for the secret, ensure that the access role has permissions for the AWS Key Management Service (AWS KMS) key. 4. For the applicable quotas, see Quotas for handling secrets. AS2 error codes 364 AWS Transfer Family User Guide Code Error Description and resolution DECOMPRESSION_FAILED Failed to decompress message. Either the file sent is corrupt, or the compression algorithm is not valid. Resend the message and verify that ZLIB compressi on is used, or resend the message without compression enabled. DECRYPT_FAILED Failed to decrypt message Decryption failed. message-ID . Ensure that the partner has the correct public encryption key. Confirm that the partner sent a payload by using a valid certificate and that encryptio n was performed by using a valid encryption algorithm. DECRYPT_FAILED_INV ALID_SMIME_FORMAT Unable to parse enveloped mimePart. MIME payload is either corrupt or in an unsupported SMIME format. The sender should make sure that the format they're using is supported, and then resend the payload. AS2 error codes 365 AWS Transfer Family User Guide Code Error Description and resolution DECRYPT_FAILED_NO_ DECRYPTION_KEY_FOU No matching decryption key found. The partner profile did not have a certificate assigned ND that matched the message, or the certificates that matched the message are now expired or no longer valid. You must update the partner profile and ensure that it contains a valid certificate. DECRYPT_FAILED_UNS UPPORTED_ENCRYPTIO SMIME Payload Decryption requested using unsupport The remote sender has sent an AS2 payload with an N_ALG ed algorithm with ID: unsupported encryption encryption-ID . algorithm. The sender must choose an encryption algorithm that's supported by AWS Transfer Family. DUPLICATE_MESSAGE Duplicate or double processed step. The payload has a duplicate processing step. For example, there are two encryption steps. Resend the message with a single step for signing, compression, and encryption. AS2 error codes 366 AWS Transfer Family User Guide Code Error Description and resolution ENCRYPT_FAILED_NO_ ENCRYPTION_KEY_FOU No valid public encryption certificates found in profile: Transfer Family is attemptin g to encrypt an outbound ND local-profile-ID message, but no encryption certificates are found for the local profile. Resolution options: • Ensure that the local profile has a certificate and private key for encryption attached. • Ensure that the encryptio n certificate is currently active. ENCRYPTION_FAILED Failed to encrypt file file- name . The file to be sent is not available for encryption. FILE_SIZE_TOO_LARGE File size is too large. HTTP_ERROR_RESPONS E_FROM_PARTNER partner-URL returned status 400 for message with ID=message-ID . Verify that the file is in its expected AS2 location and that AWS Transfer Family has permission to read the file. This occurs when sending or receiving a file that exceeds the file size limit. Communicating with the partner's AS2 server returned an unexpected HTTP response code. The partner might be able to provide more diagnostics from their AS2 server logs. AS2 error codes 367 AWS Transfer Family User Guide Code Error Description and resolution INSUFFICENT_MESSAG Encryption is required. E_SECURITY_UNENCRY PTED The partner sent an unencrypted message
|
transferfamily-ug-114
|
transferfamily-ug.pdf
| 114 |
too large. HTTP_ERROR_RESPONS E_FROM_PARTNER partner-URL returned status 400 for message with ID=message-ID . Verify that the file is in its expected AS2 location and that AWS Transfer Family has permission to read the file. This occurs when sending or receiving a file that exceeds the file size limit. Communicating with the partner's AS2 server returned an unexpected HTTP response code. The partner might be able to provide more diagnostics from their AS2 server logs. AS2 error codes 367 AWS Transfer Family User Guide Code Error Description and resolution INSUFFICENT_MESSAG Encryption is required. E_SECURITY_UNENCRY PTED The partner sent an unencrypted message to Transfer Family, which is not supported. The sender must use an encrypted payload. INVALID_ENDPOINT_P ROTOCOL Only HTTP and HTTPS are supported. You must specify HTTP or HTTPS as the protocol in your AS2 connector configuration. AS2 error codes 368 AWS Transfer Family User Guide Code Error Description and resolution INVALID_REQUEST 1. There is a problem with a message header. 2. Could not parse secret JSON. Secret JSON did not match expected format. 3. Secret must be a JSON string. 4. Username must not contain a colon. Username must not This error has several causes. The following resolutions correspond to the errors listed in the previous column. 1. Check the as2-from and as2-to fields. Make sure that the original message ID is accurate for the MDN format. Also make sure that the message ID format is not missing any AS2 headers. contain control characters. 2. Ensure that the secret Username must contain only ASCII characters. Password must not contain control characters. Password must contain only ASCII characters. value matches the documented format, as described in Enable Basic authentication for AS2 connectors. 3. Ensure that the secret is provided as a string, and not as a binary. 4. Make the necessary correction to the username or password. AS2 error codes 369 AWS Transfer Family User Guide Code Error Description and resolution INVALID_URL_FORMAT Invalid URL format: URL MDN_RESPONSE_INDIC Not applicable ATES_AUTHENTICATIO N_FAILED MDN_RESPONSE_INDIC Not applicable ATES_DECOMPRESSION _FAILED MDN_RESPONSE_INDIC Not applicable ATES_DECRYPTION_FA ILED This occurs when you are sending an outbound message using a connector configured with a malformed URL. Ensure that the connector is configured with a valid HTTP or HTTPS URL. The receiver cannot authentic ate the sender. The trading partner returns an MDN to Transfer Family with the disposition modifier Error: authentication-failed. This occurs when the receiver cannot decompress the message contents. The trading partner returns an MDN to Transfer Family with the disposition modifier Error: decompression-failed. The receiver cannot decrypt the message contents. The trading partner returns an MDN to Transfer Family with the disposition modifier Error: authentication-failed. AS2 error codes 370 AWS Transfer Family User Guide Code Error Description and resolution MDN_RESPONSE_INDIC Not applicable ATES_INSUFFICIENT_ MESSAGE_SECURITY MDN_RESPONSE_INDIC Not applicable ATES_INTEGRITY_CHE CK_FAILED PATH_NOT_FOUND Unable to create directory file-path . The parent path could not be found. The receiver expects the message to be signed or encrypted, but it isn’t. The trading partner returns an MDN to Transfer Family with the disposition modifier Error: insufficient-message- security. Enable signing and/or encryption on the connector to match the trading partner's expectations. The receiver cannot verify content integrity. The trading partner returns an MDN to Transfer Family with the disposition modifier Error: integrity-check-failed. Transfer Family is attemptin g to create a directory in the customer's Amazon S3 bucket, but the bucket is not found. Ensure that each path mentioned in the StartFile Transfer command contains the name of an existing bucket. AS2 error codes 371 AWS Transfer Family User Guide Code Error Description and resolution SEND_FILE_NOT_FOUND File path file-path not found. Transfer Family can't locate the file in the send file SERVER_NOT_FOUND Server associated with the message cannot be found. operation. Check that the configured home directory and path are valid and that Transfer Family has read permissions for the file. Transfer Family could not find the server when receiving a message. This can happen if the server is deleted during the processing of an incoming message. SERVER_NOT_ONLINE Server server-ID is not online. The Transfer Family server is offline. SIGNING_FAILED Failed to sign file. Start the server so that it can receive and process messages. The file to be sent is not available for signing, or signing could not be performed. Verify that the file is in its expected AS2 location and that AWS Transfer Family has permission to read the file. AS2 error codes 372 AWS Transfer Family User Guide Code Error Description and resolution SIGNING_FAILED_NO_ No certificate found for SIGNING_KEY_FOUND profile: local-profile- ID. Attempting to sign an outbound message, but no signing certificates are found for the local profile. Resolution options: • Ensure that the local profile has a certificate and private key for signing attached. • Ensure that the signing certificate is currently active. UNABLE_RESOLVE_HOS T_TO_IP_ADDRESS Unable to resolve hostname
|
transferfamily-ug-115
|
transferfamily-ug.pdf
| 115 |
for signing, or signing could not be performed. Verify that the file is in its expected AS2 location and that AWS Transfer Family has permission to read the file. AS2 error codes 372 AWS Transfer Family User Guide Code Error Description and resolution SIGNING_FAILED_NO_ No certificate found for SIGNING_KEY_FOUND profile: local-profile- ID. Attempting to sign an outbound message, but no signing certificates are found for the local profile. Resolution options: • Ensure that the local profile has a certificate and private key for signing attached. • Ensure that the signing certificate is currently active. UNABLE_RESOLVE_HOS T_TO_IP_ADDRESS Unable to resolve hostname to IP addresses. Transfer Family is unable to perform DNS to IP address resolution on the public DNS server that is configured in the AS2 connector. Update the connector to point to a valid partner URL. UNABLE_TO_CONNECT_ TO_REMOTE_HOST_OR_ Connection to endpoint timed out. Transfer Family cannot establish a socket connectio IP n to the configured partner's AS2 server. Check that the partner's AS2 server is available at the configured IP address. AS2 error codes 373 AWS Transfer Family User Guide Code Error Description and resolution UNABLE_TO_RESOLVE_ Unable to resolve hostname HOSTNAME hostname. VERIFICATION_FAILED Signature verification failed for AS2 message message- ID or a MIC code did not match. The Transfer Family server could not resolve the partner's hostname by using a public DNS server. Check that the configured host is registered and that the DNS record has had time to publish. Check that the sender's signing certificate matches the signing certificates for the remote profile. Also check that the MIC algorithms are compatible with AWS Transfer Family. VERIFICATION_FAILE D_NO_MATCHING_KEY_ • No public certificate matching message AWS Transfer Family is attempting to verify the FOUND signature could be found signature for a received in profile: partner-p rofile-ID . message, but no matching signing certificate is found for • Cannot get certificates for non-existent profile: partner-profile-ID . the partner profile. Resolution options: • No valid certificate was • Ensure that the partner found in profile: partner- profile-ID . profile has a signing certificate attached. • Ensure that the certificate is currently active. • Ensure that the certificate is the correct signing certifica te for the partner. AS2 error codes 374 AWS Transfer Family User Guide AWS Transfer Family managed workflows AWS Transfer Family supports managed workflows for file processing. With managed workflows, you can kick off a workflow after a file has been transferred over SFTP, FTPS, or FTP. Using this feature, you can securely and cost effectively meet your compliance requirements for business-to- business (B2B) file exchanges by coordinating all the necessary steps required for file processing. In addition, you benefit from end-to-end auditing and visibility. By orchestrating file-processing tasks, managed workflows help you preprocess data before it is consumed by your downstream applications. Such file-processing tasks might include: • Moving files to user-specific folders. • Decrypting files as part of a workflow. • Tagging files. • Performing custom processing by creating and attaching an AWS Lambda function to a workflow. • Sending notifications when a file has been successfully transferred. (For a blog post that details this use case, see Customize file delivery notifications using AWS Transfer Family managed workflows.) To quickly replicate and standardize common post-upload file processing tasks spanning multiple business units in your organization, you can deploy workflows by using infrastructure as code (IaC). You can specify a managed workflow to be initiated on files that are uploaded in full. You can also specify a different managed workflow to be initiated on files that are only partially uploaded because of a premature session disconnect. Built-in exception handling helps you quickly react to file-processing outcomes, while offering you control over how to handle failures. In addition, each workflow step produces detailed logs, which you can audit to trace the data lineage. 375 AWS Transfer Family User Guide To get started, perform the following tasks: 1. Set up your workflow to contain preprocessing actions, such as copying, tagging, and other steps based on your requirements. See Create a workflow for details. 2. Configure an execution role, which Transfer Family uses to run the workflow. See IAM policies for workflows for details. 3. Map the workflow to a server, so that on file arrival, the actions specified in this workflow are evaluated and initiated in real time. See Configure and run a workflow for details. Related information • To monitor your workflow executions, see Using CloudWatch metrics for Transfer Family servers. • For detailed execution logs and troubleshooting information, see Troubleshoot workflow-related errors using Amazon CloudWatch. • Transfer Family provides a blog post and a workshop that walk you through building a file transfer solution. This solution leverages AWS Transfer Family for managed SFTP/FTPS endpoints and Amazon Cognito and DynamoDB for user management. The blog post is available at Using
|
transferfamily-ug-116
|
transferfamily-ug.pdf
| 116 |
that on file arrival, the actions specified in this workflow are evaluated and initiated in real time. See Configure and run a workflow for details. Related information • To monitor your workflow executions, see Using CloudWatch metrics for Transfer Family servers. • For detailed execution logs and troubleshooting information, see Troubleshoot workflow-related errors using Amazon CloudWatch. • Transfer Family provides a blog post and a workshop that walk you through building a file transfer solution. This solution leverages AWS Transfer Family for managed SFTP/FTPS endpoints and Amazon Cognito and DynamoDB for user management. The blog post is available at Using Amazon Cognito as an identity provider with AWS Transfer Family and Amazon S3. You can view the details for the workshop here. • View AWS Transfer Family Managed Workflows for a brief introduction to Transfer Family workflows. Topics • Create a workflow • Use predefined steps • Use custom file-processing steps • IAM policies for workflows • Exception handling for a workflow • Monitor workflow execution • Create a workflow from a template • Remove a workflow from a Transfer Family server • Managed workflows restrictions and limitations 376 AWS Transfer Family User Guide For more help getting started with managed workflows, see the following resources: • AWS Transfer Family managed workflows demo video • Building a cloud-native file transfer platform using AWS Transfer Family workflows blog post Create a workflow You can create a managed workflow by using the AWS Management Console, as described in this topic. To make the workflow creation process as easy as possible, contextual help panels are available for most of the sections in the console. A workflow has two kinds of steps: • Nominal steps – Nominal steps are file-processing steps that you want to apply to incoming files. If you select more than one nominal step, each step is processed in a linear sequence. • Exception-handling steps – Exception handlers are file-processing steps that AWS Transfer Family executes in case any nominal steps fail or result in validation errors. Create a workflow 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the left navigation pane, choose Workflows. 3. On the Workflows page, choose Create workflow. 4. On the Create workflow page, enter a description. This description appears on the Workflows page. 5. In the Nominal steps section, choose Add step. Add one or more steps. a. Choose a step type from the available options. For more information about the various step types, see the section called “Use predefined steps”. b. Choose Next, then configure parameters for the step. c. Choose Next, then review the details for the step. d. Choose Create step to add the step and continue. e. f. Continue adding steps as needed. The maximum number of steps in a workflow is 8. After you have added all of the necessary nominal steps, scroll down to the Exception handlers – optional section, and choose Add step. Create a workflow 377 AWS Transfer Family User Guide Note So that you are informed of failures in real time, we recommend that you set up exception handlers and steps to execute when your workflow fails. 6. To configure exception handlers, add steps in the same manner as described previously. If a file causes any step to throw an exception, your exception handlers are invoked one by one. 7. (Optional) Scroll down to the Tags section, and add tags for your workflow. 8. Review the configuration, and choose Create workflow. Important After you've created a workflow, you can't edit it, so make sure to review the configuration carefully. Configure and run a workflow Before you can run a workflow, you need to associate it with a Transfer Family server. To configure Transfer Family to run a workflow on uploaded files 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the left navigation pane, choose Servers. • To add the workflow to an existing server, choose the server that you want to use for your workflow. • Alternatively, create a new server and add the workflow to it. For more information, see Configuring an SFTP, FTPS, or FTP server endpoint. 3. On the details page for the server, scroll down to the Additional details section, and then choose Edit. Note By default, servers do not have any associated workflows. You use the Additional details section to associate a workflow with the selected server. Configure and run a workflow 378 AWS Transfer Family User Guide 4. On the Edit additional details page, in the Managed workflows section, select a workflow to be run on all uploads. Note If you do not already have a workflow, choose Create a new Workflow to create one. a. Choose the workflow ID to use. b. Choose an execution role. This is the role that Transfer Family assumes
|
transferfamily-ug-117
|
transferfamily-ug.pdf
| 117 |
Additional details section, and then choose Edit. Note By default, servers do not have any associated workflows. You use the Additional details section to associate a workflow with the selected server. Configure and run a workflow 378 AWS Transfer Family User Guide 4. On the Edit additional details page, in the Managed workflows section, select a workflow to be run on all uploads. Note If you do not already have a workflow, choose Create a new Workflow to create one. a. Choose the workflow ID to use. b. Choose an execution role. This is the role that Transfer Family assumes when executing the workflow's steps. For more information, see IAM policies for workflows. Choose Save. Note If you no longer want a workflow to be associated with the server, you can remove the association. For details, see Remove a workflow from a Transfer Family server. To execute a workflow To execute a workflow, you upload a file to a Transfer Family server that you configured with an associated workflow. Configure and run a workflow 379 AWS Transfer Family Note User Guide Anytime you remove a workflow from a server and replace it with a new one, or update server configuration (which impacts a workflow's execution role), you must wait approximately 10 minutes before executing the new workflow. The Transfer Family server caches the workflow details, and it takes 10 minutes for the server to refresh its cache. Additionally, you must log out of any active SFTP sessions, and then log back in after the 10-minute waiting period to see the changes. Example # Execute a workflow > sftp [email protected] Connected to s-1234567890abcdef0.server.transfer.us-east-1.amazonaws.com. sftp> put doc1.pdf Uploading doc1.pdf to /amzn-s3-demo-bucket/home/users/bob/doc1.pdf doc1.pdf 100% 5013KB 601.0KB/s 00:08 sftp> exit > After your file has been uploaded, the action defined is performed on your file. For example, if your workflow contains a copy step, the file is copied to the location that you defined in that step. You can use Amazon CloudWatch Logs to track the steps that executed and their execution status. View workflow details You can view details about previously created workflows or to workflow executions. To view these details, you can use the console or the AWS Command Line Interface (AWS CLI). Console View workflow details 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the left navigation pane, choose Workflows. 3. On the Workflows page, choose a workflow. View workflow details 380 AWS Transfer Family User Guide The workflow details page opens. CLI To view the workflow details, use the describe-workflow CLI command, as shown in the following example. Replace the workflow ID w-1234567890abcdef0 with your own value. For more information, see describe-workflow in the AWS CLI Command Reference. # View Workflow details > aws transfer describe-workflow --workflow-id w-1234567890abcdef0 { "Workflow": { "Arn": "arn:aws:transfer:us-east-1:111122223333:workflow/ w-1234567890abcdef0", "WorkflowId": "w-1234567890abcdef0", "Name": "Copy file to shared_files", "Steps": [ View workflow details 381 AWS Transfer Family { "Type": "COPY", "CopyStepDetails": { "Name": "Copy to shared", "FileLocation": { "S3FileLocation": { "Bucket": "amzn-s3-demo-bucket", "Key": "home/shared_files/" User Guide } } } } ], "OnException": {} } } If your workflow was created as part of an AWS CloudFormation stack, you can manage the workflow using the AWS CloudFormation console (https://console.aws.amazon.com/ cloudformation). View workflow details 382 AWS Transfer Family User Guide Use predefined steps When you're creating a workflow, you can choose to add one of the following predefined steps discussed in this topic. You can also choose to add your own custom file-processing steps. For more information, see the section called “Use custom file-processing steps”. Topics • Copy file • Decrypt file • Tag file • Delete file • Named variables for workflows • Example tag and delete workflow Copy file A copy file step creates a copy of the uploaded file in a new Amazon S3 location. Currently, you can use a copy file step only with Amazon S3. The following copy file step copies files into the test folder in amzn-s3-demo-destination- bucket. If the copy file step is not the first step of your workflow, you can specify the File location. By specifying the file location, you can copy either the file that was used in the previous step or the original file that was uploaded. You can use this feature to make multiple copies of the original file while keeping the source file intact for file archival and records retention. For an example, see Example tag and delete workflow. Use predefined steps 383 AWS Transfer Family User Guide Provide the bucket and key details You must provide the bucket name and a key for the destination of the copy file step. The key can be either a path name or a file name. Whether the key is treated as a path name or a file name is determined by whether you end the
|
transferfamily-ug-118
|
transferfamily-ug.pdf
| 118 |
was uploaded. You can use this feature to make multiple copies of the original file while keeping the source file intact for file archival and records retention. For an example, see Example tag and delete workflow. Use predefined steps 383 AWS Transfer Family User Guide Provide the bucket and key details You must provide the bucket name and a key for the destination of the copy file step. The key can be either a path name or a file name. Whether the key is treated as a path name or a file name is determined by whether you end the key with the forward slash (/) character. If the final character is /, your file is copied to the folder, and its name does not change. If the final character is alphanumeric, your uploaded file is renamed to the key value. In this case, if a file with that name already exists, the behavior depends on the setting for the Overwrite existing field. Copy file 384 AWS Transfer Family User Guide • If Overwrite existing is selected, the existing file is replaced with the file being processed. • If Overwrite existing is not selected, nothing happens, and the workflow processing stops. Tip If concurrent writes are executed on the same file path, it may result in unexpected behavior when overwriting files. For example, if your key value is test/, your uploaded files are copied to the test folder. If your key value is test/today, (and Overwrite existing is selected) every file you upload is copied to a file named today in the test folder, and each succeeding file overwrites the previous one. Note Amazon S3 supports buckets and objects, and there is no hierarchy. However, you can use prefixes and delimiters in object key names to imply a hierarchy and organize your data in a way similar to folders. Use a named variable in a copy file step In a copy file step, you can use a variable to dynamically copy your files into user-specific folders. Currently, you can use ${transfer:UserName} or ${transfer:UploadDate} as a variable to copy files to a destination location for the given user who's uploading files, or based on the current date. In the following example, if the user richard-roe uploads a file, it gets copied into the amzn- s3-demo-destination-bucket/richard-roe/processed/ folder. If the user mary-major uploads a file, it gets copied into the amzn-s3-demo-destination-bucket/mary-major/ processed/ folder. Copy file 385 AWS Transfer Family User Guide Similarly, you can use ${transfer:UploadDate} as a variable to copy files to a destination location named for the current date. In the following example, if you set the destination to ${transfer:UploadDate}/processed on February 1, 2022, files uploaded are copied into the amzn-s3-demo-destination-bucket/2022-02-01/processed/ folder. Copy file 386 AWS Transfer Family User Guide You can also use both of these variables together, combining their functionality. For example, you could set the Destination key prefix to folder/${transfer:UserName}/ ${transfer:UploadDate}/, which would created nested folders, for example folder/ marymajor/2023-01-05/. IAM permissions for copy step To allow a copy step to succeed, make sure the execution role for your workflow contains the following permissions. { "Sid": "ListBucket", "Effect": "Allow", "Action": "s3:ListBucket", "Resource": [ "arn:aws:s3:::amzn-s3-demo-destination-bucket" ] }, { Copy file 387 AWS Transfer Family User Guide "Sid": "HomeDirObjectAccess", "Effect": "Allow", "Action": [ "s3:PutObject", "s3:GetObject", "s3:DeleteObjectVersion", "s3:DeleteObject", "s3:GetObjectVersion" ], "Resource": "arn:aws:s3:::amzn-s3-demo-destination-bucket/*" } Note The s3:ListBucket permission is only necessary if you do not select Overwrite existing. This permission checks your bucket to see if a file with the same name already exists. If you have selected Overwrite existing, the workflow doesn't need to check for the file, and can just write it. If your Amazon S3 files have tags, you need to add one or two permissions to your IAM policy. • Add s3:GetObjectTagging for an Amazon S3 file that isn't versioned. • Add s3:GetObjectVersionTagging for an Amazon S3 file that is versioned. Decrypt file The AWS storage blog has a post that describes how to simply decrypt files without writing any code using Transfer Family Managed workflows, Encrypt and decrypt files with PGP and AWS Transfer Family. Supported symmetric encryption algorithms For PGP decryption, Transfer Family supports the following symmetric encryption algorithms: IDEA, 3DES, CAST5, Blowfish, DES, AES-128, AES-192, AES-256, TwoFish, CAMELLIA-128, CAMELLIA-192, CAMELLIA-256 The FIPS-compliant symmetric encryption algorithms are AES-128, AES-192, AES-256, and 3DES. Decrypt file 388 AWS Transfer Family User Guide Use PGP decryption in your workflow Transfer Family has built-in support for Pretty Good Privacy (PGP) decryption. You can use PGP decryption on files that are uploaded over SFTP, FTPS, or FTP to Amazon Simple Storage Service (Amazon S3) or Amazon Elastic File System (Amazon EFS). To use PGP decryption, you must create and store the PGP private keys that will be used for decryption of your files. Your users can then encrypt files by using
|
transferfamily-ug-119
|
transferfamily-ug.pdf
| 119 |
AES-256, TwoFish, CAMELLIA-128, CAMELLIA-192, CAMELLIA-256 The FIPS-compliant symmetric encryption algorithms are AES-128, AES-192, AES-256, and 3DES. Decrypt file 388 AWS Transfer Family User Guide Use PGP decryption in your workflow Transfer Family has built-in support for Pretty Good Privacy (PGP) decryption. You can use PGP decryption on files that are uploaded over SFTP, FTPS, or FTP to Amazon Simple Storage Service (Amazon S3) or Amazon Elastic File System (Amazon EFS). To use PGP decryption, you must create and store the PGP private keys that will be used for decryption of your files. Your users can then encrypt files by using corresponding PGP encryption keys before uploading the files to your Transfer Family server. After you receive the encrypted files, you can decrypt those files in your workflow. For a detailed tutorial, see Setting up a managed workflow for decrypting a file. To use PGP decryption in your workflow 1. Identify a Transfer Family server to host your workflow, or create a new one. You need to have the server ID before you can store your PGP keys in AWS Secrets Manager with the correct secret name. 2. Store your PGP key in AWS Secrets Manager under the required secret name. For details, see Manage PGP keys. Workflows can automatically locate the correct PGP key to be used for decryption based on the secret name in Secrets Manager. Note When you store secrets in Secrets Manager, your AWS account incurs charges. For information about pricing, see AWS Secrets Manager Pricing. 3. Encrypt a file by using your PGP key pair. (For a list of supported clients, see Supported PGP clients.) If you are using the command line, run the following command. To use this command, replace [email protected] with the email address that you used to create the PGP key pair. Replace testfile.txt with the name of the file that you want to encrypt. gpg -e -r [email protected] testfile.txt 4. Upload the encrypted file to your Transfer Family server. 5. Configure a decryption step in your workflow. For more information, see Add a decryption step. Decrypt file 389 AWS Transfer Family Add a decryption step User Guide A decryption step decrypts an encrypted file that was uploaded to Amazon S3 or Amazon EFS as part of your workflow. For details about configuring decryption, see Use PGP decryption in your workflow. When you create your decryption step for a workflow, you must specify the destination for the decrypted files. You must also select whether to overwrite existing files if a file already exists at the destination location. You can monitor the decryption workflow results and get audit logs for each file in real time by using Amazon CloudWatch Logs. After you choose the Decrypt file type for your step, the Configure parameters page appears. Fill in the values for the Configure PGP decryption parameters section. The available options are as follows: • Step name – Enter a descriptive name for the step. • File location – By specifying the file location, you can decrypt either the file that was used in the previous step or the original file that was uploaded. Note This parameter is not available if this step is the first step of the workflow. • Destination for decrypted files – Choose an Amazon S3 bucket or an Amazon EFS file system as the destination for the decrypted file. • If you choose Amazon S3, you must provide a destination bucket name and a destination key prefix. To parameterize the destination key prefix by username, enter ${transfer:UserName} for Destination key prefix. Similarly, to parameterize the destination key prefix by upload date, enter ${Transfer:UploadDate} for Destination key prefix. • If you choose Amazon EFS, you must provide a destination file system and path. Note The storage option that you choose here must match the storage system that's used by the Transfer Family server with which this workflow is associated. Otherwise, you will receive an error when you attempt to run this workflow. Decrypt file 390 AWS Transfer Family User Guide • Overwrite existing – If you upload a file, and a file with the same filename already exists at the destination, the behavior depends on the setting for this parameter: • If Overwrite existing is selected, the existing file is replaced with the file being processed. • If Overwrite existing is not selected, nothing happens, and the workflow processing stops. Tip If concurrent writes are executed on the same file path, it may result in unexpected behavior when overwriting files. The following screenshot shows an example of the options that you might choose for your decrypt file step. Decrypt file 391 AWS Transfer Family User Guide Decrypt file 392 AWS Transfer Family User Guide IAM permissions for decrypt step To allow a decrypt step to succeed, make sure the execution role for
|
transferfamily-ug-120
|
transferfamily-ug.pdf
| 120 |
Overwrite existing is selected, the existing file is replaced with the file being processed. • If Overwrite existing is not selected, nothing happens, and the workflow processing stops. Tip If concurrent writes are executed on the same file path, it may result in unexpected behavior when overwriting files. The following screenshot shows an example of the options that you might choose for your decrypt file step. Decrypt file 391 AWS Transfer Family User Guide Decrypt file 392 AWS Transfer Family User Guide IAM permissions for decrypt step To allow a decrypt step to succeed, make sure the execution role for your workflow contains the following permissions. { "Sid": "ListBucket", "Effect": "Allow", "Action": "s3:ListBucket", "Resource": [ "arn:aws:s3:::amzn-s3-demo-destination-bucket" ] }, { "Sid": "HomeDirObjectAccess", "Effect": "Allow", "Action": [ "s3:PutObject", "s3:GetObject", "s3:DeleteObjectVersion", "s3:DeleteObject", "s3:GetObjectVersion" ], "Resource": "arn:aws:s3:::amzn-s3-demo-destination-bucket/*" }, { "Sid": "Decrypt", "Effect": "Allow", "Action": [ "secretsmanager:GetSecretValue", ], "Resource": "arn:aws:secretsmanager:region:account-id:secret:aws/transfer/ *" } Note The s3:ListBucket permission is only necessary if you do not select Overwrite existing. This permission checks your bucket to see if a file with the same name already exists. If you have selected Overwrite existing, the workflow doesn't need to check for the file, and can just write it. Decrypt file 393 AWS Transfer Family User Guide If your Amazon S3 files have tags, you need to add one or two permissions to your IAM policy. • Add s3:GetObjectTagging for an Amazon S3 file that isn't versioned. • Add s3:GetObjectVersionTagging for an Amazon S3 file that is versioned. Tag file To tag incoming files for further downstream processing, use a tag step. Enter the value of the tag that you would like to assign to the incoming files. Currently, the tag operation is supported only if you are using Amazon S3 for your Transfer Family server storage. The following example tag step assigns scan_outcome and clean as the tag key and value, respectively. To allow a tag step to succeed, make sure the execution role for your workflow contains the following permissions. { Tag file 394 AWS Transfer Family User Guide "Sid": "Tag", "Effect": "Allow", "Action": [ "s3:PutObjectTagging", "s3:PutObjectVersionTagging" ], "Resource": [ "arn:aws:s3:::amzn-s3-demo-bucket/*" ] } Note If your workflow contains a tag step that runs before either a copy or decrypt step, you need to add one or two permissions to your IAM policy. • Add s3:GetObjectTagging for an Amazon S3 file that isn't versioned. • Add s3:GetObjectVersionTagging for an Amazon S3 file that is versioned. Delete file To delete a processed file from a previous workflow step or to delete the originally uploaded file, use a delete file step. To allow a delete step to succeed, make sure the execution role for your workflow contains the following permissions. { Delete file 395 AWS Transfer Family User Guide "Sid": "Delete", "Effect": "Allow", "Action": [ "s3:DeleteObjectVersion", "s3:DeleteObject" ], "Resource": "arn:aws:secretsmanager:region:account-ID:secret:aws/transfer/ *" } Named variables for workflows For copy and decrypt steps, you can use a variable to dynamically perform actions. Currently, AWS Transfer Family supports the following named variables. • Use ${transfer:UserName} to copy or decrypt files to a destination based on the user who's uploading the files. • Use ${transfer:UploadDate} to copy or decrypt files to a destination location based on the current date. Example tag and delete workflow The following example illustrates a workflow that tags incoming files that need to be processed by a downstream application, such as a data analytics platform. After tagging the incoming file, the workflow then deletes the originally uploaded file to save on storage costs. Console Example tag and move workflow 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the left navigation pane, choose Workflows. 3. On the Workflows page, choose Create workflow. 4. On the Create workflow page, enter a description. This description appears on the Workflows page. 5. Add the first step (copy). a. In the Nominal steps section, choose Add step. Named variables for workflows 396 AWS Transfer Family User Guide b. Choose Copy file, then choose Next. c. Enter a step name, then select a destination bucket and a key prefix. d. Choose Next, then review the details for the step. e. Choose Create step to add the step and continue. 6. Add the second step (tag). a. In the Nominal steps section, choose Add step. b. Choose Tag file, then choose Next. c. d. e. Enter a step name. For File location, select Tag the file created from previous step. Enter a Key and Value. Example tag and delete workflow 397 AWS Transfer Family User Guide f. Choose Next, then review the details for the step. g. Choose Create step to add the step and continue. 7. Add the third step (delete). a. In the Nominal steps section, choose Add step. b. Choose Delete file, then choose Next. c. Enter a step name. Example tag and delete
|
transferfamily-ug-121
|
transferfamily-ug.pdf
| 121 |
In the Nominal steps section, choose Add step. b. Choose Tag file, then choose Next. c. d. e. Enter a step name. For File location, select Tag the file created from previous step. Enter a Key and Value. Example tag and delete workflow 397 AWS Transfer Family User Guide f. Choose Next, then review the details for the step. g. Choose Create step to add the step and continue. 7. Add the third step (delete). a. In the Nominal steps section, choose Add step. b. Choose Delete file, then choose Next. c. Enter a step name. Example tag and delete workflow 398 AWS Transfer Family User Guide d. e. f. For File location, select Delete the original source file. Choose Next, then review the details for the step. Choose Create step to add the step and continue. 8. Review the workflow configuration, and then choose Create workflow. CLI Example tag and move workflow 1. Save the following code into a file; for example, tagAndMoveWorkflow.json. Replace each user input placeholder with your own information. [ { "Type": "COPY", "CopyStepDetails": { "Name": "CopyStep", "DestinationFileLocation": { "S3FileLocation": { "Bucket": "amzn-s3-demo-bucket", "Key": "test/" } } } }, { "Type": "TAG", "TagStepDetails": { "Name": "TagStep", "Tags": [ { "Key": "name", "Value": "demo" } ], "SourceFileLocation": "${previous.file}" } }, { "Type": "DELETE", "DeleteStepDetails":{ Example tag and delete workflow 399 AWS Transfer Family User Guide "Name":"DeleteStep", "SourceFileLocation": "${original.file}" } } ] The first step copies the uploaded file to a new Amazon S3 location. The second step adds a tag (key-value pair) to the file (previous.file) that was copied to the new location. And, finally, the third step deletes the original file (original.file). 2. Create a workflow from the saved file. Replace each user input placeholder with your own information. aws transfer create-workflow --description "short-description" --steps file://path-to-file --region region-ID For example: aws transfer create-workflow --description "copy-tag-delete workflow" --steps file://tagAndMoveWorkflow.json --region us-east-1 Note For more details about using files to load parameters, see How to load parameters from a file. 3. Update an existing server. Note This step assumes you already have a Transfer Family server and you want to associate a workflow with it. If not, see Configuring an SFTP, FTPS, or FTP server endpoint. Replace each user input placeholder with your own information. aws transfer update-server --server-id server-ID --region region-ID --workflow-details '{"OnUpload":[{ "WorkflowId": "workflow- ID","ExecutionRole": "execution-role-ARN"}]}' Example tag and delete workflow 400 AWS Transfer Family For example: User Guide aws transfer update-server --server-id s-1234567890abcdef0 --region us-east-2 --workflow-details '{"OnUpload":[{ "WorkflowId": "w- abcdef01234567890","ExecutionRole": "arn:aws:iam::111111111111:role/nikki-wolf- execution-role"}]}' Use custom file-processing steps By using a custom file-processing step, you can Bring Your Own file-processing logic using AWS Lambda. Upon file arrival, a Transfer Family server invokes a Lambda function that contains custom file-processing logic, such as encrypting files, scanning for malware, or checking for incorrect file types. In the following example, the target AWS Lambda function is used to process the output file from the previous step. Use custom file-processing steps 401 AWS Transfer Family Note User Guide For an example Lambda function, see Example Lambda function for a custom workflow step. For example events (including the location for files passed into the Lambda), see Example events sent to AWS Lambda upon file upload. With a custom workflow step, you must configure the Lambda function to call the SendWorkflowStepState API operation. SendWorkflowStepState notifies the workflow execution that the step was completed with either a success or a failure status. The status of the SendWorkflowStepState API operation invokes an exception handler step or a nominal step in the linear sequence, based on the outcome of the Lambda function. If the Lambda function fails or times out, the step fails, and you see StepErrored in your CloudWatch logs. If the Lambda function is part of the nominal step and the function responds to SendWorkflowStepState with Status="FAILURE" or times out, the flow continues with the exception handler steps. In this case, the workflow does not continue to execute the remaining (if any) nominal steps. For more details, see Exception handling for a workflow. When you call the SendWorkflowStepState API operation, you must send the following parameters: { "ExecutionId": "string", "Status": "string", "Token": "string", "WorkflowId": "string" } You can extract the ExecutionId, Token, and WorkflowId from the input event that is passed when the Lambda function executes (examples are shown in the following sections). The Status value can be either SUCCESS or FAILURE. To be able to call the SendWorkflowStepState API operation from your Lambda function, you must use a version of the AWS SDK that was published after Managed Workflows were introduced. Using multiple Lambda functions consecutively When you use multiple custom steps one after the other, the File location option works differently than if you use only a single custom step. Transfer Family doesn't support passing the Lambda- Using multiple Lambda functions consecutively
|
transferfamily-ug-122
|
transferfamily-ug.pdf
| 122 |
from the input event that is passed when the Lambda function executes (examples are shown in the following sections). The Status value can be either SUCCESS or FAILURE. To be able to call the SendWorkflowStepState API operation from your Lambda function, you must use a version of the AWS SDK that was published after Managed Workflows were introduced. Using multiple Lambda functions consecutively When you use multiple custom steps one after the other, the File location option works differently than if you use only a single custom step. Transfer Family doesn't support passing the Lambda- Using multiple Lambda functions consecutively 402 AWS Transfer Family User Guide processed file back to use as the next step's input. So, if you have multiple custom steps all configured to use the previous.file option, they all use the same file location (the input file location for the first custom step). Note The previous.file setting also works differently if you have a predefined step (tag, copy, decrypt, or delete) after a custom step. If the predefined step is configured to use the previous.file setting, the predefined step uses the same input file that's used by the custom step. The processed file from the custom step is not passed to the predefined step. Accessing a file after custom processing If you're using Amazon S3 as your storage, and if your workflow includes a custom step that performs actions on the originally uploaded file, subsequent steps cannot access that processed file. That is, any step after the custom step cannot reference the updated file from the custom step output. For example, suppose that you have the following three steps in your workflow. • Step 1 – Upload a file named example-file.txt. • Step 2 – Invoke a Lambda function that changes example-file.txt in some way. • Step 3 – Attempt to perform further processing on the updated version of example-file.txt. If you configure the sourceFileLocation for Step 3 to be ${original.file}, Step 3 uses the original file location from when the server uploaded the file to storage in Step 1. If you're using ${previous.file} for Step 3, Step 3 reuses the file location that Step 2 used as input. Therefore, Step 3 causes an error. For example, if step 3 attempts to copy the updated example- file.txt, you receive the following error: { "type": "StepErrored", "details": { "errorType": "NOT_FOUND", "errorMessage": "ETag constraint not met (Service: null; Status Code: 412; Error Code: null; Request ID: null; S3 Extended Request ID: null; Proxy: null)", "stepType": "COPY", Accessing a file after custom processing 403 AWS Transfer Family User Guide "stepName": "CopyFile" }, This error occurs because the custom step modifies the entity tag (ETag) for example-file.txt so that it doesn't match the original file. Note This behavior doesn't occur if you're using Amazon EFS because Amazon EFS doesn't use entity tags to identify files. Example events sent to AWS Lambda upon file upload The following examples show the events that are sent to AWS Lambda when a file upload is complete. One example uses a Transfer Family server where the domain is configured with Amazon S3. The other example uses a Transfer Family server where the domain uses Amazon EFS. Custom step that uses an Amazon S3 domain { "token": "MzI0Nzc4ZDktMGRmMi00MjFhLTgxMjUtYWZmZmRmODNkYjc0", "serviceMetadata": { "executionDetails": { "workflowId": "w-1234567890example", "executionId": "abcd1234-aa11-bb22-cc33-abcdef123456" }, "transferDetails": { "sessionId": "36688ff5d2deda8c", "userName": "myuser", "serverId": "s-example1234567890" } }, "fileLocation": { "domain": "S3", "bucket": "amzn-s3-demo-bucket", "key": "path/to/mykey", "eTag": "d8e8fca2dc0f896fd7cb4cb0031ba249", "versionId": null } } Example events sent to AWS Lambda upon file upload 404 AWS Transfer Family User Guide Custom step that uses an Amazon EFS domain { "token": "MTg0N2Y3N2UtNWI5Ny00ZmZlLTk5YTgtZTU3YzViYjllNmZm", "serviceMetadata": { "executionDetails": { "workflowId": "w-1234567890example", "executionId": "abcd1234-aa11-bb22-cc33-abcdef123456" }, "transferDetails": { "sessionId": "36688ff5d2deda8c", "userName": "myuser", "serverId": "s-example1234567890" } }, "fileLocation": { "domain": "EFS", "fileSystemId": "fs-1234567", "path": "/path/to/myfile" } } Example Lambda function for a custom workflow step The following Lambda function extracts the information regarding the execution status, and then calls the SendWorkflowStepState API operation to return the status to the workflow for the step —either SUCCESS or FAILURE. Before your function calls the SendWorkflowStepState API operation, you can configure Lambda to take an action based on your workflow logic. import json import boto3 transfer = boto3.client('transfer') def lambda_handler(event, context): print(json.dumps(event)) # call the SendWorkflowStepState API to notify the workflow about the step's SUCCESS or FAILURE status response = transfer.send_workflow_step_state( WorkflowId=event['serviceMetadata']['executionDetails']['workflowId'], Example Lambda function for a custom workflow step 405 AWS Transfer Family User Guide ExecutionId=event['serviceMetadata']['executionDetails']['executionId'], Token=event['token'], Status='SUCCESS|FAILURE' ) print(json.dumps(response)) return { 'statusCode': 200, 'body': json.dumps(response) } IAM permissions for a custom step To allow a step that calls a Lambda to succeed, make sure the execution role for your workflow contains the following permissions. { "Sid": "Custom", "Effect": "Allow", "Action": [ "lambda:InvokeFunction" ], "Resource": [ "arn:aws:lambda:region:account-id:function:function-name" ] } IAM policies for workflows When you add a workflow to a
|
transferfamily-ug-123
|
transferfamily-ug.pdf
| 123 |
print(json.dumps(event)) # call the SendWorkflowStepState API to notify the workflow about the step's SUCCESS or FAILURE status response = transfer.send_workflow_step_state( WorkflowId=event['serviceMetadata']['executionDetails']['workflowId'], Example Lambda function for a custom workflow step 405 AWS Transfer Family User Guide ExecutionId=event['serviceMetadata']['executionDetails']['executionId'], Token=event['token'], Status='SUCCESS|FAILURE' ) print(json.dumps(response)) return { 'statusCode': 200, 'body': json.dumps(response) } IAM permissions for a custom step To allow a step that calls a Lambda to succeed, make sure the execution role for your workflow contains the following permissions. { "Sid": "Custom", "Effect": "Allow", "Action": [ "lambda:InvokeFunction" ], "Resource": [ "arn:aws:lambda:region:account-id:function:function-name" ] } IAM policies for workflows When you add a workflow to a server, you must select an execution role. The server uses this role when it executes the workflow. If the role does not have the proper permissions, AWS Transfer Family cannot run the workflow. This section describes one possible set of AWS Identity and Access Management (IAM) permissions that you can use to execute a workflow. Other examples are described later in this topic. Note If your Amazon S3 files have tags, you need to add one or two permissions to your IAM policy. IAM permissions for a custom step 406 AWS Transfer Family User Guide • Add s3:GetObjectTagging for an Amazon S3 file that isn't versioned. • Add s3:GetObjectVersionTagging for an Amazon S3 file that is versioned. To create an execution role for your workflow 1. Create a new IAM role, and add the AWS managed policy AWSTransferFullAccess to the role. For more information about creating a new IAM role, see the section called “Create an IAM role and policy”. 2. Create another policy with the following permissions, and attach it to your role. Replace each user input placeholder with your own information. { "Version": "2012-10-17", "Statement": [ { "Sid": "ConsoleAccess", "Effect": "Allow", "Action": "s3:GetBucketLocation", "Resource": "*" }, { "Sid": "ListObjectsInBucket", "Effect": "Allow", "Action": "s3:ListBucket", "Resource": [ "arn:aws:s3:::amzn-s3-demo-bucket" ] }, { "Sid": "AllObjectActions", "Effect": "Allow", "Action": "s3:*Object", "Resource": [ "arn:aws:s3:::amzn-s3-demo-bucket/*" ] }, { "Sid": "GetObjectVersion", "Effect": "Allow", "Action": "s3:GetObjectVersion", IAM policies for workflows 407 AWS Transfer Family User Guide "Resource": [ "arn:aws:s3:::amzn-s3-demo-bucket/*" ] }, { "Sid": "Custom", "Effect": "Allow", "Action": [ "lambda:InvokeFunction" ], "Resource": [ "arn:aws:lambda:region:account-id:function:function-name" ] }, { "Sid": "Tag", "Effect": "Allow", "Action": [ "s3:PutObjectTagging", "s3:PutObjectVersionTagging" ], "Resource": [ "arn:aws:s3:::amzn-s3-demo-bucket/*" ] } ] } 3. Save this role and specify it as the execution role when you add a workflow to a server. Note When you're constructing IAM roles, AWS recommends that you restrict access to your resources as much as is possible for your workflow. Workflow trust relationships Workflow execution roles also require a trust relationship with transfer.amazonaws.com. To establish a trust relationship for AWS Transfer Family, see To establish a trust relationship. Workflow trust relationships 408 AWS Transfer Family User Guide While you're establishing your trust relationship, you can also take steps to avoid the confused deputy problem. For a description of this problem, as well as examples of how to avoid it, see the section called “Cross-service confused deputy prevention”. Example execution role: Decrypt, copy, and tag If you have workflows that include tagging, copying, and decrypt steps, you can use the following IAM policy. Replace each user input placeholder with your own information. { "Version": "2012-10-17", "Statement": [ { "Sid": "CopyRead", "Effect": "Allow", "Action": [ "s3:GetObject", "s3:GetObjectTagging", "s3:GetObjectVersionTagging" ], "Resource": "arn:aws:s3:::amzn-s3-demo-source-bucket/*" }, { "Sid": "CopyWrite", "Effect": "Allow", "Action": [ "s3:PutObject", "s3:PutObjectTagging" ], "Resource": "arn:aws:s3:::amzn-s3-demo-destination-bucket/*" }, { "Sid": "CopyList", "Effect": "Allow", "Action": "s3:ListBucket", "Resource": [ "arn:aws:s3:::amzn-s3-demo-source-bucket", "arn:aws:s3:::amzn-s3-demo-destination-bucket" ] }, { "Sid": "Tag", "Effect": "Allow", Example execution role: Decrypt, copy, and tag 409 AWS Transfer Family User Guide "Action": [ "s3:PutObjectTagging", "s3:PutObjectVersionTagging" ], "Resource": "arn:aws:s3:::amzn-s3-demo-destination-bucket/*", "Condition": { "StringEquals": { "s3:RequestObjectTag/Archive": "yes" } } }, { "Sid": "ListBucket", "Effect": "Allow", "Action": "s3:ListBucket", "Resource": [ "arn:aws:s3:::amzn-s3-demo-destination-bucket" ] }, { "Sid": "HomeDirObjectAccess", "Effect": "Allow", "Action": [ "s3:PutObject", "s3:GetObject", "s3:DeleteObjectVersion", "s3:DeleteObject", "s3:GetObjectVersion" ], "Resource": "arn:aws:s3:::amzn-s3-demo-destination-bucket/*" }, { "Sid": "Decrypt", "Effect": "Allow", "Action": [ "secretsmanager:GetSecretValue" ], "Resource": "arn:aws:secretsmanager:region:account-ID:secret:aws/transfer/ *" } ] } Example execution role: Decrypt, copy, and tag 410 AWS Transfer Family User Guide Example execution role: Run function and delete In this example, you have a workflow that invokes an AWS Lambda function. If the workflow deletes the uploaded file and has an exception handler step to act upon a failed workflow execution in the previous step, use the following IAM policy. Replace each user input placeholder with your own information. { "Version": "2012-10-17", "Statement": [ { "Sid": "Delete", "Effect": "Allow", "Action": [ "s3:DeleteObject", "s3:DeleteObjectVersion" ], "Resource": "arn:aws:s3:::bucket-name" }, { "Sid": "Custom", "Effect": "Allow", "Action": [ "lambda:InvokeFunction" ], "Resource": [ "arn:aws:lambda:region:account-id:function:function-name" ] } ] } Exception handling for a workflow If any errors occur during a workflow's execution, the exception-handling steps that you specified are executed. You specify the error-handling steps for a workflow in the same manner as you specify the nominal steps for the workflow. For example, suppose
|
transferfamily-ug-124
|
transferfamily-ug.pdf
| 124 |
failed workflow execution in the previous step, use the following IAM policy. Replace each user input placeholder with your own information. { "Version": "2012-10-17", "Statement": [ { "Sid": "Delete", "Effect": "Allow", "Action": [ "s3:DeleteObject", "s3:DeleteObjectVersion" ], "Resource": "arn:aws:s3:::bucket-name" }, { "Sid": "Custom", "Effect": "Allow", "Action": [ "lambda:InvokeFunction" ], "Resource": [ "arn:aws:lambda:region:account-id:function:function-name" ] } ] } Exception handling for a workflow If any errors occur during a workflow's execution, the exception-handling steps that you specified are executed. You specify the error-handling steps for a workflow in the same manner as you specify the nominal steps for the workflow. For example, suppose that you've configured custom processing in nominal steps to validate incoming files. If the file validation fails, an exception- handling step can send an email to the administrator. The following example workflow contains two steps: Example execution role: Run function and delete 411 AWS Transfer Family User Guide • One nominal step that checks whether the uploaded file is in CSV format • An exception-handling step that sends an email in case the uploaded file is not in CSV format, and the nominal step fails To initiate the exception-handling step, the AWS Lambda function in the nominal step must respond with Status="FAILURE". For more information about error handling in workflows, see the section called “Use custom file-processing steps”. Monitor workflow execution Amazon CloudWatch monitors your AWS resources and the applications that you run in the AWS Cloud in real time. You can use Amazon CloudWatch to collect and track metrics, which are variables that you can measure for your workflows. You can view workflow metrics and consolidated logs by using Amazon CloudWatch. CloudWatch logging for a workflow CloudWatch provides consolidated auditing and logging for workflow progress and results. Monitor workflow execution 412 AWS Transfer Family User Guide View Amazon CloudWatch logs for workflows 1. Open the Amazon CloudWatch console at https://console.aws.amazon.com/cloudwatch/. 2. In the left navigation pane, choose Logs, then choose Log groups. 3. On the Log groups page, on the navigation bar, choose the correct Region for your AWS Transfer Family server. 4. Choose the log group that corresponds to your server. For example, if your server ID is s-1234567890abcdef0, your log group is /aws/transfer/ s-1234567890abcdef0. 5. On the log group details page for your server, the most recent log streams are displayed. There are two log streams for the user that you are exploring: • One for each Secure Shell (SSH) File Transfer Protocol (SFTP) session. • One for the workflow that is being executed for your server. The format for the log stream for the workflow is username.workflowID.uniqueStreamSuffix. For example, if your user is mary-major, you have the following log streams: mary-major-east.1234567890abcdef0 mary.w-abcdef01234567890.021345abcdef6789 Note The 16-digit alphanumeric identifiers listed in this example are fictitious. The values that you see in Amazon CloudWatch are different. The Log events page for mary-major-usa-east.1234567890abcdef0 displays the details for each user session, and the mary.w-abcdef01234567890.021345abcdef6789 log stream contains the details for the workflow. The following is a sample log stream for mary.w-abcdef01234567890.021345abcdef6789, based on a workflow (w-abcdef01234567890) that contains a copy step. { "type": "ExecutionStarted", CloudWatch logging for a workflow 413 User Guide AWS Transfer Family "details": { "input": { "initialFileLocation": { "bucket": "amzn-s3-demo-bucket", "key": "mary/workflowSteps2.json", "versionId": "version-id", "etag": "etag-id" } } }, "workflowId":"w-abcdef01234567890", "executionId":"execution-id", "transferDetails": { "serverId":"s-server-id", "username":"mary", "sessionId":"session-id" } }, { "type":"StepStarted", "details": { "input": { "fileLocation": { "backingStore":"S3", "bucket":"amzn-s3-demo-bucket", "key":"mary/workflowSteps2.json", "versionId":"version-id", "etag":"etag-id" } }, "stepType":"COPY", "stepName":"copyToShared" }, "workflowId":"w-abcdef01234567890", "executionId":"execution-id", "transferDetails": { "serverId":"s-server-id", "username":"mary", "sessionId":"session-id" } }, { "type":"StepCompleted", "details":{ CloudWatch logging for a workflow 414 AWS Transfer Family User Guide "output":{}, "stepType":"COPY", "stepName":"copyToShared" }, "workflowId":"w-abcdef01234567890", "executionId":"execution-id", "transferDetails":{ "serverId":"server-id", "username":"mary", "sessionId":"session-id" } }, { "type":"ExecutionCompleted", "details": {}, "workflowId":"w-abcdef01234567890", "executionId":"execution-id", "transferDetails":{ "serverId":"s-server-id", "username":"mary", "sessionId":"session-id" } } CloudWatch metrics for workflows AWS Transfer Family provides several metrics for workflows. You can view metrics for how many workflows executions started, completed successfully, and failed in the previous minute. All of the CloudWatch metrics for Transfer Family are described in Using CloudWatch metrics for Transfer Family servers. Create a workflow from a template You can deploy an AWS CloudFormation stack that creates a workflow and a server from a template. This procedure contains an example that you can use to quickly deploy a workflow. To create an AWS CloudFormation stack that creates an AWS Transfer Family workflow and server 1. Open the AWS CloudFormation console at https://console.aws.amazon.com/cloudformation. 2. Save the following code to a file. CloudWatch metrics for workflows 415 AWS Transfer Family YAML User Guide AWSTemplateFormatVersion: 2010-09-09 Resources: SFTPServer: Type: 'AWS::Transfer::Server' Properties: WorkflowDetails: OnUpload: - ExecutionRole: workflow-execution-role-arn WorkflowId: !GetAtt - TransferWorkflow - WorkflowId TransferWorkflow: Type: AWS::Transfer::Workflow Properties: Description: Transfer Family Workflows Blog Steps: - Type: COPY CopyStepDetails: Name: copyToUserKey DestinationFileLocation: S3FileLocation: Bucket: archived-records Key: ${transfer:UserName}/ OverwriteExisting: 'TRUE' - Type: TAG TagStepDetails: Name: tagFileForArchive Tags: - Key: Archive Value: yes - Type: CUSTOM CustomStepDetails:
|
transferfamily-ug-125
|
transferfamily-ug.pdf
| 125 |
To create an AWS CloudFormation stack that creates an AWS Transfer Family workflow and server 1. Open the AWS CloudFormation console at https://console.aws.amazon.com/cloudformation. 2. Save the following code to a file. CloudWatch metrics for workflows 415 AWS Transfer Family YAML User Guide AWSTemplateFormatVersion: 2010-09-09 Resources: SFTPServer: Type: 'AWS::Transfer::Server' Properties: WorkflowDetails: OnUpload: - ExecutionRole: workflow-execution-role-arn WorkflowId: !GetAtt - TransferWorkflow - WorkflowId TransferWorkflow: Type: AWS::Transfer::Workflow Properties: Description: Transfer Family Workflows Blog Steps: - Type: COPY CopyStepDetails: Name: copyToUserKey DestinationFileLocation: S3FileLocation: Bucket: archived-records Key: ${transfer:UserName}/ OverwriteExisting: 'TRUE' - Type: TAG TagStepDetails: Name: tagFileForArchive Tags: - Key: Archive Value: yes - Type: CUSTOM CustomStepDetails: Name: transferExtract Target: arn:aws:lambda:region:account-id:function:function-name TimeoutSeconds: 60 - Type: DELETE DeleteStepDetails: Name: DeleteInputFile SourceFileLocation: '${original.file}' Tags: - Key: Name Create workflow from template 416 AWS Transfer Family User Guide Value: TransferFamilyWorkflows JSON { "AWSTemplateFormatVersion": "2010-09-09", "Resources": { "SFTPServer": { "Type": "AWS::Transfer::Server", "Properties": { "WorkflowDetails": { "OnUpload": [ { "ExecutionRole": "workflow-execution-role-arn", "WorkflowId": { "Fn::GetAtt": [ "TransferWorkflow", "WorkflowId" ] } } ] } } }, "TransferWorkflow": { "Type": "AWS::Transfer::Workflow", "Properties": { "Description": "Transfer Family Workflows Blog", "Steps": [ { "Type": "COPY", "CopyStepDetails": { "Name": "copyToUserKey", "DestinationFileLocation": { "S3FileLocation": { "Bucket": "archived-records", "Key": "${transfer:UserName}/" } }, "OverwriteExisting": "TRUE" } }, Create workflow from template 417 AWS Transfer Family User Guide { "Type": "TAG", "TagStepDetails": { "Name": "tagFileForArchive", "Tags": [ { "Key": "Archive", "Value": "yes" } ] } }, { "Type": "CUSTOM", "CustomStepDetails": { "Name": "transferExtract", "Target": "arn:aws:lambda:region:account- id:function:function-name", "TimeoutSeconds": 60 } }, { "Type": "DELETE", "DeleteStepDetails": { "Name": "DeleteInputFile", "SourceFileLocation": "${original.file}" } } ], "Tags": [ { "Key": "Name", "Value": "TransferFamilyWorkflows" } ] } } } } 3. Replace the following items with your actual values. Create workflow from template 418 AWS Transfer Family User Guide • Replace workflow-execution-role-arn with the ARN for an actual workflow execution role. For example, arn:aws:transfer:us-east-2:111122223333:workflow/ w-1234567890abcdef0 • Replace arn:aws:lambda:region:account-id:function:function-name with the ARN for your Lambda function. For example, arn:aws:lambda:us- east-2:123456789012:function:example-lambda-idp. 4. Follow the instructions for deploying an AWS CloudFormation stack from an existing template in Selecting a stack template in the AWS CloudFormation User Guide. After the stack has been deployed, you can view details about it in the Outputs tab in the CloudFormation console. The template creates a new AWS Transfer Family SFTP server that uses service-managed users, and a new workflow, and associates the workflow with the new server. Remove a workflow from a Transfer Family server If you have associated a workflow with a Transfer Family server, and you now want to remove that association, you can do so by using the console or programmatically. Console To remove a workflow from a Transfer Family server 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the left navigation pane, choose Servers. 3. Choose the identifier for the server in the Server ID column. 4. On the details page for the server, scroll down to the Additional details section, and then choose Edit. 5. On the Edit additional details page, in the Managed workflows section, clear the information for all settings: • Select the dash (-) from the list of workflows for the Workflow for complete file uploads. • If not already cleared, select the dash (-) from the list of workflows for the Workflow for partial file uploads. • Select the dash (-) from the list of roles for the Managed workflows execution role. Remove a workflow from a Transfer Family server 419 AWS Transfer Family User Guide If you don't see the dash, scroll up until you see it, as it is the first value in each menu. The screen should look like the following. 6. Scroll down and choose Save to save your changes. CLI You use the update-server (or UpdateServer for API) call, and provide empty arguments for the OnUpload and OnPartialUpload parameters. From the AWS CLI, run the following command: aws transfer update-server --server-id your-server-id --workflow-details '{"OnPartialUpload":[],"OnUpload":[]}' Replace your-server-id with the ID for your server. For example, if your server ID is, s-01234567890abcdef, the command is as follows: aws transfer update-server --server-id s-01234567890abcdef --workflow-details '{"OnPartialUpload":[],"OnUpload":[]}' Managed workflows restrictions and limitations Restrictions Restrictions and limits 420 AWS Transfer Family User Guide The following restrictions currently apply to post-upload processing workflows for AWS Transfer Family. • Cross-account and cross-region AWS Lambda functions are not supported. You can, however, copy across accounts, provided that your AWS Identity and Access Management (IAM) policies are correctly configured. • For all workflow steps, any Amazon S3 buckets accessed by the workflow must be in the same region as the workflow itself. • For a decryption step, the decryption destination must match the source for Region and backing store (for example, if the file to be decrypted is stored in Amazon S3, then the specified destination must also be in Amazon S3). • Only asynchronous custom steps are supported. • Custom step timeouts are approximate. That is,
|
transferfamily-ug-126
|
transferfamily-ug.pdf
| 126 |
are not supported. You can, however, copy across accounts, provided that your AWS Identity and Access Management (IAM) policies are correctly configured. • For all workflow steps, any Amazon S3 buckets accessed by the workflow must be in the same region as the workflow itself. • For a decryption step, the decryption destination must match the source for Region and backing store (for example, if the file to be decrypted is stored in Amazon S3, then the specified destination must also be in Amazon S3). • Only asynchronous custom steps are supported. • Custom step timeouts are approximate. That is, it might take slightly longer to time out than specified. Additionally, the workflow is dependent upon the Lambda function. Therefore, if the function is delayed during execution, the workflow is not aware of the delay. • If you exceed your throttling limit, Transfer Family doesn't add workflow operations to the queue. • Workflows are not initiated for files that have a size of 0. Files with a size greater than 0 do initiate the associated workflow. • You can attach a file-processing workflow to a Transfer Family server that uses the AS2 protocol: however, AS2 messages don't execute workflows attached to the server. Limitations Additionally, the following functional limits apply to workflows for Transfer Family: • The number of workflows per Region, per account, is limited to 10. • The maximum timeout for custom steps is 30 minutes. • The maximum number of steps in a workflow is 8. • The maximum number of tags per workflow is 50. • The maximum number of concurrent executions that contain a decrypt step is 250 per workflow. • You can store a maximum of 3 PGP private keys, per Transfer Family server, per user. • The maximum size for a decrypted file is 10 GB. Restrictions and limits 421 AWS Transfer Family User Guide • We throttle the new execution rate using a token bucket system with a burst capacity of 100 and a refill rate of 1. • Anytime you remove a workflow from a server and replace it with a new one, or update server configuration (which impacts a workflow's execution role), you must wait approximately 10 minutes before executing the new workflow. The Transfer Family server caches the workflow details, and it takes 10 minutes for the server to refresh its cache. Additionally, you must log out of any active SFTP sessions, and then log back in after the 10- minute waiting period to see the changes. Restrictions and limits 422 AWS Transfer Family User Guide Managing servers In this section, you can find information on how to view a list of your servers, how to view your server details, how to edit your server details, and how to change the host key for your SFTP- enabled server. Topics • View a list of servers • Delete a server • View SFTP, FTPS, and FTP server details • View AS2 server details • Edit server details • Manage host keys for your SFTP-enabled server • Monitoring usage in the console View a list of servers On the AWS Transfer Family console, you can find a list of all your servers that are located in the AWS Region that you chose. To find a list of your servers that exist in an AWS Region • Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. If you have one or more servers in the current AWS Region, the console opens to show a list of your servers. If you don't see a list of servers, make sure that you are in the correct Region. You can also choose Servers from the navigation pane. For more information about viewing your server details, see View SFTP, FTPS, and FTP server details. Delete a server This procedure explains how to delete a Transfer Family server by using the AWS Transfer Family console or AWS CLI. View a list of servers 423 AWS Transfer Family Important User Guide You are billed, for each of the protocols enabled to access your endpoint, until you delete the server. Warning Deleting a server results in all its users being deleted. Data in the bucket that was accessed by using the server is not deleted, and remains accessible to AWS users that have privileges to those Amazon S3 buckets. Console To delete a server by using the console 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. 3. 4. 5. In the left navigation pane, choose Servers. Select the check box of the server that you want to delete. For Actions, choose Delete. In the confirmation dialog box that appears, enter the word delete, and then choose Delete to confirm that you want to delete the server. The server is deleted from the Servers page and you are no
|
transferfamily-ug-127
|
transferfamily-ug.pdf
| 127 |
the server is not deleted, and remains accessible to AWS users that have privileges to those Amazon S3 buckets. Console To delete a server by using the console 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. 3. 4. 5. In the left navigation pane, choose Servers. Select the check box of the server that you want to delete. For Actions, choose Delete. In the confirmation dialog box that appears, enter the word delete, and then choose Delete to confirm that you want to delete the server. The server is deleted from the Servers page and you are no longer billed for it. AWS CLI To delete a server by using the CLI 1. (Optional) Run the following command to view the details for the server that you want to delete permanently. aws transfer describe-server --server-id your-server-id This describe-server command returns all of the details for your server. 2. Run the following command to delete the server. Delete a server 424 AWS Transfer Family User Guide aws transfer delete-server --server-id your-server-id If successful, the command deletes the server and does not return any information. View SFTP, FTPS, and FTP server details You can find a list of details and properties for an individual AWS Transfer Family server. Server properties include protocols, identity provider, status, endpoint type, custom hostname, endpoint, users, logging role, server host key, and tags. To view server details 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the navigation pane, choose Servers. 3. Choose the identifier in the Server ID column to see the Server details page, shown following. You can change the server's properties on this page by choosing Edit. For more information about editing server details, see Edit server details. The details page for AS2 servers differs slightly. For AS2 servers, see View AS2 server details. Note The server host key Description and Date imported values are new as of September 2022. These values were introduced to support the multiple host keys feature. This feature required migration of any single host keys that were in use before the introduction of multiple host keys. The Date imported value for a migrated server host key is set to the last modified date for the server. That is, the date that you see for your migrated host key corresponds to the date that you last modified the server in any way, before the server host key migration. View SFTP server details 425 AWS Transfer Family User Guide The only key that was migrated is your oldest or only server host key. Any additional keys have their actual date from when you imported them. Additionally, the migrated key has a description that makes it easy to identify it as having been migrated. The migration occurred between September 2 and September 13. The actual migration date within this range depends on the Region of your server. View AS2 server details You can find a list of details and properties for an individual AWS Transfer Family server. Server properties include protocols, status, and more. For AS2 servers, you can also view the AS2 asynchronous MDN egress IP addresses. Each AS2 server is assigned three static IP addresses. Use these IP addresses for sending asynchronous MDNs to your trading partners over AS2. View AS2 server details 426 AWS Transfer Family User Guide The bottom portion of the AS2 server details page contains details for any attached workflow and monitoring and tagging information. View AS2 server details 427 AWS Transfer Family Edit server details User Guide After you create an AWS Transfer Family server, you can edit the server configuration. Topics • Edit the file transfer protocols • Edit custom identity provider parameters • Edit the server endpoint • Edit your logging configuration • Edit the security policy • Change the managed workflow for your server • Change the display banners for your server • Put your server online or offline To edit a server's configuration 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the left navigation pane, choose Servers. 3. Choose the identifier in the Server ID column to see the Server details page, shown following. You can change the server's properties on this page by choosing Edit: • To change the protocols, see Edit the file transfer protocols. • For the identity provider, note that you can't change a server's identity provider type after you create the server. To change the identity provider, delete the server and create a new one with the identity provider that you want. Note If your server uses a custom identity provider, you can edit some properties. For details, see Edit custom identity provider parameters. • To change the endpoint type or custom hostname, see Edit the server endpoint. • To add an agreement, you need to first add AS2
|
transferfamily-ug-128
|
transferfamily-ug.pdf
| 128 |
choosing Edit: • To change the protocols, see Edit the file transfer protocols. • For the identity provider, note that you can't change a server's identity provider type after you create the server. To change the identity provider, delete the server and create a new one with the identity provider that you want. Note If your server uses a custom identity provider, you can edit some properties. For details, see Edit custom identity provider parameters. • To change the endpoint type or custom hostname, see Edit the server endpoint. • To add an agreement, you need to first add AS2 as a protocol to your server. For details, see Edit the file transfer protocols. Edit server details 428 AWS Transfer Family User Guide • To manage host keys for your server, see Manage host keys for your SFTP-enabled server. • Under Additional details, you can edit the following information: • To change the logging role, see Edit your logging configuration. • To change the security policy, see Edit the security policy. • To change the server host key, see Manage host keys for your SFTP-enabled server. • To change the managed workflow for your server, see Change the managed workflow for your server. • To edit the display banners for your server, see Change the display banners for your server. • Under Additional configuration, you can edit the following information: • SetStat option: enable this option to ignore the error that is generated when a client attempts to use SETSTAT on a file you are uploading to an Amazon S3 bucket. For additional details, see the SetStatOption documentation in the ProtocolDetails topic. • TLS session resumption: provides a mechanism to resume or share a negotiated secret key between the control and data connection for an FTPS session. For additional details, see the TlsSessionResumptionMode documentation in the ProtocolDetails topic. • Passive IP: indicates passive mode, for FTP and FTPS protocols. Enter a single IPv4 address, such as the public IP address of a firewall, router, or load balancer. For additional details, see the PassiveIp documentation in the ProtocolDetails topic. • To start or stop your server, see Put your server online or offline. • To delete a server, see Delete a server. • To edit a user's properties, see Managing access controls. Note The server host key Description and Date imported values are new as of September 2022. These values were introduced to support the multiple host keys feature. Edit server details 429 AWS Transfer Family User Guide This feature required migration of any single host keys that were in use before the introduction of multiple host keys. The Date imported value for a migrated server host key is set to the last modified date for the server. That is, the date that you see for your migrated host key corresponds to the date that you last modified the server in any way, before the server host key migration. The only key that was migrated is your oldest or only server host key. Any additional keys have their actual date from when you imported them. Additionally, the migrated key has a description that makes it easy to identify it as having been migrated. The migration occurred between September 2 and September 13. The actual migration date within this range depends on the Region of your server. Edit the file transfer protocols On the AWS Transfer Family console, you can edit the file transfer protocol. The file transfer protocol connects the client to your server's endpoint. To edit the protocols 1. On the Server details page, choose Edit next to Protocols. 2. On the Edit protocols page, select or clear the protocol check box or check boxes to add or remove the following file transfer protocols: • Secure Shell (SSH) File Transfer Protocol (SFTP) – file transfer over SSH For more information about SFTP, see Create an SFTP-enabled server. • File Transfer Protocol Secure (FTPS) – file transfer with TLS encryption Edit the file transfer protocols 430 AWS Transfer Family User Guide For more information about FTP, see Create an FTPS-enabled server. • File Transfer Protocol (FTP) – unencrypted file transfer For more information about FTPS, see Create an FTP-enabled server. Note If you have an existing server enabled only for SFTP, and you want to add FTPS and FTP, you must ensure that you have the right identity provider and endpoint type settings that are compatible with FTPS and FTP. If you select FTPS, you must choose a certificate stored in AWS Certificate Manager (ACM) which will be used to identify your server when clients connect to it over FTPS. To request a new public certificate, see Request a public certificate in the AWS Certificate Manager User Guide. To import an existing certificate into ACM, see Importing certificates into ACM in
|
transferfamily-ug-129
|
transferfamily-ug.pdf
| 129 |
If you have an existing server enabled only for SFTP, and you want to add FTPS and FTP, you must ensure that you have the right identity provider and endpoint type settings that are compatible with FTPS and FTP. If you select FTPS, you must choose a certificate stored in AWS Certificate Manager (ACM) which will be used to identify your server when clients connect to it over FTPS. To request a new public certificate, see Request a public certificate in the AWS Certificate Manager User Guide. To import an existing certificate into ACM, see Importing certificates into ACM in the AWS Certificate Manager User Guide. To request a private certificate to use FTPS through private IP addresses, see Requesting a private certificate in the AWS Certificate Manager User Guide. Certificates with the following cryptographic algorithms and key sizes are supported: Edit the file transfer protocols 431 AWS Transfer Family User Guide • 2048-bit RSA (RSA_2048) • 4096-bit RSA (RSA_4096) • Elliptic Prime Curve 256 bit (EC_prime256v1) • Elliptic Prime Curve 384 bit (EC_secp384r1) • Elliptic Prime Curve 521 bit (EC_secp521r1) Note The certificate must be a valid SSL/TLS X.509 version 3 certificate with FQDN or IP address specified and contain information about the issuer. 3. Choose Save. You are returned to the Server details page. Edit custom identity provider parameters On the AWS Transfer Family console, for custom identity providers, you can change some of the settings, depending on whether you are using a Lambda function or an API Gateway. In either case, if your server uses the SFTP protocol, you can edit your authentication method. • If you are using a Lambda as your identity provider, you can change the underlying Lambda function. Edit custom identity provider parameters 432 AWS Transfer Family User Guide • If you are using an API Gateway as your identity provider, you can update the Gateway URL or the invocation role, or both. Edit custom identity provider parameters 433 AWS Transfer Family User Guide Edit the server endpoint On the AWS Transfer Family console, you can modify the server endpoint type and custom hostname. Additionally, for VPC endpoints, you can edit the availability zone information. Edit the server endpoint 434 AWS Transfer Family User Guide To edit the server endpoint details 1. On the Server details page, choose Edit next to Endpoint details. 2. Before you can edit the Endpoint type, you must first stop the server. Then, on the Edit endpoint configuration page, for Endpoint type, you can choose either of the following values: • Public – This option makes your server accessible over the internet. • VPC – This option makes your server accessible in your virtual private cloud (VPC). For information about VPC, see Create a server in a virtual private cloud. 3. For Custom hostname, choose one of the following: • None – If you don't want to use a custom domain, choose None. You get a server hostname provided by AWS Transfer Family. The server hostname takes the form serverId.server.transfer.regionId.amazonaws.com. • Amazon Route 53 DNS alias – To use a DNS alias automatically created for you in Route 53, choose this option. • Other DNS – To use a hostname that you already own in an external DNS service choose Other DNS. Choosing Amazon Route 53 DNS alias or Other DNS specifies the name resolution method to associate with your server's endpoint. For example, your custom domain might be sftp.inbox.example.com. A custom hostname uses a DNS name that you provide and that a DNS service can resolve. You can use Route 53 as your DNS resolver, or use your own DNS service provider. To learn how AWS Transfer Family uses Route 53 to route traffic from your custom domain to the server endpoint, see Working with custom hostnames. Edit the server endpoint 435 AWS Transfer Family User Guide 4. For VPC endpoints, you can change the information in the Availability Zones pane. 5. Choose Save. You are returned to the Server details page. Edit your logging configuration On the AWS Transfer Family console, you can change your logging configuration. Note If Transfer Family created a CloudWatch logging IAM role for you when you created a server, the IAM role is called AWSTransferLoggingAccess. You can use it for all your Transfer Family servers. To edit your logging configuration 1. On the Server details page, choose Edit next to Additional details. 2. Based on your configuration, choose between a logging role, structured JSON logging, or both. For more information, see Updating logging for a server. Edit logging 436 AWS Transfer Family Edit the security policy User Guide This procedure explains how to change a Transfer Family server's security policy by using the AWS Transfer Family console or AWS CLI. Note If your endpoint is FIPS-enabled, you can't change the FIPS
|
transferfamily-ug-130
|
transferfamily-ug.pdf
| 130 |
role is called AWSTransferLoggingAccess. You can use it for all your Transfer Family servers. To edit your logging configuration 1. On the Server details page, choose Edit next to Additional details. 2. Based on your configuration, choose between a logging role, structured JSON logging, or both. For more information, see Updating logging for a server. Edit logging 436 AWS Transfer Family Edit the security policy User Guide This procedure explains how to change a Transfer Family server's security policy by using the AWS Transfer Family console or AWS CLI. Note If your endpoint is FIPS-enabled, you can't change the FIPS security policy to a non-FIPS security policy. Console To edit the security policy by using the console 1. On the Server details page, choose Edit next to Additional details. 2. In the Cryptographic algorithm options section, choose a security policy that contains the cryptographic algorithms enabled for use by your server. For more information about security policies, see Security policies for AWS Transfer Family servers. 3. Choose Save. You are returned to the Server details page where you can see the updated security policy. AWS CLI To edit the security policy by using the CLI 1. Run the following command to view the current security policy that is attached to your server. aws transfer describe-server --server-id your-server-id This describe-server command returns all of the details for your server, including the following line: "SecurityPolicyName": "TransferSecurityPolicy-2018-11" Edit the security policy 437 AWS Transfer Family User Guide In this case, the security policy for the server is TransferSecurityPolicy-2018-11. 2. Make sure to provide the exact name of the security policy to the command. For example, run the following command to update the server to TransferSecurityPolicy-2023-05. aws transfer update-server --server-id your-server-id --security-policy-name "TransferSecurityPolicy-2023-05" Note The names of the available security policies are listed in Security policies for AWS Transfer Family servers. If successful, the command returns the following code, and updates your server's security policy. { "ServerId": "your-server-id" } Change the managed workflow for your server On the AWS Transfer Family console, you can change the managed workflow associated with the server. To change the managed workflow 1. On the Server details page, choose Edit next to Additional details. 2. On the Edit additional details page, in the Managed workflows section, select a workflow to be run on all uploads. Note If you do not already have a workflow, choose Create a new workflow to create one. a. Select the workflow ID to use. Change the managed workflow 438 AWS Transfer Family User Guide b. Choose an execution role. This is the role that Transfer Family assumes when executing the workflow's steps. For more information, see IAM policies for workflows. Choose Save. 3. Choose Save. You are returned to the Server details page. Change the display banners for your server On the AWS Transfer Family console, you can change the display banners associated with the server. To change the display banners 1. On the Server details page, choose Edit next to Additional details. 2. On the Edit additional details page, in the Display banners section, enter text for the available display banners. 3. Choose Save. You are returned to the Server details page. Put your server online or offline On the AWS Transfer Family console, you can bring your server online or take it offline. To bring your server online 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. Change the display banners for your server 439 AWS Transfer Family User Guide 2. 3. 4. In the navigation pane, choose Servers. Select the check box of the server that is offline. For Actions, choose Start. It can take a couple of minutes for a server to switch from offline to online. Note When you stop a server to take it offline, currently you are still accruing service charges for that server. To eliminate additional server-based charges, delete that server. To take your server offline 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. 3. 4. In the navigation pane, choose Servers. Select the check box of the server that is online. For Actions, choose Stop. While a server is starting up or shutting down, servers aren't available for file operations. The console doesn't show the starting and stopping states. If you find the error condition START_FAILED or STOP_FAILED, contact AWS Support to help resolve your issues. Manage host keys for your SFTP-enabled server The server host key is a private key used by the Transfer Family server to provide a unique identity to the caller, and to guarantee that it is the correct server. That guarantee is enforced by the presence of the correct public key in the caller's known_hosts file. (The known_hosts file is a standard feature used by most SSH clients to store the public keys for the servers that you've
|
transferfamily-ug-131
|
transferfamily-ug.pdf
| 131 |
show the starting and stopping states. If you find the error condition START_FAILED or STOP_FAILED, contact AWS Support to help resolve your issues. Manage host keys for your SFTP-enabled server The server host key is a private key used by the Transfer Family server to provide a unique identity to the caller, and to guarantee that it is the correct server. That guarantee is enforced by the presence of the correct public key in the caller's known_hosts file. (The known_hosts file is a standard feature used by most SSH clients to store the public keys for the servers that you've connected to.) You can retrieve the public key that corresponds to your server host key by running ssh-keyscan for your server. Manage server host keys 440 AWS Transfer Family Important User Guide If you aren't planning to migrate existing users from an existing SFTP-enabled server to a new SFTP-enabled server, ignore this section. Accidentally changing a server's host key can be disruptive. Depending on how your SFTP client is configured, it can fail immediately, with the message that no trusted host key exists, or present threatening prompts. If there are scripts for automating connections, they most likely would fail as well. By default, AWS Transfer Family provides a host key for your SFTP-enabled server. You can replace the default host key with a host key from another server. Do so only if you plan to move existing users from an existing SFTP-enabled server to your new SFTP-enabled server. To prevent your users from being prompted to verify the authenticity of your SFTP-enabled server again, import the host key for your on-premises server to the SFTP-enabled server. Doing this also prevents your users from getting a warning about a potential man-in-the-middle attack. You can also rotate host keys periodically, as an additional security measure. Note Although the Transfer Family console allows you to specify and add server host keys for all servers, these keys are only useful for servers that use the SFTP protocol. Topics • Add an additional server host key • Delete a server host key • Rotate the server host keys • Additional server host key information Add an additional server host key On the AWS Transfer Family console, you can add additional server host keys. Adding additional host keys of differing formats can be useful for identifying a server when clients connect to it, as Add an additional server host key 441 AWS Transfer Family User Guide well as improving your security profile. For example, if your original key is an RSA key, you could add an additional ECDSA key. Note The SFTP client will connect using the oldest key in the configuration that matches the key's algorithm. The oldest key for each key type (RSA, ECDSA, or ED25519) is the active key for the server for that type. Security note when a Transfer Family server has multiple types of host keys If a server has multiple types of host keys, the SFTP client can assign a preference by type. So, when there exist RSA, ECDSA, and ED25519 host keys for the server, the choice is driven by the preference by type. Modern SFTP clients prefer ECDSA and ED25519 host keys when they exist. This becomes important if you want to add an ECDSA or ED25519 key when the server previously only had RSA keys. The addition of the new ECDSA or ED25519 key would potentially manifest as a security warning for a client. To the client, the key will appear as having changed, when in fact it was not changed: the new key was added in addition to the existing RSA key. Keep this in mind if you decide to add new types of server host keys. To add an additional server host key 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the left navigation pane, choose Servers, and then choose a server that uses the SFTP protocol. 3. On the server details page, scroll down to the Server host keys section. 4. Choose Add host key. The Add server host key page displays. Add an additional server host key 442 AWS Transfer Family User Guide 5. In the Server Host Key section, enter an RSA, ECDSA, or ED25519 private key that is used to identify your server when clients connect to it over the SFTP-enabled server. Note When you create a server host key, make sure to specify -N "" (no passphrase). See Creating SSH keys on macOS, Linux, or Unix for details on how to generate key pairs. 6. (Optional) Add a description to differentiate among multiple server host keys. You can also add tags for your key. 7. Choose Add key. You are returned to the Server details page. To add a host key by using the AWS Command Line
|
transferfamily-ug-132
|
transferfamily-ug.pdf
| 132 |
enter an RSA, ECDSA, or ED25519 private key that is used to identify your server when clients connect to it over the SFTP-enabled server. Note When you create a server host key, make sure to specify -N "" (no passphrase). See Creating SSH keys on macOS, Linux, or Unix for details on how to generate key pairs. 6. (Optional) Add a description to differentiate among multiple server host keys. You can also add tags for your key. 7. Choose Add key. You are returned to the Server details page. To add a host key by using the AWS Command Line Interface (AWS CLI), use the ImportHostKey API operation and provide the new host key. If you create a new SFTP-enabled server, you provide your host key as a parameter in the CreateServer API operation. You can also use the AWS CLI to update the description for an existing host key. The following example import-host-key AWS CLI command imports a host key for the specified SFTP-enabled server. aws transfer import-host-key --description key-description --server-id your-server-id --host-key-body file://my-host-key Delete a server host key On the AWS Transfer Family console, you can delete a server host key. To delete a server host key 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. In the left navigation pane, choose Servers, and then choose a server that uses the SFTP protocol. 3. On the server details page, scroll down to the Server host keys section. Delete a server host key 443 AWS Transfer Family User Guide 4. 5. In the Server Host Keys section, select a key, and then under Actions, choose Delete. In the confirmation dialog box that appears, enter the word delete, and then choose Delete to confirm that you want to delete the host key. The host key is deleted from the Servers page. To delete the host key by using the AWS CLI, use the DeleteHostKey API operation and provide the server ID and host key ID. The following example delete-host-key AWS CLI command deletes a host key for the specified SFTP-enabled server. aws transfer delete-host-key --server-id your-server-id --host-key-id your-host-key-id Rotate the server host keys Periodically, you can rotate your server host key. This topic describes how the server chooses which key to apply, and the procedure for rotating these keys. How the client chooses a server host key The way that Transfer Family chooses which server key to apply depends on conditions for the SFTP client, as explained here. The assumption is that there is one older key and one newer key. • An SFTP client has no prior public host key for the server. The first time the client connects to the server, either of the following occurs: • The client fails the connection, if it is configured to do so. • Or, the client chooses the first key that matches the possible available algorithms and asks the user if that key can be trusted. If so, the client auto-updates the known_hosts file (or whatever local configuration file or resource the client uses to record trust decisions) and enters that key. • An SFTP client has an older key in its known_hosts file. The client prefers to use this key, even if a newer key exists, either for this key's algorithm or another algorithm. This is because the client has a higher level of trust for the key that is in its known_hosts file. • An SFTP client has the new key (in any of the available algorithms) in its known_hosts keys file. The client ignores older keys because they are not trusted and uses the new key. Rotate the server host keys 444 AWS Transfer Family User Guide • An SFTP client has both keys in its known_hosts file. The client chooses the first key by index that matches the list of available keys offered by the server. Transfer Family prefers that the SFTP client has all of the keys in its known_hosts file, since this allows the most flexibility when connecting to a Transfer Family server. Key rotation is based on the fact that multiple entries can exist in the known_hosts file for the same Transfer Family server. Rotate the server host key procedure As an example, assume that you have added the following set of server host keys to your Transfer Family server. Server host keys Host key type RSA ECDSA ED25519 RSA ECDSA ED25519 Date added to the server April 1, 2020 February 1, 2020 December 1, 2019 October 1, 2019 June 1, 2019 March 1, 2019 To rotate the server host key 1. Add a new server host key. This procedure is described in Add an additional server host key. 2. Delete one or more of the host keys of the same type that you had added previously. This procedure is described in Delete
|
transferfamily-ug-133
|
transferfamily-ug.pdf
| 133 |
assume that you have added the following set of server host keys to your Transfer Family server. Server host keys Host key type RSA ECDSA ED25519 RSA ECDSA ED25519 Date added to the server April 1, 2020 February 1, 2020 December 1, 2019 October 1, 2019 June 1, 2019 March 1, 2019 To rotate the server host key 1. Add a new server host key. This procedure is described in Add an additional server host key. 2. Delete one or more of the host keys of the same type that you had added previously. This procedure is described in Delete a server host key. 3. All keys are visible, and can be active, subject to the behavior described previously in How the client chooses a server host key. Additional server host key information You can select a host key to display details for that key. Additional server host key information 445 AWS Transfer Family User Guide You can delete a host key, or edit its description from the Actions menu on the Server details screen. Select the host key, then choose the appropriate action from the menu. Monitoring usage in the console You can get information about your server's metrics on its Server details page. This provides you with a single place to monitor your file-transfers workloads. You can track how many files you have exchanged with your partners and closely track their usage using a centralized dashboard. For details, see View SFTP, FTPS, and FTP server details. The following table describes the metrics available for Transfer Family. Namespace Metric Description AWS/Transfer BytesIn The total number of bytes transferred into the server. Reporting criteria: • For SFTP/FTP/FTPS: emitted every 5 minutes while a connection is established to the Transfer Family Monitor usage within console 446 AWS Transfer Family User Guide Namespace Metric Description server. If no files or bytes are transferred in the period, "0" is emitted. • For AS2: when the customer receives a message in their AS2 server and emitted as soon as the inbound message has finished processing Units: Count Period: 5 minutes BytesOut The total number of bytes transferred out of the server. Reporting criteria: • For SFTP/FTP/FTPS: emitted every 5 minutes while a connection is established to the Transfer Family server. If no files or bytes are transferred in the period, "0" is emitted. • For AS2: when the customer calls StartFile Transfer from their AS2 connector and emitted as soon as the outbound message has finished processin g. Units: Count Period: 5 minutes Monitor usage within console 447 AWS Transfer Family User Guide Namespace Metric Description FilesIn The total number of files transferred into the server. For servers using the AS2 protocol, this metric represent s the number of messages received. Reporting criteria: • For SFTP/FTP/FTPS: emitted every 5 minutes while a connection is established to the Transfer Family server. If no files or bytes are transferred in the period, "0" is emitted. • For AS2: when the customer receives a message in their AS2 server and emitted as soon as the inbound message has finished processing. Units: Count Period: 5 minutes FilesOut The total number of files transferred out of the server. Reporting criteria: • For SFTP/FTP/FTPS: emitted every 5 minutes while a connection is established to the Transfer Family server. If no files or bytes are transferred in the period, "0" is emitted. • For AS2: when the customer calls StartFile Transfer from their AS2 connector and emitted as soon as the outbound message has finished processin g. Units: Count Period: 5 minutes Monitor usage within console 448 AWS Transfer Family User Guide Namespace Metric Description InboundMe ssage The total number of AS2 messages successfully received from a trading partner. Reporting criteria: When the customer receives a message in their AS2 server and emitted as soon as the inbound message has finished processing successfully Units: Count Period: 5 minutes InboundFa iledMessage The total number of AS2 messages that were unsuccess fully received from a trading partner. That is, a trading partner sent a message, but the Transfer Family server was not able to successfully process it. Reporting criteria: When the customer receives a message in their AS2 server and emitted as soon as the inbound message has finished processing unsuccess fully Units: Count Period: 5 minutes OnUploadE xecutions Started The total number of workflow executions started on the server. Reporting criteria: Triggered every time an execution starts Units: Count Period: 1 minute Monitor usage within console 449 AWS Transfer Family User Guide Namespace Metric Description OnUploadE xecutions Success The total number of successful workflow executions on the server. Reporting criteria: Triggered every time an execution successfully finishes Units: Count Period: 1 minute OnUploadE xecutions Failed The total number of unsuccessful workflow executions on the server. Reporting criteria: Triggered every time an execution
|
transferfamily-ug-134
|
transferfamily-ug.pdf
| 134 |
as the inbound message has finished processing unsuccess fully Units: Count Period: 5 minutes OnUploadE xecutions Started The total number of workflow executions started on the server. Reporting criteria: Triggered every time an execution starts Units: Count Period: 1 minute Monitor usage within console 449 AWS Transfer Family User Guide Namespace Metric Description OnUploadE xecutions Success The total number of successful workflow executions on the server. Reporting criteria: Triggered every time an execution successfully finishes Units: Count Period: 1 minute OnUploadE xecutions Failed The total number of unsuccessful workflow executions on the server. Reporting criteria: Triggered every time an execution does not successfully finish Units: Count Period: 1 minute OutboundM essage The total number of AS2 messages successfully sent to a a trading partner. Reporting criteria: When the customer calls StartFileTransfer from their AS2 connector and emitted as soon as the outbound message has finished processing successfully Units: Count Period: 5 minutes Monitor usage within console 450 AWS Transfer Family User Guide Namespace Metric Description OutboundF ailedMess age The total number of AS2 messages that were unsuccess fully sent to a trading partner. Reporting criteria: When the customer calls StartFileTransfer from their AS2 connector and emitted as soon as the outbound message has finished processing unsuccessfully Units: Count Period: 5 minutes The Monitoring section contains four, individual graphs. These graphs show the bytes in, bytes out, files in, and files out. For servers that have the AS2 protocol enabled, there is an AS2 Monitoring section below the Monitoring information. This section contains details for the number of inbound messages, both successful and failed. To open the selected graph in its own window, choose the expand icon ( Monitor usage within console ). 451 AWS Transfer Family You can also click a graph's vertical ellipsis icon ( to open a dropdown menu with the following items: • Enlarge – Opens the selected graph in its own window. • Refresh – Reloads the graph with the most recent data. • View in metrics – Opens the corresponding metrics details in Amazon CloudWatch. • View logs – Opens the corresponding log group in CloudWatch. User Guide ) Monitor usage within console 452 AWS Transfer Family User Guide Managing access controls You can control a user's access to AWS Transfer Family resources by using an AWS Identity and Access Management (IAM) policy. An IAM policy is a statement, typically in JSON format, that allows a certain level of access to a resource. You use an IAM policy to define what file operations that you want to allow your users to perform and not perform. You can also use an IAM policy to define what Amazon S3 bucket or buckets that you want to give your users access to. To specify these policies for users, you create an IAM role for AWS Transfer Family that has the IAM policy and trust relationship associated with it. Each user is assigned an IAM role. The type of IAM role that AWS Transfer Family uses is called a service role. When a user logs in to your server, AWS Transfer Family assumes the IAM role mapped to the user. To learn about creating an IAM role that provides a user access to an Amazon S3 bucket, see Creating a role to delegate permissions to an AWS service in the IAM User Guide. You can grant write-only access to Amazon S3 objects by using certain permissions within an IAM policy. For details, see Grant ability to only write and list files. The AWS Storage Blog contains a post detailing how to set up least privilege access. For details, see Implementing least privilege access in an AWS Transfer Family workflow. Note If your Amazon S3 bucket is encrypted using AWS Key Management Service (AWS KMS), you must specify additional permissions in your policy. For details, see Data protection and encryption. Additionally, you can see more information about session policies in the IAM User Guide. Topics • Allowing read and write access to an Amazon S3 bucket • Creating a session policy for an Amazon S3 bucket 453 AWS Transfer Family User Guide Allowing read and write access to an Amazon S3 bucket This section describes how to create an IAM policy that allows read and write access to a specific Amazon S3 bucket. Assigning an IAM role that has this IAM policy to your user gives that user read/ write access to the specified Amazon S3 bucket. The following policy provides programmatic read, write, and tagging access to an Amazon S3 bucket. The GetObjectACL and PutObjectACL statements are only required if you need to enable Cross Account Access. That is, your Transfer Family server needs to access a bucket in a different account. { "Version": "2012-10-17", "Statement": [ { "Sid":"ReadWriteS3", "Action": [ "s3:ListBucket" ], "Effect": "Allow", "Resource": ["arn:aws:s3:::amzn-s3-demo-bucket"] }, {
|
transferfamily-ug-135
|
transferfamily-ug.pdf
| 135 |
policy that allows read and write access to a specific Amazon S3 bucket. Assigning an IAM role that has this IAM policy to your user gives that user read/ write access to the specified Amazon S3 bucket. The following policy provides programmatic read, write, and tagging access to an Amazon S3 bucket. The GetObjectACL and PutObjectACL statements are only required if you need to enable Cross Account Access. That is, your Transfer Family server needs to access a bucket in a different account. { "Version": "2012-10-17", "Statement": [ { "Sid":"ReadWriteS3", "Action": [ "s3:ListBucket" ], "Effect": "Allow", "Resource": ["arn:aws:s3:::amzn-s3-demo-bucket"] }, { "Effect": "Allow", "Action": [ "s3:PutObject", "s3:GetObject", "s3:GetObjectTagging", "s3:DeleteObject", "s3:DeleteObjectVersion", "s3:GetObjectVersion", "s3:GetObjectVersionTagging", "s3:GetObjectACL", "s3:PutObjectACL" ], "Resource": ["arn:aws:s3:::amzn-s3-demo-bucket/*"] } ] } Creating an S3 bucket access policy 454 AWS Transfer Family User Guide The ListBucket action requires permission to the bucket itself. The PUT, GET, and DELETE actions require object permissions. Because these are different resources, they are specified using different Amazon Resource Names (ARNs). To further restrict your users' access to only the home prefix of the specified Amazon S3 bucket, see Creating a session policy for an Amazon S3 bucket. Creating a session policy for an Amazon S3 bucket A session policy is an AWS Identity and Access Management (IAM) policy that restricts users to certain portions of an Amazon S3 bucket. It does so by evaluating access in real time. Note Session policies are only used with Amazon S3. For Amazon EFS, you use POSIX file permissions to limit access. You can use a session policy when you need to give the same access to a group of users to a particular portion of your Amazon S3 bucket. For example, a group of users might need access to only the home directory. That group of users share the same IAM role. Note The maximum length of a session policy is 2048 characters. For more details, see the Policy request parameter for the CreateUser action in the API reference. To create a session policy, use the following policy variables in your IAM policy: • ${transfer:HomeBucket} • ${transfer:HomeDirectory} • ${transfer:HomeFolder} • ${transfer:UserName} Creating a session policy 455 AWS Transfer Family Important User Guide You can't use the preceding variables in Managed Policies. Nor can you use them as policy variables in an IAM role definition. You create these variables in an IAM policy and supply them directly when setting up your user. Also, you can't use the ${aws:Username} variable in this session policy. This variable refers to an IAM user name and not the username required by AWS Transfer Family. Example session policy The following code shows an example session policy. { "Version": "2012-10-17", "Statement": [ { "Sid": "AllowListingOfUserFolder", "Action": [ "s3:ListBucket" ], "Effect": "Allow", "Resource": [ "arn:aws:s3:::${transfer:HomeBucket}" ], "Condition": { "StringLike": { "s3:prefix": [ "${transfer:HomeFolder}/*", "${transfer:HomeFolder}" ] } } }, { "Sid": "HomeDirObjectAccess", "Effect": "Allow", "Action": [ "s3:PutObject", "s3:GetObject", "s3:DeleteObjectVersion", "s3:DeleteObject", Example session policy 456 AWS Transfer Family User Guide "s3:GetObjectVersion", "s3:GetObjectACL", "s3:PutObjectACL" ], "Resource": "arn:aws:s3:::${transfer:HomeDirectory}/*" } ] } Note The preceding policy example assumes that users have their home directories set to include a trailing slash, to signify that it is a directory. If, on the other hand, you set a user's HomeDirectory without the trailing slash, then you should include it as part of your policy. In the previous example policy, note the use of the transfer:HomeFolder, transfer:HomeBucket, and transfer:HomeDirectory policy parameters. These parameters are set for the HomeDirectory that is configured for the user, as described in HomeDirectory and Implementing your API Gateway method. These parameters have the following definitions: • The transfer:HomeBucket parameter is replaced with the first component of HomeDirectory. • The transfer:HomeFolder parameter is replaced with the remaining portions of the HomeDirectory parameter. • The transfer:HomeDirectory parameter has the leading forward slash (/) removed so that it can be used as part of an S3 Amazon Resource Name (ARN) in a Resource statement. Note If you are using logical directories—that is, the user's homeDirectoryType is LOGICAL— these policy parameters (HomeBucket, HomeDirectory, and HomeFolder) are not supported. For example, assume that the HomeDirectory parameter that is configured for the Transfer Family user is /home/bob/amazon/stuff/. Example session policy 457 AWS Transfer Family User Guide • transfer:HomeBucket is set to /home. • transfer:HomeFolder is set to /bob/amazon/stuff/. • transfer:HomeDirectory becomes home/bob/amazon/stuff/. The first "Sid" allows the user to list all directories starting from /home/bob/amazon/stuff/. The second "Sid" limits the user'put and get access to that same path, /home/bob/amazon/ stuff/. With the preceding policy in place, when a user logs in, they can access only objects in their home directory. At connection time, AWS Transfer Family replaces these variables with the appropriate values for the user. Doing this makes it easier to apply the same policy documents to multiple users. This approach reduces the overhead of IAM role
|
transferfamily-ug-136
|
transferfamily-ug.pdf
| 136 |
is set to /home. • transfer:HomeFolder is set to /bob/amazon/stuff/. • transfer:HomeDirectory becomes home/bob/amazon/stuff/. The first "Sid" allows the user to list all directories starting from /home/bob/amazon/stuff/. The second "Sid" limits the user'put and get access to that same path, /home/bob/amazon/ stuff/. With the preceding policy in place, when a user logs in, they can access only objects in their home directory. At connection time, AWS Transfer Family replaces these variables with the appropriate values for the user. Doing this makes it easier to apply the same policy documents to multiple users. This approach reduces the overhead of IAM role and policy management for managing your users' access to your Amazon S3 bucket. You can also use a session policy to customize access for each of your users based on your business requirements. For more information, see Permissions for AssumeRole, AssumeRoleWithSAML, and AssumeRoleWithWebIdentity in the IAM User Guide. Note AWS Transfer Family stores the policy JSON, instead of the Amazon Resource Name (ARN) of the policy. So, when you change the policy in the IAM console, you need to return to AWS Transfer Family console and update your users with the latest policy contents. You can update the user on the Policy Info tab in the User configuration section. If you are using the AWS CLI, you can use the following command to update the policy. aws transfer update-user --server-id server --user-name user --policy \ "$(aws iam get-policy-version --policy-arn policy --version-id version -- output json)" Nested substitutions for session policies Nested substitutions are not performed in Transfer Family session policies. Session policies can use nested variables, such as ${transfer:HomeDirectory}. When the policy is processed, the outer variable (e.g., ${transfer:HomeDirectory}) might get replaced with a value that Nested substitutions for session policies 458 AWS Transfer Family User Guide contains another variable (e.g., {amzn-s3-demo-bucket:/$(transfer:UserName}). However, the nested variable is not further substituted with the actual username (e.g., johndoe). This means that when creating session policies for Transfer Family, you need to account for this behavior and ensure that the policy structure and variable usage are designed accordingly. The nested variables may not be resolved as expected, and the policy might not grant the intended permissions. It's important to thoroughly test and validate the session policies to ensure they work as expected. This behavior is a key consideration when implementing access control and permissions for your Transfer Family environment. One solution to this issue is to use the actual Amazon S3 bucket name in your session policy. So, for example, rather than specifying ${transfer:HomeDirectory} in your session policy, use the following, where amzn-s3-demo-bucket is your actual bucket: ${amzn-s3-demo-bucket/ transfer:UserName}. Nested substitutions for session policies 459 AWS Transfer Family User Guide AWS CloudTrail logging for AWS Transfer Family AWS Transfer Family integrates with both AWS CloudTrail and Amazon CloudWatch. CloudTrail and CloudWatch serve different but complementary purposes. • This topic covers integration with CloudTrail , an AWS service that creates a record of actions taken within your AWS account. It continuously monitors and records API operations for activities like console sign-ins, AWS Command Line Interface commands, and SDK/API operations. This allows you to keep a log of who took what action, when, and from where. CloudTrail helps with auditing, access management, and regulatory compliance by providing a history of all activity in your AWS environment. For details, see the AWS CloudTrail User Guide. • Amazon CloudWatch logging for AWS Transfer Family servers covers integration with CloudWatch, a monitoring service for AWS resources and applications. It collects metrics and logs to provide visibility into resource utilization, application performance, and overall system health. CloudWatch helps with operational tasks like troubleshooting issues, setting alarms and autoscaling. For details, see the Amazon CloudWatch User Guide. 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 operations, so they don't appear in any specific order. For an ongoing record of events in your AWS account, including events for AWS Transfer Family, 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 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: • Overview for creating a
|
transferfamily-ug-137
|
transferfamily-ug.pdf
| 137 |
of events in your AWS account, including events for AWS Transfer Family, 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 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: • Overview for creating a trail • CloudTrail supported services and integrations • Configuring Amazon SNS notifications for CloudTrail • Receiving CloudTrail log files from multiple regions and Receiving CloudTrail log files from multiple accounts 460 AWS Transfer Family User Guide All AWS Transfer Family actions are logged by CloudTrail and are documented in the Actions API reference. For example, calls to the CreateServer, ListUsers and StopServer actions generate entries in the CloudTrail log files. 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 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. If you create a trail, you can enable continuous delivery of CloudTrail events to an Amazon S3 bucket, including events for AWS Transfer Family. 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 that was made to AWS Transfer Family, the IP address from which the request was made, who made the request, when it was made, and additional details. To learn more about CloudTrail, see the AWS CloudTrail User Guide. Topics • Enable AWS CloudTrail logging • Example log entry for creating a server Enable AWS CloudTrail logging You can monitor AWS Transfer Family API operations using AWS CloudTrail. By monitoring API operations, you can get useful security and operational information. If you have Amazon S3 object level logging enabled, RoleSessionName is contained in the Requester field as [AWS:Role Unique Identifier]/username.sessionid@server-id. For more information about AWS Identity and Access Management (IAM) role unique identifiers, see Unique identifiers in the AWS Identity and Access Management User Guide. Enabling CloudTrail logging 461 AWS Transfer Family Important User Guide The maximum length of the RoleSessionName is 64 characters. If the RoleSessionName is longer, the server-id gets truncated. Example log entry for creating a server The following example shows a CloudTrail log entry (in JSON format) that demonstrates the CreateServer action. { "eventVersion": "1.09", "userIdentity": { "type": "AssumedRole", "principalId": "AAAA4FFF5HHHHH6NNWWWW:user1", "arn": "arn:aws:sts::123456789102:assumed-role/Admin/user1", "accountId": "123456789102", "accessKeyId": "AAAA52C2WWWWWW3BB4Z", "sessionContext": { "attributes": { "mfaAuthenticated": "false", "creationDate": "2018-12-18T20:03:57Z" }, "sessionIssuer": { "type": "Role", "principalId": "AAAA4FFF5HHHHH6NNWWWW", "arn": "arn:aws:iam::123456789102:role/Admin", "accountId": "123456789102", "userName": "Admin" } } }, "eventTime": "2024-02-05T19:18:53Z", "eventSource": "transfer.amazonaws.com", "eventName": "CreateServer", "awsRegion": "us-east-1", "sourceIPAddress": "11.22.1.2", "userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36", "requestParameters": { "domain": "S3", Example log entry for creating a server 462 AWS Transfer Family User Guide "hostKey": "HIDDEN_DUE_TO_SECURITY_REASONS", "protocols": [ "SFTP" ], "protocolDetails": { "passiveIp": "AUTO", "tlsSessionResumptionMode": "ENFORCED", "setStatOption": "DEFAULT" }, "securityPolicyName": "TransferSecurityPolicy-2020-06", "s3StorageOptions": { "directoryListingOptimization": "ENABLED" } }, "responseElements": { "serverId": "s-1234abcd5678efghi" }, "requestID": "6fe7e9b1-72fc-45b0-a7f9-5840268aeadf", "eventID": "4781364f-7c1e-464e-9598-52d06aa9e63a", "readOnly": false, "eventType": "AwsApiCall", "managementEvent": true, "recipientAccountId": "123456789102", "eventCategory": "Management", "tlsDetails": { "tlsVersion": "TLSv1.3", "cipherSuite": "TLS_AES_128_GCM_SHA256", "clientProvidedHostHeader": "transfer.us-east-1.amazonaws.com" }, "sessionCredentialFromConsole": "true" } Example log entry for creating a server 463 AWS Transfer Family User Guide Amazon CloudWatch logging for AWS Transfer Family servers Amazon CloudWatch is a powerful monitoring and observability service that provides comprehensive visibility into your AWS resources, including AWS Transfer Family. • Real-time monitoring: CloudWatch monitors Transfer Family resources and applications in real- time, allowing you to track and analyze their performance. • Metrics collection: CloudWatch collects and tracks various metrics for your resources and applications, which are variables you can measure and use for analysis. • CloudWatch home page: The CloudWatch home page automatically displays metrics about Transfer Family and other AWS services you use, providing a centralized view of your monitoring data. • Custom dashboards: You can create custom dashboards in CloudWatch to display metrics specific to your custom applications and the resources you choose to monitor. • Alarms and notifications: CloudWatch allows you to create alarms that monitor your metrics and trigger notifications or automated actions when certain thresholds are breached. This can be useful for monitoring file transfer activity in your Transfer Family servers and scaling resources accordingly. • Cost optimization: You can use the data collected by CloudWatch to identify
|
transferfamily-ug-138
|
transferfamily-ug.pdf
| 138 |
displays metrics about Transfer Family and other AWS services you use, providing a centralized view of your monitoring data. • Custom dashboards: You can create custom dashboards in CloudWatch to display metrics specific to your custom applications and the resources you choose to monitor. • Alarms and notifications: CloudWatch allows you to create alarms that monitor your metrics and trigger notifications or automated actions when certain thresholds are breached. This can be useful for monitoring file transfer activity in your Transfer Family servers and scaling resources accordingly. • Cost optimization: You can use the data collected by CloudWatch to identify under-utilized resources and take actions, such as stopping or deleting instances, to optimize your costs. Overall, the comprehensive monitoring capabilities in CloudWatch make it a valuable tool for managing and optimizing your Transfer Family infrastructure and the applications running on it. Types of CloudWatch logging for Transfer Family Transfer Family provides two ways to log events to CloudWatch: • JSON structured logging • Logging via a logging role For Transfer Family servers, you can choose the logging mechanism that you prefer. For connectors and workflows, only logging roles are supported. Types of CloudWatch logging for Transfer Family 464 AWS Transfer Family JSON structured logging User Guide For logging server events, we recommend using JSON structured logging. This provides a more comprehensive logging format that enables CloudWatch log querying. For this type of logging, the IAM policy for the user that creates the server (or edits the server's logging configuration) must contain the following permissions: • logs:CreateLogDelivery • logs:DeleteLogDelivery • logs:DescribeLogGroups • logs:DescribeResourcePolicies • logs:GetLogDelivery • logs:ListLogDeliveries • logs:PutResourcePolicy • logs:UpdateLogDelivery The following is an example policy. { "Version": "2012-10-17", "Statement": [ { "Sid": "VisualEditor0", "Effect": "Allow", "Action": [ "logs:CreateLogDelivery", "logs:GetLogDelivery", "logs:UpdateLogDelivery", "logs:DeleteLogDelivery", "logs:ListLogDeliveries", "logs:PutResourcePolicy", "logs:DescribeResourcePolicies", "logs:DescribeLogGroups" ], "Resource": "*" } ] } Types of CloudWatch logging for Transfer Family 465 AWS Transfer Family User Guide For details on setting up JSON structured logging, see Creating, updating, and viewing logging for servers. Logging role To log events for a managed workflow that is attached to a server, as well as for connectors, you need to specify a logging role. To set access, you create a resource-based IAM policy and an IAM role that provides that access information. The following is an example policy for an AWS account that can log server events. { "Version": "2012-10-17", "Statement": [ { "Sid": "VisualEditor0", "Effect": "Allow", "Action": [ "logs:CreateLogStream", "logs:DescribeLogStreams", "logs:CreateLogGroup", "logs:PutLogEvents" ], "Resource": "arn:aws:logs:*:*:log-group:/aws/transfer/*" } ] } For details on configuring a logging role to log workflow events see Managing logging for workflows. Creating, updating, and viewing logging for servers For all AWS Transfer Family servers, we provide structured logging. We recommend that you use structured logging for all new and existing Transfer Family servers. Benefits of using structured logging include the following: • Receive logs in a structured JSON format. • Query your logs with Amazon CloudWatch Logs Insights, which automatically discovers JSON formatted fields. Creating logging for servers 466 AWS Transfer Family User Guide • Share log groups across AWS Transfer Family resources allows you to combine log streams from multiple servers into a single log group, making it easier to manage your monitoring configurations and log retention settings. • Create aggregated metrics and visualizations that can be added to CloudWatch dashboards. • Track usage and performance data by using log groups to create consolidated log metrics, visualizations, and dashboards. To enable logging for workflows that are attached to servers, you must use a logging role. Note When you add a logging role, the logging group is always /aws/transfer/your- serverID, and can't be changed. This means, that unless you are sending your structured server logs to the same group, you will be logging to two separate logging groups. If you know that you are going to associate a workflow with your server, and thus need to add a logging role, you can set up structured logging to log to the default log group of / aws/transfer/your-serverID. To modify your logging group, see StructuredLogDestinations in the AWS Transfer Family API Reference. If you create a new server by using the Transfer Family console, logging is enabled by default. After you create the server, you can use the UpdateServer API operation to change your logging configuration. For details, see StructuredLogDestinations. Currently, for workflows, if you want logging enabled, you must specify a logging role: • If you associate a workflow with a server, using either the CreateServer or UpdateServer API operation, the system does not automatically create a logging role. If you want to log your workflow events, you need to explicitly attach a logging role to the server. • If you create a server using the Transfer Family console and you attach a workflow, logs are sent to a log group that contains
|
transferfamily-ug-139
|
transferfamily-ug.pdf
| 139 |
you can use the UpdateServer API operation to change your logging configuration. For details, see StructuredLogDestinations. Currently, for workflows, if you want logging enabled, you must specify a logging role: • If you associate a workflow with a server, using either the CreateServer or UpdateServer API operation, the system does not automatically create a logging role. If you want to log your workflow events, you need to explicitly attach a logging role to the server. • If you create a server using the Transfer Family console and you attach a workflow, logs are sent to a log group that contains the server ID in the name. The format is /aws/transfer/server- id, for example, /aws/transfer/s-1111aaaa2222bbbb3. The server logs can be sent to this same log group or a different one. Logging considerations for creating and editing servers in the console Creating logging for servers 467 AWS Transfer Family User Guide • New servers created through the console only support structured JSON logging, unless a workflow is attached to the server. • No logging is not an option for new servers that you create in the console. • Existing servers can enable structured JSON logging through the console at any time. • Enabling structured JSON logging through the console disables the existing logging method, so as to not double charge customers. The exception is if a workflow is attached to the server. • If you enable structured JSON logging, you cannot later disable it through the console. • If you enable structured JSON logging, you can change the log group destination through the console at any time. • If you enable structured JSON logging, you cannot edit the logging role through the console if you have enabled both logging types through the API. The exception is if your server has a workflow attached. However, the logging role does continue to appear in Additional details. Logging considerations for creating and editing servers using the API or SDK • If you create a new server through the API, you can configure either or both types of logging, or choose no logging. • For existing servers, enable and disable structured JSON logging at any time. • You can change the log group through the API at any time. • You can change the logging role through the API at any time. To enable structured logging, you must be logged into an account with the following permissions • logs:CreateLogDelivery • logs:DeleteLogDelivery • logs:DescribeLogGroups • logs:DescribeResourcePolicies • logs:GetLogDelivery • logs:ListLogDeliveries • logs:PutResourcePolicy • logs:UpdateLogDelivery Creating logging for servers 468 AWS Transfer Family User Guide An example policy is available in the section Configure CloudWatch logging role. Topics • Creating logging for servers • Updating logging for a server • Viewing the server configuration Creating logging for servers When you create a new server, on the Configure additional details page, you can specify an existing log group, or create a new one. If you choose Create log group, the CloudWatch console (https://console.aws.amazon.com/ cloudwatch/) opens to the Create log group page. For details, see Create a log group in CloudWatch Logs. Updating logging for a server The details for logging depend on the scenario for your update. Creating logging for servers 469 AWS Transfer Family Note User Guide When you opt into structured JSON logging, there can be a delay, in rare cases, where Transfer Family stops logging in the old format, but takes some time to start logging in the new JSON format. This can result in events that don't get logged. There won’t be any service disruptions, but you should be careful transferring files during the first hour after changing your logging method, as logs could be dropped. If you are editing an existing server, your options depend on the state of the server. • The server already has a logging role enabled, but does not have Structured JSON logging enabled. • The server does not have any logging enabled. Updating logging for a server 470 AWS Transfer Family User Guide • The server already has Structured JSON logging enabled, but does not have a logging role specified. Updating logging for a server 471 AWS Transfer Family User Guide • The server already has Structured JSON logging enabled, and also has a logging role specified. Viewing the server configuration The details for the server configuration page depend on your scenario: Depending on your scenario, the server configuration page might look like one of the following examples: • No logging is enabled. Viewing the server configuration 472 AWS Transfer Family User Guide • Structured JSON logging is enabled. • Logging role is enabled, but structured JSON logging is not enabled. Viewing the server configuration 473 AWS Transfer Family User Guide • Both types of logging (logging role and structured JSON logging) are enabled. Managing logging for workflows CloudWatch
|
transferfamily-ug-140
|
transferfamily-ug.pdf
| 140 |
enabled, and also has a logging role specified. Viewing the server configuration The details for the server configuration page depend on your scenario: Depending on your scenario, the server configuration page might look like one of the following examples: • No logging is enabled. Viewing the server configuration 472 AWS Transfer Family User Guide • Structured JSON logging is enabled. • Logging role is enabled, but structured JSON logging is not enabled. Viewing the server configuration 473 AWS Transfer Family User Guide • Both types of logging (logging role and structured JSON logging) are enabled. Managing logging for workflows CloudWatch provides consolidated auditing and logging for workflow progress and results. Additionally, AWS Transfer Family provides several metrics for workflows. You can view metrics for how many workflows executions started, completed successfully, and failed in the previous minute. All of the CloudWatch metrics for Transfer Family are described in Using CloudWatch metrics for Transfer Family servers. View Amazon CloudWatch logs for workflows 1. Open the Amazon CloudWatch console at https://console.aws.amazon.com/cloudwatch/. 2. In the left navigation pane, choose Logs, then choose Log groups. 3. On the Log groups page, on the navigation bar, choose the correct Region for your AWS Transfer Family server. 4. Choose the log group that corresponds to your server. For example, if your server ID is s-1234567890abcdef0, your log group is /aws/transfer/ s-1234567890abcdef0. 5. On the log group details page for your server, the most recent log streams are displayed. There are two log streams for the user that you are exploring: • One for each Secure Shell (SSH) File Transfer Protocol (SFTP) session. Managing logging for workflows 474 AWS Transfer Family User Guide • One for the workflow that is being executed for your server. The format for the log stream for the workflow is username.workflowID.uniqueStreamSuffix. For example, if your user is mary-major, you have the following log streams: mary-major-east.1234567890abcdef0 mary.w-abcdef01234567890.021345abcdef6789 Note The 16-digit alphanumeric identifiers listed in this example are fictitious. The values that you see in Amazon CloudWatch are different. The Log events page for mary-major-usa-east.1234567890abcdef0 displays the details for each user session, and the mary.w-abcdef01234567890.021345abcdef6789 log stream contains the details for the workflow. The following is a sample log stream for mary.w-abcdef01234567890.021345abcdef6789, based on a workflow (w-abcdef01234567890) that contains a copy step. { "type": "ExecutionStarted", "details": { "input": { "initialFileLocation": { "bucket": "amzn-s3-demo-bucket", "key": "mary/workflowSteps2.json", "versionId": "version-id", "etag": "etag-id" } } }, "workflowId":"w-abcdef01234567890", "executionId":"execution-id", "transferDetails": { "serverId":"s-server-id", "username":"mary", "sessionId":"session-id" } Managing logging for workflows 475 User Guide AWS Transfer Family }, { "type":"StepStarted", "details": { "input": { "fileLocation": { "backingStore":"S3", "bucket":"amzn-s3-demo-bucket", "key":"mary/workflowSteps2.json", "versionId":"version-id", "etag":"etag-id" } }, "stepType":"COPY", "stepName":"copyToShared" }, "workflowId":"w-abcdef01234567890", "executionId":"execution-id", "transferDetails": { "serverId":"s-server-id", "username":"mary", "sessionId":"session-id" } }, { "type":"StepCompleted", "details":{ "output":{}, "stepType":"COPY", "stepName":"copyToShared" }, "workflowId":"w-abcdef01234567890", "executionId":"execution-id", "transferDetails":{ "serverId":"server-id", "username":"mary", "sessionId":"session-id" } }, { "type":"ExecutionCompleted", "details": {}, "workflowId":"w-abcdef01234567890", "executionId":"execution-id", Managing logging for workflows 476 AWS Transfer Family User Guide "transferDetails":{ "serverId":"s-server-id", "username":"mary", "sessionId":"session-id" } } Configure CloudWatch logging role To set access, you create a resource-based IAM policy and an IAM role that provides that access information. To enable Amazon CloudWatch logging, you start by creating an IAM policy that enables CloudWatch logging. You then create an IAM role and attach the policy to it. You can do this when you are creating a server or by editing an existing server. For more information about CloudWatch, see What is Amazon CloudWatch? and What is Amazon CloudWatch logs? in the Amazon CloudWatch User Guide. Use the following example IAM policies to allow CloudWatch logging. Use a logging role { "Version": "2012-10-17", "Statement": [ { "Sid": "VisualEditor0", "Effect": "Allow", "Action": [ "logs:CreateLogStream", "logs:DescribeLogStreams", "logs:CreateLogGroup", "logs:PutLogEvents" ], "Resource": "arn:aws:logs:*:*:log-group:/aws/transfer/*" } ] } Use structured logging { Configuring a role for CloudWatch 477 AWS Transfer Family User Guide "Version": "2012-10-17", "Statement": [ { "Sid": "VisualEditor0", "Effect": "Allow", "Action": [ "logs:CreateLogDelivery", "logs:GetLogDelivery", "logs:UpdateLogDelivery", "logs:DeleteLogDelivery", "logs:ListLogDeliveries", "logs:PutResourcePolicy", "logs:DescribeResourcePolicies", "logs:DescribeLogGroups" ], "Resource": "*" } ] } In the preceding example policy, for the Resource, replace the region-id and AWS account with your values. For example, "Resource": "arn:aws::logs:us- east-1:111122223333:log-group:/aws/transfer/*" You then create a role and attach the CloudWatch Logs policy that you created. To create an IAM role and attach a policy 1. In the navigation pane, choose Roles, and then choose Create role. On the Create role page, make sure that AWS service is chosen. 2. Choose Transfer from the service list, and then choose Next: Permissions. This establishes a trust relationship between AWS Transfer Family and the IAM role. Additionally, add aws:SourceAccount and aws:SourceArn condition keys to protect yourself against the confused deputy problem. See the following documentation for more details: • Procedure for establishing a trust relationship with AWS Transfer Family: To establish a trust relationship • Description for confused deputy problem: the confused deputy problem Configuring a role for CloudWatch 478 AWS Transfer Family User Guide 3. In
|
transferfamily-ug-141
|
transferfamily-ug.pdf
| 141 |
Create role. On the Create role page, make sure that AWS service is chosen. 2. Choose Transfer from the service list, and then choose Next: Permissions. This establishes a trust relationship between AWS Transfer Family and the IAM role. Additionally, add aws:SourceAccount and aws:SourceArn condition keys to protect yourself against the confused deputy problem. See the following documentation for more details: • Procedure for establishing a trust relationship with AWS Transfer Family: To establish a trust relationship • Description for confused deputy problem: the confused deputy problem Configuring a role for CloudWatch 478 AWS Transfer Family User Guide 3. In the Attach permissions policies section, locate and choose the CloudWatch Logs policy that you just created, and choose Next: Tags. 4. (Optional) Enter a key and value for a tag, and choose Next: Review. 5. On the Review page, enter a name and description for your new role, and then choose Create role. 6. To view the logs, choose the Server ID to open the server configuration page, and choose View logs. You are redirected to the CloudWatch console where you can see your log streams. On the CloudWatch page for your server, you can see records of user authentication (success and failure), data uploads (PUT operations), and data downloads (GET operations). Viewing Transfer Family log streams To view your Transfer Family server logs 1. Navigate to the details page for a server. 2. Choose View logs. This opens Amazon CloudWatch. 3. The log group for your selected server is displayed. Viewing Transfer Family log streams 479 AWS Transfer Family User Guide 4. You can select a log stream to display details and individual entries for the stream. • If there is a listing for ERRORS, you can choose it to view details for the latest errors for the server. Viewing Transfer Family log streams 480 AWS Transfer Family User Guide • Choose any other entry to see an example log stream. Viewing Transfer Family log streams 481 AWS Transfer Family User Guide • If your server has a managed workflow associated with it, you can view logs for the workflow runs. Note The format for the log stream for the workflow is username.workflowId.uniqueStreamSuffix. For example, decrypt-user.w- a1111222233334444.aaaa1111bbbb2222 could be the name of a log stream for user decrypt-user and workflow w-a1111222233334444. Note For any expanded log entry, you can copy the entry to the clipboard by choosing Copy. For more details about CloudWatch logs, see Viewing log data. Viewing Transfer Family log streams 482 AWS Transfer Family User Guide Creating Amazon CloudWatch alarms The following example shows how to create Amazon CloudWatch alarms using the AWS Transfer Family metric, FilesIn. CDK new cloudwatch.Metric({ namespace: "AWS/Transfer", metricName: "FilesIn", dimensionsMap: { ServerId: "s-00000000000000000" }, statistic: "Average", period: cdk.Duration.minutes(1), }).createAlarm(this, "AWS/Transfer FilesIn", { threshold: 1000, evaluationPeriods: 10, datapointsToAlarm: 5, comparisonOperator: cloudwatch.ComparisonOperator.GREATER_THAN_OR_EQUAL_TO_THRESHOLD, }); AWS CloudFormation Type: AWS::CloudWatch::Alarm Properties: Namespace: AWS/Transfer MetricName: FilesIn Dimensions: - Name: ServerId Value: s-00000000000000000 Statistic: Average Period: 60 Threshold: 1000 EvaluationPeriods: 10 DatapointsToAlarm: 5 ComparisonOperator: GreaterThanOrEqualToThreshold Creating Amazon CloudWatch alarms 483 AWS Transfer Family User Guide Logging Amazon S3 API operations to S3 access logs Note This section does not apply to Transfer Family web apps. If you are using Amazon S3 access logs to identify S3 requests made on behalf of your file transfer users, RoleSessionName is used to display which IAM role was assumed to service the file transfers. It also displays additional information such as the user name, session id, and server-id used for the transfers. The format is [AWS:Role Unique Identifier]/ username.sessionid@server-id and is contained in the Requester field. For example, the following are the contents for a sample Requester field from an S3 access log for a file that was copied to the S3 bucket. arn:aws:sts::AWS-Account-ID:assumed-role/IamRoleName/ username.sessionid@server-id In the Requester field above, it shows the IAM Role called IamRoleName. For more information about IAM role unique identifiers, see Unique identifiers in the AWS Identity and Access Management User Guide. Examples to limit confused deputy problem The confused deputy problem is a security issue where an entity that doesn't have permission to perform an action can coerce a more-privileged entity to perform the action. In AWS, cross-service impersonation can result in the confused deputy problem. For more details, see Cross-service confused deputy prevention. Note In the following examples, replace each user input placeholder with your own information. In these examples, you can remove the ARN details for a workflow if your server doesn't have any workflows attached to it. Logging S3 API calls to S3 access logs 484 AWS Transfer Family User Guide The following example logging/invocation policy allows any server (and workflow) in the account to assume the role. { "Version": "2012-10-17", "Statement": [ { "Sid": "AllowAllServersWithWorkflowAttached", "Effect": "Allow", "Principal": { "Service": "transfer.amazonaws.com" }, "Action": "sts:AssumeRole", "Condition": { "StringEquals": { "aws:SourceAccount": "account-id" }, "ArnLike":
|
transferfamily-ug-142
|
transferfamily-ug.pdf
| 142 |
For more details, see Cross-service confused deputy prevention. Note In the following examples, replace each user input placeholder with your own information. In these examples, you can remove the ARN details for a workflow if your server doesn't have any workflows attached to it. Logging S3 API calls to S3 access logs 484 AWS Transfer Family User Guide The following example logging/invocation policy allows any server (and workflow) in the account to assume the role. { "Version": "2012-10-17", "Statement": [ { "Sid": "AllowAllServersWithWorkflowAttached", "Effect": "Allow", "Principal": { "Service": "transfer.amazonaws.com" }, "Action": "sts:AssumeRole", "Condition": { "StringEquals": { "aws:SourceAccount": "account-id" }, "ArnLike": { "aws:SourceArn": [ "arn:aws:transfer:region:account-id:server/*", "arn:aws:transfer:region:account-id:workflow/*" ] } } } ] } The following example logging/invocation policy allows a specific server (and workflow) to assume the role. { "Version": "2012-10-17", "Statement": [ { "Sid": "AllowSpecificServerWithWorkflowAttached", "Effect": "Allow", "Principal": { "Service": "transfer.amazonaws.com" }, "Action": "sts:AssumeRole", "Condition": { "StringEquals": { Examples to limit confused deputy problem 485 AWS Transfer Family User Guide "aws:SourceAccount": "account-id" }, "ArnEquals": { "aws:SourceArn": [ "arn:aws:transfer:region:account-id:server/server-id", "arn:aws:transfer:region:account-id:workflow/workflow-id" ] } } } ] } CloudWatch log structure for Transfer Family This topic describes the fields that are populated in Transfer Family logs: both for JSON structured log entries and legacy log entries. Topics • JSON structured logs for Transfer Family • Legacy logs for Transfer Family JSON structured logs for Transfer Family The following table contains details for log entry fields for Transfer Family SFTP/FTP/FTPS actions, in the new JSON structured log format. Field Description Example entry activity-type The action by the user The available activity types are as follows: AUTH_FAIL URE , CONNECTED , DISCONNECTED , ERROR, EXIT_REASON , CLOSE, CREATE_SYMLINK , DELETE, MKDIR, OPEN, PARTIAL_C LOSE , RENAME, RMDIR, CloudWatch log structure for Transfer Family 486 AWS Transfer Family User Guide Field Description Example entry bytes-in bytes-out ciphers client home-dir kex message method mode SETSTAT, TLS_RESUM E_FAILURE . Number of bytes uploaded by the user 29238420042 Number of bytes downloaded by the user 23094032490328 Specifies the SSH cipher negotiated for the connection (available ciphers are listed in Cryptographic algorithms) [email protected] The user's client software SSH-2.0-OpenSSH_7.4 /user-home-bucket/test The directory that the end user lands on when they connect to the endpoint if their home directory type is PATH: if they have a logical home directory, this value is always / Specifies the negotiated SSH key exchange (KEX) for the diffie-hellman-group14-sha2 56 connection (available KEX are listed in Cryptographic algorithms) Provides more information related to the error <string> The authentication method publickey Specifies how a client opens a file CREATE | TRUNCATE | WRITE JSON structured logs for Transfer Family 487 AWS Transfer Family Field operation path ssh-public-key ssh-public-key-fingerprint User Guide Description Example entry The client operation on a file OPEN | CLOSE Actual file path affected /amzn-s3-demo-bucket/test- file-1.pdf The public key body for the user that is connecting AAAAC3NzaC1lZDI1NT E5AAAAIA9OY0qV6XYV HaaOiWAcj2spDJVbgj rqDPY4pxd6GnHl The public key fingerprint, as shown in the console for SHA256:BY3gNMHwTfj d4n2VuT4pTyLOk82zW service-managed users when Zj4KEYEu7y4r/0 listing their user keys. Note In the console, the fingerprint is displayed with the padding character s (if any): from 0 to 3 equal signs (=) at the end. In the log entry, this padding is stripped from the output. ssh-public-key-type Type of public key: Transfer Family supports RSA-, ECDSA-, and ED25519-f ormatted keys ssh-ed25519 JSON structured logs for Transfer Family 488 AWS Transfer Family Field resource-arn User Guide Description Example entry A system-assigned, unique identifier for a specific arn:aws:transfer:ap-northea st-1:12346789012:server/s-1 resource (for example, a 234567890akeu2js2 server) role The IAM role of the user arn:aws:iam::0293883675:rol e/testuser-role session-id source-ip user user-policy A system-assigned, unique identifier for a single session 9ca9a0e1cec6ad9d Client IP address 18.323.0.129 The end user's username myname192 The permissions specified for the end user: this field is The JSON code for the session policy that is being used populated if the user's policy is a session policy. Legacy logs for Transfer Family The following table contains details for log entries for various Transfer Family actions. Note These entries are not in the new JSON structured log format. The following table contains details for log entries for various Transfer Family actions, in the new JSON structured log format. Legacy logs for Transfer Family 489 AWS Transfer Family Action Authentication failures COPY/TAG/DELETE/DECRYPT workflow Custom step workflow Deletes Downloads User Guide Corresponding logs within Amazon CloudWatch Logs ERRORS AUTH_FAILURE Method=pu blickey User=lhr Message="RSA SHA256:Lf z3R2nmLY4raK+b7Rb1rSvUIbAE+a+Hxg0c7l 1JIZ0" SourceIP=3.8.172.211 {"type":"StepStarted","details":{"input":{"fi leLocation":{"backingStore":"EFS","filesystem Id":"fs-12345678","path":"/lhr/regex.py"}},"s tepType":"TAG","stepName":"successfu l_tag_step"},"workflowId":"w-1111aaa a2222bbbb3","executionId":"81234abcd-1234- efgh-5678-ijklmnopqr90","transferDetails": {"serverId":"s-1234abcd5678efghi","usernam e":"lhr","sessionId":"1234567890abcdef0"}} {"type":"CustomStepInvoked","details":{"outpu t":{"token":"MzM4Mjg5YWUtYTEzMy00YjI zLWI3OGMtYzU4OGI2ZjQyMzE5"},"stepTyp e":"CUSTOM","stepName":"efs-s3_copy_ 2"},"workflowId":"w-9283e49d33297c3f 7","executionId":"1234abcd-1234-efgh-5678- ijklmnopqr90","transferDetails":{"serverId":"s- zzzz1111aaaa22223","username":"lhr"," sessionId":"1234567890abcdef0"}} lhr.33a8fb495ffb383b DELETE Path=/bucket/ user/123.jpg lhr.33a8fb495ffb383b OPEN Path=/bucket/ user/123.jpg Mode=READ llhr.33a8fb495ffb383b CLOSE Path=/bucket/ user/123.jpg BytesOut=3618546 Legacy logs for Transfer Family 490 AWS Transfer Family Action Logins/Logouts Renames Sample workflow error log Symlinks Uploads User Guide Corresponding logs within Amazon CloudWatch Logs user.914984e553bcddb6 CONNECTED SourceIP=1.22.111.222 User=lhr HomeDir=L OGICAL Client=SSH-2.0-OpenSSH_7.4 Role=arn:aws::iam::123456789012:role/sftp- s3-access user.914984e553bcddb6 DISCONNECTED lhr.33a8fb495ffb383b RENAME Path=/buc ket/user/lambo.png NewPath=/bucket/user/ ferrari.png {"type":"StepErrored","details":{"errorType":
|
transferfamily-ug-143
|
transferfamily-ug.pdf
| 143 |
workflow Custom step workflow Deletes Downloads User Guide Corresponding logs within Amazon CloudWatch Logs ERRORS AUTH_FAILURE Method=pu blickey User=lhr Message="RSA SHA256:Lf z3R2nmLY4raK+b7Rb1rSvUIbAE+a+Hxg0c7l 1JIZ0" SourceIP=3.8.172.211 {"type":"StepStarted","details":{"input":{"fi leLocation":{"backingStore":"EFS","filesystem Id":"fs-12345678","path":"/lhr/regex.py"}},"s tepType":"TAG","stepName":"successfu l_tag_step"},"workflowId":"w-1111aaa a2222bbbb3","executionId":"81234abcd-1234- efgh-5678-ijklmnopqr90","transferDetails": {"serverId":"s-1234abcd5678efghi","usernam e":"lhr","sessionId":"1234567890abcdef0"}} {"type":"CustomStepInvoked","details":{"outpu t":{"token":"MzM4Mjg5YWUtYTEzMy00YjI zLWI3OGMtYzU4OGI2ZjQyMzE5"},"stepTyp e":"CUSTOM","stepName":"efs-s3_copy_ 2"},"workflowId":"w-9283e49d33297c3f 7","executionId":"1234abcd-1234-efgh-5678- ijklmnopqr90","transferDetails":{"serverId":"s- zzzz1111aaaa22223","username":"lhr"," sessionId":"1234567890abcdef0"}} lhr.33a8fb495ffb383b DELETE Path=/bucket/ user/123.jpg lhr.33a8fb495ffb383b OPEN Path=/bucket/ user/123.jpg Mode=READ llhr.33a8fb495ffb383b CLOSE Path=/bucket/ user/123.jpg BytesOut=3618546 Legacy logs for Transfer Family 490 AWS Transfer Family Action Logins/Logouts Renames Sample workflow error log Symlinks Uploads User Guide Corresponding logs within Amazon CloudWatch Logs user.914984e553bcddb6 CONNECTED SourceIP=1.22.111.222 User=lhr HomeDir=L OGICAL Client=SSH-2.0-OpenSSH_7.4 Role=arn:aws::iam::123456789012:role/sftp- s3-access user.914984e553bcddb6 DISCONNECTED lhr.33a8fb495ffb383b RENAME Path=/buc ket/user/lambo.png NewPath=/bucket/user/ ferrari.png {"type":"StepErrored","details":{"errorType": "BAD_REQUEST","errorMessage":"Cannot tag Efs file","stepType":"TAG","stepName":"s uccessful_tag_step"},"workflowId":"w -1234abcd5678efghi","executionId":"8 1234abcd-1234-efgh-5678-ijklmnopqr90 ","transferDetails":{"serverId":"s-1234abcd56 78efghi","username":"lhr","sessionId":"123456 7890abcdef0"}} lhr.eb49cf7b8651e6d5 CREATE_SYMLINK LinkPath=/fs-12345678/lhr/pqr.jpg TargetPat h=abc.jpg lhr.33a8fb495ffb383b OPEN Path=/bucket/ user/123.jpg Mode=CREATE|TRUNCATE| WRITE lhr.33a8fb495ffb383b CLOSE Path=/bucket/ user/123.jpg BytesIn=3618546 Legacy logs for Transfer Family 491 AWS Transfer Family Action Workflows User Guide Corresponding logs within Amazon CloudWatch Logs {"type":"ExecutionStarted","details":{"input" :{"initialFileLocation":{"backingStore":"EFS" ,"filesystemId":"fs-12345678","path":"/lhr/ regex.py"}}},"workflowId":"w-1111aaaa2 222bbbb3","executionId":"1234abcd-12 34-efgh-5678-ijklmnopqr90","transfer Details":{"serverId":"s-zzzz1111aaaa22223","u sername":"lhr","sessionId":"12345678 90abcdef0"}} {"type":"StepStarted","details":{"input":{"fi leLocation":{"backingStore":"EFS","filesystem Id":"fs-12345678","path":"/lhr/regex.py"}},"s tepType":"CUSTOM","stepName":"efs-s3 _copy_2"},"workflowId":"w-9283e49d33 297c3f7","executionId":"1234abcd-1234- efgh-5678-ijklmnopqr90","transferDetails": {"serverId":"s-18ca49dce5d842e0b","us ername":"lhr","sessionId":"123456789 0abcdef0"}} Example CloudWatch log entries This topic presents example log entries. Topics • Example transfer sessions log entries • Example log entries for SFTP connectors • Example log entries for Key exchange algorithm failures Example CloudWatch log entries 492 AWS Transfer Family User Guide Example transfer sessions log entries In this example, an SFTP user connects to a Transfer Family server, uploads a file, then disconnects from the session. The following log entry reflects an SFTP user connecting to a Transfer Family server. { "role": "arn:aws:iam::500655546075:role/transfer-s3", "activity-type": "CONNECTED", "ciphers": "[email protected],[email protected]", "client": "SSH-2.0-OpenSSH_7.4", "source-ip": "52.94.133.133", "resource-arn": "arn:aws:transfer:us-east-1:500655546075:server/ s-3fe215d89f074ed2a", "home-dir": "/test/log-me", "ssh-public-key": "AAAAC3NzaC1lZDI1NTE5AAAAIA9OY0qV6XYVHaaOiWAcj2spDJVbgjrqDPY4pxd6GnHl", "ssh-public-key-fingerprint": "SHA256:BY3gNMHwTfjd4n2VuT4pTyLOk82zWZj4KEYEu7y4r/0", "ssh-public-key-type": "ssh-ed25519", "user": "log-me", "kex": "ecdh-sha2-nistp256", "session-id": "9ca9a0e1cec6ad9d" } The following log entry reflects the SFTP user uploading a file into their Amazon S3 bucket. { "mode": "CREATE|TRUNCATE|WRITE", "path": "/test/log-me/config-file", "activity-type": "OPEN", "resource-arn": "arn:aws:transfer:us-east-1:500655546075:server/ s-3fe215d89f074ed2a", "session-id": "9ca9a0e1cec6ad9d" } The following log entries reflect the SFTP user disconnecting from their SFTP session. First, the client closes the connection to the bucket, and then the client disconnects the SFTP session. { "path": "/test/log-me/config-file", Example transfer sessions log entries 493 AWS Transfer Family "activity-type": "CLOSE", "resource-arn": "arn:aws:transfer:us-east-1:500655546075:server/ s-3fe215d89f074ed2a", "bytes-in": "121", "session-id": "9ca9a0e1cec6ad9d" User Guide } { "activity-type": "DISCONNECTED", "resource-arn": "arn:aws:transfer:us-east-1:500655546075:server/ s-3fe215d89f074ed2a", "session-id": "9ca9a0e1cec6ad9d" } Note The available activity types are as follows: AUTH_FAILURE, CONNECTED, DISCONNECTED, ERROR, EXIT_REASON, CLOSE, CREATE_SYMLINK, DELETE, MKDIR, OPEN, PARTIAL_CLOSE, RENAME, RMDIR, SETSTAT, TLS_RESUME_FAILURE. Example log entries for SFTP connectors This section contains example logs for both a successful and an unsuccessful transfer. Logs are generated to a log group named /aws/transfer/connector-id, where connector-id is the identifier for your SFTP connector. Log entries for SFTP connectors are generated when you run either a StartFileTransfer or StartDirectoryListing command. This log entry is for a transfer that completed successfully. { "operation": "RETRIEVE", "timestamp": "2023-10-25T16:33:27.373720Z", "connector-id": "connector-id", "transfer-id": "transfer-id", "file-transfer-id": "transfer-id/file-transfer-id", "url": "sftp://192.0.2.0", "file-path": "/remotebucket/remotefilepath", "status-code": "COMPLETED", "start-time": "2023-10-25T16:33:26.945481Z", "end-time": "2023-10-25T16:33:27.159823Z", Example log entries for SFTP connectors 494 AWS Transfer Family User Guide "account-id": "480351544584", "connector-arn": "arn:aws:transfer:us-east-1:account-id:connector/connector-id", "local-directory-path": "/connectors-localbucket" "bytes": 514 } This log entry is for a transfer that timed out, and thus was not completed successfully. { "operation": "RETRIEVE", "timestamp": "2023-10-25T22:33:47.625703Z", "connector-id": "connector-id", "transfer-id": "transfer-id", "file-transfer-id": "transfer-id/file-transfer-id", "url": "sftp://192.0.2.0", "file-path": "/remotebucket/remotefilepath", "status-code": "FAILED", "failure-code": "TIMEOUT_ERROR", "failure-message": "Transfer request timeout.", "account-id": "480351544584", "connector-arn": "arn:aws:transfer:us-east-1:account-id:connector/connector-id", "local-directory-path": "/connectors-localbucket" } This log entry is for a SEND operation that succeeds. { "operation": "SEND", "timestamp": "2024-04-24T18:16:12.513207284Z", "connector-id": "connector-id", "transfer-id": "transfer-id", "file-transfer-id": "transfer-id/file-transfer-id", "url": "sftp://server-id.server.transfer.us-east-1.amazonaws.com", "file-path": "/amzn-s3-demo-bucket/my-test-folder/connector-metrics-us- east-1-2024-01-02.csv", "status-code": "COMPLETED", "start-time": "2024-04-24T18:16:12.295235884Z", "end-time": "2024-04-24T18:16:12.461840732Z", "account-id": "255443218509", "connector-arn": "arn:aws:transfer:us-east-1:account-id:connector/connector-id", "bytes": 275 } Example log entries for SFTP connectors 495 AWS Transfer Family User Guide Descriptions for some key fields in the previous log examples. • timestamp represents when the log is added to CloudWatch. start-time and end-time correspond to when the connector actually starts and finishes a transfer. • transfer-id is a unique identifier that is assigned for each start-file-transfer request. If the user passes multiple file paths in a single start-file-transfer API operation, all the files share the same transfer-id. • file-transfer-id is a unique value generated for each file transferred. Note that the initial portion of the file-transfer-id is the same as transfer-id. Example log entries for Key exchange algorithm failures This section contains example logs where the Key exchange algorithm (KEX) failed. These are examples from the ERRORS log stream for structured logs. This log entry is an example where there is a host key type error. { "activity-type": "KEX_FAILURE", "source-ip": "999.999.999.999", "resource-arn": "arn:aws:transfer:us-east-1:999999999999:server/ s-999999999999999999", "message": "no matching host key type found", "kex": "ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,ecdsa-sha2- [email protected],[email protected],ecdsa-sha2- [email protected],ssh-ed25519,ssh-rsa,ssh-dss" } This log entry is an example where there is a KEX mismatch. { "activity-type": "KEX_FAILURE", "source-ip": "999.999.999.999", "resource-arn": "arn:aws:transfer:us-east-1:999999999999:server/ s-999999999999999999", "message": "no matching key exchange method found", "kex": "diffie-hellman-group1-sha1,diffie-hellman-group14-sha1,diffie-hellman- group14-sha256" } Example log entries for Key exchange algorithm failures 496 AWS Transfer Family User Guide Using CloudWatch metrics for Transfer Family servers
|
transferfamily-ug-144
|
transferfamily-ug.pdf
| 144 |
algorithm (KEX) failed. These are examples from the ERRORS log stream for structured logs. This log entry is an example where there is a host key type error. { "activity-type": "KEX_FAILURE", "source-ip": "999.999.999.999", "resource-arn": "arn:aws:transfer:us-east-1:999999999999:server/ s-999999999999999999", "message": "no matching host key type found", "kex": "ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,ecdsa-sha2- [email protected],[email protected],ecdsa-sha2- [email protected],ssh-ed25519,ssh-rsa,ssh-dss" } This log entry is an example where there is a KEX mismatch. { "activity-type": "KEX_FAILURE", "source-ip": "999.999.999.999", "resource-arn": "arn:aws:transfer:us-east-1:999999999999:server/ s-999999999999999999", "message": "no matching key exchange method found", "kex": "diffie-hellman-group1-sha1,diffie-hellman-group14-sha1,diffie-hellman- group14-sha256" } Example log entries for Key exchange algorithm failures 496 AWS Transfer Family User Guide Using CloudWatch metrics for Transfer Family servers Note You can also get metrics for Transfer Family from within the Transfer Family console itself. For details, see Monitoring usage in the console You can get information about your server using CloudWatch metrics. A metric represents a time- ordered set of data points that are published to CloudWatch. When using metrics, you must specify the Transfer Family namespace, metric name, and dimension. For more information about metrics, see Metrics in the Amazon CloudWatch User Guide. The following table describes the CloudWatch metrics for Transfer Family. Namespace Metric Description AWS/Transfer BytesIn The total number of bytes transferred into the server. Reporting criteria: • For SFTP/FTP/FTPS: emitted every 5 minutes while a connection is established to the Transfer Family server. If no files or bytes are transferred in the period, "0" is emitted. • For AS2: when the customer receives a message in their AS2 server and emitted as soon as the inbound message has finished processing Units: Count Period: 5 minutes BytesOut The total number of bytes transferred out of the server. Reporting criteria: • For SFTP/FTP/FTPS: emitted every 5 minutes while a connection is established to the Transfer Family Using CloudWatch metrics 497 AWS Transfer Family User Guide Namespace Metric Description server. If no files or bytes are transferred in the period, "0" is emitted. • For AS2: when the customer calls StartFile Transfer from their AS2 connector and emitted as soon as the outbound message has finished processin g. Units: Count Period: 5 minutes FilesIn The total number of files transferred into the server. For servers using the AS2 protocol, this metric represent s the number of messages received. Reporting criteria: • For SFTP/FTP/FTPS: emitted every 5 minutes while a connection is established to the Transfer Family server. If no files or bytes are transferred in the period, "0" is emitted. • For AS2: when the customer receives a message in their AS2 server and emitted as soon as the inbound message has finished processing. Units: Count Period: 5 minutes Using CloudWatch metrics 498 AWS Transfer Family User Guide Namespace Metric Description FilesOut The total number of files transferred out of the server. Reporting criteria: • For SFTP/FTP/FTPS: emitted every 5 minutes while a connection is established to the Transfer Family server. If no files or bytes are transferred in the period, "0" is emitted. • For AS2: when the customer calls StartFile Transfer from their AS2 connector and emitted as soon as the outbound message has finished processin g. Units: Count Period: 5 minutes InboundMe ssage The total number of AS2 messages successfully received from a trading partner. Reporting criteria: When the customer receives a message in their AS2 server and emitted as soon as the inbound message has finished processing successfully Units: Count Period: 5 minutes Using CloudWatch metrics 499 AWS Transfer Family User Guide Namespace Metric Description InboundFa iledMessage The total number of AS2 messages that were unsuccess fully received from a trading partner. That is, a trading partner sent a message, but the Transfer Family server was not able to successfully process it. Reporting criteria: When the customer receives a message in their AS2 server and emitted as soon as the inbound message has finished processing unsuccess fully Units: Count Period: 5 minutes OnUploadE xecutions Started The total number of workflow executions started on the server. Reporting criteria: Triggered every time an execution starts Units: Count Period: 1 minute OnUploadE xecutions Success The total number of successful workflow executions on the server. Reporting criteria: Triggered every time an execution successfully finishes Units: Count Period: 1 minute Using CloudWatch metrics 500 AWS Transfer Family User Guide Namespace Metric Description OnUploadE xecutions Failed The total number of unsuccessful workflow executions on the server. Reporting criteria: Triggered every time an execution does not successfully finish Units: Count Period: 1 minute OutboundM essage The total number of AS2 messages successfully sent to a a trading partner. Reporting criteria: When the customer calls StartFileTransfer from their AS2 connector and emitted as soon as the outbound message has finished processing successfully Units: Count Period: 5 minutes OutboundF ailedMess age The total number of AS2 messages that were unsuccess fully sent to a trading partner. Reporting criteria: When the customer calls
|
transferfamily-ug-145
|
transferfamily-ug.pdf
| 145 |
Guide Namespace Metric Description OnUploadE xecutions Failed The total number of unsuccessful workflow executions on the server. Reporting criteria: Triggered every time an execution does not successfully finish Units: Count Period: 1 minute OutboundM essage The total number of AS2 messages successfully sent to a a trading partner. Reporting criteria: When the customer calls StartFileTransfer from their AS2 connector and emitted as soon as the outbound message has finished processing successfully Units: Count Period: 5 minutes OutboundF ailedMess age The total number of AS2 messages that were unsuccess fully sent to a trading partner. Reporting criteria: When the customer calls StartFileTransfer from their AS2 connector and emitted as soon as the outbound message has finished processing unsuccessfully Units: Count Period: 5 minutes Using CloudWatch metrics 501 AWS Transfer Family User Guide Transfer Family dimensions A dimension is a name/value pair that is part of the identity of a metric. For more information about dimensions, see Dimensions in the Amazon CloudWatch User Guide. The following table describes the CloudWatch dimensions for Transfer Family. Dimension Description ServerId The unique ID of the server. ConnectorId The unique ID of the connector. Used for AS2, for OutboundMessage and OutboundFailedMessage Using AWS User Notifications with AWS Transfer Family To get notified about AWS Transfer Family events, you can use AWS User Notifications to set up various delivery channels. When an event matches a rule that you specify, you receive a notification. You can receive notifications for events through multiple channels, including email, Amazon Q Developer in chat applications chat notifications, or AWS Console Mobile Application push notifications. You can also see notifications in the Console Notifications Center. User Notifications supports aggregation, which can reduce the number of notifications that you receive during specific events. For more information, see the Customize file delivery notifications using AWS Transfer Family managed workflows blog post, and What is AWS User Notifications? in the AWS User Notifications User Guide. Using queries to filter log entries You can use CloudWatch queries to filter and identify log entries for Transfer Family. This section contains some examples. 1. Sign in to the AWS Management Console and open the CloudWatch console at https:// console.aws.amazon.com/cloudwatch/. Transfer Family dimensions 502 AWS Transfer Family User Guide 2. You can create queries or rules. • To create a Logs Insights query, choose Logs Insights from the left navigation panel, and then enter the details for your query. • To create a Contributor Insights rule, choose Insights > Contributor Insights from the left navigation panel and then enter the details for your rule. 3. Run the query or rule that you created. View the top authentication failure contributors In your structured logs, an authentication failure log entry looks similar to the following: { "method":"password", "activity-type":"AUTH_FAILURE", "source-ip":"999.999.999.999", "resource-arn":"arn:aws:transfer:us-east-1:999999999999:server/s-0123456789abcdef", "message":"Invalid user name or password", "user":"exampleUser" } Run the following query to view the top contributors to authentication failures. filter @logStream = 'ERRORS' | filter `activity-type` = 'AUTH_FAILURE' | stats count() as AuthFailures by user, method | sort by AuthFailures desc | limit 10 Rather than using CloudWatch Logs Insights, you can create a CloudWatch Contributors Insights rule to view authentication failures. Create a rule similar to the following. { "AggregateOn": "Count", "Contribution": { "Filters": [ { "Match": "$.activity-type", "In": [ "AUTH_FAILURE" CloudWatch queries 503 User Guide AWS Transfer Family ] } ], "Keys": [ "$.user" ] }, "LogFormat": "JSON", "Schema": { "Name": "CloudWatchLogRule", "Version": 1 }, "LogGroupARNs": [ "arn:aws:logs:us-east-1:999999999999:log-group:/customer/structured_logs" ] } View log entries where a file was opened In your structured logs, a file read log entry looks similar to the following: { "mode":"READ", "path":"/fs-0df669c89d9bf7f45/avtester/example", "activity-type":"OPEN", "resource-arn":"arn:aws:transfer:us-east-1:999999999999:server/s-0123456789abcdef", "session-id":"0049cd844c7536c06a89" } Run the following query to view log entries that indicate a file was opened. filter `activity-type` = 'OPEN' | display @timestamp, @logStream, `session-id`, mode, path CloudWatch queries 504 AWS Transfer Family User Guide Managing Transfer Family events using Amazon EventBridge Amazon EventBridge is a serverless service that uses events to connect application components together, which can make it easier for you to build scalable event-driven applications. Event-driven architecture is a style of building loosely coupled software systems that work together by emitting and responding to events. Events represent a change in a resource or environment. As with many AWS services, Transfer Family generates and sends events to the EventBridge default event bus. Note that the default event bus is automatically provisioned in every AWS account. An event bus is a router that receives events and delivers them to zero or more destinations, or targets. You specify rules for the event bus that evaluates events as they arrive. Each rule checks whether an event matches the rule's event pattern. If the event matches, the event bus sends the event to one or more specified targets. Topics • Transfer Family events • Sending Transfer Family events by using EventBridge rules • Amazon EventBridge
|
transferfamily-ug-146
|
transferfamily-ug.pdf
| 146 |
Family generates and sends events to the EventBridge default event bus. Note that the default event bus is automatically provisioned in every AWS account. An event bus is a router that receives events and delivers them to zero or more destinations, or targets. You specify rules for the event bus that evaluates events as they arrive. Each rule checks whether an event matches the rule's event pattern. If the event matches, the event bus sends the event to one or more specified targets. Topics • Transfer Family events • Sending Transfer Family events by using EventBridge rules • Amazon EventBridge permissions • Additional EventBridge resources • Transfer Family events detail reference 505 AWS Transfer Family User Guide Transfer Family events Transfer Family automatically sends events to the default EventBridge event bus. You can create rules on the event bus where each rule includes an event pattern and one or more targets. Events that match a rule's event pattern are delivered to the specified targets on a best effort basis, however, some events might be delivered out of order. The following events are generated by Transfer Family. For more information, see EventBridge events in the Amazon EventBridge User Guide. SFTP, FTPS, and FTP server events Event detail type Description FTP Server File Download Completed FTP Server File Download Failed FTP Server File Upload Completed A file has been downloaded successfully for the FTP protocol. An attempt to download a file has failed for the FTP protocol. A file has been uploaded successfully for the FTP protocol. FTP Server File Upload Failed An attempt to upload a file has failed for the FTP protocol. FTPS Server File Download Completed FTPS Server File Download Failed FTPS Server File Upload Completed FTPS Server File Upload Failed SFTP Server File Download Completed A file has been downloaded successfully for the FTPS protocol. An attempt to download a file has failed for the FTPS protocol. A file has been uploaded successfully for the FTPS protocol. An attempt to upload a file has failed for the FTPS protocol. A file has been downloaded successfully for the SFTP protocol. Transfer Family events 506 AWS Transfer Family User Guide Event detail type Description An attempt to download a file has failed for the SFTP protocol. A file has been uploaded successfully for the SFTP protocol. An attempt to upload a file has failed for the SFTP protocol. SFTP Server File Download Failed SFTP Server File Upload Completed SFTP Server File Upload Failed SFTP connector events Event detail type Description SFTP Connector File Send Completed A file transfer from a connector to a remote SFTP server has completed successfully. SFTP Connector File Send Failed A file transfer from a connector to a remote SFTP server has failed. SFTP Connector File Retrieve Completed A file transfer from a remote SFTP server to a connector has completed successfully. SFTP Connector File Retrieve Failed A file transfer from a remote SFTP server to a connector has failed. SFTP Connector Directory Listing Completed A start file directory listing call that has completed successfu lly. SFTP Connector Directory Listing Failed A start file directory listing that has failed. SFTP Connector Remote Move Completed Files or directories have been moved or renamed successfully on the remote server. SFTP Connector Remote Move Failed Files or directories have been failed to be moved or renamed on the remote server. SFTP connector events 507 AWS Transfer Family User Guide Event detail type Description SFTP Connector Remote Delete Completed Files or directories have been successfully deleted on the remote server. SFTP Connector Remote Delete Failed Files or directories have failed to be deleted on the remote server. AS2 events Event detail type Description AS2 Payload Receive Completed The payload for an AS2 message has been received. AS2 Payload Receive Failed The payload for an AS2 message has not been received. AS2 Payload Send Completed The payload for an AS2 message has been sent successfully. AS2 Payload Send Failed The payload for an AS2 message has failed to send. AS2 MDN Receive Completed The message disposition notification for an AS2 message has been received. AS2 MDN Receive Failed The message disposition notification for an AS2 message has not been received. AS2 MDN Send Completed The message disposition notification for an AS2 message has been sent successfully. AS2 MDN Send Failed The message disposition notification for an AS2 message has failed to send. AS2 events 508 AWS Transfer Family User Guide Sending Transfer Family events by using EventBridge rules If you want the EventBridge default event bus to send Transfer Family events to a target, you must create a rule that contains an event pattern that matches the data in your desired Transfer Family events. To capture AWS Transfer Family events in Amazon EventBridge 1. Sign in to the AWS Management Console
|
transferfamily-ug-147
|
transferfamily-ug.pdf
| 147 |
MDN Send Completed The message disposition notification for an AS2 message has been sent successfully. AS2 MDN Send Failed The message disposition notification for an AS2 message has failed to send. AS2 events 508 AWS Transfer Family User Guide Sending Transfer Family events by using EventBridge rules If you want the EventBridge default event bus to send Transfer Family events to a target, you must create a rule that contains an event pattern that matches the data in your desired Transfer Family events. To capture AWS Transfer Family events in Amazon EventBridge 1. Sign in to the AWS Management Console and open the Amazon EventBridge console at https://console.aws.amazon.com/events/. 2. 3. 4. 5. 6. 7. In the navigation pane, choose Rules, then choose Create rule. Enter a descriptive name for the rule, and optionally enter a description. For Rule type, select Rule with an event pattern then choose Next. In the Event source section, select AWS events or EventBridge partner events. In the Creation method section, choose Use pattern form. In the Event pattern section, provide the following information. a. b. c. d. e. f. For Event source, choose AWS services. For AWS service, choose Transfer. For Event type, choose the Transfer Family event type that you want to trigger your rule. Depending upon your Event type selection, you may be presented with an Event Type Specification 1 section. If you see the Event Type Specification 1 section, select the specific events you want to capture (or select Any event to capture all events for your selected event type). (Optional) Use the Event pattern editor to specify filters for event details. Choose Next. 8. Choose a target from the choices available in Select targets. Choose from the following available targets. • AWS service. Popular options are Lambda functions for serverless compute, Amazon SQS queues for message processing, Amazon SNS topics for notifications, and AWS Step Functions for orchestrating workflows. • EventBridge API Destination. If you want to send events to an HTTP endpoint outside of AWS, you can use an API Destination as your target. Sending Transfer Family events 509 AWS Transfer Family User Guide • EventBridge event bus. You can send events to another event bus, either in the same account and region or in a different account or region. For comprehensive instructions on creating event bus rules, see Creating rules that react to events in the Amazon EventBridge User Guide. For help in selecting a target, see Select targets in the Amazon EventBridge User Guide. 9. Configure any additional options for your target then choose Next. 10. (Optional) Add tags to your rule and choose Next. 11. In the Review and create screen, if everything looks good, choose Create rule. Creating event patterns for Transfer Family events When Transfer Family delivers an event to the default event bus, EventBridge uses the event pattern defined for each rule to determine if the event should be delivered to the rule's targets. An event pattern matches the data in the desired Transfer Family events. Each event pattern is a JSON object that contains the following: • A source attribute that identifies the service sending the event. For Transfer Family events, the source is aws.transfer. • (Optional) A detail-type attribute that contains an array of the event types to match. • (Optional) A detail attribute containing any other event data on which to match. For example, the following event pattern matches against all events from Transfer Family: { "source": ["aws.transfer"] } The following event pattern example matches all of the SFTP connector events: { "source": ["aws.transfer"], "detail-type": ["SFTP Connector File Send Completed", "SFTP Connector File Retrieve Completed", "SFTP Connector File Retrieve Failed", "SFTP Connector File Send Failed"] Creating event patterns 510 AWS Transfer Family } User Guide The following event pattern example matches all Transfer Family failed events: { "source": ["aws.transfer"], "detail-type": [{"wildcard", "*Failed"}] } The following event pattern example matches successful SFTP downloads for user username: { "source": ["aws.transfer"], "detail-type": ["SFTP Server File Download Completed"], "detail": { "username": [username] } } For more information on writing event patterns, see Event patterns in the EventBridge User Guide. Testing event patterns for Transfer Family events in EventBridge You can use the EventBridge Sandbox to quickly define and test an event pattern, without having to complete the broader process of creating or editing a rule. Using the Sandbox, you can define an event pattern and use a sample event to confirm that the pattern matches the desired events. EventBridge gives you the option of creating a new rule by using that event pattern directly from the sandbox. For more information, see Testing an event pattern using the EventBridge Sandbox in the EventBridge User Guide. Amazon EventBridge permissions Transfer Family doesn't require any additional permissions to deliver events to Amazon EventBridge. The targets that you specify
|
transferfamily-ug-148
|
transferfamily-ug.pdf
| 148 |
quickly define and test an event pattern, without having to complete the broader process of creating or editing a rule. Using the Sandbox, you can define an event pattern and use a sample event to confirm that the pattern matches the desired events. EventBridge gives you the option of creating a new rule by using that event pattern directly from the sandbox. For more information, see Testing an event pattern using the EventBridge Sandbox in the EventBridge User Guide. Amazon EventBridge permissions Transfer Family doesn't require any additional permissions to deliver events to Amazon EventBridge. The targets that you specify might require specific permissions or configuration. For more details on using specific services for targets, see Amazon EventBridge targets in the Amazon EventBridge User Guide. Testing event patterns for Transfer Family events 511 AWS Transfer Family User Guide Additional EventBridge resources Refer to the following topics in the Amazon EventBridge User Guide for more information on how to use EventBridge to process and manage events. • For detailed information on how event buses work, see Amazon EventBridge event bus. • For information on event structure, see Events. • For information on constructing event patterns for EventBridge to use when matching events against rules, see Event patterns. • For information on creating rules to specify which events EventBridge processes, see Rules. • For information on how to specify what services or other destinations to which EventBridge sends matched events, see Targets. Transfer Family events detail reference All events from AWS services have a common set of fields containing metadata about the event. These metadata can include the AWS service that is the source of the event, the time the event was generated, the account and Region in which the event took place, and others. For definitions of these general fields, see Event structure reference in the Amazon EventBridge User Guide. In addition, each event has a detail field that contains data specific to that particular event. The following reference defines the detail fields for the various Transfer Family events. When you use EventBridge to select and manage Transfer Family events, consider the following: • The source field for all events from Transfer Family is set to aws.transfer. • The detail-type field specifies the event type. For example, FTP Server File Download Completed. • The detail field contains the data that is specific to that particular event. For information on constructing event patterns that enable rules to match Transfer Family events, see Event patterns in the Amazon EventBridge User Guide. For more information on events and how EventBridge processes them, see Amazon EventBridge events in the Amazon EventBridge User Guide. Additional resources 512 User Guide AWS Transfer Family Topics • SFTP, FTPS, and FTP server events • SFTP connector events • AS2 events SFTP, FTPS, and FTP server events The following are the detail fields for SFTP, FTPS, and FTP server events: • FTP Server File Download Completed • FTP Server File Download Failed • FTP Server File Upload Completed • FTP Server File Upload Failed • FTPS Server File Download Completed • FTPS Server File Download Failed • FTPS Server File Upload Completed • FTPS Server File Upload Failed • SFTP Server File Download Completed • SFTP Server File Download Failed • SFTP Server File Upload Completed • SFTP Server File Upload Failed The source and detail-type fields are included below because they contain specific values for Transfer Family events. For definitions of the other metadata fields that are included in all events, see Event structure reference in the Amazon EventBridge User Guide. { . . ., "detail-type": "string", "source": "aws.transfer", . . ., "detail": { "failure-code" : "string", "status-code" : "string", Server events 513 AWS Transfer Family User Guide "protocol" : "string", "bytes" : "number", "client-ip" : "string", "failure-message" : "string", "end-timestamp" : "string", "etag" : "string", "file-path" : "string", "server-id" : "string", "username" : "string", "session-id" : "string", "start-timestamp" : "string" } } detail-type Identifies the type of event. For this event, the value is one of the SFTP, FTPS, or FTP server event names listed previously. source Identifies the service that generated the event. For Transfer Family events, this value is aws.transfer. detail A JSON object that contains information about the event. The service generating the event determines the content of this field. For this event, the data includes the following: failure-code Category for why the transfer failed. Values: PARTIAL_UPLOAD | PARTIAL_DOWNLOAD | UNKNOWN_ERROR status-code Whether the transfer is successful. Values: COMPLETED | FAILED. protocol The protocol used for the transfer. Values: SFTP | FTPS | FTP Server events 514 User Guide AWS Transfer Family bytes The number of bytes transferred. client-ip The IP address for the client involved in the transfer failure-message For failed transfers, the details for why the transfer failed. end-timestamp For successful transfers, the
|
transferfamily-ug-149
|
transferfamily-ug.pdf
| 149 |
information about the event. The service generating the event determines the content of this field. For this event, the data includes the following: failure-code Category for why the transfer failed. Values: PARTIAL_UPLOAD | PARTIAL_DOWNLOAD | UNKNOWN_ERROR status-code Whether the transfer is successful. Values: COMPLETED | FAILED. protocol The protocol used for the transfer. Values: SFTP | FTPS | FTP Server events 514 User Guide AWS Transfer Family bytes The number of bytes transferred. client-ip The IP address for the client involved in the transfer failure-message For failed transfers, the details for why the transfer failed. end-timestamp For successful transfers, the timestamp for when the file finishes being processed. etag The entity tag (only used for Amazon S3 files). file-path The path to the file being transferred. server-id The unique ID for the Transfer Family server. username The user that is performing the transfer. session-id The unique identifier for the transfer session. start-timestamp For successful transfers, the timestamp for when file processing begins. Example SFTP Server File Download Failed example event The following example shows an event where a download failed on an SFTP server (Amazon EFS is the storage being used). { Server events 515 AWS Transfer Family "version": "0", "id": "event-ID", "detail-type": "SFTP Server File Download Failed", "source": "aws.transfer", "account": "958412138249", "time": "2024-01-29T17:20:27Z", "region": "us-east-1", "resources": [ "arn:aws:transfer:us-east-1:958412138249:server/s-1234abcd5678efghi" User Guide ], "detail": { "failure-code": "PARTIAL_DOWNLOAD", "status-code": "FAILED", "protocol": "SFTP", "bytes": 4100, "client-ip": "IP-address", "failure-message": "File was partially downloaded.", "end-timestamp": "2024-01-29T17:20:27.749749117Z", "file-path": "/fs-1234abcd5678efghi/user0/test-file", "server-id": "s-1234abcd5678efghi", "username": "test", "session-id": "session-ID", "start-timestamp": "2024-01-29T17:20:16.706282454Z" } } Example FTP Server File Upload Completed example event The following example shows an event where an upload completed successfully on an FTP server (Amazon S3 is the storage being used). { "version": "0", "id": "event-ID", "detail-type": "FTP Server File Upload Completed", "source": "aws.transfer", "account": "958412138249", "time": "2024-01-29T16:31:43Z", "region": "us-east-1", "resources": [ "arn:aws:transfer:us-east-1:958412138249:server/s-1111aaaa2222bbbb3" ], "detail": { Server events 516 AWS Transfer Family User Guide "status-code": "COMPLETED", "protocol": "FTP", "bytes": 1048576, "client-ip": "10.0.0.141", "end-timestamp": "2024-01-29T16:31:43.311866408Z", "etag": "b6d81b360a5672d80c27430f39153e2c", "file-path": "/amzn-s3-demo-bucket/test/1mb_file", "server-id": "s-1111aaaa2222bbbb3", "username": "test", "session-id": "event-ID", "start-timestamp": "2024-01-29T16:31:42.462088327Z" } } SFTP connector events The following are the detail fields for SFTP connector events: • SFTP Connector File Send Completed • SFTP Connector File Send Failed • SFTP Connector File Retrieve Completed • SFTP Connector File Retrieve Failed • SFTP Connector Directory Listing Completed • SFTP Connector Directory Listing Failed • SFTP Connector Remote Move Completed • SFTP Connector Remote Move Failed • SFTP Connector Remote Delete Completed • SFTP Connector Remote Delete Failed The source and detail-type fields are included below because they contain specific values for Transfer Family events. For definitions of the other metadata fields that are included in all events, see Event structure reference in the Amazon EventBridge User Guide. { . . ., "detail-type": "string", "source": "aws.transfer", Connector events 517 User Guide AWS Transfer Family . . ., "detail": { "operation" : "string", "max-items" : "number", "connector-id" : "string", "output-directory-path" : "string", "listing-id" : "string", "transfer-id" : "string", "file-transfer-id" : "string", "url" : "string", "file-path" : "string", "status-code" : "string", "failure-code" : "string", "failure-message" : "string", "start-timestamp" : "string", "end-timestamp" : "string", "local-directory-path" : "string", "remote-directory-path" : "string" "item-count" : "number" "truncated" : "boolean" "bytes" : "number", "local-file-location" : { "domain" : "string", "bucket" : "string", "key" : "string" }, "output-file-location" : { "domain" : "string", "bucket" : "string", "key" : "string" } } } detail-type Identifies the type of event. For this event, the value is one of the SFTP connector event names listed previously. source Identifies the service that generated the event. For Transfer Family events, this value is aws.transfer. Connector events 518 AWS Transfer Family detail User Guide A JSON object that contains information about the event. The service that generates the event determines the content of this field. For this event, the data includes the following: max-items The maximum number of directory/file names to return. operation Whether the StartFileTransfer request is sending or retrieving a file. Values: SEND| RETRIEVE. connector-id The unique identifier for the SFTP connector being used. output-directory-path The path (bucket and prefix) in Amazon S3 to store the results of the file/directory listing. listing-id A unique identifier for the StartDirectoryListing API operation. This identifier can be used to check CloudWatch logs to see the status of listing request. transfer-id The unique identifier for the transfer event (a StartFileTransfer request). file-transfer-id The unique identifier for the file being transferred. url The URL of the partner's AS2 or SFTP endpoint. file-path The location and file that is being sent or retrieved. status-code Whether the transfer is successful. Values: FAILED | COMPLETED. Connector events 519 AWS Transfer Family failure-code User Guide For failed transfers, the reason code for why the transfer failed. failure-message For failed transfers, the details for why the transfer failed. start-timestamp For successful transfers, the timestamp for when file
|
transferfamily-ug-150
|
transferfamily-ug.pdf
| 150 |
CloudWatch logs to see the status of listing request. transfer-id The unique identifier for the transfer event (a StartFileTransfer request). file-transfer-id The unique identifier for the file being transferred. url The URL of the partner's AS2 or SFTP endpoint. file-path The location and file that is being sent or retrieved. status-code Whether the transfer is successful. Values: FAILED | COMPLETED. Connector events 519 AWS Transfer Family failure-code User Guide For failed transfers, the reason code for why the transfer failed. failure-message For failed transfers, the details for why the transfer failed. start-timestamp For successful transfers, the timestamp for when file processing begins. end-timestamp For successful transfers, the timestamp for when file processing completes. local-directory-path For RETRIEVE requests, the location in which to place the retrieved file. remote-directory-path For SEND requests, the file directory in which to place the file on the partner's SFTP server. This is the value for the RemoteDirectoryPath that the user passed to the StartFileTransfer request. You can specify a default directory on the partner's SFTP server. If so, this field is empty. item-count The number of items (directories and files) returned for the listing request. truncated Whether the list output contains all of the items contained in the remote directory or not. bytes The number of bytes being transferred. The value is 0 for failed transfers. local-file-location This parameter contains the details of the location of the AWS storage file. domain The storage being used. Currently, the only value is S3. Connector events 520 AWS Transfer Family bucket User Guide The container for the object in Amazon S3. key The name assigned to the object in Amazon S3. output-file-location This parameter contains the details of the location for where to store the results of the directory listing in AWS storage. domain The storage being used. Currently, the only value is S3. bucket The container for the object in Amazon S3. key The name assigned to the object in Amazon S3. Example SFTP Connector File Send Failed example event The following example shows an event where an SFTP connector failed while trying to send a file to a remote SFTP server. { "version": "0", "id": "event-ID", "detail-type": "SFTP Connector File Send Failed", "source": "aws.transfer", "account": "123456789012", "time": "2024-01-24T19:30:45Z", "region": "us-east-1", "resources": [ "arn:aws:transfer:us-east-1:123456789012:connector/c-f1111aaaa2222bbbb3" ], "detail": { "operation": "SEND", "connector-id": "c-f1111aaaa2222bbbb3", Connector events 521 AWS Transfer Family User Guide "transfer-id": "transfer-ID", "file-transfer-id": "file-transfer-ID", "url": "sftp://s-21a23456789012a.server.transfer.us-east-1.amazonaws.com", "file-path": "/amzn-s3-demo-bucket/testfile.txt", "status-code": "FAILED", "failure-code": "CONNECTION_ERROR", "failure-message": "Unknown Host", "remote-directory-path": "", "bytes": 0, "start-timestamp": "2024-01-24T18:29:33.658729Z", "end-timestamp": "2024-01-24T18:29:33.993196Z", "local-file-location": { "domain": "S3", "bucket": "amzn-s3-demo-bucket", "key": "testfile.txt" } } } Example SFTP Connector File Retrieve Completed example event The following example shows an event where an SFTP connector successfully retrieved a file sent from a remote SFTP server. { "version": "0", "id": "event-ID", "detail-type": "SFTP Connector File Retrieve Completed", "source": "aws.transfer", "account": "123456789012", "time": "2024-01-24T18:28:08Z", "region": "us-east-1", "resources": [ "arn:aws:transfer:us-east-1:123456789012:connector/c-f1111aaaa2222bbbb3" ], "detail": { "operation": "RETRIEVE", "connector-id": "c-fc68000012345aa18", "transfer-id": "file-transfer-ID", "file-transfer-id": "file-transfer-ID", "url": "sftp://s-21a23456789012a.server.transfer.us-east-1.amazonaws.com", "file-path": "testfile.txt", "status-code": "COMPLETED", Connector events 522 AWS Transfer Family User Guide "local-directory-path": "/amzn-s3-demo-bucket", "bytes": 63533, "start-timestamp": "2024-01-24T18:28:07.632388Z", "end-timestamp": "2024-01-24T18:28:07.774898Z", "local-file-location": { "domain": "S3", "bucket": "amzn-s3-demo-bucket", "key": "testfile.txt" } } } Example SFTP Connector Directory Listing Completed example event The following example shows an event where a start directory listing call retrieved a listing file from a remote SFTP server. { "version": "0", "id": "event-ID", "detail-type": "SFTP Connector Directory Listing Completed", "source": "aws.transfer", "account": "123456789012", "time": "2024-01-24T18:28:08Z", "region": "us-east-1", "resources": [ "arn:aws:transfer:us-east-1:123456789012:connector/c-f1111aaaa2222bbbb3" ], "detail": { "max-items": 10000, "connector-id": "c-fc68000012345aa18", "output-directory-path": "/amzn-s3-demo-bucket/example/file-listing-output", "listing-id": "123456-23aa-7980-abc1-1a2b3c4d5e", "url": "sftp://s-21a23456789012a.server.transfer.us-east-1.amazonaws.com", "status-code": "COMPLETED", "remote-directory-path": "/home", "item-count": 10000, "truncated": true, "start-timestamp": "2024-01-24T18:28:07.632388Z", "end-timestamp": "2024-01-24T18:28:07.774898Z", "output-file-location": { "domain": "S3", Connector events 523 AWS Transfer Family User Guide "bucket": "amzn-s3-demo-bucket", "key": "c-fc1ab90fd0d047e7a-70987273-49nn-4006-bab1-1a7290cc412ba.json" } } } AS2 events The following are the detail fields for AS2 events: • AS2 Payload Receive Completed • AS2 Payload Receive Failed • AS2 Payload Send Completed • AS2 Payload Send Failed • AS2 MDN Receive Completed • AS2 MDN Receive Failed • AS2 MDN Send Completed • AS2 MDN Send Failed The source and detail-type fields are included below because they contain specific values for Transfer Family events. For definitions of the other metadata fields that are included in all events, see Event structure reference in the Amazon EventBridge User Guide. { . . ., "detail-type": "string", "source": "aws.transfer", . . ., "detail": { "s3-attributes" : { "file-bucket" : "string", "file-key" : "string", "json-bucket" : "string", "json-key" : "string", "mdn-bucket" : "string", "mdn-key" : "string" } "mdn-subject" : "string", AS2 events 524 AWS Transfer Family User Guide "mdn-message-id" : "string", "disposition" : "string", "bytes" : "number", "as2-from" : "string", "as2-message-id" : "string", "as2-to" : "string", "connector-id" : "string", "client-ip" : "string", "agreement-id" : "string", "server-id" : "string", "requester-file-name" : "string", "message-subject" : "string", "start-timestamp" : "string", "end-timestamp" : "string", "status-code" : "string", "failure-code" : "string", "failure-message"
|
transferfamily-ug-151
|
transferfamily-ug.pdf
| 151 |
the Amazon EventBridge User Guide. { . . ., "detail-type": "string", "source": "aws.transfer", . . ., "detail": { "s3-attributes" : { "file-bucket" : "string", "file-key" : "string", "json-bucket" : "string", "json-key" : "string", "mdn-bucket" : "string", "mdn-key" : "string" } "mdn-subject" : "string", AS2 events 524 AWS Transfer Family User Guide "mdn-message-id" : "string", "disposition" : "string", "bytes" : "number", "as2-from" : "string", "as2-message-id" : "string", "as2-to" : "string", "connector-id" : "string", "client-ip" : "string", "agreement-id" : "string", "server-id" : "string", "requester-file-name" : "string", "message-subject" : "string", "start-timestamp" : "string", "end-timestamp" : "string", "status-code" : "string", "failure-code" : "string", "failure-message" : "string", "transfer-id" : "string" } } detail-type Identifies the type of event. For this event, the value is one of the AS2 events listed previously. source Identifies the service that generated the event. For Transfer Family events, this value is aws.transfer. detail A JSON object that contains information about the event. The service generating the event determines the content of this field. s3-attributes Identifies the Amazon S3 bucket and key for the file being transferred. For MDN events, it also identifies the bucket and key for the MDN file. file-bucket The container for the object in Amazon S3. AS2 events 525 AWS Transfer Family file-key User Guide The name assigned to the object in Amazon S3. json-bucket For COMPLETED or FAILED transfers, the container for the JSON file. json-key For COMPLETED or FAILED transfers, the name assigned to the JSON file in Amazon S3. mdn-bucket For MDN events, the container for the MDN file. mdn-key For MDN events, the name assigned to the MDN file in Amazon S3. mdn-subject For MDN events, a text description for the message disposition. mdn-message-id For MDN events, a unique ID for the MDN message. disposition For MDN events, the category for the disposition. bytes The number of bytes in the message. as2-from The AS2 trading partner that is sending the message. as2-message-id A unique identifier for the AS2 message being transferred. as2-to The AS2 trading partner that is receiving the message. AS2 events 526 AWS Transfer Family connector-id User Guide For AS2 messages being sent from a Transfer Family server to a trading partner, the unique identifier for the AS2 connector being used. client-ip For server events (transfers from a trading partner to a Transfer Family server), the IP address for the client involved in the transfer. agreement-id For server events, the unique identifier for the AS2 agreement. server-id For server events, a unique ID only for the Transfer Family server. requester-file-name For payload events, the original name for the file received during the transfer. message-subject A text description for the subject of the message. start-timestamp For successful transfers, the timestamp for when file processing begins. end-timestamp For successful transfers, the timestamp for when file processing completes. status-code The code that corresponds to the state of the AS2 message transfer process. Valid values: COMPLETED | FAILED | PROCESSING. failure-code For failed transfers, the category for why the transfer failed. failure-message For failed transfers, the details for why the transfer failed. transfer-id The unique identifier for the transfer event. AS2 events 527 AWS Transfer Family User Guide Example AS2 Payload Receive Completed example event { "version": "0", "id": "event-ID", "detail-type": "AS2 Payload Receive Completed", "source": "aws.transfer", "account": "076722215406", "time": "2024-02-07T06:47:05Z", "region": "us-east-1", "resources": ["arn:aws:transfer:us-east-1:076722215406:connector/ c-1111aaaa2222bbbb3"], "detail": { "s3-attributes": { "file-key": "/inbound/processed/testAs2Message.dat", "file-bucket": "amzn-s3-demo-bucket" }, "client-ip": "client-IP-address", "requester-file-name": "testAs2MessageVerifyFile.dat", "end-timestamp": "2024-02-07T06:47:06.040031Z", "as2-from": "as2-from-ID", "as2-message-id": "as2-message-ID", "message-subject": "Message from AS2 tests", "start-timestamp": "2024-02-07T06:47:05.410Z", "status-code": "PROCESSING", "bytes": 63, "as2-to": "as2-to-ID", "agreement-id": "a-1111aaaa2222bbbb3", "server-id": "s-1234abcd5678efghi" } } Example AS2 MDN Receive Failed example event { "version": "0", "id": "event-ID", "detail-type": "AS2 MDN Receive Failed", "source": "aws.transfer", "account": "889901007463", "time": "2024-02-06T22:05:09Z", "region": "us-east-1", "resources": ["arn:aws:transfer:us-east-1:076722215406:server/s-1111aaaa2222bbbb3"], AS2 events 528 AWS Transfer Family "detail": { User Guide "mdn-subject": "Your Requested MDN Response re: Test run from Id 123456789abcde to partner ijklmnop987654", "s3-attributes": { "json-bucket": "amzn-s3-demo-bucket1", "file-key": "/as2Integ/TestOutboundWrongCert.dat", "file-bucket": "amzn-s3-demo-bucket2", "json-key": "/as2Integ/failed/TestOutboundWrongCert.dat.json" }, "mdn-message-id": "MDN-message-ID", "end-timestamp": "2024-02-06T22:05:09.479878Z", "as2-from": "PartnerA", "as2-message-id": "as2-message-ID", "connector-id": "c-1234abcd5678efghj", "message-subject": "Test run from Id 123456789abcde to partner ijklmnop987654", "start-timestamp": "2024-02-06T22:05:03Z", "failure-code": "VERIFICATION_FAILED_NO_MATCHING_KEY_FOUND", "status-code": "FAILED", "as2-to": "MyCompany", "failure-message": "No public certificate matching message signature could be found in profile: p-1234abcd5678efghj", "transfer-id": "transfer-ID" } } AS2 events 529 AWS Transfer Family User Guide Security in AWS Transfer Family Cloud security at AWS is the highest priority. As an AWS customer, you benefit from a data center and network architecture that is built to meet the requirements of the most security-sensitive organizations. Security is a shared responsibility between AWS and you. The shared responsibility model describes this as security of the cloud and security in the cloud: To learn whether an AWS service is within the scope of specific compliance programs, see AWS services in Scope by Compliance Program and choose the compliance program that you are interested in. For general
|
transferfamily-ug-152
|
transferfamily-ug.pdf
| 152 |
Family User Guide Security in AWS Transfer Family Cloud security at AWS is the highest priority. As an AWS customer, you benefit from a data center and network architecture that is built to meet the requirements of the most security-sensitive organizations. Security is a shared responsibility between AWS and you. The shared responsibility model describes this as security of the cloud and security in the cloud: To learn whether an AWS service is within the scope of specific compliance programs, see AWS services in Scope by Compliance Program and choose the compliance program that you are interested in. For general information, see AWS Compliance Programs. You can download third-party audit reports using AWS Artifact. For more information, see Downloading Reports in AWS Artifact. Your compliance responsibility when using AWS services is determined by the sensitivity of your data, your company's compliance objectives, and applicable laws and regulations. AWS provides the following resources to help with compliance: • Security Compliance & Governance – These solution implementation guides discuss architectural considerations and provide steps for deploying security and compliance features. • HIPAA Eligible Services Reference – Lists HIPAA eligible services. Not all AWS services are HIPAA eligible. • AWS Compliance Resources – This collection of workbooks and guides might apply to your industry and location. • AWS Customer Compliance Guides – Understand the shared responsibility model through the lens of compliance. The guides summarize the best practices for securing AWS services and map the guidance to security controls across multiple frameworks (including National Institute of Standards and Technology (NIST), Payment Card Industry Security Standards Council (PCI), and International Organization for Standardization (ISO)). • Evaluating Resources with Rules in the AWS Config Developer Guide – The AWS Config service assesses how well your resource configurations comply with internal practices, industry guidelines, and regulations. • AWS Security Hub – This AWS service provides a comprehensive view of your security state within AWS. Security Hub uses security controls to evaluate your AWS resources and to check your 530 AWS Transfer Family User Guide compliance against security industry standards and best practices. For a list of supported services and controls, see Security Hub controls reference. • Amazon GuardDuty – This AWS service detects potential threats to your AWS accounts, workloads, containers, and data by monitoring your environment for suspicious and malicious activities. GuardDuty can help you address various compliance requirements, like PCI DSS, by meeting intrusion detection requirements mandated by certain compliance frameworks. • AWS Audit Manager – This AWS service helps you continuously audit your AWS usage to simplify how you manage risk and compliance with regulations and industry standards. This documentation helps you understand how to apply the shared responsibility model when using AWS Transfer Family. The following topics show you how to configure AWS Transfer Family to meet your security and compliance objectives. You also learn how to use other AWS services that help you to monitor and secure your AWS Transfer Family resources. We offer a workshop that provides prescriptive guidance and a hands on lab on how you can build a scalable and secure file transfer architecture on AWS without needing to modify existing applications or manage server infrastructure. You can view the details for this workshop here. Topics • Security policies for AWS Transfer Family servers • Security policies for AWS Transfer Family SFTP connectors • Using hybrid post-quantum key exchange with AWS Transfer Family • Data protection and encryption • Managing SSH and PGP keys in Transfer Family • Identity and access management for AWS Transfer Family • Compliance validation for AWS Transfer Family • Resilience in AWS Transfer Family • Infrastructure security in AWS Transfer Family • Add a web application firewall • Cross-service confused deputy prevention • AWS managed policies for AWS Transfer Family 531 AWS Transfer Family User Guide Security policies for AWS Transfer Family servers Server security policies in AWS Transfer Family allow you to limit the set of cryptographic algorithms (message authentication codes (MACs), key exchanges (KEXs), and cipher suites) associated with your server. For a list of supported cryptographic algorithms, see Cryptographic algorithms. For a list of supported key algorithms for use with server host keys and service- managed user keys, see Managing SSH and PGP keys in Transfer Family. Note We strongly recommend updating your servers to our latest security policy. • TransferSecurityPolicy-2024-01 is the default security policy attached to your server when creating a server using the console, API, or CLI. • If you create a Transfer Family server using CloudFormation and accept the default security policy, the server is assigned TransferSecurityPolicy-2018-11. If you are concerned about client compatibility, please affirmatively state which security policy you wish to use when creating or updating a server rather than using the default policy, which is subject to change. To change the security policy
|
transferfamily-ug-153
|
transferfamily-ug.pdf
| 153 |
SSH and PGP keys in Transfer Family. Note We strongly recommend updating your servers to our latest security policy. • TransferSecurityPolicy-2024-01 is the default security policy attached to your server when creating a server using the console, API, or CLI. • If you create a Transfer Family server using CloudFormation and accept the default security policy, the server is assigned TransferSecurityPolicy-2018-11. If you are concerned about client compatibility, please affirmatively state which security policy you wish to use when creating or updating a server rather than using the default policy, which is subject to change. To change the security policy for a server, see Edit the security policy. For more information on security in Transfer Family, see the following blog posts: • Six tips to improve the security of your AWS Transfer Family server • How Transfer Family can help you build a secure, compliant managed file transfer solution Topics • Cryptographic algorithms • TransferSecurityPolicy-2024-01 • TransferSecurityPolicy-SshAuditCompliant-2025-02 • TransferSecurityPolicy-2023-05 • TransferSecurityPolicy-2022-03 • TransferSecurityPolicy-2020-06 and TransferSecurityPolicy-Restricted-2020-06 Security policies for servers 532 AWS Transfer Family User Guide • TransferSecurityPolicy-2018-11 and TransferSecurityPolicy-Restricted-2018-11 • TransferSecurityPolicy-FIPS-2024-01/TransferSecurityPolicy-FIPS-2024-05 • TransferSecurityPolicy-FIPS-2023-05 • TransferSecurityPolicy-FIPS-2020-06 • Post Quantum security policies Cryptographic algorithms For host keys, we support the following algorithms: • rsa-sha2-256 • rsa-sha2-512 • ecdsa-sha2-nistp256 • ecdsa-sha2-nistp384 • ecdsa-sha2-nistp521 • ssh-ed25519 Additionally, the following security policies allow ssh-rsa: • TransferSecurityPolicy-2018-11 • TransferSecurityPolicy-2020-06 • TransferSecurityPolicy-FIPS-2020-06 • TransferSecurityPolicy-FIPS-2023-05 • TransferSecurityPolicy-FIPS-2024-01 • TransferSecurityPolicy-PQ-SSH-FIPS-Experimental-2023-04 Note It is important to understand the distinction between the RSA key type—which is always ssh-rsa—and the RSA host key algorithm, which can be any of the supported algorithms. The following is a list of supported cryptographic algorithms for each security policy. Cryptographic algorithms 533 AWS Transfer Family Note User Guide In the following table and policies, note the following use of algorithm types. • SFTP servers only use algorithms in the SshCiphers, SshKexs, and SshMacs sections. • FTPS servers only use algorithms in the TlsCiphers section. • FTP servers, since they don't use encryption, do not use any of these algorithms. • The FIPS-2024-05 and FIPS-2024-01 security policies are identical, except that FIPS-2024-05 doesn't support the ssh-rsa algorithm. • Transfer Family has introduced new restricted policies that closely parallel existing policies: • The TransferSecurityPolicy-Restricted-2018-11 and TransferSecurityPolicy-2018-11 security policies are identical, except that the restricted policy doesn't support the [email protected] cipher. • The TransferSecurityPolicy-Restricted-2020-06 and TransferSecurityPolicy-2020-06 security policies are identical, except that the restricted policy doesn't support the [email protected] cipher. *In the following table, the [email protected] cipher is included in the non-restricted policy only, Security policy 2024-01 SshAuditC ompliant- 2025-02 2023-05 2022-03 2020-06 SshCiphers aes128- ctr aes128- gc ♦ ♦ ♦ ♦ ♦ ♦ FIPS-2024 -05 FIPS-2023 -05 FIPS-2020 -06 2018-11 2020-06 restricte d ♦ ♦ FIPS-2024 -01 ♦ ♦ ♦ ♦ ♦ 2018-11 restricte d ♦ ♦ Cryptographic algorithms 534 AWS Transfer Family User Guide Security policy 2024-01 SshAuditC ompliant- 2023-05 2022-03 2020-06 FIPS-2024 -05 FIPS-2023 -05 FIPS-2020 -06 2018-11 2025-02 2020-06 restricte FIPS-2024 2018-11 restricte -01 ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ d ♦ ♦ ♦ * ♦ d ♦ ♦ ♦ * ♦ ♦ ♦ m@openssh .com aes192- ctr aes256- ctr aes256- gc ♦ ♦ ♦ m@openssh .com chacha20- poly1305@ openssh.c om SshKexs curve2551 ♦ 9- sha256 curve2551 ♦ 9- sha256@ libssh.or g ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ Cryptographic algorithms 535 AWS Transfer Family User Guide Security policy 2024-01 SshAuditC ompliant- 2023-05 2022-03 2020-06 FIPS-2024 -05 FIPS-2023 -05 FIPS-2020 -06 2018-11 2025-02 2020-06 restricte FIPS-2024 d -01 2018-11 restricte d ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ diffie- he llman- gro up14- sha1 diffie- he llman- gro up14- sha2 56 diffie- he llman- gro up16- sha5 12 diffie- he llman- gro up18- sha5 12 Cryptographic algorithms 536 AWS Transfer Family User Guide Security policy 2024-01 SshAuditC ompliant- 2023-05 2022-03 2020-06 FIPS-2024 -05 FIPS-2023 -05 FIPS-2020 -06 2018-11 2025-02 2020-06 restricte FIPS-2024 2018-11 restricte ♦ ♦ ♦ ♦ ♦ ♦ ♦ d ♦ ♦ ♦ ♦ -01 ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ diffie- he llman- group- exchan ge- sha256 ecdh- sha2- nistp256 ecdh- sha2- nistp384 ecdh- sha2- nistp521 SshMacs hmac- sha1 d ♦ ♦ ♦ ♦ ♦ ♦ hmac- sha1- etm@open ssh.com hmac- sha2 -256 ♦ ♦ ♦ ♦ Cryptographic algorithms 537 AWS Transfer Family User Guide Security policy 2024-01 SshAuditC ompliant- 2023-05 2022-03 2020-06 FIPS-2024 -05 FIPS-2023 -05 FIPS-2020 -06 2018-11 2025-02 2020-06 restricte FIPS-2024 2018-11 restricte d ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ hmac- sha2 -256- etm@ openssh.c om ♦ ♦ ♦ ♦ ♦ hmac- sha2 -512 hmac- sha2 -512- etm@ openssh.c om umac-128- etm@opens sh.com umac-128@ openssh.c om umac-64- e tm@openss h.com -01 ♦ ♦ ♦ ♦ ♦ ♦ ♦
|
transferfamily-ug-154
|
transferfamily-ug.pdf
| 154 |
sha2- nistp521 SshMacs hmac- sha1 d ♦ ♦ ♦ ♦ ♦ ♦ hmac- sha1- etm@open ssh.com hmac- sha2 -256 ♦ ♦ ♦ ♦ Cryptographic algorithms 537 AWS Transfer Family User Guide Security policy 2024-01 SshAuditC ompliant- 2023-05 2022-03 2020-06 FIPS-2024 -05 FIPS-2023 -05 FIPS-2020 -06 2018-11 2025-02 2020-06 restricte FIPS-2024 2018-11 restricte d ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ hmac- sha2 -256- etm@ openssh.c om ♦ ♦ ♦ ♦ ♦ hmac- sha2 -512 hmac- sha2 -512- etm@ openssh.c om umac-128- etm@opens sh.com umac-128@ openssh.c om umac-64- e tm@openss h.com -01 ♦ ♦ ♦ ♦ ♦ ♦ ♦ d ♦ ♦ ♦ ♦ ♦ ♦ Cryptographic algorithms 538 AWS Transfer Family User Guide Security policy 2024-01 SshAuditC ompliant- 2023-05 2022-03 2020-06 FIPS-2024 -05 FIPS-2023 -05 FIPS-2020 -06 2018-11 2025-02 2020-06 restricte FIPS-2024 d -01 2018-11 restricte d ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ umac-64@o penssh.co m TlsCiphers TLS_ECDHE ♦ _ECDSA_WI TH_AES_12 8_CBC_SHA 256 TLS_ECDHE ♦ _ECDSA_WI TH_AES_12 8_GCM_SHA 256 TLS_ECDHE ♦ _ECDSA_WI TH_AES_25 6_CBC_SHA 384 TLS_ECDHE ♦ _ECDSA_WI TH_AES_25 6_GCM_SHA 384 Cryptographic algorithms 539 AWS Transfer Family User Guide Security policy 2024-01 SshAuditC ompliant- 2023-05 2022-03 2020-06 FIPS-2024 -05 FIPS-2023 -05 FIPS-2020 -06 2018-11 2025-02 ♦ ♦ ♦ 2020-06 restricte FIPS-2024 d ♦ -01 ♦ ♦ ♦ 2018-11 restricte d ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ TLS_ECDHE ♦ _RSA_WITH _AES_128_ CBC_SHA25 6 TLS_ECDHE ♦ _RSA_WITH _AES_128_ GCM_SHA25 6 TLS_ECDHE ♦ _RSA_WITH _AES_256_ CBC_SHA38 4 TLS_ECDHE ♦ _RSA_WITH _AES_256_ GCM_SHA38 4 TLS_RSA_W ITH_AES_1 28_CBC_SH A256 Cryptographic algorithms 540 AWS Transfer Family User Guide Security policy 2024-01 SshAuditC ompliant- 2023-05 2022-03 2020-06 FIPS-2024 -05 FIPS-2023 -05 FIPS-2020 -06 2018-11 2025-02 2020-06 restricte FIPS-2024 d -01 2018-11 restricte d ♦ TLS_RSA_W ITH_AES_2 56_CBC_SH A256 TransferSecurityPolicy-2024-01 The following shows the TransferSecurityPolicy-2024-01 security policy. { "SecurityPolicy": { "Fips": false, "SecurityPolicyName": "TransferSecurityPolicy-2024-01", "SshCiphers": [ "[email protected]", "[email protected]", "aes128-ctr", "aes256-ctr", "aes192-ctr" ], "SshKexs": [ "ecdh-sha2-nistp256", "ecdh-sha2-nistp384", "ecdh-sha2-nistp521", "curve25519-sha256", "[email protected]", "diffie-hellman-group18-sha512", "diffie-hellman-group16-sha512", "diffie-hellman-group-exchange-sha256" ], "SshMacs": [ "[email protected]", "[email protected]" ], "TlsCiphers": [ TransferSecurityPolicy-2024-01 541 AWS Transfer Family User Guide "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384" ] } } TransferSecurityPolicy-SshAuditCompliant-2025-02 The following shows the TransferSecurityPolicy-SshAuditCompliant-2025-02 security policy. Note This security policy is designed around the recommendations provided by the ssh-audit tool, and is 100% compliant with that tool. { "SecurityPolicy": { "Fips": false, "Protocols": [ "SFTP", "FTPS" ], "SecurityPolicyName": "TransferSecurityPolicy-SshAuditCompliant-2025-02", "SshCiphers": [ "[email protected]", "[email protected]", "aes128-ctr", "aes256-ctr", "aes192-ctr" ], "SshKexs": [ "curve25519-sha256", "[email protected]", "diffie-hellman-group18-sha512", "diffie-hellman-group16-sha512", TransferSecurityPolicy-SshAuditCompliant-2025-02 542 AWS Transfer Family User Guide "diffie-hellman-group-exchange-sha256" ], "SshMacs": [ "[email protected]", "[email protected]" ], "TlsCiphers": [ "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384" ], "Type": "SERVER" } } TransferSecurityPolicy-2023-05 The following shows the TransferSecurityPolicy-2023-05 security policy. { "SecurityPolicy": { "Fips": false, "SecurityPolicyName": "TransferSecurityPolicy-2023-05", "SshCiphers": [ "[email protected]", "[email protected]", "aes256-ctr", "aes192-ctr" ], "SshKexs": [ "curve25519-sha256", "[email protected]", "diffie-hellman-group16-sha512", "diffie-hellman-group18-sha512", "diffie-hellman-group-exchange-sha256" ], "SshMacs": [ "[email protected]", TransferSecurityPolicy-2023-05 543 AWS Transfer Family User Guide "[email protected]" ], "TlsCiphers": [ "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384" ] } } TransferSecurityPolicy-2022-03 The following shows the TransferSecurityPolicy-2022-03 security policy. { "SecurityPolicy": { "Fips": false, "SecurityPolicyName": "TransferSecurityPolicy-2022-03", "SshCiphers": [ "[email protected]", "[email protected]", "aes256-ctr", "aes192-ctr" ], "SshKexs": [ "curve25519-sha256", "[email protected]", "diffie-hellman-group16-sha512", "diffie-hellman-group18-sha512", "diffie-hellman-group-exchange-sha256" ], "SshMacs": [ "[email protected]", "[email protected]", "hmac-sha2-512", "hmac-sha2-256" ], "TlsCiphers": [ TransferSecurityPolicy-2022-03 544 AWS Transfer Family User Guide "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384" ] } } TransferSecurityPolicy-2020-06 and TransferSecurityPolicy- Restricted-2020-06 The following shows the TransferSecurityPolicy-2020-06 security policy. Note The TransferSecurityPolicy-Restricted-2020-06 and TransferSecurityPolicy-2020-06 security policies are identical, except that the restricted policy doesn't support the [email protected] cipher. { "SecurityPolicy": { "Fips": false, "SecurityPolicyName": "TransferSecurityPolicy-2020-06", "SshCiphers": [ "[email protected]", //Not included in TransferSecurityPolicy- Restricted-2020-06 "aes128-ctr", "aes192-ctr", "aes256-ctr", "[email protected]", "[email protected]" ], "SshKexs": [ "ecdh-sha2-nistp256", "ecdh-sha2-nistp384", "ecdh-sha2-nistp521", TransferSecurityPolicy-2020-06 and TransferSecurityPolicy-Restricted-2020-06 545 AWS Transfer Family User Guide "diffie-hellman-group-exchange-sha256", "diffie-hellman-group16-sha512", "diffie-hellman-group18-sha512", "diffie-hellman-group14-sha256" ], "SshMacs": [ "[email protected]", "[email protected]", "[email protected]", "[email protected]", "hmac-sha2-256", "hmac-sha2-512" ], "TlsCiphers": [ "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384" ] } } TransferSecurityPolicy-2018-11 and TransferSecurityPolicy- Restricted-2018-11 The following shows the TransferSecurityPolicy-2018-11 security policy. Note The TransferSecurityPolicy-Restricted-2018-11 and TransferSecurityPolicy-2018-11 security policies are identical, except that the restricted policy doesn't support the [email protected] cipher. { "SecurityPolicy": { "Fips": false, TransferSecurityPolicy-2018-11 and TransferSecurityPolicy-Restricted-2018-11 546 AWS Transfer Family User Guide "SecurityPolicyName": "TransferSecurityPolicy-2018-11", "SshCiphers": [ "[email protected]", //Not included in TransferSecurityPolicy- Restricted-2018-11 "aes128-ctr", "aes192-ctr", "aes256-ctr", "[email protected]", "[email protected]" ], "SshKexs": [ "curve25519-sha256", "[email protected]", "ecdh-sha2-nistp256", "ecdh-sha2-nistp384", "ecdh-sha2-nistp521", "diffie-hellman-group-exchange-sha256", "diffie-hellman-group16-sha512", "diffie-hellman-group18-sha512", "diffie-hellman-group14-sha256", "diffie-hellman-group14-sha1" ], "SshMacs": [ "[email protected]", "[email protected]", "[email protected]", "[email protected]", "[email protected]", "[email protected]", "[email protected]", "hmac-sha2-256", "hmac-sha2-512", "hmac-sha1" ], "TlsCiphers": [ "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384", "TLS_RSA_WITH_AES_128_CBC_SHA256", TransferSecurityPolicy-2018-11 and TransferSecurityPolicy-Restricted-2018-11 547 AWS Transfer Family User Guide "TLS_RSA_WITH_AES_256_CBC_SHA256" ] } } TransferSecurityPolicy-FIPS-2024-01/TransferSecurityPolicy- FIPS-2024-05 The following shows the TransferSecurityPolicy-FIPS-2024-01 and TransferSecurityPolicy- FIPS-2024-05 security policies. Note
|
transferfamily-ug-155
|
transferfamily-ug.pdf
| 155 |
restricted policy doesn't support the [email protected] cipher. { "SecurityPolicy": { "Fips": false, TransferSecurityPolicy-2018-11 and TransferSecurityPolicy-Restricted-2018-11 546 AWS Transfer Family User Guide "SecurityPolicyName": "TransferSecurityPolicy-2018-11", "SshCiphers": [ "[email protected]", //Not included in TransferSecurityPolicy- Restricted-2018-11 "aes128-ctr", "aes192-ctr", "aes256-ctr", "[email protected]", "[email protected]" ], "SshKexs": [ "curve25519-sha256", "[email protected]", "ecdh-sha2-nistp256", "ecdh-sha2-nistp384", "ecdh-sha2-nistp521", "diffie-hellman-group-exchange-sha256", "diffie-hellman-group16-sha512", "diffie-hellman-group18-sha512", "diffie-hellman-group14-sha256", "diffie-hellman-group14-sha1" ], "SshMacs": [ "[email protected]", "[email protected]", "[email protected]", "[email protected]", "[email protected]", "[email protected]", "[email protected]", "hmac-sha2-256", "hmac-sha2-512", "hmac-sha1" ], "TlsCiphers": [ "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384", "TLS_RSA_WITH_AES_128_CBC_SHA256", TransferSecurityPolicy-2018-11 and TransferSecurityPolicy-Restricted-2018-11 547 AWS Transfer Family User Guide "TLS_RSA_WITH_AES_256_CBC_SHA256" ] } } TransferSecurityPolicy-FIPS-2024-01/TransferSecurityPolicy- FIPS-2024-05 The following shows the TransferSecurityPolicy-FIPS-2024-01 and TransferSecurityPolicy- FIPS-2024-05 security policies. Note The FIPS service endpoint and TransferSecurityPolicy-FIPS-2024-01 and TransferSecurityPolicy-FIPS-2024-05 security policies are only available in some AWS Regions. For more information, see AWS Transfer Family endpoints and quotas in the AWS General Reference. The only difference between these two security policies is that TransferSecurityPolicy- FIPS-2024-01 supports the ssh-rsa algorithm, and TransferSecurityPolicy-FIPS-2024-05 doesn't. { "SecurityPolicy": { "Fips": true, "SecurityPolicyName": "TransferSecurityPolicy-FIPS-2024-01", "SshCiphers": [ "[email protected]", "[email protected]", "aes128-ctr", "aes256-ctr", "aes192-ctr" ], "SshKexs": [ "ecdh-sha2-nistp256", "ecdh-sha2-nistp384", "ecdh-sha2-nistp521", "diffie-hellman-group18-sha512", "diffie-hellman-group16-sha512", "diffie-hellman-group-exchange-sha256" TransferSecurityPolicy-FIPS-2024-01/TransferSecurityPolicy-FIPS-2024-05 548 User Guide AWS Transfer Family ], "SshMacs": [ "[email protected]", "[email protected]" ], "TlsCiphers": [ "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384" ] } } TransferSecurityPolicy-FIPS-2023-05 The FIPS certification details for AWS Transfer Family can be found at https://csrc.nist.gov/ projects/cryptographic-module-validation-program/validated-modules/search/all The following shows the TransferSecurityPolicy-FIPS-2023-05 security policy. Note The FIPS service endpoint and TransferSecurityPolicy-FIPS-2023-05 security policy is only available in some AWS Regions. For more information, see AWS Transfer Family endpoints and quotas in the AWS General Reference. { "SecurityPolicy": { "Fips": true, "SecurityPolicyName": "TransferSecurityPolicy-FIPS-2023-05", "SshCiphers": [ "[email protected]", "[email protected]", "aes256-ctr", "aes192-ctr" TransferSecurityPolicy-FIPS-2023-05 549 User Guide AWS Transfer Family ], "SshKexs": [ "diffie-hellman-group16-sha512", "diffie-hellman-group18-sha512", "diffie-hellman-group-exchange-sha256" ], "SshMacs": [ "[email protected]", "[email protected]" ], "TlsCiphers": [ "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384" ] } } TransferSecurityPolicy-FIPS-2020-06 The FIPS certification details for AWS Transfer Family can be found at https://csrc.nist.gov/ projects/cryptographic-module-validation-program/validated-modules/search/all The following shows the TransferSecurityPolicy-FIPS-2020-06 security policy. Note The FIPS service endpoint and TransferSecurityPolicy-FIPS-2020-06 security policy are only available in some AWS Regions. For more information, see AWS Transfer Family endpoints and quotas in the AWS General Reference. { "SecurityPolicy": { "Fips": true, "SecurityPolicyName": "TransferSecurityPolicy-FIPS-2020-06", TransferSecurityPolicy-FIPS-2020-06 550 User Guide AWS Transfer Family "SshCiphers": [ "aes128-ctr", "aes192-ctr", "aes256-ctr", "[email protected]", "[email protected]" ], "SshKexs": [ "ecdh-sha2-nistp256", "ecdh-sha2-nistp384", "ecdh-sha2-nistp521", "diffie-hellman-group-exchange-sha256", "diffie-hellman-group16-sha512", "diffie-hellman-group18-sha512", "diffie-hellman-group14-sha256" ], "SshMacs": [ "[email protected]", "[email protected]", "hmac-sha2-256", "hmac-sha2-512" ], "TlsCiphers": [ "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384" ] } } Post Quantum security policies This table lists the algorithms for the Transfer Family post quantum security policies. These polices are described in detail in Using hybrid post-quantum key exchange with AWS Transfer Family. The policy listings follow the table. Post Quantum security policies 551 AWS Transfer Family Note User Guide The earlier post quantum policies (TransferSecurityPolicy-PQ-SSH-Experimental-2023-04 and TransferSecurityPolicy-PQ-SSH-FIPS-Experimental-2023-04 are deprecated. We recommend that you use the new policies instead. Security policy SSH ciphers aes128-ctr [email protected] aes192-ctr aes256-ctr [email protected] KEXs mlkem768x25519-sha256 mlkem768nistp256-sha256 mlkem1024nistp384-sha384 diffie-hellman-group14-sha2 56 diffie-hellman-group16-sha5 12 diffie-hellman-group18-sha5 12 ecdh-sha2-nistp384 TransferSecurityPolicy-2025 -03 TransferSecurityPolicy-FIPS -2025-03 ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ Post Quantum security policies 552 AWS Transfer Family Security policy TransferSecurityPolicy-2025 -03 TransferSecurityPolicy-FIPS -2025-03 User Guide ecdh-sha2-nistp521 ecdh-sha2-nistp256 diffie-hellman-group-exchan ge-sha256 curve25519-sha256@ libssh.org curve25519-sha256 MACs hmac-sha2-256-etm@ openssh.com hmac-sha2-512-etm@ openssh.com TLS ciphers TLS_ECDHE_ECDSA_WI TH_AES_128_CBC_SHA256 TLS_ECDHE_ECDSA_WI TH_AES_128_GCM_SHA256 TLS_ECDHE_ECDSA_WI TH_AES_256_CBC_SHA384 TLS_ECDHE_ECDSA_WI TH_AES_256_GCM_SHA384 TLS_ECDHE_RSA_WITH _AES_128_CBC_SHA256 ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ Post Quantum security policies 553 AWS Transfer Family Security policy TransferSecurityPolicy-2025 -03 TransferSecurityPolicy-FIPS -2025-03 User Guide TLS_ECDHE_RSA_WITH _AES_128_GCM_SHA256 TLS_ECDHE_RSA_WITH _AES_256_CBC_SHA384 TLS_ECDHE_RSA_WITH _AES_256_GCM_SHA384 ♦ ♦ ♦ TransferSecurityPolicy-2025-03 ♦ ♦ ♦ The following shows the TransferSecurityPolicy-2025-03 security policy. { "SecurityPolicy": { "Fips": false, "SecurityPolicyName": "TransferSecurityPolicy-2025-03", "SshCiphers": [ "[email protected]", "[email protected]", "aes128-ctr", "aes256-ctr", "aes192-ctr" ], "SshKexs": [ "mlkem768x25519-sha256", "mlkem768nistp256-sha256", "mlkem1024nistp384-sha384", "ecdh-sha2-nistp256", "ecdh-sha2-nistp384", "ecdh-sha2-nistp521", "curve25519-sha256", "[email protected]", "diffie-hellman-group16-sha512", "diffie-hellman-group18-sha512", "diffie-hellman-group-exchange-sha256" ], "SshMacs": [ Post Quantum security policies 554 AWS Transfer Family User Guide "[email protected]", "[email protected]" ], "TlsCiphers": [ "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384" ], "Type": "SERVER", "Protocols": [ "SFTP", "FTPS" ] } } TransferSecurityPolicy-FIPS-2025-03 The following shows the TransferSecurityPolicy-FIPS-2025-03 security policy. { "SecurityPolicy": { "Fips": true, "SecurityPolicyName": "TransferSecurityPolicy-FIPS-2025-03", "SshCiphers": [ "[email protected]", "[email protected]", "aes256-ctr", "aes192-ctr", "aes128-ctr" ], "SshKexs": [ "mlkem768x25519-sha256", "mlkem768nistp256-sha256", "mlkem1024nistp384-sha384", "ecdh-sha2-nistp256", "ecdh-sha2-nistp384", "ecdh-sha2-nistp521", Post Quantum security policies 555 AWS Transfer Family User Guide "diffie-hellman-group-exchange-sha256", "diffie-hellman-group16-sha512", "diffie-hellman-group18-sha512" ], "SshMacs": [ "[email protected]", "[email protected]" ], "TlsCiphers": [ "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384" ], "Type": "SERVER", "Protocols": [ "SFTP", "FTPS" ] } } Security policies for AWS Transfer Family SFTP connectors SFTP connector security policies in AWS Transfer Family allow you to limit the set of cryptographic algorithms (message authentication codes (MACs), key exchanges (KEXs), and cipher suites) associated with your SFTP connector. The following is a list of supported cryptographic
|
transferfamily-ug-156
|
transferfamily-ug.pdf
| 156 |
"[email protected]", "aes256-ctr", "aes192-ctr", "aes128-ctr" ], "SshKexs": [ "mlkem768x25519-sha256", "mlkem768nistp256-sha256", "mlkem1024nistp384-sha384", "ecdh-sha2-nistp256", "ecdh-sha2-nistp384", "ecdh-sha2-nistp521", Post Quantum security policies 555 AWS Transfer Family User Guide "diffie-hellman-group-exchange-sha256", "diffie-hellman-group16-sha512", "diffie-hellman-group18-sha512" ], "SshMacs": [ "[email protected]", "[email protected]" ], "TlsCiphers": [ "TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256", "TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384", "TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384", "TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384" ], "Type": "SERVER", "Protocols": [ "SFTP", "FTPS" ] } } Security policies for AWS Transfer Family SFTP connectors SFTP connector security policies in AWS Transfer Family allow you to limit the set of cryptographic algorithms (message authentication codes (MACs), key exchanges (KEXs), and cipher suites) associated with your SFTP connector. The following is a list of supported cryptographic algorithms for each SFTP connector security policy. Note TransferSFTPConnectorSecurityPolicy-2024-03 is the default security policy that is applied to SFTP connectors. You can change the security policy for your connector. Select Connectors from the Transfer Family left navigation pane, and select your connector. Then select Edit in the Sftp configuration section. Security policies for SFTP connectors 556 AWS Transfer Family User Guide In the Cryptographic algorithm options section, choose any available security policy from the dropdown list in the Security Policy field. Security policy TransferSFTPConnec torSecurityPolicy- TransferSFTPConnec torSecurityPolicy- TransferSFTPConnec torSecurityPolicy- FIPS-2024-10 2024-03 2023-07 ♦ ♦ Ciphers aes128-ctr aes128-gc [email protected] aes192-ctr aes256-ctr aes256-gc [email protected] Kexs curve25519-sha256 curve25519- [email protected] diffie-hellman-gro up14-sha1 diffie-hellman-gro up16-sha512 diffie-hellman-gro up18-sha512 diffie-hellman-group- exchange-sha256 ecdh-sha2-nistp256 ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ Security policies for SFTP connectors 557 AWS Transfer Family Security policy TransferSFTPConnec torSecurityPolicy- TransferSFTPConnec torSecurityPolicy- TransferSFTPConnec torSecurityPolicy- FIPS-2024-10 2024-03 2023-07 User Guide ♦ ♦ ♦ ♦ ♦ ♦ ♦ ecdh-sha2-nistp384 ecdh-sha2-nistp521 Macs hmac-sha2-512- [email protected] hmac-sha2-256- [email protected] hmac-sha2-512 hmac-sha2-256 hmac-sha1 hmac-sha1-96 Host Key Algorithms rsa-sha2-256 rsa-sha2-512 ecdsa-sha2-nistp256 ecdsa-sha2-nistp384 ecdsa-sha2-nistp521 ssh-rsa ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ ♦ Security policies for SFTP connectors 558 AWS Transfer Family User Guide Using hybrid post-quantum key exchange with AWS Transfer Family Transfer Family supports a hybrid post-quantum key establishment option for the Secure Shell (SSH) protocol. Post-quantum key establishment is needed because it's already possible to record network traffic and save it for decryption in future by a quantum computer, which is called a store- now-harvest-later attack. You can use this option when you connect to Transfer Family for secure file transfers into and out of Amazon Simple Storage Service (Amazon S3) storage or Amazon Elastic File System (Amazon EFS). Post-quantum hybrid key establishment in SSH introduces post-quantum key establishment mechanisms, which it uses in conjunction with classical key exchange algorithms. SSH keys created with classical cipher suites are safe from brute-force attacks with current technology. However, classical encryption isn't expected to remain secure after the emergence of large-scale quantum computing in the future. If your organization relies on the long-term confidentiality of data passed over a Transfer Family connection, you should consider a plan to migrate to post-quantum cryptography before large- scale quantum computers become available for use. To protect data encrypted today against potential future attacks, AWS is participating with the cryptographic community in the development of quantum-resistant or post-quantum algorithms. We've implemented hybrid post-quantum key exchange cipher suites in Transfer Family that combine classic and post-quantum elements. These hybrid cipher suites are available for use on your production workloads in most AWS Regions. However, because the performance characteristics and bandwidth requirements of hybrid cipher suites are different from those of classic key exchange mechanisms, we recommend that you test them on your Transfer Family connections. Find out more about post-quantum cryptography in the Post-Quantum Cryptography security blog post. Contents • About post-quantum hybrid key exchange in SSH • How post-quantum hybrid key establishment works in Transfer Family • Why ML-KEM? Post-Quantum security policies 559 AWS Transfer Family User Guide • Post-quantum hybrid SSH key exchange and cryptographic requirements (FIPS 140) • Testing post-quantum hybrid key exchange in Transfer Family • Enable post-quantum hybrid key exchange on your SFTP endpoint • Set up an SFTP client that supports post-quantum hybrid key exchange • Confirm post-quantum hybrid key exchange in SFTP About post-quantum hybrid key exchange in SSH Transfer Family supports post-quantum hybrid key exchange cipher suites, which uses both the classical Elliptic Curve Diffie-Hellman (ECDH) key exchange algorithm, and ML-KEM. ML-KEM is a post-quantum public-key encryption and key-establishment algorithm that the National Institute for Standards and Technology(NIST) has designated as its first standard post-quantum key- agreement algorithm. The client and server still do an ECDH key exchange. Additionally, the server encapsulates a post- quantum shared secret to the client’s post-quantum KEM public key, which is advertised in the client’s SSH key exchange message. This strategy combines the high assurance of a classical key exchange with the security of the proposed post-quantum key exchanges, to help ensure that the handshakes are protected as long
|
transferfamily-ug-157
|
transferfamily-ug.pdf
| 157 |
Diffie-Hellman (ECDH) key exchange algorithm, and ML-KEM. ML-KEM is a post-quantum public-key encryption and key-establishment algorithm that the National Institute for Standards and Technology(NIST) has designated as its first standard post-quantum key- agreement algorithm. The client and server still do an ECDH key exchange. Additionally, the server encapsulates a post- quantum shared secret to the client’s post-quantum KEM public key, which is advertised in the client’s SSH key exchange message. This strategy combines the high assurance of a classical key exchange with the security of the proposed post-quantum key exchanges, to help ensure that the handshakes are protected as long as the ECDH or the post-quantum shared secret cannot be broken. How post-quantum hybrid key establishment works in Transfer Family AWS recently announced support for post-quantum key exchange in SFTP file transfers in AWS Transfer Family. Transfer Family securely scales business-to-business file transfers to AWS Storage services using SFTP and other protocols. SFTP is a more secure version of the File Transfer Protocol (FTP) that runs over SSH. The post-quantum key exchange support of Transfer Family raises the security bar for data transfers over SFTP. The post-quantum hybrid key exchange SFTP support in Transfer Family includes combining post- quantum algorithms ML-KEM-768, and ML-KEM-1024, with ECDH over P256, P384, or Curve25519 curves. The following corresponding SSH key exchange methods are specified in the post-quantum hybrid SSH key exchange draft. • mlkem768nistp256-sha256 • mlkem1024nistp384-sha384 About post-quantum hybrid key exchange in SSH 560 AWS Transfer Family • mlkem768x25519-sha256 Why ML-KEM? User Guide AWS is committed to supporting standardized, interoperable algorithms. ML-KEM is the only post-quantum key exchange algorithm standardized and approved by the NIST Post-Quantum Cryptography project. Standards bodies are already integrating ML-KEM into protocols. AWS already supports ML-KEM in TLS in some AWS API endpoints. As part of this commitment, AWS has submitted a draft proposal to the IETF for post-quantum cryptography that combines ML-KEM with NIST-approved curves like P256 for SSH. To help enhance security for our customers, the AWS implementation of the post-quantum key exchange in SFTP and SSH follows that draft. We plan to support future updates to it until our proposal is adopted by the IETF and becomes a standard. The new key exchange methods (listed in section How post-quantum hybrid key establishment works in Transfer Family) might change as the draft evolves towards standardization. Note Post-quantum algorithm support is currently available for post-quantum hybrid key exchange in TLS for AWS KMS ( see Using hybrid post-quantum TLS with AWS KMS),AWS Certificate Manager, and AWS Secrets Manager API endpoints. Post-quantum hybrid SSH key exchange and cryptographic requirements (FIPS 140) For customers that require FIPS compliance, Transfer Family provides FIPS-approved cryptography in SSH by using the AWS FIPS 140-certified, open-source cryptographic library, AWS-LC. The post- quantum hybrid key exchange methods supported in the TransferSecurityPolicy-FIPS-2025-03 in Transfer Family are FIPS approved according to NIST's SP 800-56Cr2 (section 2). The German Federal Office for Information Security ( BSI) and the Agence nationale de la sécurité des systèmes d'information (ANSSI) of France also recommend such post-quantum hybrid key exchange methods. Testing post-quantum hybrid key exchange in Transfer Family This section describes the steps you take to test post-quantum hybrid key exchange. How to test it 561 AWS Transfer Family User Guide 1. Enable post-quantum hybrid key exchange on your SFTP endpoint. 2. Use an SFTP client (such as Set up an SFTP client that supports post-quantum hybrid key exchange) that supports post-quantum hybrid key exchange by following the guidance in the aforementioned draft specification. 3. Transfer a file using a Transfer Family server. 4. Confirm post-quantum hybrid key exchange in SFTP. Enable post-quantum hybrid key exchange on your SFTP endpoint You can choose the SSH policy when you create a new SFTP server endpoint in Transfer Family, or by editing the Cryptographic algorithm options in an existing SFTP endpoint. The following snapshot shows an example of the AWS Management Console where you update the SSH policy. The SSH policy names that support post-quantum key exchange are TransferSecurityPolicy-2025-03 and TransferSecurityPolicy-FIPS-2025-03. For more details on Transfer Family policies, see Security policies for AWS Transfer Family servers. How to test it 562 AWS Transfer Family User Guide Set up an SFTP client that supports post-quantum hybrid key exchange After you select the correct post-quantum SSH policy in your SFTP Transfer Family endpoint, you can experiment with post-quantum SFTP in Transfer Family. Install the latest OpenSSH client (such as version 9.9) on your local system to test. Note Make sure that your client supports one or more of the ML-KEM algorithms listed earlier. You can view the supported algorithms for your version of OpenSSH by running this command: ssh -Q kex. You can run the example SFTP client to connect to your SFTP endpoint (for example, s-1111aaaa2222bbbb3.server.transfer.us-west-2.amazonaws.com) by using the post- quantum hybrid key exchange methods,
|
transferfamily-ug-158
|
transferfamily-ug.pdf
| 158 |
hybrid key exchange After you select the correct post-quantum SSH policy in your SFTP Transfer Family endpoint, you can experiment with post-quantum SFTP in Transfer Family. Install the latest OpenSSH client (such as version 9.9) on your local system to test. Note Make sure that your client supports one or more of the ML-KEM algorithms listed earlier. You can view the supported algorithms for your version of OpenSSH by running this command: ssh -Q kex. You can run the example SFTP client to connect to your SFTP endpoint (for example, s-1111aaaa2222bbbb3.server.transfer.us-west-2.amazonaws.com) by using the post- quantum hybrid key exchange methods, as shown in the following command. sftp -v -o \ KexAlgorithms=mlkem768x25519-sha256 \ -i username_private_key_PEM_file \ [email protected] In the previous command, replace the following items with your own information: • Replace username_private_key_PEM_file with the SFTP user's private key PEM-encoded file • Replace username with the SFTP user name • Replace server-id with the Transfer Family server ID • Replace region-id with the actual region where your Transfer Family server is located Confirm post-quantum hybrid key exchange in SFTP To confirm that post-quantum hybrid key exchange was used during an SSH connection for SFTP to Transfer Family, check the client output. Optionally, you can use a packet capture program. If you use the OpenSSH 9.9 client, the output should look similar to the following (omitting irrelevant information for brevity): How to test it 563 AWS Transfer Family User Guide % sftp -o KexAlgorithms=mlkem768x25519-sha256 -v -o IdentitiesOnly=yes - i username_private_key_PEM_file [email protected] west-2.amazonaws.com OpenSSH_9.9p2, OpenSSL 3.4.1 11 Feb 2025 debug1: Reading configuration data /Users/username/.ssh/config debug1: /Users/username/.ssh/config line 146: Applying options for * debug1: Reading configuration data /Users/username/.ssh/bastions-config debug1: Reading configuration data /opt/homebrew/etc/ssh/ssh_config debug1: Connecting to s-1111aaaa2222bbbb3.server.transfer.us-west-2.amazonaws.com [xxx.yyy.zzz.nnn] port 22. debug1: Connection established. [...] debug1: Local version string SSH-2.0-OpenSSH_9.9 debug1: Remote protocol version 2.0, remote software version AWS_SFTP_1.1 debug1: compat_banner: no match: AWS_SFTP_1.1 debug1: Authenticating to s-1111aaaa2222bbbb3.server.transfer.us- west-2.amazonaws.com:22 as 'username' debug1: load_hostkeys: fopen /Users/username/.ssh/known_hosts2: No such file or directory [...] debug1: SSH2_MSG_KEXINIT sent debug1: SSH2_MSG_KEXINIT received debug1: kex: algorithm: mlkem768x25519-sha256 debug1: kex: host key algorithm: ssh-ed25519 debug1: kex: server->client cipher: aes128-ctr MAC: [email protected] compression: none debug1: kex: client->server cipher: aes128-ctr MAC: [email protected] compression: none debug1: expecting SSH2_MSG_KEX_ECDH_REPLY debug1: SSH2_MSG_KEX_ECDH_REPLY received debug1: Server host key: ssh-ed25519 SHA256:Ic1Ti0cdDmFdStj06rfU0cmmNccwAha/ASH2unr6zX0 [...] debug1: rekey out after 4294967296 blocks debug1: SSH2_MSG_NEWKEYS sent debug1: expecting SSH2_MSG_NEWKEYS debug1: SSH2_MSG_NEWKEYS received debug1: rekey in after 4294967296 blocks [...] Authenticated to s-1111aaaa2222bbbb3.server.transfer.us-west-2.amazonaws.com ([xxx.yyy.zzz.nnn]:22) using "publickey". debug1: channel 0: new session [client-session] (inactive timeout: 0) [...] Connected to s-1111aaaa2222bbbb3.server.transfer.us-west-2.amazonaws.com. How to test it 564 AWS Transfer Family sftp> User Guide The output shows that client negotiation occurred using the post-quantum hybrid mlkem768x25519-sha256 method and successfully established an SFTP session. Data protection and encryption The AWS shared responsibility model applies to data protection in AWS Transfer Family (Transfer Family). As described in this model, AWS is responsible for protecting the global infrastructure that runs all of the AWS Cloud. You are responsible for maintaining control over your content that is hosted on this infrastructure. This content includes the security configuration and management tasks for the AWS services that you use. For more information about data privacy, see the Data privacy FAQ. For information about data protection in Europe, see the AWS shared responsibility model and GDPR blog post on the AWS Security Blog. For data protection purposes, we recommend that you protect AWS account credentials and set up individual user accounts with AWS IAM Identity Center. That way each user is given only the permissions necessary to fulfill their job duties. We also recommend that you secure your data in the following ways: • Use multi-factor authentication (MFA) with each account. • Use SSL/TLS to communicate with AWS resources. We support TLS 1.2. • Set up API and user activity logging with AWS CloudTrail. • Use AWS encryption solutions, along with all default security controls within AWS services. • Use advanced managed security services such as Amazon Macie, which assists in discovering and securing personal data that is stored in Amazon S3. • If you require FIPS 140-2 validated cryptographic modules when accessing AWS through a command line interface or an API, use a FIPS endpoint. For more information about the available FIPS endpoints, see Federal information processing standard (FIPS) 140-2. We strongly recommend that you never put sensitive identifying information, such as your customers' account numbers, into free-form fields such as a Name field. This includes when you work with Transfer Family or other AWS services using the console, API, AWS CLI, or AWS SDKs. Any configuration data that you enter into Transfer Family service configuration, or other services' configurations, might get picked up for inclusion in diagnostic logs. When you provide a URL to an Data protection 565 AWS Transfer Family User Guide external server, don't include credentials information in the URL to validate your
|
transferfamily-ug-159
|
transferfamily-ug.pdf
| 159 |
processing standard (FIPS) 140-2. We strongly recommend that you never put sensitive identifying information, such as your customers' account numbers, into free-form fields such as a Name field. This includes when you work with Transfer Family or other AWS services using the console, API, AWS CLI, or AWS SDKs. Any configuration data that you enter into Transfer Family service configuration, or other services' configurations, might get picked up for inclusion in diagnostic logs. When you provide a URL to an Data protection 565 AWS Transfer Family User Guide external server, don't include credentials information in the URL to validate your request to that server. In contrast, data from upload and download operations into and out of Transfer Family servers is treated as completely private and never exists outside of encrypted channels—such as an SFTP or FTPS connection. This data is only ever accessible to authorized persons. Data encryption AWS Transfer Family uses the default encryption options you set for your Amazon S3 bucket to encrypt your data. When you enable encryption on a bucket, all objects are encrypted when they are stored in the bucket. The objects are encrypted by using server-side encryption with either Amazon S3 managed keys (SSE-S3) or AWS Key Management Service (AWS KMS) managed keys (SSE-KMS). For information about server-side encryption, see Protecting data using server-side encryption in the Amazon Simple Storage Service User Guide. The following steps show you how to encrypt data in AWS Transfer Family. To allow encryption in AWS Transfer Family 1. Enable default encryption for your Amazon S3 bucket. For instructions, see Amazon S3 default encryption for S3 buckets in the Amazon Simple Storage Service User Guide. 2. Update the AWS Identity and Access Management (IAM) role policy that is attached to the user to grant the required AWS Key Management Service (AWS KMS) permissions. 3. If you are using a session policy for the user, the session policy must grant the required AWS KMS permissions. The following example shows an IAM policy that grants the minimum permissions required when using AWS Transfer Family with an Amazon S3 bucket that is enabled for AWS KMS encryption. Include this example policy in both the user IAM role policy and session policy, if you are using one. { "Sid": "Stmt1544140969635", "Action": [ "kms:Decrypt", "kms:Encrypt", "kms:GenerateDataKey", "kms:GetPublicKey", "kms:ListKeyPolicies" Data protection 566 AWS Transfer Family ], "Effect": "Allow", "Resource": "arn:aws:kms:region:account-id:key/kms-key-id" User Guide } Note The KMS key ID that you specify in this policy must be the same as the one specified for the default encryption in step 1. Root, or the IAM role that is used for the user, must be allowed in the AWS KMS key policy. For information about the AWS KMS key policy, see Using key policies in AWS KMS in the AWS Key Management Service Developer Guide. Managing SSH and PGP keys in Transfer Family In this section, you can find information about SSH keys, including how to generate them and how to rotate them. For details about using Transfer Family with AWS Lambda to manage keys, see the blog post Enabling user self-service key management with AAWS Transfer Family and AWS Lambda. Note AWS Transfer Family accepts RSA, ECDSA, and ED25519 keys. This section also covers how to generate and manage Pretty Good Privacy (PGP) keys. Topics • Generate SSH keys for service-managed users • Rotate SSH keys • Generate PGP keys • Manage PGP keys • Supported PGP clients Supported algorithms for user and server keys Key management 567 AWS Transfer Family User Guide The following key algorithms are supported for user and server key-pairs within AWS Transfer Family. Note For algorithms to use with PGP decryption in workflows, see Algorithms supported for PGP key-pairs. • For ED25519: ssh-ed25519 • For RSA: • rsa-sha2-256 • rsa-sha2-512 • For ECDSA: • ecdsa-sha2-nistp256 • ecdsa-sha2-nistp384 • ecdsa-sha2-nistp521 Note We support ssh-rsa with SHA1 for our older security policies. For details, see Cryptographic algorithms. Generate SSH keys for service-managed users You can set up your server to authenticate users using the service managed authentication method, where usernames and SSH keys are stored within the service. The user's public SSH key is uploaded to the server as a user's property. This key is used by the server as part of a standard key-based authentication process. Each user can have multiple public SSH keys on file with an individual server. For limits on number of keys that can be stored per user, see AWS Transfer Family endpoints and quotas in the Amazon Web Services General Reference. As an alternative to the service managed authentication method, you can authenticate users using a custom identity provider, or AWS Directory Service for Microsoft Active Directory. For Generate SSH keys 568 AWS Transfer Family User Guide more information, see Working with custom identity providers or Using AWS
|
transferfamily-ug-160
|
transferfamily-ug.pdf
| 160 |
is used by the server as part of a standard key-based authentication process. Each user can have multiple public SSH keys on file with an individual server. For limits on number of keys that can be stored per user, see AWS Transfer Family endpoints and quotas in the Amazon Web Services General Reference. As an alternative to the service managed authentication method, you can authenticate users using a custom identity provider, or AWS Directory Service for Microsoft Active Directory. For Generate SSH keys 568 AWS Transfer Family User Guide more information, see Working with custom identity providers or Using AWS Directory Service for Microsoft Active Directory. A server can only authenticate users using one method (service managed, directory service, or custom identity provider), and that method cannot be changed after the server is created. Topics • Creating SSH keys on macOS, Linux, or Unix • Creating SSH keys on Microsoft Windows • Converting an SSH2 key to SSH public key format Creating SSH keys on macOS, Linux, or Unix On the macOS, Linux, or Unix operating systems, you use the ssh-keygen command to create an SSH public key and SSH private key also known as a key pair. Note In the following examples, we do not specify a passphrase: in this case, the tool asks you to enter your passphrase and then repeat it to verify. Creating a passphrase offers better protection for your private key, and might also improve overall system security. You cannot recover your passphrase: if you forget it, you must create a new key. However, if you are generating a server host key, you must specify an empty passphrase, by specifying the -N "" option in the command (or by pressing Enter twice when prompted), because Transfer Family servers cannot request a password at start-up. To create SSH keys on a macOS, Linux, or Unix operating system 1. On macOS, Linux, or Unix operating systems, open a command terminal. 2. AWS Transfer Family accepts RSA-, ECDSA-, and ED25519-formatted keys. Choose the appropriate command based on the type of key-pair you are generating. Tip: Replace key_name with the actual name of your SSH key pair file. • To generate an RSA 4096-bit key pair: ssh-keygen -t rsa -b 4096 -f key_name Generate SSH keys 569 AWS Transfer Family User Guide • To generate an ECDSA 521-bit key-pair (ECDSA has bit sizes of 256, 384, and 521): ssh-keygen -t ecdsa -b 521 -f key_name • To generate an ED25519 key pair: ssh-keygen -t ed25519 -f key_name The following shows an example of the ssh-keygen output. ssh-keygen -t rsa -b 4096 -f key_name Generating public/private rsa key pair. Enter passphrase (empty for no passphrase): Enter same passphrase again: Your identification has been saved in key_name. Your public key has been saved in key_name.pub. The key fingerprint is: SHA256:8tDDwPmanTFcEzjTwPGETVWOGW1nVz+gtCCE8hL7PrQ bob.amazon.com The key's randomart image is: +---[RSA 4096]----+ | . ....E | | . = ... | |. . . = ..o | | . o + oo = | | + = .S.= * | | . o o ..B + o | | .o.+.* . | | =o*+*. | | ..*o*+. | +----[SHA256]-----+ Tip: When you run the ssh-keygen command as shown preceding, it creates the public and private keys as files in the current directory. Your SSH key pair is now ready to use. Follow steps 3 and 4 to store the SSH public key for your service-managed users. These users use the keys when they transfer files on Transfer Family server endpoints. 3. Navigate to the key_name.pub file and open it. Generate SSH keys 570 AWS Transfer Family User Guide 4. Copy the text and paste it in SSH public key for the service-managed user. a. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/, then select Servers from the navigation pane. b. On the Servers page, select the Server ID for server that contains the user that you want to update. c. d. Select the user for which you are adding a public key. In the SSH public keys pane, choose Add SSH public key. e. Paste the text of the public key you generated into the SSH public key text box, and then choose Add key. Generate SSH keys 571 AWS Transfer Family User Guide The new key is listed in the SSH public key pane. Creating SSH keys on Microsoft Windows Windows uses a slightly different SSH key pair format. The public key must be in the PUB format, and the private key must be in the PPK format. On Windows, you can use PuTTYgen to create an SSH key pair in the appropriate formats. You can also use PuTTYgen to convert a private key generated using ssh-keygen to a .ppk file. Note If you present WinSCP with a private key file not in .ppk
|
transferfamily-ug-161
|
transferfamily-ug.pdf
| 161 |
Generate SSH keys 571 AWS Transfer Family User Guide The new key is listed in the SSH public key pane. Creating SSH keys on Microsoft Windows Windows uses a slightly different SSH key pair format. The public key must be in the PUB format, and the private key must be in the PPK format. On Windows, you can use PuTTYgen to create an SSH key pair in the appropriate formats. You can also use PuTTYgen to convert a private key generated using ssh-keygen to a .ppk file. Note If you present WinSCP with a private key file not in .ppk format, that client offers to convert the key into .ppk format for you. For a tutorial about creating SSH keys by using PuTTYgen on Windows, see the SSH.com website. Generate SSH keys 572 AWS Transfer Family User Guide Converting an SSH2 key to SSH public key format AWS Transfer Family only accepts SSH-formatted public keys. If you have an SSH2 public key, you need to convert it. An SSH2 public key has the following format: ---- BEGIN SSH2 PUBLIC KEY ---- Comment: "rsa-key-20160402" AAAAB3NzaC1yc2EAAAABJQAAAgEAiL0jjDdFqK/kYThqKt7THrjABTPWvXmB3URI : : ---- END SSH2 PUBLIC KEY ---- An SSH public key has the following format: ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAA... Run the following command to convert an SSH2-formatted public key into an SSH-formatted public key. Replace ssh2-key with the name of your SSH2 key, and ssh-key with the name of your SSH key. ssh-keygen -i -f ssh2-key.pub > ssh-key.pub Rotate SSH keys For security, we recommend the best practice of rotating your SSH keys. Usually, this rotation is specified as a part of a security policy and is implemented in some automated fashion. Depending upon the level of security, for a highly sensitive communication, an SSH key pair might be used only once. Doing this eliminates any risk due to stored keys. However, it is much more common to store SSH credentials for a period of time and set an interval that doesn't place undue burden on users. A time interval of three months is common. There are two methods used to perform SSH key rotation: • On the console, you can upload a new SSH public key and delete an existing SSH public key. • Using the API, you can update existing users by using the DeleteSshPublicKey API to delete a user's Secure Shell (SSH) public key and the ImportSshPublicKey API to add a new Secure Shell (SSH) public key to the user's account. Rotate SSH keys 573 AWS Transfer Family Console To perform a key rotation in the console User Guide 1. Open the AWS Transfer Family console at https://console.aws.amazon.com/transfer/. 2. Navigate to the Servers page. 3. Choose the identifier in the Server ID column to see the Server details page. 4. Under Users, select the check box of the user whose SSH public key that you want to rotate, then choose Actions, and then choose Add key to see the Add key page. or Choose the username to see the User details page, and then choose Add SSH public key to see the Add key page. 5. Enter the new SSH public key and choose Add key. Important The format of the SSH public key depends on the type of key you generated. • For RSA keys, the format is ssh-rsa string. • For ED25519 keys, the format is ssh-ed25519 string. • For ECDSA keys, the key begins with ecdsa-sha2-nistp256, ecdsa-sha2- nistp384, or ecdsa-sha2-nistp521, depending on the size of the key you generated. The beginning string is then followed by string, similar to the other key types. You are returned to the User details page, and the new SSH public key that you just entered appears in the SSH public keys section. 6. Select the check box of the old you key that you want to delete and then choose Delete. 7. Confirm the deletion operation by entering the word delete, and then choose Delete. Rotate SSH keys 574 AWS Transfer Family API To perform a key rotation using the API User Guide 1. On macOS, Linux, or Unix operating systems, open a command terminal. 2. Retrieve the SSH key that you want to delete by entering the following command. To use this command, replace serverID with the server ID for your Transfer Family server, and replace username with your username. aws transfer describe-user --server-id='serverID' --user-name='username' The command returns details about the user. Copy the contents of the "SshPublicKeyId": field. You will need to enter this value later in this procedure. "SshPublicKeys": [ { "SshPublicKeyBody": "public-key", "SshPublicKeyId": "keyID", "DateImported": 1621969331.072 } ], 3. Next, import a new SSH key for your user. At the prompt, enter the following command. To use this command, replace serverID with the server ID for your Transfer Family server, replace username with your username, and replace public-key with the fingerprint
|
transferfamily-ug-162
|
transferfamily-ug.pdf
| 162 |
serverID with the server ID for your Transfer Family server, and replace username with your username. aws transfer describe-user --server-id='serverID' --user-name='username' The command returns details about the user. Copy the contents of the "SshPublicKeyId": field. You will need to enter this value later in this procedure. "SshPublicKeys": [ { "SshPublicKeyBody": "public-key", "SshPublicKeyId": "keyID", "DateImported": 1621969331.072 } ], 3. Next, import a new SSH key for your user. At the prompt, enter the following command. To use this command, replace serverID with the server ID for your Transfer Family server, replace username with your username, and replace public-key with the fingerprint of your new public key. aws transfer import-ssh-public-key --server-id='serverID' --user-name='username' --ssh-public-key-body='public-key' If the command is successful, no output is returned. 4. Finally, delete the old key by running the following command. To use this command, replace serverID with the server ID for your Transfer Family server, replace username with your username, and replace keyID-from-step-2 with the key ID value that you copied in step 2 of this procedure aws transfer delete-ssh-public-key --server-id='serverID' --user-name='username' --ssh-public-key-id='keyID-from-step-2' 5. (Optional) To confirm that the old key no longer exists, repeat step 2. Rotate SSH keys 575 AWS Transfer Family Generate PGP keys User Guide You can use Pretty Good Privacy (PGP) decryption with the files that Transfer Family processes with workflows. To use decryption in a workflow step, provide a PGP key. The AWS storage blog has a post that describes how to simply decrypt files without writing any code using Transfer Family Managed workflows, Encrypt and decrypt files with PGP and AWS Transfer Family. The operator that you use to generate your PGP keys depends on your operating system and the version of the key-generation software that you're using. If you're using Linux or Unix, use your package installer to install gpg. Depending on your Linux distribution, one of the following commands should work for you. sudo yum install gnupg sudo apt-get install gnupg For Windows or macOS, you can download what you need from https://gnupg.org/download/. After you install your PGP key generator software, you run the gpg --full-gen-key or gpg -- gen-key command to generate a key pair. Note If you're using GnuPG version 2.3.0 or newer, you must run gpg --full-gen-key. When prompted for the type of key to create, choose RSA or ECC. However, if you choose ECC, make sure to choose either NIST or BrainPool for the elliptic curve. Do not choose Curve 25519. Algorithms supported for PGP key-pairs We support the following algorithms for PGP key pairs: • RSA • Elgamal Generate PGP keys 576 User Guide AWS Transfer Family • ECC: • NIST • BrainPool Note We don't support cCurve25519 keys. Useful gpg subcommands The following are some useful subcommands for gpg: • gpg --help – This command lists the available options and might include some examples. • gpg --list-keys – This command lists the details for all the key pairs that you have created. • gpg --fingerprint – This command lists the details for all your key pairs, including each key's fingerprint. • gpg --export -a user-name – This command exports the public key portion of the key for the user-name that was used when the key was generated. Manage PGP keys To manage your PGP keys, use AWS Secrets Manager. Note Your secret name includes your Transfer Family server ID. This means you should have already identified or created a server before you can store your PGP key information in AWS Secrets Manager. If you want to use one key and passphrase for all of your users, you can store the PGP key block information under the secret name aws/transfer/server-id/@pgp-default, where server- id is the ID for your Transfer Family server. Transfer Family uses this default key if there is no key where the user-name matches the user that's executing the workflow. Manage PGP keys 577 AWS Transfer Family User Guide You can create a key for a specific user. In this case, the format for the secret name is aws/ transfer/server-id/user-name, where user-name matches the user that's running the workflow for a Transfer Family server. Note You can store a maximum of 3 PGP private keys, per Transfer Family server, per user. To configure PGP keys for use with decryption 1. Depending on the version of GPG that you are using, run one of the following commands to generate a PGP key pair that doesn't use a Curve 25519 encryption algorithm. • If you are using GnuPG version 2.3.0 or newer, run the following command: gpg --full-gen-key You can choose RSA, or, if you choose ECC, you can choose either NIST or BrainPool for the elliptic curve. If you run gpg --gen-key instead, you create a key pair that uses the ECC Curve 25519 encryption algorithm, which we don't currently support for PGP keys.
|
transferfamily-ug-163
|
transferfamily-ug.pdf
| 163 |
PGP keys for use with decryption 1. Depending on the version of GPG that you are using, run one of the following commands to generate a PGP key pair that doesn't use a Curve 25519 encryption algorithm. • If you are using GnuPG version 2.3.0 or newer, run the following command: gpg --full-gen-key You can choose RSA, or, if you choose ECC, you can choose either NIST or BrainPool for the elliptic curve. If you run gpg --gen-key instead, you create a key pair that uses the ECC Curve 25519 encryption algorithm, which we don't currently support for PGP keys. • For versions of GnuPG prior to 2.3.0, you can use the following command, since RSA is the default encryption type. gpg --gen-key Important During the key-generation process, you must provide a passphrase and an email address. Make sure to take note of these values. You must provide the passphrase when you enter the key's details into AWS Secrets Manager later in this procedure. And you must provide the same email address to export the private key in the next step. 2. Run the following command to export the private key. To use this command, replace private.pgp with the name of the file in which to save the private key block, and [email protected] with the email address that you used when you generated the key pair. Manage PGP keys 578 AWS Transfer Family User Guide gpg --output private.pgp --armor --export-secret-key [email protected] 3. Use AWS Secrets Manager to store your PGP key. a. Sign in to the AWS Management Console and open the AWS Secrets Manager console at https://console.aws.amazon.com/secretsmanager/. b. In the left navigation pane, choose Secrets. c. On the Secrets page, choose Store a new secret. d. On the Choose secret type page, for Secret type, select Other type of secret. e. In the Key/value pairs section, choose the Key/value tab. • Key – Enter PGPPrivateKey. Note You must enter the PGPPrivateKey string exactly: do not add any spaces before or between characters. • value – Paste the text of your private key into the value field. You can find the text of your private key in the file (for example, private.pgp) that you specified when you exported your key earlier in this procedure. The key begins with -----BEGIN PGP PRIVATE KEY BLOCK----- and ends with -----END PGP PRIVATE KEY BLOCK-----. Note Make sure that the text block contains only the private key and does not contain the public key as well. f. Select Add row and in the Key/value pairs section, choose the Key/value tab. • Key – Enter PGPPassphrase. Note You must enter the PGPPassphrase string exactly: do not add any spaces before or between characters. Manage PGP keys 579 AWS Transfer Family User Guide • value – Enter the passphrase you used when you generated your PGP key pair. Note You can add up to 3 sets of keys and passphrases. To add a second set, add two new rows, and enter PGPPrivateKey2 and PGPPassphrase2 for the keys, and paste in another private key and passphrase. To add a third set, key values must be PGPPrivateKey3 and PGPPassphrase3. g. Choose Next. h. On the Configure secret page, enter a name and description for your secret. • If you're creating a default key, that is, a key that can be used by any Transfer Family user, enter aws/transfer/server-id/@pgp-default. Replace server-id with the ID of the server that contains the workflow that has a decrypt step. • If you're creating a key to be used by a specific Transfer Family user, enter aws/ transfer/server-id/user-name. Replace server-id with the ID of the server that contains the workflow that has a decrypt step, and replace user-name with the Manage PGP keys 580 AWS Transfer Family User Guide name of the user that's running the workflow. The user-name is stored in the identity provider that the Transfer Family server is using. i. Choose Next and accept the defaults on the Configure rotation page. Then choose Next. j. On the Review page, choose Store to create and store the secret. The following screenshot shows the details for the user marymajor for a specific Transfer Family server. This example shows three keys and their corresponding passphrases. Supported PGP clients The following clients have been tested with Transfer Family and can be used to generate PGP keys, and to encrypt files that you intend to decrypt with a workflow. • Gpg4win + Kleopatra. Note When you select Sign / Encrypt Files, make sure to clear the selection for Sign as: we do not currently support signing for encrypted files. Supported PGP clients 581 AWS Transfer Family User Guide If you sign the encrypted file and attempt to upload it to a Transfer Family server with a decryption workflow, you receive the following error: Encrypted file
|
transferfamily-ug-164
|
transferfamily-ug.pdf
| 164 |
corresponding passphrases. Supported PGP clients The following clients have been tested with Transfer Family and can be used to generate PGP keys, and to encrypt files that you intend to decrypt with a workflow. • Gpg4win + Kleopatra. Note When you select Sign / Encrypt Files, make sure to clear the selection for Sign as: we do not currently support signing for encrypted files. Supported PGP clients 581 AWS Transfer Family User Guide If you sign the encrypted file and attempt to upload it to a Transfer Family server with a decryption workflow, you receive the following error: Encrypted file with signed message unsupported • Major GnuPG versions: 2.4, 2.3, 2.2, 2.0, and 1.4. Note that other PGP clients might work as well, but only the clients mentioned here have been tested with Transfer Family. Identity and access management for AWS Transfer Family AWS Identity and Access Management (IAM) is an AWS service that helps an administrator securely control access to AWS resources. IAM administrators control who can be authenticated (signed in) Identity and access management 582 AWS Transfer Family User Guide and authorized (have permissions) to use AWS Transfer Family resources. IAM is an AWS service that you can use with no additional charge. Topics • Audience • Authenticating with identities • Managing access using policies • How AWS Transfer Family works with IAM • AWS Transfer Family identity-based policy examples • AWS Transfer Family tag-based policy examples • Troubleshooting AWS Transfer Family identity and access Audience How you use AWS Identity and Access Management (IAM) differs, depending on the work that you do in AWS Transfer Family. Service user – If you use the AWS Transfer Family service to do your job, then your administrator provides you with the credentials and permissions that you need. As you use more AWS Transfer Family features to do your work, you might need additional permissions. Understanding how access is managed can help you request the right permissions from your administrator. If you cannot access a feature in AWS Transfer Family, see Troubleshooting AWS Transfer Family identity and access. Service administrator – If you're in charge of AWS Transfer Family resources at your company, you probably have full access to AWS Transfer Family. It's your job to determine which AWS Transfer Family features and resources your service users should access. You must then submit requests to your IAM administrator to change the permissions of your service users. Review the information on this page to understand the basic concepts of IAM. To learn more about how your company can use IAM with AWS Transfer Family, see How AWS Transfer Family works with IAM. IAM administrator – If you're an IAM administrator, you might want to learn details about how you can write policies to manage access to AWS Transfer Family. To view example AWS Transfer Family identity-based policies that you can use in IAM, see AWS Transfer Family identity-based policy examples. Audience 583 AWS Transfer Family User Guide Authenticating with identities Authentication is how you sign in to AWS using your identity credentials. You must be authenticated (signed in to AWS) as the AWS account root user, as an IAM user, or by assuming an IAM role. You can sign in to AWS as a federated identity by using credentials provided through an identity source. AWS IAM Identity Center (IAM Identity Center) users, your company's single sign-on authentication, and your Google or Facebook credentials are examples of federated identities. When you sign in as a federated identity, your administrator previously set up identity federation using IAM roles. When you access AWS by using federation, you are indirectly assuming a role. Depending on the type of user you are, you can sign in to the AWS Management Console or the AWS access portal. For more information about signing in to AWS, see How to sign in to your AWS account in the AWS Sign-In User Guide. If you access AWS programmatically, AWS provides a software development kit (SDK) and a command line interface (CLI) to cryptographically sign your requests by using your credentials. If you don't use AWS tools, you must sign requests yourself. For more information about using the recommended method to sign requests yourself, see AWS Signature Version 4 for API requests in the IAM User Guide. Regardless of the authentication method that you use, you might be required to provide additional security information. For example, AWS recommends that you use multi-factor authentication (MFA) to increase the security of your account. To learn more, see Multi-factor authentication in the AWS IAM Identity Center User Guide and AWS Multi-factor authentication in IAM in the IAM User Guide. AWS account root user When you create an AWS account, you begin with one sign-in identity that has complete access to all AWS services and resources
|
transferfamily-ug-165
|
transferfamily-ug.pdf
| 165 |
requests yourself, see AWS Signature Version 4 for API requests in the IAM User Guide. Regardless of the authentication method that you use, you might be required to provide additional security information. For example, AWS recommends that you use multi-factor authentication (MFA) to increase the security of your account. To learn more, see Multi-factor authentication in the AWS IAM Identity Center User Guide and AWS Multi-factor authentication in IAM in the IAM User Guide. AWS account root user When you create an AWS account, you begin with one sign-in identity that has complete access to all AWS services and resources in the account. This identity is called the AWS account root user and is accessed by signing in with the email address and password that you used to create the account. We strongly recommend that you don't use the root user for your everyday tasks. Safeguard your root user credentials and use them to perform the tasks that only the root user can perform. For the complete list of tasks that require you to sign in as the root user, see Tasks that require root user credentials in the IAM User Guide. Authenticating with identities 584 AWS Transfer Family Federated identity User Guide As a best practice, require human users, including users that require administrator access, to use federation with an identity provider to access AWS services by using temporary credentials. A federated identity is a user from your enterprise user directory, a web identity provider, the AWS Directory Service, the Identity Center directory, or any user that accesses AWS services by using credentials provided through an identity source. When federated identities access AWS accounts, they assume roles, and the roles provide temporary credentials. For centralized access management, we recommend that you use AWS IAM Identity Center. You can create users and groups in IAM Identity Center, or you can connect and synchronize to a set of users and groups in your own identity source for use across all your AWS accounts and applications. For information about IAM Identity Center, see What is IAM Identity Center? in the AWS IAM Identity Center User Guide. IAM users and groups An IAM user is an identity within your AWS account that has specific permissions for a single person or application. Where possible, we recommend relying on temporary credentials instead of creating IAM users who have long-term credentials such as passwords and access keys. However, if you have specific use cases that require long-term credentials with IAM users, we recommend that you rotate access keys. For more information, see Rotate access keys regularly for use cases that require long- term credentials in the IAM User Guide. An IAM group is an identity that specifies a collection of IAM users. You can't sign in as a group. You can use groups to specify permissions for multiple users at a time. Groups make permissions easier to manage for large sets of users. For example, you could have a group named IAMAdmins and give that group permissions to administer IAM resources. Users are different from roles. A user is uniquely associated with one person or application, but a role is intended to be assumable by anyone who needs it. Users have permanent long-term credentials, but roles provide temporary credentials. To learn more, see Use cases for IAM users in the IAM User Guide. IAM roles An IAM role is an identity within your AWS account that has specific permissions. It is similar to an IAM user, but is not associated with a specific person. To temporarily assume an IAM role in the AWS Management Console, you can switch from a user to an IAM role (console). You can assume a Authenticating with identities 585 AWS Transfer Family User Guide role by calling an AWS CLI or AWS API operation or by using a custom URL. For more information about methods for using roles, see Methods to assume a role in the IAM User Guide. IAM roles with temporary credentials are useful in the following situations: • Federated user access – To assign permissions to a federated identity, you create a role and define permissions for the role. When a federated identity authenticates, the identity is associated with the role and is granted the permissions that are defined by the role. For information about roles for federation, see Create a role for a third-party identity provider (federation) in the IAM User Guide. If you use IAM Identity Center, you configure a permission set. To control what your identities can access after they authenticate, IAM Identity Center correlates the permission set to a role in IAM. For information about permissions sets, see Permission sets in the AWS IAM Identity Center User Guide. • Temporary IAM user permissions – An IAM user or role can assume an IAM role
|
transferfamily-ug-166
|
transferfamily-ug.pdf
| 166 |
with the role and is granted the permissions that are defined by the role. For information about roles for federation, see Create a role for a third-party identity provider (federation) in the IAM User Guide. If you use IAM Identity Center, you configure a permission set. To control what your identities can access after they authenticate, IAM Identity Center correlates the permission set to a role in IAM. For information about permissions sets, see Permission sets in the AWS IAM Identity Center User Guide. • Temporary IAM user permissions – An IAM user or role can assume an IAM role to temporarily take on different permissions for a specific task. • Cross-account access – You can use an IAM role to allow someone (a trusted principal) in a different account to access resources in your account. Roles are the primary way to grant cross- account access. However, with some AWS services, you can attach a policy directly to a resource (instead of using a role as a proxy). To learn the difference between roles and resource-based policies for cross-account access, see Cross account resource access in IAM in the IAM User Guide. • Cross-service access – Some AWS services use features in other AWS services. For example, when you make a call in a service, it's common for that service to run applications in Amazon EC2 or store objects in Amazon S3. A service might do this using the calling principal's permissions, using a service role, or using a service-linked role. • Forward access sessions (FAS) – When you use an IAM user or role to perform actions in AWS, you are considered a principal. When you use some services, you might perform an action that then initiates another action in a different service. FAS uses the permissions of the principal calling an AWS service, combined with the requesting AWS service to make requests to downstream services. FAS requests are only made when a service receives a request that requires interactions with other AWS services or resources to complete. In this case, you must have permissions to perform both actions. For policy details when making FAS requests, see Forward access sessions. • Service role – A service role is an IAM role that a service assumes to perform actions on your behalf. An IAM administrator can create, modify, and delete a service role from within IAM. For more information, see Create a role to delegate permissions to an AWS service in the IAM User Guide. Authenticating with identities 586 AWS Transfer Family User Guide • Service-linked role – A service-linked role is a type of service role that is linked to an AWS service. The service can assume the role to perform an action on your behalf. Service-linked roles appear in your AWS account and are owned by the service. An IAM administrator can view, but not edit the permissions for service-linked roles. • Applications running on Amazon EC2 – You can use an IAM role to manage temporary credentials for applications that are running on an EC2 instance and making AWS CLI or AWS API requests. This is preferable to storing access keys within the EC2 instance. To assign an AWS role to an EC2 instance and make it available to all of its applications, you create an instance profile that is attached to the instance. An instance profile contains the role and enables programs that are running on the EC2 instance to get temporary credentials. For more information, see Use an IAM role to grant permissions to applications running on Amazon EC2 instances in the IAM User Guide. Managing access using policies You control access in AWS by creating policies and attaching them to AWS identities or resources. A policy is an object in AWS that, when associated with an identity or resource, defines their permissions. AWS evaluates these policies when a principal (user, root user, or role session) makes a request. Permissions in the policies determine whether the request is allowed or denied. Most policies are stored in AWS as JSON documents. For more information about the structure and contents of JSON policy documents, see Overview of JSON policies in the IAM User Guide. Administrators can use AWS JSON policies to specify who has access to what. That is, which principal can perform actions on what resources, and under what conditions. By default, users and roles have no permissions. To grant users permission to perform actions on the resources that they need, an IAM administrator can create IAM policies. The administrator can then add the IAM policies to roles, and users can assume the roles. IAM policies define permissions for an action regardless of the method that you use to perform the operation. For example, suppose that you have a policy that allows the iam:GetRole action. A
|
transferfamily-ug-167
|
transferfamily-ug.pdf
| 167 |
AWS JSON policies to specify who has access to what. That is, which principal can perform actions on what resources, and under what conditions. By default, users and roles have no permissions. To grant users permission to perform actions on the resources that they need, an IAM administrator can create IAM policies. The administrator can then add the IAM policies to roles, and users can assume the roles. IAM policies define permissions for an action regardless of the method that you use to perform the operation. For example, suppose that you have a policy that allows the iam:GetRole action. A user with that policy can get role information from the AWS Management Console, the AWS CLI, or the AWS API. Identity-based policies Identity-based policies are JSON permissions policy documents that you can attach to an identity, such as an IAM user, group of users, or role. These policies control what actions users and roles can Managing access using policies 587 AWS Transfer Family User Guide perform, on which resources, and under what conditions. To learn how to create an identity-based policy, see Define custom IAM permissions with customer managed policies in the IAM User Guide. Identity-based policies can be further categorized as inline policies or managed policies. Inline policies are embedded directly into a single user, group, or role. Managed policies are standalone policies that you can attach to multiple users, groups, and roles in your AWS account. Managed policies include AWS managed policies and customer managed policies. To learn how to choose between a managed policy or an inline policy, see Choose between managed policies and inline policies in the IAM User Guide. Resource-based policies Resource-based policies are JSON policy documents that you attach to a resource. Examples of resource-based policies are IAM role trust policies and Amazon S3 bucket policies. In services that support resource-based policies, service administrators can use them to control access to a specific resource. For the resource where the policy is attached, the policy defines what actions a specified principal can perform on that resource and under what conditions. You must specify a principal in a resource-based policy. Principals can include accounts, users, roles, federated users, or AWS services. Resource-based policies are inline policies that are located in that service. You can't use AWS managed policies from IAM in a resource-based policy. Access control lists (ACLs) Access control lists (ACLs) control which principals (account members, users, or roles) have permissions to access a resource. ACLs are similar to resource-based policies, although they do not use the JSON policy document format. Amazon S3, AWS WAF, and Amazon VPC are examples of services that support ACLs. To learn more about ACLs, see Access control list (ACL) overview in the Amazon Simple Storage Service Developer Guide. Other policy types AWS supports additional, less-common policy types. These policy types can set the maximum permissions granted to you by the more common policy types. • Permissions boundaries – A permissions boundary is an advanced feature in which you set the maximum permissions that an identity-based policy can grant to an IAM entity (IAM user or role). You can set a permissions boundary for an entity. The resulting permissions are the Managing access using policies 588 AWS Transfer Family User Guide intersection of an entity's identity-based policies and its permissions boundaries. Resource-based policies that specify the user or role in the Principal field are not limited by the permissions boundary. An explicit deny in any of these policies overrides the allow. For more information about permissions boundaries, see Permissions boundaries for IAM entities in the IAM User Guide. • Service control policies (SCPs) – SCPs are JSON policies that specify the maximum permissions for an organization or organizational unit (OU) in AWS Organizations. AWS Organizations is a service for grouping and centrally managing multiple AWS accounts that your business owns. If you enable all features in an organization, then you can apply service control policies (SCPs) to any or all of your accounts. The SCP limits permissions for entities in member accounts, including each AWS account root user. For more information about Organizations and SCPs, see Service control policies in the AWS Organizations User Guide. • Resource control policies (RCPs) – RCPs are JSON policies that you can use to set the maximum available permissions for resources in your accounts without updating the IAM policies attached to each resource that you own. The RCP limits permissions for resources in member accounts and can impact the effective permissions for identities, including the AWS account root user, regardless of whether they belong to your organization. For more information about Organizations and RCPs, including a list of AWS services that support RCPs, see Resource control policies (RCPs) in the AWS Organizations User Guide. • Session policies – Session policies are advanced policies that
|
transferfamily-ug-168
|
transferfamily-ug.pdf
| 168 |
– RCPs are JSON policies that you can use to set the maximum available permissions for resources in your accounts without updating the IAM policies attached to each resource that you own. The RCP limits permissions for resources in member accounts and can impact the effective permissions for identities, including the AWS account root user, regardless of whether they belong to your organization. For more information about Organizations and RCPs, including a list of AWS services that support RCPs, see Resource control policies (RCPs) in the AWS Organizations User Guide. • Session policies – Session policies are advanced policies that you pass as a parameter when you programmatically create a temporary session for a role or federated user. The resulting session's permissions are the intersection of the user or role's identity-based policies and the session policies. Permissions can also come from a resource-based policy. An explicit deny in any of these policies overrides the allow. For more information, see Session policies in the IAM User Guide. Multiple policy types When multiple types of policies apply to a request, the resulting permissions are more complicated to understand. To learn how AWS determines whether to allow a request when multiple policy types are involved, see Policy evaluation logic in the IAM User Guide. How AWS Transfer Family works with IAM Before you use AWS Identity and Access Management (IAM) to manage access to AWS Transfer Family, you should understand what IAM features are available to use with AWS Transfer Family. To get a high-level view of how AWS Transfer Family and other AWS services work with IAM, see AWS services that work with IAM in the IAM User Guide. How AWS Transfer Family works with IAM 589 AWS Transfer Family Topics • AWS Transfer Family identity-based policies • AWS Transfer Family resource-based policies • Authorization based on AWS Transfer Family tags • AWS Transfer Family IAM roles AWS Transfer Family identity-based policies User Guide With IAM identity-based policies, you can specify allowed or denied actions and resources as well as the conditions under which actions are allowed or denied. AWS Transfer Family supports specific actions, resources, and condition keys. To learn about all of the elements that you use in a JSON policy, see IAM JSON policy elements reference in the AWS Identity and Access Management User Guide. Actions Administrators can use AWS JSON policies to specify who has access to what. That is, which principal can perform actions on what resources, and under what conditions. The Action element of a JSON policy describes the actions that you can use to allow or deny access in a policy. Policy actions usually have the same name as the associated AWS API operation. There are some exceptions, such as permission-only actions that don't have a matching API operation. There are also some operations that require multiple actions in a policy. These additional actions are called dependent actions. Include actions in a policy to grant permissions to perform the associated operation. Policy actions in AWS Transfer Family use the following prefix before the action: transfer:. For example, to grant someone permission to create a server, with the Transfer Family CreateServer API operation, you include the transfer:CreateServer action in their policy. Policy statements must include either an Action or NotAction element. AWS Transfer Family defines its own set of actions that describe tasks that you can perform with this service. To specify multiple actions in a single statement, separate them with commas as follows. "Action": [ "transfer:action1", How AWS Transfer Family works with IAM 590 AWS Transfer Family "transfer:action2" User Guide You can specify multiple actions using wildcards (*). For example, to specify all actions that begin with the word Describe, include the following action. "Action": "transfer:Describe*" To see a list of AWS Transfer Family actions, see Actions defined by AWS Transfer Family in the Service Authorization Reference. Resources Administrators can use AWS JSON policies to specify who has access to what. That is, which principal can perform actions on what resources, and under what conditions. The Resource JSON policy element specifies the object or objects to which the action applies. Statements must include either a Resource or a NotResource element. As a best practice, specify a resource using its Amazon Resource Name (ARN). You can do this for actions that support a specific resource type, known as resource-level permissions. For actions that don't support resource-level permissions, such as listing operations, use a wildcard (*) to indicate that the statement applies to all resources. "Resource": "*" The Transfer Family server resource has the following ARN. arn:aws:transfer:${Region}:${Account}:server/${ServerId} For example, to specify the s-01234567890abcdef Transfer Family server in your statement, use the following ARN. "Resource": "arn:aws:transfer:us-east-1:123456789012:server/s-01234567890abcdef" For more information about the format of ARNs, see Amazon Resource Names (ARNs) in the Service Authorization Reference, or IAM ARNs in
|
transferfamily-ug-169
|
transferfamily-ug.pdf
| 169 |
a resource using its Amazon Resource Name (ARN). You can do this for actions that support a specific resource type, known as resource-level permissions. For actions that don't support resource-level permissions, such as listing operations, use a wildcard (*) to indicate that the statement applies to all resources. "Resource": "*" The Transfer Family server resource has the following ARN. arn:aws:transfer:${Region}:${Account}:server/${ServerId} For example, to specify the s-01234567890abcdef Transfer Family server in your statement, use the following ARN. "Resource": "arn:aws:transfer:us-east-1:123456789012:server/s-01234567890abcdef" For more information about the format of ARNs, see Amazon Resource Names (ARNs) in the Service Authorization Reference, or IAM ARNs in the IAM User Guide. To specify all instances that belong to a specific account, use the wildcard (*). How AWS Transfer Family works with IAM 591 AWS Transfer Family User Guide "Resource": "arn:aws:transfer:us-east-1:123456789012:server/*" Some AWS Transfer Family actions are performed on multiple resources, such as those used in IAM policies. In those cases, you must use the wildcard (*). "Resource": "arn:aws:transfer:*:123456789012:server/*" In some cases you need to specify more than one type of resource, for example, if you create a policy that allows access to Transfer Family servers and users. To specify multiple resources in a single statement, separate the ARNs with commas. "Resource": [ "resource1", "resource2" ] To see a list of AWS Transfer Family resources, see Resource types defined by AWS Transfer Family in the Service Authorization Reference. Condition keys Administrators can use AWS JSON policies to specify who has access to what. That is, which principal can perform actions on what resources, and under what conditions. The Condition element (or Condition block) lets you specify conditions in which a statement is in effect. The Condition element is optional. You can create conditional expressions that use condition operators, such as equals or less than, to match the condition in the policy with values in the request. If you specify multiple Condition elements in a statement, or multiple keys in a single Condition element, AWS evaluates them using a logical AND operation. If you specify multiple values for a single condition key, AWS evaluates the condition using a logical OR operation. All of the conditions must be met before the statement's permissions are granted. You can also use placeholder variables when you specify conditions. For example, you can grant an IAM user permission to access a resource only if it is tagged with their IAM user name. For more information, see IAM policy elements: variables and tags in the IAM User Guide. AWS supports global condition keys and service-specific condition keys. To see all AWS global condition keys, see AWS global condition context keys in the IAM User Guide. How AWS Transfer Family works with IAM 592 AWS Transfer Family User Guide AWS Transfer Family defines its own set of condition keys and also supports using some global condition keys. To see a list of AWS Transfer Family condition keys, see Condition keys for AWS Transfer Family in the Service Authorization Reference. Examples To view examples of AWS Transfer Family identity-based policies, see AWS Transfer Family identity- based policy examples. AWS Transfer Family resource-based policies Resource-based policies are JSON policy documents that specify what actions a specified principal can perform on the AWS Transfer Family resource and under what conditions. Amazon S3 supports resource-based permissions policies for Amazon S3 buckets. Resource-based policies let you grant usage permission to other accounts on a per-resource basis. You can also use a resource-based policy to allow an AWS service to access your Amazon S3 buckets. To enable cross-account access, you can specify an entire account or IAM entities in another account as the principal in a resource-based policy. Adding a cross-account principal to a resource- based policy is only half of establishing the trust relationship. When the principal and the resource are in different AWS accounts, you must also grant the principal entity permission to access the resource. Grant permission by attaching an identity-based policy to the entity. However, if a resource-based policy grants access to a principal in the same account, no additional identity-based policy is required. For more information, see How IAM roles differ from resource-based policies in the AWS Identity and Access Management User Guide. The Amazon S3 service supports only one type of resource-based policy called a bucket policy, which is attached to a bucket. This policy defines which principal entities (accounts, users, roles, and federated users) can perform actions on the object. Examples To view examples of AWS Transfer Family resource-based policies, see AWS Transfer Family tag- based policy examples. Authorization based on AWS Transfer Family tags You can attach tags to AWS Transfer Family resources or pass tags in a request to AWS Transfer Family. To control access based on tags, you provide tag information in the condition element of a policy using the transfer:ResourceTag/key-name, aws:RequestTag/key-name,
|
transferfamily-ug-170
|
transferfamily-ug.pdf
| 170 |
supports only one type of resource-based policy called a bucket policy, which is attached to a bucket. This policy defines which principal entities (accounts, users, roles, and federated users) can perform actions on the object. Examples To view examples of AWS Transfer Family resource-based policies, see AWS Transfer Family tag- based policy examples. Authorization based on AWS Transfer Family tags You can attach tags to AWS Transfer Family resources or pass tags in a request to AWS Transfer Family. To control access based on tags, you provide tag information in the condition element of a policy using the transfer:ResourceTag/key-name, aws:RequestTag/key-name, or How AWS Transfer Family works with IAM 593 AWS Transfer Family User Guide aws:TagKeys condition keys. For information about how to use tags to control access to AWS Transfer Family resources, see AWS Transfer Family tag-based policy examples. AWS Transfer Family IAM roles An IAM role is an entity within your AWS account that has specific permissions. Using temporary credentials with AWS Transfer Family You can use temporary credentials to sign in with federation, assume an IAM role, or to assume a cross-account role. You obtain temporary security credentials by calling AWS STS API operations such as AssumeRole or GetFederationToken. AWS Transfer Family supports using temporary credentials. AWS Transfer Family identity-based policy examples By default, IAM users and roles don't have permission to create or modify AWS Transfer Family resources. They also can't perform tasks using the AWS Management Console, AWS CLI, or AWS API. An IAM administrator must create IAM policies that grant users and roles permission to perform specific API operations on the specified resources they need. The administrator must then attach those policies to the IAM users or groups that require those permissions. To learn how to create an IAM identity-based policy using these example JSON policy documents, see Creating policies on the JSON tab in the AWS Identity and Access Management User Guide. Topics • Policy best practices • Using the AWS Transfer Family console • Allow users to view their own permissions Policy best practices Identity-based policies determine whether someone can create, access, or delete AWS Transfer Family resources in your account. These actions can incur costs for your AWS account. When you create or edit identity-based policies, follow these guidelines and recommendations: • Get started with AWS managed policies and move toward least-privilege permissions – To get started granting permissions to your users and workloads, use the AWS managed policies Identity-based policy examples 594 AWS Transfer Family User Guide that grant permissions for many common use cases. They are available in your AWS account. We recommend that you reduce permissions further by defining AWS customer managed policies that are specific to your use cases. For more information, see AWS managed policies or AWS managed policies for job functions in the IAM User Guide. • Apply least-privilege permissions – When you set permissions with IAM policies, grant only the permissions required to perform a task. You do this by defining the actions that can be taken on specific resources under specific conditions, also known as least-privilege permissions. For more information about using IAM to apply permissions, see Policies and permissions in IAM in the IAM User Guide. • Use conditions in IAM policies to further restrict access – You can add a condition to your policies to limit access to actions and resources. For example, you can write a policy condition to specify that all requests must be sent using SSL. You can also use conditions to grant access to service actions if they are used through a specific AWS service, such as AWS CloudFormation. For more information, see IAM JSON policy elements: Condition in the IAM User Guide. • Use IAM Access Analyzer to validate your IAM policies to ensure secure and functional permissions – IAM Access Analyzer validates new and existing policies so that the policies adhere to the IAM policy language (JSON) and IAM best practices. IAM Access Analyzer provides more than 100 policy checks and actionable recommendations to help you author secure and functional policies. For more information, see Validate policies with IAM Access Analyzer in the IAM User Guide. • Require multi-factor authentication (MFA) – If you have a scenario that requires IAM users or a root user in your AWS account, turn on MFA for additional security. To require MFA when API operations are called, add MFA conditions to your policies. For more information, see Secure API access with MFA in the IAM User Guide. For more information about best practices in IAM, see Security best practices in IAM in the IAM User Guide. Using the AWS Transfer Family console To access the AWS Transfer Family console, you must have a minimum set of permissions. These permissions must allow you to list and view details about the AWS
|
transferfamily-ug-171
|
transferfamily-ug.pdf
| 171 |
scenario that requires IAM users or a root user in your AWS account, turn on MFA for additional security. To require MFA when API operations are called, add MFA conditions to your policies. For more information, see Secure API access with MFA in the IAM User Guide. For more information about best practices in IAM, see Security best practices in IAM in the IAM User Guide. Using the AWS Transfer Family console To access the AWS Transfer Family console, you must have a minimum set of permissions. These permissions must allow you to list and view details about the AWS Transfer Family resources in your AWS account. If you create an identity-based policy that is more restrictive than the minimum required permissions, the console won't function as intended for entities (IAM users or roles) with that policy. For more information, see Adding permissions to a user in the AWS Identity and Access Management User Guide. Identity-based policy examples 595 AWS Transfer Family User Guide You don't need to allow minimum console permissions for users that are making calls only to the AWS CLI or the AWS API. Instead, allow access to only the actions that match the API operation that you're trying to perform. Allow users to view their own permissions This example shows how you might create a policy that allows IAM users to view the inline and managed policies that are attached to their user identity. This policy includes permissions to complete this action on the console or programmatically using the AWS CLI or AWS API. { "Version": "2012-10-17", "Statement": [ { "Sid": "ViewOwnUserInfo", "Effect": "Allow", "Action": [ "iam:GetUserPolicy", "iam:ListGroupsForUser", "iam:ListAttachedUserPolicies", "iam:ListUserPolicies", "iam:GetUser" ], "Resource": ["arn:aws:iam::*:user/${aws:username}"] }, { "Sid": "NavigateInConsole", "Effect": "Allow", "Action": [ "iam:GetGroupPolicy", "iam:GetPolicyVersion", "iam:GetPolicy", "iam:ListAttachedGroupPolicies", "iam:ListGroupPolicies", "iam:ListPolicyVersions", "iam:ListPolicies", "iam:ListUsers" ], "Resource": "*" } ] } Identity-based policy examples 596 AWS Transfer Family User Guide AWS Transfer Family tag-based policy examples The following are examples of how to control access to AWS Transfer Family resources based on tags. Using tags to control access to AWS Transfer Family resources Conditions in IAM policies are part of the syntax that you use to specify permissions to AWS Transfer Family resources. You can control access to AWS Transfer Family resources (such as users, servers, roles, and other entities) based on tags on those resources. Tags are key-value pairs. For more information about tagging resources, see Tagging AWS resources in the AWS General Reference. In AWS Transfer Family, resources can have tags, and some actions can include tags. When you create an IAM policy, you can use tag condition keys to control the following: • Which users can perform actions on an AWS Transfer Family resource, based on tags that the resource has. • What tags can be passed in an action's request. • Whether specific tag keys can be used in a request. By using tag-based access control, you can apply finer control than at the API level. You also can apply more dynamic control than by using resource-based access control. You can create IAM policies that allow or deny an operation based on tags provided in the request (request tags). You can also create IAM policies based on tags on the resource that is being operated on (resource tags). In general, resource tags are for tags that are already on resources, request tags are for when you're adding tags to or removing tags from a resource. For the complete syntax and semantics of tag condition keys, see Controlling access to AWS resources using resource tags in the IAM User Guide. For details about specifying IAM policies with API Gateway, see Control access to an API with IAM permissions in the API Gateway Developer Guide. Example 1: Deny actions based on resource tags You can deny an action to be performed on a resource based on tags. The following example policy denies TagResource, UntagResource, StartServer, StopServer, DescribeServer, and DescribeUser operations if the user or server resource is tagged with the key stage and the value prod. Tag-based policy examples 597 AWS Transfer Family User Guide { "Version": "2012-10-17", "Statement": [ { "Effect": "Deny", "Action": [ "transfer:TagResource", "transfer:UntagResource", "transfer:StartServer", "transfer:StopServer", "transfer:DescribeServer", "transfer:DescribeUser ], "Resource": "*", "Condition": { "StringEquals": { "aws:ResourceTag/stage": "prod" } } } ] } Example 2: Allow actions based on resource tags You can allow an action to be performed on a resource based on tags. The following example policy allows TagResource, UntagResource, StartServer, StopServer, DescribeServer, and DescribeUser operations if the user or server resource is tagged with the key stage and the value prod. { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": [ "transfer:TagResource", "transfer:UntagResource", "transfer:StartServer", "transfer:StopServer", "transfer:DescribeServer", "transfer:DescribeUser Tag-based policy examples 598 AWS Transfer Family ], "Resource": "*", "Condition": { "StringEquals": { "aws:ResourceTag/stage": "prod" } } } ] } User Guide Example 3: Deny creation
|
transferfamily-ug-172
|
transferfamily-ug.pdf
| 172 |
"prod" } } } ] } Example 2: Allow actions based on resource tags You can allow an action to be performed on a resource based on tags. The following example policy allows TagResource, UntagResource, StartServer, StopServer, DescribeServer, and DescribeUser operations if the user or server resource is tagged with the key stage and the value prod. { "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": [ "transfer:TagResource", "transfer:UntagResource", "transfer:StartServer", "transfer:StopServer", "transfer:DescribeServer", "transfer:DescribeUser Tag-based policy examples 598 AWS Transfer Family ], "Resource": "*", "Condition": { "StringEquals": { "aws:ResourceTag/stage": "prod" } } } ] } User Guide Example 3: Deny creation of a user or server based on request tags The following example policy contains two statements. The first statement denies the CreateServer operation on all resources if the cost center key for the tag doesn't have a value. The second statement denies the CreateServer operation if the cost center key for the tag contains any other value besides 1, 2 or 3. Note This policy does allow creating or deleting a resource that contains a key called costcenter and a value of 1, 2, or 3. { "Version": "2012-10-17", "Statement": [ { "Effect": "Deny", "Action": [ "transfer:CreateServer" ], "Resource": [ "*" ], "Condition": { "Null": { "aws:RequestTag/costcenter": "true" } } }, Tag-based policy examples 599 User Guide AWS Transfer Family { "Effect": "Deny", "Action": "transfer:CreateServer", "Resource": [ "*" ], "Condition": { "ForAnyValue:StringNotEquals": { "aws:RequestTag/costcenter": [ "1", "2", "3" ] } } } ] } Troubleshooting AWS Transfer Family identity and access Use the following information to help you diagnose and fix common issues that you might encounter when working with AWS Transfer Family and IAM. Topics • I am not authorized to perform an action in AWS Transfer Family • I am not authorized to perform iam:PassRole • I want to allow people outside of my AWS account to access my AWS Transfer Family resources I am not authorized to perform an action in AWS Transfer Family If the AWS Management Console tells you that you're not authorized to perform an action, then you must contact your administrator for assistance. Your administrator is the person that provided you with your sign-in credentials. The following example error occurs when the mateojackson IAM user tries to use the console to view details about a widget but does not have transfer:GetWidget permissions. User: arn:aws:iam::123456789012:user/mateojackson is not authorized to perform: transfer:GetWidget on resource: my-example-widget Troubleshooting identity and access 600 AWS Transfer Family User Guide In this case, Mateo asks his administrator to update his policies to allow him to access the my- example-widget resource using the transfer;:GetWidget action. I am not authorized to perform iam:PassRole If you receive an error that you're not authorized to perform the iam:PassRole action, your policies must be updated to allow you to pass a role to AWS Transfer Family. Some AWS services allow you to pass an existing role to that service instead of creating a new service role or service-linked role. To do this, you must have permissions to pass the role to the service. The following example error occurs when an IAM user named marymajor tries to use the console to perform an action in AWS Transfer Family. However, the action requires the service to have permissions that are granted by a service role. Mary does not have permissions to pass the role to the service. User: arn:aws:iam::123456789012:user/marymajor is not authorized to perform: iam:PassRole In this case, Mary's policies must be updated to allow her to perform the iam:PassRole action. If you need help, contact your AWS administrator. Your administrator is the person who provided you with your sign-in credentials. The following example policy contains the permission to pass a role to AWS Transfer Family. { "Version": "2012-10-17", "Statement": [ { "Action": "iam:PassRole", "Resource": "arn:aws::iam::123456789012:role/*", "Effect": "Allow" } ] } Troubleshooting identity and access 601 AWS Transfer Family User Guide I want to allow people outside of my AWS account to access my AWS Transfer Family resources You can create a role that users in other accounts or people outside of your organization can use to access your resources. You can specify who is trusted to assume the role. For services that support resource-based policies or access control lists (ACLs), you can use those policies to grant people access to your resources. To learn more, consult the following: • To learn whether AWS Transfer Family supports these features, see How AWS Transfer Family works with IAM. • To learn how to provide access to your resources across AWS accounts that you own, see Providing access to an IAM user in another AWS account that you own in the IAM User Guide. • To learn how to provide access to your resources to third-party AWS accounts, see Providing access to AWS accounts owned by third parties in
|
transferfamily-ug-173
|
transferfamily-ug.pdf
| 173 |
access control lists (ACLs), you can use those policies to grant people access to your resources. To learn more, consult the following: • To learn whether AWS Transfer Family supports these features, see How AWS Transfer Family works with IAM. • To learn how to provide access to your resources across AWS accounts that you own, see Providing access to an IAM user in another AWS account that you own in the IAM User Guide. • To learn how to provide access to your resources to third-party AWS accounts, see Providing access to AWS accounts owned by third parties in the IAM User Guide. • To learn how to provide access through identity federation, see Providing access to externally authenticated users (identity federation) in the IAM User Guide. • To learn the difference between using roles and resource-based policies for cross-account access, see Cross account resource access in IAM in the IAM User Guide. Compliance validation for AWS Transfer Family Third-party auditors assess the security and compliance of AWS Transfer Family as part of multiple AWS compliance programs. These include SOC, PCI, HIPAA, and others. For the complete list, see AWS Services in Scope by Compliance Program. For a list of AWS services in scope of specific compliance programs, see AWS services in scope by compliance program. For general information, see AWS compliance programs. You can download third-party audit reports using AWS Artifact. For more information, see Downloading reports in AWS Artifact. Your compliance responsibility when using AWS Transfer Family is determined by the sensitivity of your data, your company's compliance objectives, and applicable laws and regulations. AWS provides the following resources to help with compliance: Compliance validation 602 AWS Transfer Family User Guide • Security and compliance quick start guides – These deployment guides discuss architectural considerations and provide steps for deploying security- and compliance-focused baseline environments on AWS. • Architecting for HIPAA security and compliance whitepaper – This whitepaper describes how companies can use AWS to create HIPAA-compliant applications. • AWS compliance resources – This collection of workbooks and guides might apply to your industry and location. • AWS Config – This AWS service assesses how well your resource configurations comply with internal practices, industry guidelines, and regulations. • AWS Security Hub – This AWS service provides a comprehensive view of your security state within AWS that helps you check your compliance with security industry standards and best practices. Resilience in AWS Transfer Family The AWS global infrastructure is built around AWS Regions and Availability Zones. AWS Regions provide multiple physically separated and isolated Availability Zones, which are connected with low-latency, high-throughput, and highly redundant networking. With Availability Zones, you can design and operate applications and databases that automatically fail over between Availability Zones without interruption. Availability Zones are more highly available, fault tolerant, and scalable than traditional single or multiple data center infrastructures. AWS Transfer Family supports up to 3 Availability Zones and is backed by an auto scaling, redundant fleet for your connection and transfer requests. Note the following: • For public endpoints: • Availability Zone-level redundancy is built into the service • There are redundant fleets for each AZ. • This redundancy is provided automatically • For endpoints in a Virtual Private Cloud (VPC), see Create a server in a virtual private cloud. See also • For more information about AWS Regions and Availability Zones, see AWS global infrastructure. Resilience 603 AWS Transfer Family User Guide • For an example on how to build for higher redundancy and minimize network latency by using Latency-based routing, see the blog post Minimize network latency with your AWS Transfer Family servers. Infrastructure security in AWS Transfer Family As a managed service, AWS Transfer Family is protected by AWS global network security. For information about AWS security services and how AWS protects infrastructure, see AWS Cloud Security. To design your AWS environment using the best practices for infrastructure security, see Infrastructure Protection in Security Pillar AWS Well‐Architected Framework. You use AWS published API calls to access AWS Transfer Family through the network. Clients must support the following: • Transport Layer Security (TLS). We require TLS 1.2 and recommend TLS 1.3. • Cipher suites with perfect forward secrecy (PFS) such as DHE (Ephemeral Diffie-Hellman) or ECDHE (Elliptic Curve Ephemeral Diffie-Hellman). Most modern systems such as Java 7 and later support these modes. Additionally, requests must be signed by using an access key ID and a secret access key that is associated with an IAM principal. Or you can use the AWS Security Token Service (AWS STS) to generate temporary security credentials to sign requests. Add a web application firewall AWS WAF is a web application firewall that helps protect web applications and APIs from attacks. You can use it to configure a set of rules known as a web access
|
transferfamily-ug-174
|
transferfamily-ug.pdf
| 174 |
as DHE (Ephemeral Diffie-Hellman) or ECDHE (Elliptic Curve Ephemeral Diffie-Hellman). Most modern systems such as Java 7 and later support these modes. Additionally, requests must be signed by using an access key ID and a secret access key that is associated with an IAM principal. Or you can use the AWS Security Token Service (AWS STS) to generate temporary security credentials to sign requests. Add a web application firewall AWS WAF is a web application firewall that helps protect web applications and APIs from attacks. You can use it to configure a set of rules known as a web access control list (web ACL) that allow, block, or count web requests based on customizable web security rules and conditions that you define. For more information, see Using AWS WAF to protect your APIs. To add AWS WAF 1. Open the API Gateway console at https://console.aws.amazon.com/apigateway/. 2. In the APIs navigation pane, and then choose your custom identity provider template. 3. Choose Stages. 4. In the Stages pane, choose the name of the stage. Infrastructure security 604 AWS Transfer Family User Guide 5. In the Stage Editor pane, choose the Settings tab. 6. Do one of the following: • Under Web Application Firewall (WAF), for Web ACL, choose the web ACL that you want to associate with this stage. • If the web ACL you need doesn't exist, you will need to create one by doing the following: 1. Choose Create Web ACL. 2. On the AWS WAF service homepage, choose Create web ACL. 3. In Web ACL details, for Name, type the name of the web ACL. 4. In Rules, choose Add rules, then choose Add my own rules and rule groups. 5. For Rule type, choose IP set to identify a specific list of IP addresses. 6. For Rule, enter the name of the rule. 7. For IP set, choose an existing IP set. To create an IP set, see Creating an IP set. 8. For IP address to use as the originating address, choose IP address in header. 9. For Header field name, enter SourceIP. 10.For Position inside header, choose First IP address. 11.For Fallback for missing IP address, choose Match or No Match depending on how you want to handle an invalid (or missing) IP address in the header. 12.For Action, choose the action of the IP set. 13.For Default web ACL action for requests that don't match any rules, choose Allow or Block and then click Next. 14.For steps 4 and 5, choose Next. 15.In Review and create, review your choices, and then choose Create web ACL. 7. Choose Save Changes. 8. Choose Resources. 9. For Actions, choose Deploy API. For information on how secure Transfer Family with AWS web application firewall, see Securing Transfer Family with AWS application firewall and Amazon API Gateway in the AWS storage blog. Web application firewall 605 AWS Transfer Family User Guide Cross-service confused deputy prevention The confused deputy problem is a security issue where an entity that doesn't have permission to perform an action can coerce a more-privileged entity to perform the action. In AWS, cross-service impersonation can result in the confused deputy problem. Cross-service impersonation can occur when one service (the calling service) calls another service (the called service). The calling service can be manipulated to use its permissions to act on another customer's resources in a way that it should not otherwise have permission to access. To prevent this, AWS provides tools that help you protect your data for all services with service principals that have been given access to resources in your account. For a detailed description of this problem, see the confused deputy problem in the IAM User Guide. We recommend using the aws:SourceArn and aws:SourceAccount global condition context keys in resource policies to limit the permissions that AWS Transfer Family has for the resource. If you use both global condition context keys, the aws:SourceAccount value and the account in the aws:SourceArn value must use the same account ID when used in the same policy statement. The most effective way to protect against the confused deputy problem is to use the exact Amazon Resource Name (ARN) of the resource you want to allow. If you are specifying multiple resources, use the aws:SourceArn global context condition key with wildcard characters (*) for the unknown portions of the ARN. For example, arn:aws:transfer::region::account- id:server/*. AWS Transfer Family uses the following types of roles: • User role – Allows service-managed users to access the necessary Transfer Family resources. AWS Transfer Family assumes this role in the context of a Transfer Family user ARN. • Access role – Provides access to only the Amazon S3 files that are being transferred. For inbound AS2 transfers, the access role uses the Amazon Resource Name (ARN) for the agreement. For outbound AS2 transfers,
|
transferfamily-ug-175
|
transferfamily-ug.pdf
| 175 |
are specifying multiple resources, use the aws:SourceArn global context condition key with wildcard characters (*) for the unknown portions of the ARN. For example, arn:aws:transfer::region::account- id:server/*. AWS Transfer Family uses the following types of roles: • User role – Allows service-managed users to access the necessary Transfer Family resources. AWS Transfer Family assumes this role in the context of a Transfer Family user ARN. • Access role – Provides access to only the Amazon S3 files that are being transferred. For inbound AS2 transfers, the access role uses the Amazon Resource Name (ARN) for the agreement. For outbound AS2 transfers, the access role uses the ARN for the connector. • Invocation role – For use with Amazon API Gateway as the server's custom identity provider. Transfer Family assumes this role in the context of a Transfer Family server ARN. • Logging role – Used to log entries into Amazon CloudWatch. Transfer Family uses this role to log success and failure details along with information about file transfers. Transfer Family assumes this role in the context of a Transfer Family server ARN. For outbound AS2 transfers, the logging role uses the connector ARN. Cross-service confused deputy prevention 606 AWS Transfer Family User Guide • Execution role – Allows a Transfer Family user to call and launch workflows. Transfer Family assumes this role in the context of a Transfer Family workflow ARN. For more information, see Policies and permissions in IAM in the IAM User Guide. Note In the following examples, replace each user input placeholder with your own information. Note In our examples, we use both ArnLike and ArnEquals. They are functionally identical, and therefore you may use either when you construct your policies. Transfer Family documentation uses ArnLike when the condition contains a wildcard character, and ArnEquals to indicate an exact match condition. AWS Transfer Family user role cross-service confused deputy prevention The following example policy allows any user of any server in the account to assume the role. { "Version": "2012-10-17", "Statement": [ { "Sid": "", "Effect": "Allow", "Principal": { "Service": "transfer.amazonaws.com" }, "Action": "sts:AssumeRole", "Condition": { "StringEquals": { "aws:SourceAccount": "account-id" }, "ArnLike": { Transfer Family user roles 607 AWS Transfer Family User Guide "aws:SourceArn": "arn:aws:transfer:region:account-id:user/*" } } } ] } The following example policy allows any user of a specific server to assume the role. { "Version": "2012-10-17", "Statement": [ { "Sid": "", "Effect": "Allow", "Principal": { "Service": "transfer.amazonaws.com" }, "Action": "sts:AssumeRole", "Condition": { "StringEquals": { "aws:SourceAccount": "account-id" }, "ArnEquals": { "aws:SourceArn": "arn:aws:transfer:region:account-id:user/server- id/*" } } } ] } The following example policy allows a specific user of a specific server to assume the role. { "Version": "2012-10-17", "Statement": [ { "Sid": "", "Effect": "Allow", "Principal": { "Service": "transfer.amazonaws.com" }, Transfer Family user roles 608 AWS Transfer Family User Guide "Action": "sts:AssumeRole", "Condition": { "ArnLike": { "aws:SourceArn": "arn:aws:transfer:region:account-id:user/server- id/user-name" } } } ] } AWS Transfer Family workflow role cross-service confused deputy prevention The following example policy allows any workflow in the account to assume the role. { "Version": "2012-10-17", "Statement": [ { "Sid": "", "Effect": "Allow", "Principal": { "Service": "transfer.amazonaws.com" }, "Action": "sts:AssumeRole", "Condition": { "StringEquals": { "aws:SourceAccount": "account-id" }, "ArnLike": { "aws:SourceArn": "arn:aws:transfer:region:account-id:workflow/*" } } } ] } The following example policy allows a specific workflow to assume the role. { "Version": "2012-10-17", Transfer Family workflow roles 609 User Guide AWS Transfer Family "Statement": [ { "Sid": "", "Effect": "Allow", "Principal": { "Service": "transfer.amazonaws.com" }, "Action": "sts:AssumeRole", "Condition": { "ArnLike": { "aws:SourceArn": "arn:aws:transfer:region:account- id:workflow/workflow-id" } } } ] } AWS Transfer Family connector role cross-service confused deputy prevention The following example policy allows any connector in the account to assume the role. { "Version": "2012-10-17", "Statement": [ { "Sid": "", "Effect": "Allow", "Principal": { "Service": "transfer.amazonaws.com" }, "Action": "sts:AssumeRole", "Condition": { "StringEquals": { "aws:SourceAccount": "account-id" }, "ArnLike": { "aws:SourceArn": "arn:aws:transfer:region:account-id:connector/*" } } } ] Transfer Family connector roles 610 AWS Transfer Family } User Guide The following example policy allows a specific connector to assume the role. { "Version": "2012-10-17", "Statement": [ { "Sid": "", "Effect": "Allow", "Principal": { "Service": "transfer.amazonaws.com" }, "Action": "sts:AssumeRole", "Condition": { "ArnLike": { "aws:SourceArn": "arn:aws:transfer:region:account- id:connector/connector-id" } } } ] } AWS Transfer Family logging and invocation role cross-service confused deputy prevention Note The following examples can be used in both logging and invocation roles. In these examples, you can remove the ARN details for a workflow if your server doesn't have any workflows attached to it. The following example logging/invocation policy allows any server (and workflow) in the account to assume the role. { "Version": "2012-10-17", "Statement": [ Transfer Family logging/invocation roles 611 User Guide AWS Transfer Family { "Sid": "AllowAllServersWithWorkflowAttached", "Effect": "Allow", "Principal": { "Service": "transfer.amazonaws.com" }, "Action": "sts:AssumeRole", "Condition": { "StringEquals": { "aws:SourceAccount": "account-id" }, "ArnLike": { "aws:SourceArn": [ "arn:aws:transfer:region:account-id:server/*", "arn:aws:transfer:region:account-id:workflow/*" ] } } } ] } The
|
transferfamily-ug-176
|
transferfamily-ug.pdf
| 176 |
prevention Note The following examples can be used in both logging and invocation roles. In these examples, you can remove the ARN details for a workflow if your server doesn't have any workflows attached to it. The following example logging/invocation policy allows any server (and workflow) in the account to assume the role. { "Version": "2012-10-17", "Statement": [ Transfer Family logging/invocation roles 611 User Guide AWS Transfer Family { "Sid": "AllowAllServersWithWorkflowAttached", "Effect": "Allow", "Principal": { "Service": "transfer.amazonaws.com" }, "Action": "sts:AssumeRole", "Condition": { "StringEquals": { "aws:SourceAccount": "account-id" }, "ArnLike": { "aws:SourceArn": [ "arn:aws:transfer:region:account-id:server/*", "arn:aws:transfer:region:account-id:workflow/*" ] } } } ] } The following example logging/invocation policy allows a specific server (and workflow) to assume the role. { "Version": "2012-10-17", "Statement": [ { "Sid": "AllowSpecificServerWithWorkflowAttached", "Effect": "Allow", "Principal": { "Service": "transfer.amazonaws.com" }, "Action": "sts:AssumeRole", "Condition": { "StringEquals": { "aws:SourceAccount": "account-id" }, "ArnEquals": { "aws:SourceArn": [ "arn:aws:transfer:region:account-id:server/server-id", "arn:aws:transfer:region:account-id:workflow/workflow-id" Transfer Family logging/invocation roles 612 AWS Transfer Family ] } } } ] } User Guide AWS managed policies for AWS Transfer Family To add permissions to users, groups, and roles, it is easier to use AWS managed policies than to write policies yourself. It takes time and expertise to create AWS Identity and Access Management (IAM) customer managed policies that provide your team with only the permissions that they need. To get started quickly, you can use our AWS managed policies. These policies cover common use cases and are available in your AWS account. For more information about AWS managed policies, see AWS managed policies in the IAM User Guide. For a detailed listing of all AWS managed policies, see the AWS managed policy reference guide. AWS services maintain and update AWS managed policies. You can't change the permissions in AWS managed policies. Services occasionally add additional permissions to an AWS managed policy to support new features. This type of update affects all identities (users, groups, and roles) where the policy is attached. Services are most likely to update an AWS managed policy when a new feature is launched or when new operations become available. Services do not remove permissions from an AWS managed policy, so policy updates won't break your existing permissions. Additionally, AWS supports managed policies for job functions that span multiple services. For example, the ReadOnlyAccess AWS managed policy provides read-only access to all AWS services and resources. When a service launches a new feature, AWS adds read-only permissions for new operations and resources. For a list and descriptions of job function policies, see AWS managed policies for job functions in the IAM User Guide. AWS managed policy: AWSTransferConsoleFullAccess The AWSTransferConsoleFullAccess policy provides full access to Transfer Family through the AWS Management Console. For more information, see Service-linked role for AWS Transfer Family. AWS managed policy: AWSTransferFullAccess The AWSTransferFullAccess policy provides full access to Transfer Family services. For more information, see Service-linked role for AWS Transfer Family. AWS managed policies 613 AWS Transfer Family User Guide AWS managed policy: AWSTransferLoggingAccess The AWSTransferLoggingAccess policy grants AWS Transfer Family full access to create log streams and groups and put log events to your account. For more information, see Service-linked role for AWS Transfer Family. AWS managed policy: AWSTransferReadOnlyAccess The AWSTransferReadOnlyAccess policy provides read-only access to Transfer Family services. For more information, see Service-linked role for AWS Transfer Family. AWS Transfer Family updates to AWS managed policies View details about updates to AWS managed policies for AWS Transfer Family since this service began tracking these changes. For automatic alerts about changes to this page, subscribe to the RSS feed on the Document history for AWS Transfer Family page. Change Description Date Documentation update Added sections for each of the Transfer Family managed January 27, 2022 policies. AWSTransferReadOnlyAccess – Update to an existing policy AWS Transfer Family added new permissions to allow the September 30, 2021 AWS Transfer Family started tracking changes policy to read AWS Managed Microsoft AD. AWS Transfer Family started tracking changes for its AWS managed policies. June 15, 2021 AWSTransferLoggingAccess 614 AWS Transfer Family User Guide AWS Transfer Family Terraform module HashiCorpTerraform is an open-source Infrastructure as Code (IaC) engine developed using the HashiCorp Configuration Language (HCL). Terraform provides a consistent command line interface (CLI) workflow that, in conjunction with AWS Transfer Family for the back-end infrastructure, can manage hundreds of cloud services and codify cloud APIs into declarative configuration files. You can use Terraform to safely deploy AWS Transfer Family SFTP endpoints backed by Amazon S3, and associated dependencies and customizations. This automation provides you with a customizable Terraform module and end-to-end examples to create an SFTP endpoint (PUBLIC endpoint type), integrate with Amazon CloudWatch for logging and monitoring, manage user identities for endpoint access, and configure IAM roles for access to Amazon S3 buckets where files are stored. For the repository that contains Terraform code to create the resources required
|
transferfamily-ug-177
|
transferfamily-ug.pdf
| 177 |
Family for the back-end infrastructure, can manage hundreds of cloud services and codify cloud APIs into declarative configuration files. You can use Terraform to safely deploy AWS Transfer Family SFTP endpoints backed by Amazon S3, and associated dependencies and customizations. This automation provides you with a customizable Terraform module and end-to-end examples to create an SFTP endpoint (PUBLIC endpoint type), integrate with Amazon CloudWatch for logging and monitoring, manage user identities for endpoint access, and configure IAM roles for access to Amazon S3 buckets where files are stored. For the repository that contains Terraform code to create the resources required to run AWS Transfer Family on premises, see the Terraform Transfer Family module source code on GitHub. Note TheAWS Transfer Family module for Terraform is a community supported effort. It is not part of an AWS service. Best-effort support is provided by the AWS Storage community. 615 AWS Transfer Family User Guide Troubleshooting AWS Transfer Family This chapter provides troubleshooting information for common issues you might encounter when using AWS Transfer Family. Each section focuses on a specific area of functionality to help you quickly find solutions to your problems. • For issues with IAM in Transfer Family, see Troubleshooting AWS Transfer Family identity and access. • For issues with your Transfer Family web apps, see Troubleshooting your web apps. Topics • Troubleshoot authentication issues • Troubleshoot SFTP connectivity and transfer issues • Troubleshoot custom identity provider issues • Troubleshoot workflow issues • Troubleshoot SFTP connector issues • Troubleshoot EFS issues • Troubleshoot storage and encryption issues • Troubleshoot monitoring and alerting issues • Troubleshoot cross-region transfer issues • Troubleshoot Web Application Firewall integration issues • Troubleshoot service-managed user issues • Troubleshoot AS2 issues Troubleshoot authentication issues This section describes possible solutions for the following authentication issues. Topics • Authentication failures—SSH/SFTP • Managed AD mismatched realms issue • Active Directory group limits exceeded Authentication issues 616 AWS Transfer Family User Guide • Miscellaneous authentication issues • Troubleshoot Amazon API Gateway issues • Troubleshoot testing your identity provider Authentication failures—SSH/SFTP Description When you try to connect to your server using Secure Shell (SSH) File Transfer Protocol (SFTP), you receive a message similar to the following: Received disconnect from 3.130.115.105 port 22:2: Too many authentication failures Authentication failed. Note If you are using an API Gateway and receive this error, see Too many authentication failures. Cause You have not added an RSA key pair for your user, so you must authenticate using a password instead. Solution When you run the sftp command, specify the -o PubkeyAuthentication=no option. This option forces the system to request your password. For example: sftp -o PubkeyAuthentication=no [email protected] id.amazonaws.com Managed AD mismatched realms issue Description A user's realm and their group realm must match. They must both be in the default realm, or they must both be in the trusted realm. Authentication failures—SSH/SFTP 617 AWS Transfer Family Cause User Guide If a user and their group do not match, the user cannot be authenticated by Transfer Family. If you test the identity provider for the user, you receive the error No associated access found for user's groups. Solution Reference a group in the user's realm that matches the group realm (either default or trusted). Active Directory group limits exceeded Description When attempting to add more Active Directory groups to your AWS Transfer Family server, you receive an error indicating you've reached the maximum number of groups allowed. Cause AWS Transfer Family has a default limit of 100 Active Directory groups per server. Solution These are two possible solutions: • Consolidate your Active Directory groups to reduce the total number needed. • If your use case requires more than 100 groups, consider using a custom identity provider solution as described in Simplify Active Directory authentication with a custom identity provider for AWS Transfer Family. Miscellaneous authentication issues Description You receive an authentication error and none of the other troubleshooting works Cause You might have specified a target for a logical directory that contains a leading or trailing slash (/). Solution Active Directory group limits exceeded 618 AWS Transfer Family User Guide Update your logical directory target, to make sure it begins with a slash, and does not contain a trailing slash. For example, /amzn-s3-demo-bucket/images is acceptable, but amzn-s3-demo- bucket/images and /amzn-s3-demo-bucket/images/ are not. Troubleshoot Amazon API Gateway issues This section describes possible solutions for the following API Gateway issues. Topics • Too many authentication failures • Connection closed Too many authentication failures Description When you try to connect to your server using Secure Shell (SSH) File Transfer Protocol (SFTP), you get the following error: Received disconnect from 3.15.127.197 port 22:2: Too many authentication failures Authentication failed. Couldn't read packet: Connection reset by peer Cause You might have entered an incorrect password for your user. Try again to enter the
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.