Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2024-0349 Overview
CVE-2024-0349 affects SourceCodester Engineers Online Portal 1.0. The application sets a sensitive cookie without the Secure attribute, allowing it to be transmitted over unencrypted HTTP connections. An attacker on the network path can capture the cookie and reuse it to impersonate the victim.
The weakness is classified as [CWE-614] (Sensitive Cookie in HTTPS Session Without 'Secure' Attribute). The flaw is exploitable remotely but requires conditions such as access to the victim's network traffic, making reliable exploitation harder than a typical web flaw.
Critical Impact
Session cookies can leak over plaintext channels, enabling session hijacking and unauthorized access to Engineers Online Portal user accounts.
Affected Products
- SourceCodester Engineers Online Portal 1.0
- Deployments of the engineers_online_portal project tracked under CPE cpe:2.3:a:engineers_online_portal_project:engineers_online_portal:1.0
- Downstream forks that inherit the vulnerable cookie configuration
Discovery Timeline
- 2024-01-09 - CVE-2024-0349 published to NVD
- 2026-06-17 - Last updated in NVD database
Technical Details for CVE-2024-0349
Vulnerability Analysis
The Engineers Online Portal issues session cookies without the Secure flag. Browsers therefore send these cookies on any request to the application host, including requests over plain HTTP. If an attacker can observe network traffic between the browser and server, the cookie value is exposed in cleartext.
Once captured, the cookie can be replayed to the application to assume the victim's authenticated session. The impact is limited to confidentiality of session data; integrity and availability are not directly affected. Exploitation requires network positioning, such as a shared Wi-Fi segment or a compromised upstream device, which raises attack complexity.
Root Cause
The root cause is improper cookie configuration in the application's authentication layer. The Set-Cookie response header omits the Secure directive, so the browser's cookie policy does not restrict transmission to HTTPS. This is a classic [CWE-614] misconfiguration common in PHP projects that do not set session.cookie_secure or pass the secure flag to setcookie().
Attack Vector
Exploitation is network-based and does not require authentication or user interaction. An attacker performs passive sniffing or an active man-in-the-middle on the victim's network path. When the victim or application triggers any HTTP request to the portal, the browser transmits the session cookie, which the attacker captures and replays. The vulnerability description notes that the exploit has been disclosed publicly through VulDB entry 250117, though no weaponized tooling is tracked in CISA KEV or Exploit-DB.
For technical details, see the VulDB entry for CVE-2024-0349.
Detection Methods for CVE-2024-0349
Indicators of Compromise
- Set-Cookie response headers from the Engineers Online Portal that do not include the Secure attribute
- Session cookies for the portal observed in HTTP (port 80) traffic captures
- Concurrent authenticated sessions for the same account from geographically or network-distinct source addresses
- Account activity that does not align with the legitimate user's normal access pattern
Detection Strategies
- Inspect HTTP responses from the application with a proxy such as Burp Suite or OWASP ZAP and flag any Set-Cookie header missing Secure or HttpOnly
- Deploy TLS inspection or NetFlow monitoring to identify plaintext HTTP sessions reaching the portal
- Correlate web server access logs with authentication events to spot session replay from unexpected IP addresses
Monitoring Recommendations
- Alert on any inbound traffic to the portal on TCP/80 if HTTPS is intended to be enforced
- Baseline per-user session source addresses and user agents, then alert on deviations
- Review web server logs for repeated use of the same session identifier from multiple source addresses within short time windows
How to Mitigate CVE-2024-0349
Immediate Actions Required
- Enforce HTTPS site-wide and redirect all HTTP requests to HTTPS at the web server
- Configure the application and PHP runtime to issue cookies with the Secure and HttpOnly attributes
- Rotate active session identifiers after applying the fix to invalidate previously exposed cookies
- Restrict exposure of the portal to trusted networks until a fix is deployed
Patch Information
No vendor patch is listed in the NVD record for CVE-2024-0349. SourceCodester has not published an advisory addressing the sensitive cookie configuration in Engineers Online Portal 1.0. Operators should apply the configuration-level mitigations below and monitor the VulDB CTI entry 250117 for updates.
Workarounds
- Set session.cookie_secure = 1 and session.cookie_httponly = 1 in php.ini for the portal
- Add Strict-Transport-Security headers to force browsers to use HTTPS for the portal domain
- Terminate TLS at a reverse proxy and configure it to rewrite Set-Cookie headers to include the Secure flag
- Disable plaintext HTTP listeners on the web server once HTTPS is confirmed working
# Configuration example
# php.ini hardening for session cookies
session.cookie_secure = 1
session.cookie_httponly = 1
session.cookie_samesite = "Strict"
# Apache: force HTTPS and add HSTS
<VirtualHost *:80>
ServerName portal.example.com
Redirect permanent / https://portal.example.com/
</VirtualHost>
<VirtualHost *:443>
ServerName portal.example.com
Header always set Strict-Transport-Security "max-age=31536000; includeSubDomains"
Header edit Set-Cookie ^(.*)$ $1;Secure;HttpOnly
</VirtualHost>
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

