# Enforce SSL Connections on Azure MySQL Servers to Secure Data in Transit

- Source: https://support.icompaas.com/support/solutions/articles/62000234785-enforce-ssl-connections-on-azure-mysql-servers-to-secure-data-in-transit
- Section: [Solutions](https://support.icompaas.com/support/solutions) › [Azure Database Services Benchmark v1.0.0](https://support.icompaas.com/support/solutions/62000112693) › [Azure Database Services Benchmark](https://support.icompaas.com/support/solutions/folders/62000169261)
- Last updated: 2026-05-29
- Publisher: iCompaas, Inc. (https://www.icompaas.com)

**Profile Applicability:**

-   **Level 1**  
    

**Description:** Enforcing SSL connections ensures that MySQL servers require encrypted communication for data exchange, protecting data in transit from interception or tampering. This is critical for securing sensitive information.

**Rationale:** Enforcing SSL for MySQL servers adds an extra layer of security by ensuring all communications between the database server and client are encrypted, preventing "man-in-the-middle" attacks and data leakage.

**Impact:**

-   Pros:  
    
    -   Ensures encrypted communication, improving security.  
        
    -   Helps in meeting compliance standards (e.g., PCI DSS).  
        
    -   Prevents unauthorized interception of data in transit.  
        
-   Cons:  
    
    -   Some applications may need additional configuration to support SSL connections.  
        
    -   Enabling SSL can have a small performance overhead due to encryption/decryption operations.  
        

**Default Value:**

By default, SSL enforcement is not enabled when provisioning a MySQL database server.  

**Pre-requisites:** Ensure that your MySQL client supports SSL connections and has valid certificates configured.

**Remediation**

**Test Plan:**

**Using Azure Portal:**

1.  Log in to the Azure Portal: [https://portal.azure.com](https://portal.azure.com/).  
    
2.  Navigate to Azure Database for MySQL servers.  
    
3.  For each server, click on Connection security.  
    
4.  Under SSL settings, ensure that Enforce SSL connection is set to Enabled.  
    

**Using Azure CLI:**

1\. Run the following command to check the SSL enforcement status:  

az mysql server show --resource-group <resourceGroupName> --name <serverName> --query sslEnforcement

-   The output should show that sslEnforcement is set to Enabled.  
    

**Implementation Plan:**

**Using Azure Portal:**

1.  Go to Azure Database for MySQL servers.  
    
2.  Select the desired database server.  
    
3.  Under Connection security, click SSL settings.  
    
4.  Ensure Enforce SSL connection is set to Enabled.  
    

**Using Azure CLI:**  
1\.  To enable SSL connection enforcement, run

az mysql server update --resource-group <resourceGroupName> --name <serverName> --ssl-enforcement Enabled

  

**Backout Plan:**

**Using Azure Portal:**

1.  Go to Azure Database for MySQL servers.  
    
2.  Under Connection security, disable the Enforce SSL connection setting if necessary.  
    

**Using Azure CLI:**  
1.  To disable SSL connection enforcement, run:

az mysql server update --resource-group <resourceGroupName> --name <serverName> --ssl-enforcement Disabled

  

**References:**

-   [SSL Connection Security for Azure MySQL  
    ](https://docs.microsoft.com/en-us/azure/mysql/single-server/concepts-ssl-connection-security)
    
-   [How to Configure SSL for Azure MySQL](https://docs.microsoft.com/en-us/azure/mysql/single-server/how-to-configure-ssl)

## Related compliance guidance

- [SOC 2 compliance: a practical implementation guide for cloud-native SaaS teams](https://support.icompaas.com/compliance/soc-2-trust-services-criteria): Configuration checks like this one are the technical half of a SOC 2 / ISO 27001 programme — the guide shows where they fit, what else an auditor expects, and how to evidence them.
- [ISO/IEC 27001:2022 compliance: a practical implementation guide](https://support.icompaas.com/compliance/iso-27001-2022): ISO 27001 Annex A.8 (technological controls) is where cloud hardening evidence lands; the guide shows how to run the ISMS around it.
