Thursday, September 17, 2026

PoC Exploit Released for Critical OpenSSH Vulnerability (CVE-2024-6387)

An alarming new development emerged in the cybersecurity landscape with the release of a proof-of-concept (PoC) exploit targeting the critical vulnerability identified as CVE-2024-6387.

This vulnerability, discovered by researchers at Qualys, allows remote unauthenticated attackers to execute arbitrary code on vulnerable OpenSSH servers, posing a significant risk to users relying on this widely utilized protocol for secure communication.

Overview of CVE-2024-6387

The vulnerability in question is characterized as a race condition within OpenSSH’s server daemon (sshd). Specifically, if a client does not authenticate within the defined LoginGraceTime, the system’s signal handler can lead to unsafe function calls.

The PoC exploit, developed by GitHub user YassDEV221608, is designed predominantly for 32-bit OpenSSH servers operating on Linux systems that utilize the GNU C Library (glibc). Notably, this flaw has been confirmed not to affect OpenBSD systems.

Investigate Real-World Malicious Links, Malware & Phishing Attacks With ANY.RUN – Try for Free

As per a report by Exploit Finder, the exploit takes advantage of a signal handler race condition, which occurs when sshd’s SIGALRM handler is activated due to a failed authentication attempt. This flaw allows attackers to gain unauthorized root access by executing code.

While the exploit requires extensive attempts to succeed, as noted by cybersecurity expert Schwartz, the potential impact is severe. OpenSSH developers confirmed this vulnerability impacts only specific versions, urging users to apply patches where available.

For security professionals and researchers looking to explore the exploit, the environment is set up using Docker. Below is a sample Dockerfile to create a vulnerable OpenSSH environment:

# Dockerfile to set up vulnerable OpenSSH server

FROM i386/ubuntu:20.04

ENV DEBIAN_FRONTEND=noninteractive

RUN dpkg --add-architecture i386 && apt-get update && apt-get install -y \

    build-essential \

    wget \

    curl \

    libssl-dev:i386 \

    zlib1g-dev:i386

RUN groupadd sshd && useradd -g sshd -s /bin/false sshd

RUN wget https://cdn.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-9.2p1.tar.gz && \

    tar -xzf openssh-9.2p1.tar.gz && \

    cd openssh-9.2p1 && \

    ./configure && make && make install

RUN mkdir /var/run/sshd

RUN echo 'root:password' | chpasswd

RUN sed -i 's/#PermitRootLogin prohibit-password/PermitRootLogin yes/' /usr/local/etc/sshd_config && \

    sed -i 's/#PasswordAuthentication yes/PasswordAuthentication yes/' /usr/local/etc/sshd_config && \

    echo 'MaxStartups 100:30:200' >> /usr/local/etc/sshd_config

EXPOSE 22

CMD ["/usr/local/sbin/sshd", "-D"]

Building the Docker Image

To build the Docker image, use the following command:

bash

sudo docker build --platform=linux/386 -t vulnerable-openssh:9.2p1 .

Running the Docker Container

Run the container with the command:

bash

sudo docker run --platform=linux/386 -d -p 2222:22 --name vuln-ssh-32bit vulnerable-openssh:9.2p1

PoC Script for Exploiting CVE-2024-6387

The exploit script CVE-2024-6387.py is a critical part of the PoC, allowing users to scan and exploit vulnerable servers. Below is an overview of the script’s functionality:

import argparse

import threading

import socket

import time

def exploit_vulnerability(target_ip, target_port):

    # Logic to exploit CVE-2024-6387

    # (This is a simplified demonstration)

    print(f"Exploiting target: {target_ip}:{target_port}")

    # Add actual exploitation code here...

def main():

    parser = argparse.ArgumentParser(description='CVE-2024-6387 PoC Exploit Script')

    parser.add_argument('-T', '--targets', required=True, help='Target IP addresses or domain names')

    parser.add_argument('-p', '--port', default=22, help='Port number to exploit (default: 22)')

    args = parser.parse_args()

    targets = args.targets.split(',')

    threads = []

    for target in targets:

        thread = threading.Thread(target=exploit_vulnerability, args=(target, args.port))

        threads.append(thread)

        thread.start()

    for thread in threads:

        thread.join()

if __name__ == "__main__":

    main()

To protect against CVE-2024-6387, system administrators are urged to update their OpenSSH installations to the latest versions, which include critical patches addressing this vulnerability.

Additionally, configurations that limit authentication attempts and enhance logging can help mitigate the risk of exploitation.

As the cybersecurity community reacts to the implications of CVE-2024-6387, the release of this exploit underscores the necessity of proactive security measures.

Organizations using OpenSSH are strongly advised to assess their systems for vulnerabilities and implement necessary updates to safeguard against potential attacks. 

Find this News Interesting! Follow us on Google NewsLinkedIn, and X to Get Instant Updates!

Divya
Divya
Divya is a Senior Journalist at GBhackers covering Cyber Attacks, Threats, Breaches, Vulnerabilities and other happenings in the cyber world.

Hot this week

How To Access Dark Web Anonymously and know its Secretive and Mysterious Activities

What is Deep Web The deep web, invisible web, or...

How to Build and Run a Security Operations Center (SOC Guide) – 2023

Today’s Cyber security operations center (CSOC) should have everything...

Russian Hackers Bypass EDR to Deliver a Weaponized TeamViewer Component

TeamViewer's popularity and remote access capabilities make it an...

Web Server Penetration Testing Checklist – 2026

Web server pentesting is performed under three significant categories: identity,...

ATM Penetration Testing – Advanced Testing Methods to Find The Vulnerabilities

ATM Penetration testing, Hackers have found different approaches to...

Docker Sandboxes Vulnerabilities Let Malicious Guests Escape Workspace and Access Host Files

Docker has released security fixes for two serious vulnerabilities...

Hackers Turn AI Agent Into a Cyber Weapon After Deleting Its Safety Refusals

A French-speaking cybercrime crew calling itself BlackHatSect0r && DXQRTXX...

Jenkins Patches 20 Plugin Flaws Leading to RCE, XSS and Credential Theft

Jenkins has released security updates addressing 20 vulnerabilities across...

NightEagle Hackers Target Russian Companies Using GhostContainer Backdoor

The NightEagle advanced persistent threat group, tracked as APT-Q-95,...

GhostCode Abuses Microsoft Entra Device Enrollment to Maintain Access After Token Revocation

A newly identified device-code phishing kit dubbed GhostCode exploits...

VectraRAT Malware-as-a-Service Lets Hackers Bypass UAC and Hijack Windows Systems

VectraRAT, a previously undocumented Malware-as-a-Service platform that combines remote-access...

TP-Link Tapo Camera Flaw Lets Attackers Gain Admin Access Without Password

Security researchers have revealed two vulnerabilities in TP-Link’s Tapo...

Related Articles

Recent News