CVE-2024-50687
Executive Summary
CVE-2024-50687 identifies an Insecure Direct Object Reference (IDOR) vulnerability in the SunGrow iSolarCloud platform, specifically within the devService API model. This flaw allows an authenticated attacker to manipulate direct object references (e.g., device IDs, user IDs) in API requests to access or modify resources belonging to other users without proper authorization. The vulnerability was remediated by the vendor on October 31, 2024, but no specific patched version has been publicly disclosed. Given the nature of the product—a cloud-based solar energy management system—exploitation could lead to unauthorized access to sensitive energy production data, device configurations, and potentially control over solar inverters and other connected hardware.
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
Supply Chain & Package Security
This vulnerability is not related to an open-source package (NPM, PyPI, Go, Ruby). It affects a proprietary cloud service (iSolarCloud) and its associated API. The supply chain risk is limited to the vendor's software development lifecycle and the security of the cloud infrastructure.
CVSS Breakdown & Threat Level
The CVSS score is listed as 0.0, indicating insufficient data for a full vector calculation. However, based on the vulnerability type (IDOR) and the context (cloud-based energy management), a reasonable estimated vector would be:
- Attack Vector (AV): Network (N) – Exploitable remotely via API calls.
- Attack Complexity (AC): Low (L) – Requires only valid authentication and knowledge of the API structure.
- Privileges Required (PR): Low (L) – An attacker needs a valid user account.
- User Interaction (UI): None (N) – No user action required beyond the attacker's own.
- Scope (S): Unchanged (U) – The vulnerable component is the API itself.
- Confidentiality Impact (C): High (H) – Exposure of other users' energy data and device configurations.
- Integrity Impact (I): High (H) – Potential to modify device settings or configurations.
- Availability Impact (A): Low (L) – Unlikely to cause denial of service, but possible through misconfiguration.
Estimated CVSS:3.1 Vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:L
Estimated Base Score: 7.6 (High)
Threat Level: High. The combination of remote exploitability, low privileges required, and potential for both data breach and device manipulation makes this a serious threat for SunGrow iSolarCloud users.
Deep Dive & Mechanics
The vulnerability resides in the devService API model of the iSolarCloud platform. IDOR vulnerabilities occur when an application exposes direct references to internal implementation objects (e.g., database keys, file names, device IDs) without proper access control checks.
Mechanism:
- Authentication Bypass (Partial): The attacker must first authenticate to the iSolarCloud platform as a legitimate user.
- API Discovery: The attacker identifies API endpoints under the
devServicemodel that accept parameters likedeviceId,userId,plantId, etc. - Parameter Manipulation: The attacker modifies these parameters in API requests to values belonging to other users. For example, changing
deviceId=12345todeviceId=67890. - Unauthorized Access: The server processes the request without verifying that the authenticated user has permission to access the resource identified by the manipulated parameter. This allows the attacker to:
- View energy production data of other solar plants.
- Access device configurations (inverter settings, panel layouts).
- Potentially modify device settings (e.g., power output limits, grid connection parameters).
- Retrieve personal information of other users (names, addresses, contact details).
Root Cause: The devService API lacks proper authorization checks. It relies on the client-provided object reference (e.g., device ID) to fetch data, but does not cross-reference this with the authenticated user's permissions. This is a classic case of missing function-level access control.
Vulnerable vs. Patched Code
No specific code snippets are available. The vulnerability is in the server-side API logic of the iSolarCloud platform.
Vulnerable (Conceptual):
# Vulnerable API endpoint
@app.route('/api/devService/getDeviceData', methods=['GET'])
def get_device_data():
device_id = request.args.get('deviceId')
# Directly query database without checking user permissions
device_data = db.query("SELECT * FROM devices WHERE id = ?", device_id)
return jsonify(device_data)
Patched (Conceptual):
# Patched API endpoint
@app.route('/api/devService/getDeviceData', methods=['GET'])
def get_device_data():
device_id = request.args.get('deviceId')
user_id = get_current_user_id() # From authentication token
# Verify that the current user has permission to access this device
if not db.query("SELECT 1 FROM user_devices WHERE user_id = ? AND device_id = ?", user_id, device_id):
return jsonify({"error": "Unauthorized"}), 403
device_data = db.query("SELECT * FROM devices WHERE id = ?", device_id)
return jsonify(device_data)
The patch introduces a permission check that ensures the authenticated user is explicitly linked to the requested device before returning any data.
Exploitation & Lab Setup
Red Team (Exploitation)
Prerequisites:
- A valid user account on the SunGrow iSolarCloud platform.
- Network access to the iSolarCloud API endpoints (typically
https://api.isolarcloud.comor a custom domain). - A tool like Burp Suite, Postman, or a custom Python script.
Exploitation Steps:
- Authenticate: Log in to the iSolarCloud web interface or API to obtain a session token (e.g., JWT, cookie).
- Intercept Traffic: Use Burp Suite to intercept API requests made by the web application.
- Identify IDOR Endpoint: Look for requests to endpoints under
/api/devService/that contain parameters likedeviceId,userId,plantId,sn, etc. - Manipulate Parameter: Send a request with a modified parameter value. For example:
ChangeGET /api/devService/getDeviceList?userId=12345 HTTP/1.1 Host: api.isolarcloud.com Authorization: Bearer <valid_token>userId=12345touserId=99999. - Observe Response: If the response returns data for user 99999, the IDOR is confirmed.
- Automate: Write a script to iterate through possible IDs and exfiltrate data.
Example Python Script (Conceptual):
import requests
base_url = "https://api.isolarcloud.com"
token = "<valid_token>"
headers = {"Authorization": f"Bearer {token}"}
# Brute-force device IDs
for device_id in range(1000, 2000):
url = f"{base_url}/api/devService/getDeviceData?deviceId={device_id}"
response = requests.get(url, headers=headers)
if response.status_code == 200 and "deviceName" in response.text:
print(f"Found device {device_id}: {response.text}")
Blue Team (Detection & Defense)
Detection:
- Monitor API logs for unusual patterns of parameter manipulation (e.g., sequential or random
deviceIdvalues from a single user). - Alert on
403 Forbiddenresponses followed by200 OKfor the same endpoint from the same IP (indicating a brute-force attempt). - Implement rate limiting on API endpoints that accept object references.
Defense:
- Immediate: Apply the vendor's October 31, 2024 patch. If not possible, implement a Web Application Firewall (WAF) rule to block requests with suspicious parameter patterns.
- Long-term: Enforce strict authorization checks on all API endpoints. Use a centralized authorization framework (e.g., OAuth 2.0 scopes, attribute-based access control). Never trust client-provided object references without verification.
Indicators of Compromise (IOCs)
Network IOCs:
- Unusual API requests to
/api/devService/endpoints with varyingdeviceId,userId, orplantIdparameters. - High volume of
403 Forbiddenresponses followed by200 OKfrom the same source IP. - Requests with
deviceIdvalues outside the expected range for the authenticated user.
Host IOCs (if attacker gains access to a user's machine):
- Presence of scripts or tools like
curl,wget, or custom Python scripts making repeated API calls. - Browser extensions or Burp Suite macros used for automated parameter manipulation.
Log IOCs:
- Application logs showing
SELECTqueries ondevicesoruserstables without correspondinguser_devicesjoin. - Authentication logs showing a single user accessing an unusually high number of distinct device IDs.
Detection Engineering
YARA Rule
rule Detect_iSolarCloud_IDOR_Exploitation {
meta:
description = "Detects potential IDOR exploitation attempts against SunGrow iSolarCloud devService API"
author = "Valters IT"
date = "2024-11-15"
reference = "CVE-2024-50687"
strings:
$api_path = "/api/devService/" ascii wide nocase
$param_deviceId = "deviceId=" ascii wide nocase
$param_userId = "userId=" ascii wide nocase
$param_plantId = "plantId=" ascii wide nocase
$http_get = "GET" ascii wide
$http_post = "POST" ascii wide
condition:
any of ($http*) and $api_path and any of ($param_*)
}
Sigma Rule
title: Suspicious API Parameter Manipulation to iSolarCloud devService
id: 7a8b9c0d-1e2f-3a4b-5c6d-7e8f9a0b1c2d
status: experimental
description: Detects potential IDOR exploitation attempts against SunGrow iSolarCloud devService API by monitoring for sequential or unusual parameter values.
author: Valters IT
date: 2024/11/15
references:
- https://nvd.nist.gov/vuln/detail/CVE-2024-50687
logsource:
category: web
product: iis
service: application
detection:
selection:
cs-uri-stem|contains: '/api/devService/'
cs-uri-query|contains|all:
- 'deviceId='
- 'userId='
- 'plantId='
condition: selection
falsepositives:
- Legitimate API usage by administrators
- Automated monitoring tools
level: high
Suricata Rule
alert http $HOME_NET any -> $EXTERNAL_NET any (msg:"CVE-2024-50687 Potential iSolarCloud IDOR Exploitation"; flow:to_server,established; content:"/api/devService/"; http_uri; nocase; content:"deviceId="; http_uri; nocase; pcre:"/deviceId=\d{5,}/"; classtype:attempted-recon; sid:1000001; rev:1;)
Remediation & Mitigation
Immediate Actions:
- Apply Vendor Patch: Contact SunGrow support to confirm the patch has been applied to your iSolarCloud instance. The remediation was applied on October 31, 2024.
- Verify Patch: After patching, test the
devServiceAPI endpoints to ensure that manipulatingdeviceIdoruserIdparameters returns a403 Forbiddenerror for unauthorized resources. - Review Access Logs: Examine API access logs for any signs of prior exploitation (unusual parameter patterns, data exfiltration).
Long-Term Mitigations:
- Implement Strong Authorization: Ensure all API endpoints enforce proper access control checks. Use a framework like Spring Security (Java) or Django REST Framework permissions (Python) to centralize authorization logic.
- Use Indirect Object References: Replace direct database IDs with random, non-guessable tokens (e.g., UUIDs) in API requests.
- Rate Limiting: Implement rate limiting on API endpoints to slow down brute-force attempts.
- Regular Security Audits: Conduct regular penetration testing and code reviews focusing on authorization flaws.
- User Education: Advise users to use strong, unique passwords and enable multi-factor authentication (MFA) if available.
Valters IT
What is this? Security researchers use these exact search queries on Shodan.io (a search engine for internet-connected devices) to find vulnerable systems globally. You can copy these dorks to see if your organization's IP space is exposed.