lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:	Wed, 04 Jun 2008 15:16:36 -0700 (PDT)
From:	David Miller <davem@...emloft.net>
To:	den@...nvz.org
Cc:	netdev@...r.kernel.org
Subject: Re: [PATCH net-2.6] [RAW]: Raw socket leak.

From: "Denis V. Lunev" <den@...nvz.org>
Date: Fri, 30 May 2008 17:43:05 +0400

> The program below just leaks the raw kernel socket
> 
> int main() {
>         int fd = socket(PF_INET, SOCK_RAW, IPPROTO_UDP);
>         struct sockaddr_in addr;
> 
>         memset(&addr, 0, sizeof(addr));
>         inet_aton("127.0.0.1", &addr.sin_addr);
>         addr.sin_family = AF_INET;
>         addr.sin_port = htons(2048);
>         sendto(fd,  "a", 1, MSG_MORE, &addr, sizeof(addr));
>         return 0;
> }
> 
> Corked packet is allocated via sock_wmalloc which holds the owner socket,
> so one should uncork it and flush all pending data on close. Do this in the
> same way as in UDP.
> 
> Signed-off-by: Denis V. Lunev <den@...nvz.org>
> Acked-by: Alexey Kuznetsov <kuznet@....inr.ac.ru>

Applied, thanks Denis.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