Cloud Defense Logo

Products

Solutions

Company

Book A Live Demo

Rule: VPC flow logs should be enabled

Ensure VPC flow logs are enabled for high security compliance.

RuleVPC flow logs should be enabled
FrameworkNIST Cybersecurity Framework (CSF) v1.1
Severity
High

VPC Flow Logs for NIST Cybersecurity Framework (CSF) v1

Description:

Enabling VPC Flow Logs is a crucial step in aligning your AWS infrastructure with the NIST Cybersecurity Framework (CSF) version 1. VPC Flow Logs capture network traffic information within your Virtual Private Cloud (VPC), providing valuable insights into traffic patterns, allowing for threat analysis, and supporting incident response activities. This rule ensures that VPC Flow Logs are enabled, promoting visibility and aiding in security monitoring within your AWS environment.

Troubleshooting Steps (if needed):

If you encounter any issues while enabling VPC Flow Logs, follow the troubleshooting steps below:

  1. 1.
    Confirm VPC Flow Logs Support: Ensure that your AWS region supports VPC Flow Logs. Not all AWS regions may have this feature available.
  2. 2.
    Verify IAM Permissions: Ensure that the IAM role associated with your VPC Flow Logs has the necessary permissions to create and write logs to the chosen log destination (such as CloudWatch Logs or an S3 bucket).
  3. 3.
    Check Resource Limitations: Ensure that you have not reached the resource limitations within your AWS account such as the maximum number of Flow Logs per VPC.
  4. 4.
    Verify Log Destination Settings: Double-check the settings for your log destination (CloudWatch Logs or S3 bucket) to ensure they are properly configured and accessible.

Necessary Codes (if applicable):

No specific codes are required to enable VPC Flow Logs, as it can be done directly through the AWS Management Console or via CLI commands.

Step-by-step Guide:

Enabling VPC Flow Logs through AWS Management Console:

  1. 1.
    Log in to the AWS Management Console.
  2. 2.
    Navigate to the Amazon VPC service.
  3. 3.
    Select the desired VPC for which you want to enable Flow Logs.
  4. 4.
    Click on the "Flow Logs" tab in the VPC details pane.
  5. 5.
    Click the "Create Flow Log" button.
  6. 6.
    Configure the following settings:
    • Choose a unique name for the Flow Log.
    • Select the desired target for the log data (e.g., CloudWatch Logs or an S3 bucket).
    • Set the appropriate IAM role associated with the Flow Logs.
    • Choose the log format (e.g., JSON or text).
    • Optionally, apply any desired filter patterns.
    • Select the appropriate Network Interface(s), Subnet(s), or entire VPC for the Flow Logs.
  7. 7.
    Click the "Create" button to enable VPC Flow Logs.

Enabling VPC Flow Logs through AWS Command Line Interface (CLI):

  1. 1.
    Open the terminal or command prompt.
  2. 2.
    Install and configure the AWS CLI, if not already done.
  3. 3.
    Run the following CLI command to enable VPC Flow Logs:
aws ec2 create-flow-logs --resource-type VPC --resource-ids <VPC_ID> --traffic-type ALL --log-group-name <LOG_GROUP_NAME> --deliver-logs-permission-arn <IAM_ROLE_ARN>

Replace the placeholders

<VPC_ID>
,
<LOG_GROUP_NAME>
, and
<IAM_ROLE_ARN>
with the respective values for your setup. 4. Verify the command output for successful creation of VPC Flow Logs.

Conclusion:

Enabling VPC Flow Logs in alignment with the NIST Cybersecurity Framework (CSF) version 1 helps to enhance the security and visibility of your AWS environment. By following the provided step-by-step guide, you can seamlessly enable VPC Flow Logs either through the AWS Management Console or the AWS Command Line Interface (CLI).

Is your System Free of Underlying Vulnerabilities?
Find Out Now