Profile Applicability:
• Level 1
Description:
Amazon SageMaker Models can be deployed with VPC configurations that restrict network access to the model endpoints. Configuring VPC settings ensures that the model endpoints are accessible only within the specified Virtual Private Cloud, enhancing security by isolating the model from public internet access.
Rationale:
By associating SageMaker Models with a VPC, you limit access to the models to trusted networks only, reducing the attack surface. This helps prevent unauthorized access and potential data exfiltration from the model endpoints. It is especially important when models process sensitive or proprietary data.
Impact:
Pros:
Enhances security by isolating model endpoints within a private network.
Helps meet regulatory compliance by controlling network boundaries.
Reduces risk of data exposure through public endpoints.
Cons:
May increase complexity in network setup and require proper routing and security group rules.
Could restrict legitimate access if VPC configuration is not correctly managed.
Default Value:
By default, SageMaker Models are not associated with any VPC and may be publicly accessible.
Pre-requisites:
Properly configured VPC with subnets and security groups.
IAM permissions to view and modify SageMaker Model configurations.
Test Plan:
Using AWS Console:
Sign in to the AWS Management Console.
Navigate to SageMaker > Models.
Select a model to review its configuration.
Check if the model has a VPC configuration attached (look for VPC ID, Subnet IDs, Security Group IDs).
Confirm that the VPC settings are configured and not empty.
Using AWS CLI:
List SageMaker models:
aws sagemaker list-models
Describe a specific model:
aws sagemaker describe-model --model-name <model-name>
Look for the
VpcConfig
section in the output.Verify that
VpcConfig
includes validSubnets
andSecurityGroupIds
arrays (not empty).
Implementation Plan:
Using AWS Console:
When creating or updating a SageMaker Model, under the Network section, enable VPC configuration.
Select the appropriate VPC, subnets, and security groups.
Save and deploy the model.
Using AWS CLI:
Prepare a JSON configuration file for the model with a
VpcConfig
section, for example:
"VpcConfig": { "SecurityGroupIds": ["sg-xxxxxxxx"], "Subnets": ["subnet-xxxxxxxx", "subnet-yyyyyyyy"] }
Create or update the model with the configuration:
aws sagemaker create-model --cli-input-json file://model-config.json
Backout Plan:
Using AWS Console:
Edit the model configuration.
Remove or disable the VPC configuration.
Save changes and redeploy the model if necessary.
Using AWS CLI:
Modify the model configuration JSON by removing the
VpcConfig
section or setting it to null.Update or recreate the model without VPC configuration.
References:
AWS SageMaker API Documentation:
CreateModel
—VpcConfig
parameterAWS SageMaker User Guide: Securing Models with VPC
CIS AWS Foundations Benchmark (networking and isolation best practices)