Re: [libipq] owner of packet, possible patch

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> Hi,
>
> I'm a student in computer science and for my master thesis i have to
> handle packets in a userspace queue. Libipq works fine for me, except
> one information which is missing: the owner of a (transmitted) packet.

You may fine some interest in

http://people.mandriva.com/~sbellabes/cn_net/

It implements a new approach of local firewalling.

BR,
--
Regit

>
> With the following two additional lines, the problem seems to be solved:
>
> in file
>    include/linux/netfilter_ipv4/ip_queue.h
> in
>    typedef struct ipq_packet_msg_t
> line 33 add:
>
>         unsigned int uid;               /* uid of packet owner*/
>
>
> in file
>    net/ipv4/netfilter/ip_queue.c
> line 249 add:
>
>         pmsg->uid             = entry->skb->sk->sk_socket->file->f_uid;
>
>
> Initial tests have been successful and are showing the correct uid in
> ipq_packet_msg_t in userspace. Please tell me, what you think about
> this modification.
>
> Since I found some other people who are looking for the same
> information, i wonder if there is a possibility to include the uid
> field officially in the source of netfilter?!
>
> Regards,
> Jack
>
>




[Index of Archives]     [Linux Netfilter Development]     [Linux Kernel Networking Development]     [Netem]     [Berkeley Packet Filter]     [Linux Kernel Development]     [Advanced Routing & Traffice Control]     [Bugtraq]

  Powered by Linux