Skip to main content

More Info:

Compute instances should have in-transit encryption enabled for boot and block volume attachments. This protects data from interception as it moves between the instance and storage

Risk Level

Medium

Address

Compliance, Security

Compliance Standards

  • APRA CPS 234 (Australia)
  • AWS Startup Security Baseline
  • AWS Well Architected Framework
  • BSI C5 (Germany)
  • Brazil LGPD
  • CCPA / CPRA (California)
  • CIS Critical Security Controls v8
  • CMMC 2.0
  • CSA Cloud Controls Matrix v4
  • DPDPA
  • Digital Operational Resilience Act (EU)
  • GDPR
  • HIPAA
  • ISO 27001
  • ISO/IEC 27017
  • ISO/IEC 27018
  • ISO/IEC 27701
  • KSA PDPL
  • MAS Technology Risk Management (Singapore)
  • MITRE ATT&CK (Cloud)
  • NIS2 Directive
  • NIST CSF
  • NIST SP 800-171
  • NYDFS 23 NYCRR 500
  • PCI
  • Reserve Bank of India (RBI) Cyber Security Framework
  • SOC2
  • SWIFT Customer Security Controls Framework
  • Sarbanes-Oxley IT General Controls
  • Securities and Exchange Board of India (SEBI) - Cloud Security Adoption Framework
  • UK NCSC Cyber Assessment Framework

Triage and Remediation

Remediation

Using Console

To remediate “OCI Compute Instances Should Have In-Transit Encryption Enabled” for OCI Compute Monitoring using the OCI Console, you need to enable in‑transit encryption for the Oracle Cloud Agent Monitoring plugin on each instance.Follow these steps per instance:
  1. Sign in to OCI Console
    Make sure you’re in the correct tenancy and region.
  2. Go to the Compute instance
    • Open the navigation menu (☰).
    • Go to Compute → Instances.
    • Select the Compartment where the instance is.
    • Click the instance name you want to fix.
  3. Open Oracle Cloud Agent plugins
    • On the instance details page, in the left-side or main tabs, click Oracle Cloud Agent (or Oracle Cloud Agent plugins).
    • You’ll see a list of plugins like:
      • Monitoring
      • Management Agent
      • Block Volume Management
      • etc.
  4. Edit the Monitoring plugin configuration
    • Find the Monitoring plugin in the list.
    • Ensure its Status is Enabled (if not, click Edit or the action menu () → Enable).
    • In the same area, look for In‑transit encryption or similar security/encryption option.
    • Click Edit (or the pencil icon) for the Monitoring plugin configuration.
  5. Enable in‑transit encryption
    • In the plugin settings, set In‑transit encryption (or Encrypt data in transit / Use TLS for monitoring data) to Enabled.
    • If prompted, choose the appropriate protocol (TLS) and minimum version (e.g., TLS 1.2 or higher).
    • Save the changes by clicking Save or Update.
  6. Verify plugin and encryption status
    • After saving, confirm:
      • Monitoring plugin is Enabled.
      • In‑transit encryption shows as Enabled for that plugin.
    • Optionally, check a few other instances in the same compartment and repeat.
  7. Repeat for all affected instances
    • Apply the same configuration for each instance flagged by your security/compliance tool or Cloud Guard.
If your organization uses instance configuration / instance pools, update the instance configuration with these agent settings and then recreate or refresh instances from that configuration so new instances inherit in‑transit encryption by default.
Below is how to remediate the “OCI Compute Instances Should Have In-Transit Encryption Enabled” finding using the OCI CLI, focusing on block/boot volume attachments to compute instances.In-transit encryption is a property of the volume attachment, not the instance or volume itself, so you must (re)attach with encryption-in-transit enabled.

1. Prerequisites

  • OCI CLI installed and configured:
  • You know:
    • Your tenancy OCID
    • The compartment OCID(s) where the instances reside
    • Proper permissions (read and manage on compute and block volumes).

2. Identify Non-Compliant Volume Attachments

List all volume attachments in a compartment and filter for those without in-transit encryption.
Check for these fields on each attachment:
  • isPvEncryptionInTransitEnabled (for paravirtualized attachments)
  • isIscsiEncryptionEnabled (for iSCSI, if present)
You want all of these to be True.To programmatically find non-compliant ones (example using jq):
Record for each non-compliant attachment:
  • id (volume attachment OCID)
  • instanceId
  • volumeId
  • attachmentType (paravirtualized / iscsi)

3. Stop the Affected Instance (Required for Detach)

For each affected instanceId:
Wait until the instance is STOPPED:

4. Detach the Existing (Non-Encrypted-in-Transit) Volume Attachment

For each non-compliant volumeAttachmentId:
Wait for the attachment to be removed (optional check):

