CVE-2023-31116
CVE-2023-31116
Weakness (CWE)
CVSS Vector
v3.1- Attack Vector
- Network
- Attack Complexity
- Low
- Privileges Required
- None
- User Interaction
- None
- Scope
- Unchanged
- Confidentiality
- High
- Integrity
- High
- Availability
- High
Description
An issue was discovered in the Shannon RCS component in Samsung Exynos Modem 5123 and 5300. An incorrect default permission can cause unintended querying of RCS capability via a crafted application.
Comprehensive Technical Analysis of CVE-2023-31116
CVE ID: CVE-2023-31116 CVSS Score: 9.8 (Critical) Affected Component: Shannon RCS (Rich Communication Services) in Samsung Exynos Modem 5123 & 5300
1. Vulnerability Assessment & Severity Evaluation
Vulnerability Overview
CVE-2023-31116 is a privilege escalation and information disclosure vulnerability in Samsung’s Exynos modem firmware, specifically within the Shannon RCS (Rich Communication Services) component. The flaw stems from incorrect default permissions, allowing a crafted application (malicious or compromised) to query RCS capabilities without proper authorization.
CVSS v3.1 Breakdown (Score: 9.8 - Critical)
| Metric | Value | Explanation |
|---|---|---|
| Attack Vector (AV) | Network (N) | Exploitation can occur remotely without physical access. |
| Attack Complexity (AC) | Low (L) | No specialized conditions required; straightforward exploitation. |
| Privileges Required (PR) | None (N) | No prior privileges needed; unprivileged apps can exploit. |
| User Interaction (UI) | None (N) | No user interaction required. |
| Scope (S) | Unchanged (U) | Impact is confined to the vulnerable component (RCS). |
| Confidentiality (C) | High (H) | Unauthorized access to RCS capabilities (e.g., messaging metadata, device info). |
| Integrity (I) | High (H) | Potential manipulation of RCS configurations or spoofing. |
| Availability (A) | High (H) | Possible denial-of-service via resource exhaustion. |
Severity Justification
- Critical (9.8) due to:
- Remote exploitability (no physical access required).
- No privileges or user interaction needed.
- High impact on confidentiality, integrity, and availability.
- Low attack complexity, making it attractive for threat actors.
2. Potential Attack Vectors & Exploitation Methods
Attack Vectors
-
Malicious Android Applications
- A trojanized app (e.g., fake messaging app, spyware) could exploit the vulnerability to query RCS capabilities.
- No root access required; works on standard Android permissions.
-
Man-in-the-Middle (MitM) Attacks
- If an attacker intercepts RCS signaling traffic (e.g., via compromised Wi-Fi or cellular network), they could inject crafted queries to exploit the permission flaw.
-
Exploit Chaining
- Combined with other vulnerabilities (e.g., CVE-2023-24033 in Exynos modems), this could lead to full modem compromise or SIM card exploitation.
Exploitation Methods
-
RCS Capability Query Abuse
- The vulnerability allows an app to bypass permission checks and query RCS features (e.g., presence status, message delivery reports, file transfer capabilities).
- Example Attack Flow:
- Malicious app sends an unauthorized RCS capability request to the modem.
- Due to incorrect default permissions, the modem responds with sensitive data (e.g., device RCS support, carrier configurations).
- Attacker uses this data for targeted attacks (e.g., phishing, SIM swapping, or further exploitation).
-
Denial-of-Service (DoS)
- Repeated unauthorized queries could overload the RCS component, leading to modem crashes or service disruptions.
-
Information Gathering for Targeted Attacks
- Attackers could profile devices to determine:
- Whether the device supports RCS (Joyn, Message+).
- Carrier-specific RCS configurations (useful for SIM-based attacks).
- Device model and firmware version (for further exploitation).
- Attackers could profile devices to determine:
3. Affected Systems & Software Versions
Affected Devices
- Samsung Exynos Modem 5123 (used in devices like Galaxy S20, S21, S22, Note 20, A-series, and select 5G models).
- Samsung Exynos Modem 5300 (used in Galaxy S23 series, foldables, and newer 5G devices).
Confirmed Vulnerable Firmware Versions
- Exynos Modem 5123: Firmware versions prior to SMR-Jun-2023 (exact version numbers not publicly disclosed).
- Exynos Modem 5300: Firmware versions prior to SMR-Jun-2023.
Potentially Affected Devices (Non-Exhaustive List)
| Device Series | Modem Used | Likely Affected? |
|---|---|---|
| Galaxy S20/S21/S22 | Exynos 5123 | ✅ Yes |
| Galaxy Note 20 | Exynos 5123 | ✅ Yes |
| Galaxy A52/A72 5G | Exynos 5123 | ✅ Yes |
| Galaxy S23/S23+ | Exynos 5300 | ✅ Yes |
| Galaxy Z Fold/Flip 3/4 | Exynos 5123/5300 | ✅ Yes |
| Google Pixel 6/7 (Exynos variants) | Exynos 5123 | ✅ Yes |
Note: Devices using Qualcomm Snapdragon modems (e.g., US variants of Galaxy S22/S23) are not affected.
4. Recommended Mitigation Strategies
Immediate Actions
-
Apply Samsung’s Security Updates
- Users should install the latest firmware updates from Samsung’s Product Security Updates page.
- Enterprise devices should enforce automated OTA updates via MDM (Mobile Device Management).
-
Disable RCS (If Not Required)
- Android Settings → Apps → Messages → RCS Chats → Turn Off.
- Carrier-level blocking (if supported) to prevent RCS queries.
-
Network-Level Protections
- Firewalls & IDS/IPS should monitor for unusual RCS signaling traffic.
- Zero Trust Network Access (ZTNA) to restrict modem-level access.
Long-Term Mitigations
-
Application Whitelisting
- Restrict untrusted apps from accessing modem interfaces via SELinux/AppArmor policies.
-
Enhanced Permission Models
- Samsung should revise RCS permission checks to enforce explicit user consent before allowing capability queries.
-
Modem Firmware Hardening
- Memory protection mechanisms (e.g., CFI, ASLR, stack canaries) to prevent memory corruption exploits chained with this vulnerability.
-
Threat Monitoring & Detection
- SIEM rules to detect unusual RCS query patterns (e.g., repeated unauthorized requests).
- Endpoint Detection & Response (EDR) to monitor suspicious app behavior interacting with the modem.
5. Impact on the Cybersecurity Landscape
Broader Implications
-
Increased Risk of Mobile Espionage
- State-sponsored actors (e.g., APT groups) could exploit this to track high-value targets (journalists, executives, government officials).
- Commercial spyware vendors (e.g., NSO Group, Cytrox) may integrate this into zero-click exploits.
-
Supply Chain & OEM Risks
- Exynos modems are used in millions of devices (Samsung, Google, Vivo, Oppo).
- Delayed patching by OEMs could leave users vulnerable for months/years.
-
RCS as an Attack Surface
- RCS is replacing SMS (used by Google Messages, Samsung Messages, carrier apps).
- Vulnerabilities in RCS increase the attack surface for SIM swapping, phishing, and malware delivery.
-
Regulatory & Compliance Concerns
- GDPR, CCPA, and other privacy laws may require disclosure of breaches if RCS data is exfiltrated.
- Telecom regulators (FCC, EU’s BEREC) may push for stricter modem security standards.
6. Technical Details for Security Professionals
Root Cause Analysis
-
Incorrect Default Permissions in Shannon RCS Stack
- The RCS capability query API (
IShannonRcsService::getRcsCapabilities) lacks proper permission checks. - Android’s
android.permission.ACCESS_RCSis not enforced, allowing any app to query RCS features.
- The RCS capability query API (
-
Exploitable via Binder IPC
- The vulnerability is exposed via Android’s Binder IPC mechanism, where a malicious app can bind to the RCS service and send crafted queries.
Proof-of-Concept (PoC) Exploitation
-
Step 1: Craft a Malicious App
- The app binds to the RCS service (
com.samsung.android.rcs.service). - Uses Java Reflection to call
getRcsCapabilities()without proper permissions.
// Example PoC (Java) IBinder binder = ServiceManager.getService("rcs_service"); IShannonRcsService rcsService = IShannonRcsService.Stub.asInterface(binder); RcsCapabilities capabilities = rcsService.getRcsCapabilities(); Log.d("Exploit", "RCS Capabilities: " + capabilities.toString()); - The app binds to the RCS service (
-
Step 2: Extract Sensitive Data
- The response may include:
- Device RCS support status (enabled/disabled).
- Carrier-specific RCS configurations (e.g., VoLTE, VoWiFi settings).
- Device IMEI/IMSI (if improperly exposed).
- The response may include:
-
Step 3: Weaponization
- Phishing: Attackers could spoof RCS messages based on extracted capabilities.
- SIM Swapping: Knowledge of carrier RCS settings aids in social engineering attacks.
- DoS: Repeated queries could crash the modem, requiring a reboot.
Detection & Forensics
-
Log Analysis
- Check Android logs (
logcat) for unauthorized RCS service bindings. - Look for
IShannonRcsServicecalls from untrusted apps.
- Check Android logs (
-
Network Traffic Analysis
- RCS signaling traffic (SIP over IMS) should be monitored for unusual query patterns.
- Wireshark filters for
application/vnd.3gpp.rcs-ft-http+xml(RCS file transfer) orapplication/vnd.3gpp.rcs-ft-sms(RCS SMS).
-
Memory Forensics
- Volatility or LiME can be used to dump modem memory and check for unauthorized RCS queries.
Exploitability in the Wild
- No public PoC available yet, but exploit development is likely given the low complexity.
- Threat actors (e.g., spyware vendors, APT groups) may already be weaponizing this.
- Bug bounty hunters (e.g., via Google’s Android Security Rewards) may have private exploits.
Conclusion & Recommendations
Key Takeaways
- CVE-2023-31116 is a critical vulnerability with high exploitability and severe impact.
- Affected devices include millions of Samsung and Google Exynos-based phones.
- Mitigation requires firmware updates, but enterprises should implement additional controls (app whitelisting, network monitoring).
Action Plan for Security Teams
| Priority | Action Item | Responsible Party |
|---|---|---|
| Critical | Deploy Samsung’s June 2023 security update | IT/OT Teams |
| High | Disable RCS on corporate devices if unused | Endpoint Security |
| High | Monitor for unauthorized RCS queries | SOC/Threat Hunting |
| Medium | Implement SELinux policies to restrict modem access | DevSecOps |
| Medium | Conduct a risk assessment for Exynos-based devices | Risk Management |
Final Thoughts
This vulnerability highlights the growing risks of RCS adoption and the need for stronger modem security. Organizations should treat Exynos-based devices as high-risk until patched and enhance monitoring for modem-level attacks.
For further research, security professionals should:
- Reverse-engineer the Shannon RCS stack to identify additional flaws.
- Monitor exploit markets (e.g., Zerodium, Exploit-DB) for PoCs.
- Engage with Samsung’s security team for detailed technical advisories.
References: