LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-29-2008, 08:41 PM   #1
bharati.bhole
LQ Newbie
 
Registered: Jan 2008
Posts: 2

Rep: Reputation: 0
Question Accessing IP table.


Hi,
My project is to implement iptable support for a network driver.
For this purpose I want to know all the filters set by Linux stack so that when I receive a packet on my network card I can accept it or reject it depending on the filter rules in the table. For this I need access to iptable NF_IP_LOCAL_IN.

Could anybody please help me for finding out the hook for iptable NF_IP_LOCAL_IN.

Regards,
Bharati.
 
Old 01-29-2008, 10:09 PM   #2
bsdunix
Senior Member
 
Registered: May 2006
Distribution: Caldera, CTOS, Debian, FreeBSD, Mac OS X, Mandrake, Minix, OpenBSD, Slackware, SuSE
Posts: 1,757

Rep: Reputation: 80
I'm not exactly sure what your looking for, but if your interested in where NF_IP_LOCAL_IN is located in the iptables source code look at iptables-$VERSION/libiptc/libip4tc.c file.
Code:
/* Library which manipulates firewall rules.  Version 0.1. */
---snip---
#define HOOK_LOCAL_IN		NF_IP_LOCAL_IN
---snip---
and then there is this document:

Linux netfilter Hacking HOWTO
http://www.netfilter.org/documentati...g-HOWTO-3.html
 
Old 01-30-2008, 02:46 PM   #3
bharati.bhole
LQ Newbie
 
Registered: Jan 2008
Posts: 2

Original Poster
Rep: Reputation: 0
Question

As per my knowledge netfilters are on the top of iptable.
I want to access iptable from my kernel module. i dont want to add or remove any filter rules, but just want to check for existing filter rules.
So if the iptable contains some filter saying drop the packet coming for port 8080 then I need to do that in my kernel module or network card driver.
For this purpose I need to get pointer to iptable.
Could anybody please tell me what I need to do to get iptable pointer from my kernel module.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
iptables(marking) + ip rule add fwmark 1 table 200 + ip route add via GW table 200 ?? amitsharma_26 Linux - Networking 9 05-26-2010 07:42 AM
"No partition table or unknown signature on partition table" 10.1 install madcow007 Slackware 4 02-09-2009 12:04 PM
Slack 10: S-ATA = "No partition table or unknown signature on partition table"? dissolved soul Slackware - Installation 11 08-05-2004 03:12 PM
MySQL non-realtime table-by-table mirroring Passive Linux - Software 1 01-20-2004 01:11 PM
How to import MS ACCESS Table including OLE filed into the MySQL Table ? myunicom Linux - General 1 11-28-2003 12:30 PM


All times are GMT -5. The time now is 05:05 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration