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] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANX6Dan5bdA-3wSiyAaQmOV6DHArxjknUFpR-s8coA9Yjx2N8A@mail.gmail.com>
Date:	Thu, 1 Sep 2011 15:40:12 -0400
From:	Viral Mehta <viral.vkm@...il.com>
To:	netdev@...r.kernel.org
Subject: Re: interface information for recvd packet

On Tue, Aug 30, 2011 at 11:55 AM, Viral Mehta <viral.vkm@...il.com> wrote:
>
> Hi,
>
> I was trying to implement following thing,
>
> 1. I wanted to know whenever packet received for particular socket, I
> want to know which network interface actually received it ?

My objective is still the same..

> 2. I was looking at net/ipv4/tcp.c and in function tcp_recvmsg(); I am
> trying to get interface name by accessing sk_buff->dev->name

I tried printing address of SKBs, but it gives different address in
NIC driver and tcp.c
My understanding is, struct sk_buff* remains same through out all
layers i.e., NIC driver allocates it after receving frame
and same is passed till TCP layer. But, apparently looks I am wrong
from the prints that I have put.

Can someone shed some light ?

>    However, it gives me (null). I have made sure that in my ethernet
> (NIC) driver, I filled up that information before doing netif_rx().
>
> So, the question is,
> Is this information Trimmed out at some upper layer ??
>

--
Thanks,
Viral Mehta
--
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