CVE-2018-20685
OpenSSH Remote Directory Permission Bypass Vulnerability
Description
In OpenSSH 7.9, scp.c in the scp client allows remote SSH servers to bypass intended access restrictions via the filename of . or an empty filename. The impact is modifying the permissions of the target directory on the client side.
INFO
Published Date :
Jan. 10, 2019, 9:29 p.m.
Last Modified :
Feb. 23, 2023, 11:15 p.m.
Source :
[email protected]
Remotely Exploitable :
Yes !
Impact Score :
3.6
Exploitability Score :
1.6
Public PoC/Exploit Available at Github
CVE-2018-20685 has a 13 public PoC/Exploit
available at Github.
Go to the Public Exploits
tab to see the list.
Affected Products
The following products are affected by CVE-2018-20685
vulnerability.
Even if cvefeed.io
is aware of the exact versions of the
products
that
are
affected, the information is not represented in the table below.
References to Advisories, Solutions, and Tools
Here, you will find a curated list of external links that provide in-depth
information, practical solutions, and valuable tools related to
CVE-2018-20685
.
We scan GitHub repositories to detect new proof-of-concept exploits. Following list is a collection of public exploits and proof-of-concepts, which have been published on GitHub (sorted by the most recently updated).
SSHScout is a lightweight tool designed to identify servers running SSH.
cve-2024-6387 openssh openssh-server ssh-banner vulnerability-checker vulnerability-detection
Python
None
None
Linux Restricted Shell Breakout & privilege escalation on Direct Admin using OpenSSH, CPAN shell and FileZilla.
None
This is a boot2root VM and is a continuation of the Basic Pentesting series. This series is designed to help newcomers to penetration testing develop pentesting skills and have fun exploring part of the offensive side of security. VirtualBox is the recommended platform for this challenge (though it should also work with VMware -- however, I haven’t tested that). This VM is a moderate step up in difficulty from the first entry in this series. If you’ve solved the first entry and have tried a few other beginner-oriented challenges, this VM should be a good next step. Once again, this challenge contains multiple initial exploitation vectors and privilege escalation vulnerabilities. Your goal is to remotely attack the VM, gain root privileges, and read the flag located at /root/flag.txt. Once you’ve finished, try to find other vectors you might have missed! If you’d like to send me a link to your writeup, enjoyed the VM or have questions or feedback, feel free to contact me at: [email protected] If you finished the VM, please also consider posting a writeup! Writeups help you internalize what you worked on and help anyone else who might be struggling or wants to see someone else’s process. There were lots of wonderful writeups for Basic Pentesting: 1, and I look forward to reading the writeups for this challenge.
None
Dockerfile Makefile Shell Go Smarty Open Policy Agent Mustache
This is walkthrough of another Boot2Root Vulnhub machine ! This can be a real life scenario if rockies becomes admins. Easy going in round about 15 mins.
None
Dockerfile Makefile
None
Dockerfile Makefile Shell Go Smarty Open Policy Agent
None
Dockerfile Makefile Shell Go Smarty
A Simple and Comprehensive Vulnerability Scanner for Containers, Suitable for CI for Web
Python HTML CSS JavaScript
None
Shell
Results are limited to the first 15 repositories due to potential performance issues.
The following list is the news that have been mention
CVE-2018-20685
vulnerability anywhere in the article.
The following table lists the changes that have been made to the
CVE-2018-20685
vulnerability over time.
Vulnerability history details can be useful for understanding the evolution of a vulnerability, and for identifying the most recent changes that may impact the vulnerability's severity, exploitability, or other characteristics.
-
CVE Modified by [email protected]
May. 14, 2024
Action Type Old Value New Value -
Modified Analysis by [email protected]
Feb. 23, 2023
Action Type Old Value New Value Removed CVSS V3 NIST AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:H/A:N Added CVSS V3.1 NIST AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:H/A:N Changed Reference Type http://www.securityfocus.com/bid/106531 Third Party Advisory, VDB Entry http://www.securityfocus.com/bid/106531 Broken Link Changed Reference Type https://access.redhat.com/errata/RHSA-2019:3702 No Types Assigned https://access.redhat.com/errata/RHSA-2019:3702 Third Party Advisory Changed Reference Type https://cert-portal.siemens.com/productcert/pdf/ssa-412672.pdf No Types Assigned https://cert-portal.siemens.com/productcert/pdf/ssa-412672.pdf Patch, Third Party Advisory Changed Reference Type https://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.bin/ssh/scp.c.diff?r1=1.197&r2=1.198&f=h Patch, Third Party Advisory https://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.bin/ssh/scp.c.diff?r1=1.197&r2=1.198&f=h Patch Changed Reference Type https://github.com/openssh/openssh-portable/commit/6010c0303a422a9c5fa8860c061bf7105eb7f8b2 Patch, Third Party Advisory https://github.com/openssh/openssh-portable/commit/6010c0303a422a9c5fa8860c061bf7105eb7f8b2 Patch Changed Reference Type https://security.gentoo.org/glsa/202007-53 No Types Assigned https://security.gentoo.org/glsa/202007-53 Third Party Advisory Changed Reference Type https://www.oracle.com/technetwork/security-advisory/cpuapr2019-5072813.html Patch https://www.oracle.com/technetwork/security-advisory/cpuapr2019-5072813.html Patch, Third Party Advisory Changed Reference Type https://www.oracle.com/technetwork/security-advisory/cpuoct2019-5072832.html No Types Assigned https://www.oracle.com/technetwork/security-advisory/cpuoct2019-5072832.html Patch, Third Party Advisory Changed CPE Configuration OR *cpe:2.3:o:redhat:enterprise_linux:7.0:*:*:*:*:*:*:* OR *cpe:2.3:o:redhat:enterprise_linux:7.0:*:*:*:*:*:*:* *cpe:2.3:o:redhat:enterprise_linux:8.0:*:*:*:*:*:*:* *cpe:2.3:o:redhat:enterprise_linux_eus:8.1:*:*:*:*:*:*:* *cpe:2.3:o:redhat:enterprise_linux_eus:8.2:*:*:*:*:*:*:* *cpe:2.3:o:redhat:enterprise_linux_eus:8.4:*:*:*:*:*:*:* *cpe:2.3:o:redhat:enterprise_linux_eus:8.6:*:*:*:*:*:*:* *cpe:2.3:o:redhat:enterprise_linux_server_aus:8.2:*:*:*:*:*:*:* *cpe:2.3:o:redhat:enterprise_linux_server_aus:8.4:*:*:*:*:*:*:* *cpe:2.3:o:redhat:enterprise_linux_server_aus:8.6:*:*:*:*:*:*:* *cpe:2.3:o:redhat:enterprise_linux_server_tus:8.2:*:*:*:*:*:*:* *cpe:2.3:o:redhat:enterprise_linux_server_tus:8.4:*:*:*:*:*:*:* *cpe:2.3:o:redhat:enterprise_linux_server_tus:8.6:*:*:*:*:*:*:* Added CPE Configuration AND OR *cpe:2.3:o:fujitsu:m10-1_firmware:*:*:*:*:*:*:*:* versions up to (excluding) xcp2361 OR cpe:2.3:h:fujitsu:m10-1:-:*:*:*:*:*:*:* Added CPE Configuration AND OR *cpe:2.3:o:fujitsu:m10-4_firmware:*:*:*:*:*:*:*:* versions up to (excluding) xcp2361 OR cpe:2.3:h:fujitsu:m10-4:-:*:*:*:*:*:*:* Added CPE Configuration AND OR *cpe:2.3:o:fujitsu:m10-4s_firmware:*:*:*:*:*:*:*:* versions up to (excluding) xcp2361 OR cpe:2.3:h:fujitsu:m10-4s:-:*:*:*:*:*:*:* Added CPE Configuration AND OR *cpe:2.3:o:fujitsu:m12-1_firmware:*:*:*:*:*:*:*:* versions up to (excluding) xcp2361 OR cpe:2.3:h:fujitsu:m12-1:-:*:*:*:*:*:*:* Added CPE Configuration AND OR *cpe:2.3:o:fujitsu:m12-2_firmware:*:*:*:*:*:*:*:* versions up to (excluding) xcp2361 OR cpe:2.3:h:fujitsu:m12-2:-:*:*:*:*:*:*:* Added CPE Configuration AND OR *cpe:2.3:o:fujitsu:m12-2s_firmware:*:*:*:*:*:*:*:* versions up to (excluding) xcp2361 OR cpe:2.3:h:fujitsu:m12-2s:-:*:*:*:*:*:*:* Added CPE Configuration AND OR *cpe:2.3:o:fujitsu:m10-1_firmware:*:*:*:*:*:*:*:* versions up to (excluding) xcp3070 OR cpe:2.3:h:fujitsu:m10-1:-:*:*:*:*:*:*:* Added CPE Configuration AND OR *cpe:2.3:o:fujitsu:m10-4_firmware:*:*:*:*:*:*:*:* versions up to (excluding) xcp3070 OR cpe:2.3:h:fujitsu:m10-4:-:*:*:*:*:*:*:* Added CPE Configuration AND OR *cpe:2.3:o:fujitsu:m10-4s_firmware:*:*:*:*:*:*:*:* versions up to (excluding) xcp3070 OR cpe:2.3:h:fujitsu:m10-4s:-:*:*:*:*:*:*:* Added CPE Configuration AND OR *cpe:2.3:o:fujitsu:m10-4s_firmware:*:*:*:*:*:*:*:* versions up to (excluding) xcp3070 OR cpe:2.3:h:fujitsu:m10-4s:-:*:*:*:*:*:*:* Added CPE Configuration AND OR *cpe:2.3:o:fujitsu:m12-1_firmware:*:*:*:*:*:*:*:* versions up to (excluding) xcp3070 OR cpe:2.3:h:fujitsu:m12-1:-:*:*:*:*:*:*:* Added CPE Configuration AND OR *cpe:2.3:o:fujitsu:m12-2_firmware:*:*:*:*:*:*:*:* versions up to (excluding) xcp3070 OR cpe:2.3:h:fujitsu:m12-2:-:*:*:*:*:*:*:* Added CPE Configuration AND OR *cpe:2.3:o:fujitsu:m12-2s_firmware:*:*:*:*:*:*:*:* versions up to (excluding) xcp3070 OR cpe:2.3:h:fujitsu:m12-2s:-:*:*:*:*:*:*:* Added CPE Configuration AND OR *cpe:2.3:o:siemens:scalance_x204rna_firmware:*:*:*:*:*:*:*:* versions up to (excluding) 3.2.7 OR cpe:2.3:h:siemens:scalance_x204rna:-:*:*:*:*:*:*:* Added CPE Configuration AND OR *cpe:2.3:o:siemens:scalance_x204rna_eec_firmware:*:*:*:*:*:*:*:* versions up to (excluding) 3.2.7 OR cpe:2.3:h:siemens:scalance_x204rna_eec:-:*:*:*:*:*:*:* -
CVE Modified by [email protected]
Dec. 13, 2022
Action Type Old Value New Value Added Reference https://cert-portal.siemens.com/productcert/pdf/ssa-412672.pdf [No Types Assigned] -
CWE Remap by [email protected]
Aug. 24, 2020
Action Type Old Value New Value Changed CWE CWE-706 CWE-863 -
CVE Modified by [email protected]
Jul. 28, 2020
Action Type Old Value New Value Removed Reference https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2018-20685 [Issue Tracking, Patch, Third Party Advisory] Added Reference https://security.gentoo.org/glsa/202007-53 [No Types Assigned] -
CVE Modified by [email protected]
Nov. 06, 2019
Action Type Old Value New Value Added Reference https://access.redhat.com/errata/RHSA-2019:3702 [No Types Assigned] -
CVE Modified by [email protected]
Oct. 16, 2019
Action Type Old Value New Value Added Reference https://www.oracle.com/technetwork/security-advisory/cpuoct2019-5072832.html [No Types Assigned] -
CWE Remap by [email protected]
Oct. 03, 2019
Action Type Old Value New Value Changed CWE CWE-284 CWE-284 CWE-706 -
Modified Analysis by [email protected]
Apr. 25, 2019
Action Type Old Value New Value Changed Reference Type https://www.oracle.com/technetwork/security-advisory/cpuapr2019-5072813.html No Types Assigned https://www.oracle.com/technetwork/security-advisory/cpuapr2019-5072813.html Patch Added CPE Configuration OR *cpe:2.3:o:redhat:enterprise_linux:7.0:*:*:*:*:*:*:* Added CPE Configuration OR *cpe:2.3:o:oracle:solaris:10:*:*:*:*:*:*:* -
CVE Modified by [email protected]
Apr. 23, 2019
Action Type Old Value New Value Added Reference https://www.oracle.com/technetwork/security-advisory/cpuapr2019-5072813.html [No Types Assigned] -
Modified Analysis by [email protected]
Mar. 29, 2019
Action Type Old Value New Value Changed Reference Type https://lists.debian.org/debian-lts-announce/2019/03/msg00030.html No Types Assigned https://lists.debian.org/debian-lts-announce/2019/03/msg00030.html Mailing List, Third Party Advisory Changed Reference Type https://security.gentoo.org/glsa/201903-16 No Types Assigned https://security.gentoo.org/glsa/201903-16 Third Party Advisory Changed CPE Configuration OR *cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:* OR *cpe:2.3:o:debian:debian_linux:8.0:*:*:*:*:*:*:* *cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:* -
CVE Modified by [email protected]
Mar. 25, 2019
Action Type Old Value New Value Added Reference https://lists.debian.org/debian-lts-announce/2019/03/msg00030.html [No Types Assigned] -
CVE Modified by [email protected]
Mar. 21, 2019
Action Type Old Value New Value Added Reference https://security.gentoo.org/glsa/201903-16 [No Types Assigned] -
Modified Analysis by [email protected]
Feb. 26, 2019
Action Type Old Value New Value Changed Reference Type https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2018-20685 Patch, Third Party Advisory https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2018-20685 Issue Tracking, Patch, Third Party Advisory Changed Reference Type https://www.debian.org/security/2019/dsa-4387 No Types Assigned https://www.debian.org/security/2019/dsa-4387 Third Party Advisory Changed Reference Type https://sintonen.fi/advisories/scp-client-multiple-vulnerabilities.txt No Types Assigned https://sintonen.fi/advisories/scp-client-multiple-vulnerabilities.txt Patch, Third Party Advisory Changed Reference Type https://security.netapp.com/advisory/ntap-20190215-0001/ No Types Assigned https://security.netapp.com/advisory/ntap-20190215-0001/ Third Party Advisory Changed Reference Type https://usn.ubuntu.com/3885-1/ No Types Assigned https://usn.ubuntu.com/3885-1/ Third Party Advisory Changed CPE Configuration OR *cpe:2.3:a:openbsd:openssh:7.9:*:*:*:*:*:*:* OR *cpe:2.3:a:openbsd:openssh:*:*:*:*:*:*:*:* versions up to (including) 7.9 *cpe:2.3:a:winscp:winscp:*:*:*:*:*:*:*:* versions up to (including) 5.13 Added CPE Configuration OR *cpe:2.3:a:netapp:cloud_backup:-:*:*:*:*:*:*:* *cpe:2.3:a:netapp:element_software:-:*:*:*:*:*:*:* *cpe:2.3:a:netapp:ontap_select_deploy:-:*:*:*:*:*:*:* *cpe:2.3:a:netapp:steelstore_cloud_integrated_storage:-:*:*:*:*:*:*:* *cpe:2.3:a:netapp:storage_automation_store:-:*:*:*:*:*:*:* Added CPE Configuration OR *cpe:2.3:o:debian:debian_linux:9.0:*:*:*:*:*:*:* Added CPE Configuration OR *cpe:2.3:o:canonical:ubuntu_linux:14.04:*:*:*:lts:*:*:* *cpe:2.3:o:canonical:ubuntu_linux:16.04:*:*:*:lts:*:*:* *cpe:2.3:o:canonical:ubuntu_linux:18.04:*:*:*:lts:*:*:* *cpe:2.3:o:canonical:ubuntu_linux:18.10:*:*:*:*:*:*:* -
CVE Modified by [email protected]
Feb. 16, 2019
Action Type Old Value New Value Added Reference https://security.netapp.com/advisory/ntap-20190215-0001/ [No Types Assigned] -
CVE Modified by [email protected]
Feb. 10, 2019
Action Type Old Value New Value Added Reference https://www.debian.org/security/2019/dsa-4387 [No Types Assigned] -
CVE Modified by [email protected]
Feb. 09, 2019
Action Type Old Value New Value Added Reference https://usn.ubuntu.com/3885-1/ [No Types Assigned] -
CVE Modified by [email protected]
Jan. 31, 2019
Action Type Old Value New Value Changed Description In OpenSSH 7.9, scp.c in the scp client allows remote SSH servers to bypass intended access restrictions via the filename of . or an empty filename. In OpenSSH 7.9, scp.c in the scp client allows remote SSH servers to bypass intended access restrictions via the filename of . or an empty filename. The impact is modifying the permissions of the target directory on the client side. Added Reference https://sintonen.fi/advisories/scp-client-multiple-vulnerabilities.txt [No Types Assigned] -
Initial Analysis by [email protected]
Jan. 29, 2019
Action Type Old Value New Value Added CVSS V2 Metadata Victim must voluntarily interact with attack mechanism Added CVSS V2 (AV:N/AC:H/Au:N/C:N/I:P/A:N) Added CVSS V3 AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:H/A:N Changed Reference Type https://github.com/openssh/openssh-portable/commit/6010c0303a422a9c5fa8860c061bf7105eb7f8b2 No Types Assigned https://github.com/openssh/openssh-portable/commit/6010c0303a422a9c5fa8860c061bf7105eb7f8b2 Patch, Third Party Advisory Changed Reference Type http://www.securityfocus.com/bid/106531 No Types Assigned http://www.securityfocus.com/bid/106531 Third Party Advisory, VDB Entry Changed Reference Type https://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.bin/ssh/scp.c.diff?r1=1.197&r2=1.198&f=h No Types Assigned https://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.bin/ssh/scp.c.diff?r1=1.197&r2=1.198&f=h Patch, Third Party Advisory Added Reference https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2018-20685 [Patch, Third Party Advisory] Added CWE CWE-284 Added CPE Configuration OR *cpe:2.3:a:openbsd:openssh:7.9:*:*:*:*:*:*:* -
CVE Modified by [email protected]
Jan. 12, 2019
Action Type Old Value New Value Added Reference http://www.securityfocus.com/bid/106531 [No Types Assigned]
CWE - Common Weakness Enumeration
While CVE identifies
specific instances of vulnerabilities, CWE categorizes the common flaws or
weaknesses that can lead to vulnerabilities. CVE-2018-20685
is
associated with the following CWEs:
Common Attack Pattern Enumeration and Classification (CAPEC)
Common Attack Pattern Enumeration and Classification
(CAPEC)
stores attack patterns, which are descriptions of the common attributes and
approaches employed by adversaries to exploit the CVE-2018-20685
weaknesses.
Exploit Prediction
EPSS is a daily estimate of the probability of exploitation activity being observed over the next 30 days.
0.38 }} -0.10%
score
0.73158
percentile