What it is: Cleartext Transmission of Sensitive Information (CWE-319) is a type of vulnerability that occurs when sensitive data is transmitted over an unsecured communication channel.
Why it matters: This can lead to unauthorized access and modification of sensitive information, posing significant security risks.
How to fix it: Encrypt the data before transmission using secure protocols like TLS/SSL.
TL;DR: Cleartext Transmission of Sensitive Information (CWE-319) is a critical vulnerability where sensitive data is transmitted without encryption, making it susceptible to interception. The primary remediation involves encrypting all communications with reliable cryptographic protocols.
| Field | Value |
|---|---|
| CWE ID | CWE-319 |
| OWASP Category | A04:2025 - Cryptographic Failures |
| CAPEC | CAPEC-102, CAPEC-117, CAPEC-383, CAPEC-477, CAPEC-65 |
| Typical Severity | Critical |
| Affected Technologies | web protocols, network communication |
| Detection Difficulty | Moderate |
| Last Updated | 2026-07-29 |
What is Cleartext Transmission of Sensitive Information?
Cleartext Transmission of Sensitive Information (CWE-319) is a type of vulnerability that occurs when sensitive or security-critical data is transmitted in cleartext over an unsecured communication channel, making it vulnerable to interception by unauthorized actors. As defined by the MITRE Corporation under CWE-319, and classified by the OWASP Foundation under A04:2025 - Cryptographic Failures.
Quick Summary
Cleartext Transmission of Sensitive Information is a critical security vulnerability that occurs when sensitive data is transmitted without encryption over unsecured communication channels. This can lead to unauthorized access and modification of sensitive information, posing significant risks such as financial loss, compliance issues, and reputational damage. Jump to: What it is · Why it matters · Where it occurs · Who is affected · Who is NOT affected
Jump to: Quick Summary · Cleartext Transmission of Sensitive Information Overview · How Cleartext Transmission of Sensitive Information Works · Business Impact of Cleartext Transmission of Sensitive Information · Cleartext Transmission of Sensitive Information Attack Scenario · How to Detect Cleartext Transmission of Sensitive Information · How to Fix Cleartext Transmission of Sensitive Information · Framework-Specific Fixes for Cleartext Transmission of Sensitive Information · How to Ask AI to Check Your Code for Cleartext Transmission of Sensitive Information · Cleartext Transmission of Sensitive Information Best Practices Checklist · Cleartext Transmission of Sensitive Information FAQ · Vulnerabilities Related to Cleartext Transmission of Sensitive Information · References · Scan Your Own Site
Cleartext Transmission of Sensitive Information Overview
What
Cleartext Transmission of Sensitive Information (CWE-319) involves transmitting sensitive data over unsecured communication channels, making the data vulnerable to interception by unauthorized actors.
Why it matters
This vulnerability can lead to significant security breaches where attackers can read and modify sensitive information during transmission. Unauthorized access and modification can result in financial loss, compliance issues, and reputational damage.
Where it occurs
Cleartext Transmission of Sensitive Information typically occurs when web applications or other systems transmit data over HTTP instead of HTTPS, exposing the communication channel to interception.
Who is affected
Applications that do not use secure protocols like TLS/SSL for transmitting sensitive information are at risk. This includes any application where security-critical data is sent over an unsecured network connection.
Who is NOT affected
Systems already using encrypted channels (such as HTTPS) and properly configured servers to enforce encryption for all communication are not vulnerable to this issue.
How Cleartext Transmission of Sensitive Information Works
Root Cause
The root cause lies in the lack of proper encryption mechanisms when transmitting sensitive data over unsecured communication channels, leading to potential interception by unauthorized actors.
Attack Flow
- An attacker gains access to a network interface or any link along the transmission path.
- The attacker sniffs the cleartext data as it traverses the network.
- Sensitive information is intercepted and potentially modified during transmission.
Prerequisites to Exploit
- Access to an intermediary node on the communication channel.
- Ability to monitor traffic without being detected by security measures.
Vulnerable Code
import requests
def send_data(url, data):
response = requests.post(url, data=data)
return response.text
This code sends sensitive data over HTTP without encryption, making it vulnerable to interception and modification during transmission.
Secure Code
import requests
def send_data_securely(url, data):
secure_url = url.replace('http://', 'https://')
response = requests.post(secure_url, data=data)
return response.text
The secure version ensures that the data is transmitted over HTTPS, encrypting it and preventing interception by unauthorized actors.
Business Impact of Cleartext Transmission of Sensitive Information
Confidentiality
Sensitive information can be read by unauthorized actors during transmission.
- Financial loss from stolen credentials or sensitive data exposure.
- Compliance penalties for failing to protect customer data.
Integrity
Sensitive information can be modified during transmission, leading to tampered data reaching the destination.
- Unauthorized modifications can lead to operational disruptions and financial losses.
Cleartext Transmission of Sensitive Information Attack Scenario
- An attacker gains access to a network interface or any link along the communication path between the client and server.
- The attacker sniffs the cleartext data as it traverses the network.
- The intercepted sensitive information is read and potentially modified during transmission.
How to Detect Cleartext Transmission of Sensitive Information
Manual Testing
- Check if sensitive data is transmitted over HTTP instead of HTTPS.
- Verify that all communication channels are properly encrypted using TLS/SSL.
Automated Scanners (SAST / DAST)
Static analysis can detect hard-coded URLs or configurations transmitting data without encryption. Dynamic testing requires observing actual network traffic to confirm cleartext transmission.
PenScan Detection
PenScan’s scanner engines such as ZAP, Nuclei, Wapiti, and Nikto are effective in identifying unencrypted communication channels.
- ZAP: Detects HTTP requests without proper SSL/TLS configuration.
- Nikto: Identifies servers not enforcing HTTPS for sensitive data transmission.
False Positive Guidance
False positives can occur if the scanner detects encrypted traffic but misinterprets it as cleartext due to incorrect configurations or network anomalies. Ensure that all detected instances are verified against actual network traffic and configurations.
How to Fix Cleartext Transmission of Sensitive Information
- Encrypt sensitive data before transmission using reliable cryptographic protocols like TLS/SSL.
- Configure servers to use encrypted channels for communication, ensuring proper SSL/TLS configuration.
- Use tools and techniques such as penetration testing and threat modeling to identify and remediate cleartext transmission issues.
Framework-Specific Fixes for Cleartext Transmission of Sensitive Information
Python (Django)
Ensure that all sensitive data is transmitted over HTTPS by configuring Django settings:
SECURE_SSL_REDIRECT = True
This setting forces all incoming requests to be redirected to HTTPS, ensuring encrypted communication.
Java
Configure the web server or application container to enforce SSL/TLS for all communication channels. For example, in a Spring Boot application:
@Bean
public SecurityWebFilterChain securityWebFilterChain(ServerHttpSecurity http) {
return http.requiresChannel().anyRequest().requiresSecure().and().build();
}
This configuration ensures that all requests are redirected to HTTPS.
Node.js
Use middleware to enforce SSL/TLS for sensitive data transmission:
app.use((req, res, next) => {
if (!req.secure) {
return res.redirect(`https://${req.headers.host}${req.url}`);
}
next();
});
This code redirects all HTTP requests to HTTPS.
How to Ask AI to Check Your Code for Cleartext Transmission of Sensitive Information
Review the following Python code block for potential CWE-319 Cleartext Transmission of Sensitive Information vulnerabilities and rewrite it using secure communication protocols:
Review the following [language] code block for potential CWE-319 Cleartext Transmission of Sensitive Information vulnerabilities and rewrite it using [primary fix technique]: [paste code here]
Cleartext Transmission of Sensitive Information Best Practices Checklist
- ✅ Ensure all sensitive data is transmitted over HTTPS.
- ✅ Configure servers to enforce SSL/TLS for communication channels.
- ✅ Use tools like ZAP and Nikto to detect unencrypted communication.
Cleartext Transmission of Sensitive Information FAQ
How does cleartext transmission of sensitive information occur?
It happens when data is transmitted without encryption, making it vulnerable to interception by unauthorized actors.
What are the consequences of cleartext transmission of sensitive information?
Unauthorized access and modification of sensitive data can lead to financial loss and reputational damage.
How does an attacker exploit cleartext transmission of sensitive information?
An attacker can intercept network traffic to steal or modify transmitted data, leading to security breaches.
What is the primary fix for cleartext transmission of sensitive information?
Encrypting data before transmission using reliable cryptographic protocols ensures confidentiality and integrity.
How do I detect cleartext transmission of sensitive information in my application?
Use tools like SSL/TLS scanners to check if your application uses encrypted channels for communication.
Can you provide an example of vulnerable code related to cleartext transmission of sensitive information?
Vulnerable code sends data over HTTP instead of HTTPS, exposing it to interception.
What are the best practices to prevent cleartext transmission of sensitive information?
Always use secure protocols like TLS/SSL for all data transmissions and ensure proper configuration.
Vulnerabilities Related to Cleartext Transmission of Sensitive Information
| CWE | Name | Relationship |
|---|---|---|
| CWE-311 | Missing Encryption of Sensitive Data | ChildOf |
References
Scan Your Own Site
Manual code review catches what you know to look for. An automated scan catches what you didn’t. Scan your own website using PenScan to find Cleartext Transmission of Sensitive Information and other risks before an attacker does.