5. Reattach the Volume with In-Transit Encryption Enabled

You need:
  • instanceId (same as before)
  • volumeId
  • attachmentType (paravirtualized or iscsi)
  • For boot volumes: use the boot volume attachment commands.
  • For data volumes: use the volume attachment commands.

5.1. Reattach a Data Volume (Paravirtualized)

5.2. Reattach a Data Volume (iSCSI)

5.3. Reattach a Boot Volume with In-Transit Encryption

For boot volumes, use attach-boot-volume:
(Use the same attachment type and AD as originally.)

6. Restart the Instance


7. Validate In-Transit Encryption Is Enabled

Re-list the volume attachments:
Confirm that:
  • is-pv-encryption-in-transit-enabled is true for paravirtualized
  • is-iscsi-encryption-enabled is true for iSCSI

If you share an example attachment JSON from your environment, I can give exact CLI commands tailored to that specific instance and volume.
In OCI there is no toggle on a Compute instance called “in‑transit encryption.” It’s enforced by how you expose and connect to the instance (HTTPS, SSH, VPN, SSL/TLS on load balancer, etc.).For “OCI Compute Instances Should Have In-Transit Encryption Enabled” as a monitoring control, what you can do in Python is:
  1. Continuously discover public‑facing compute endpoints.
  2. Check whether they are using TLS (HTTPS/SSL) or plaintext (HTTP/other).
  3. Optionally auto‑remediate (e.g., tag non‑compliant instances or send an alarm / notification for manual HTTPS enforcement via LB / web server config).
Below is a minimal, practical approach to add such monitoring with Python and OCI SDK.

1. Prerequisites

  • Python 3.x
  • oci SDK installed:
  • OCI config file (~/.oci/config) with a profile that has:
    • Compute:Read
    • VirtualNetwork:Read
    • Monitoring:manage (if you want to create alarms)
    • Ons:manage or Events/Notifications if you’ll send notifications

2. Discover Compute instances and their public endpoints

This script:
  • Lists all instances in a compartment
  • Finds their VNICs & public IPs
  • Records TCP ports that look like HTTP/HTTPS (80, 443, others if you choose)
At this point you know which instances are internet‑facing.

3. Check in‑transit encryption status (simple TCP/TLS check)

For monitoring, a pragmatic test is:
  • Try connecting via HTTPS (443) and validate the TLS handshake.
  • Optionally, detect if HTTP (80) is open and serving plaintext.
This gives you a monitoring view: which compute instances are serving unencrypted HTTP but not working HTTPS.

4. Publish results as custom metrics to OCI Monitoring

Create a custom metric namespace (e.g. security/compute_encryption) and push a metric like unencrypted_endpoints per instance.
Now you have a Monitoring metric indicating in‑transit encryption compliance per instance.

5. Create an OCI Monitoring Alarm (in console) on this metric

In OCI Console → Monitoring → Alarms:
  1. Create alarm
    • Metric namespace: security/compute_encryption
    • Metric name: unencrypted_endpoints
    • Dimension: instanceId (All)
    • Query example:
  2. Severity: Critical / High
  3. Destination: Choose/Configure Notifications (Email, PagerDuty, etc.)
This turns your Python script into an in‑transit encryption monitor.

6. Operational remediation (what actually fixes the misconfiguration)

The script only detects and monitors. To remediate per instance (done outside Python or via automation):
  • For web workloads:
    • Put instance behind an OCI Load Balancer with an HTTPS listener and valid certificate.
    • Or configure the web server (Nginx/Apache/etc.) on the instance to:
      • Enable HTTPS
      • Redirect all HTTP → HTTPS
  • For APIs/other services:
    • Require TLS (e.g., gRPC over TLS, TLS for custom TCP protocols).
  • For admin access:
    • Use SSH (already encrypted) instead of telnet/rsh, etc.
    • Use VPN / FastConnect for private access only.
You can extend the Python script to:
  • Tag non‑compliant instances: encryption_in_transit = "non_compliant"
  • Or send an Operations ticket / webhook for manual remediation.

If you specify your exact protocol/port (e.g., HTTP on 8080, custom API on 8443), I can adjust the example checks and metrics code accordingly.
In-transit encryption is configured on boot and block volume attachments, not on the oci_core_instance or monitoring resources, so it cannot be remediated via “OCI Compute Monitoring” directly.Changing is_pv_encryption_in_transit_enabled from false to true may force replacement of the volume attachment (detach/attach), which can cause downtime for that volume.Verification: terraform plan should show is_pv_encryption_in_transit_enabled: "false" => "true" on the relevant oci_core_boot_volume_attachment and/or oci_core_volume_attachment resources.