mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* About net part of the kernel
@ 2002-02-20  4:58 Sandeep Gopal Nijsure
  2002-02-20  5:05 ` Ben Collins
  2002-02-20  5:10 ` Alex Song
  0 siblings, 2 replies; 4+ messages in thread
From: Sandeep Gopal Nijsure @ 2002-02-20  4:58 UTC (permalink / raw)
  To: linux-kernel

Hi,

I want to make, say, a machine 10.0.0.5 accept an IP packet with the
destination address of 10.0.0.2. I hope I can do this by changing a bit of
kernel networking code, where it's decided whether to accept an IP packet
as a local packet.. I could not locate the code.. could anybody tell me
where exactly the decision process take place?

Thanks a lot..
Sandeep 



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: About net part of the kernel
  2002-02-20  4:58 About net part of the kernel Sandeep Gopal Nijsure
@ 2002-02-20  5:05 ` Ben Collins
  2002-02-20  5:10 ` Alex Song
  1 sibling, 0 replies; 4+ messages in thread
From: Ben Collins @ 2002-02-20  5:05 UTC (permalink / raw)
  To: Sandeep Gopal Nijsure; +Cc: linux-kernel

On Tue, Feb 19, 2002 at 10:58:53PM -0600, Sandeep Gopal Nijsure wrote:
> Hi,
> 
> I want to make, say, a machine 10.0.0.5 accept an IP packet with the
> destination address of 10.0.0.2. I hope I can do this by changing a bit of
> kernel networking code, where it's decided whether to accept an IP packet
> as a local packet.. I could not locate the code.. could anybody tell me
> where exactly the decision process take place?

You could just use device aliasing:

ifconfig eth0 10.0.0.5
ifconfig eth0:1 10.0.0.2

Either that, or if you simply want to sniff network packets, look into
turning on promiscuous mode (as tcpdump does).

-- 
 .----------=======-=-======-=========-----------=====------------=-=-----.
/       Ben Collins    --    Debian GNU/Linux    --    WatchGuard.com      \
`          bcollins@debian.org   --   Ben.Collins@watchguard.com           '
 `---=========------=======-------------=-=-----=-===-======-------=--=---'

^ permalink raw reply	[flat|nested] 4+ messages in thread

* RE: About net part of the kernel
  2002-02-20  4:58 About net part of the kernel Sandeep Gopal Nijsure
  2002-02-20  5:05 ` Ben Collins
@ 2002-02-20  5:10 ` Alex Song
  2002-02-20  5:13   ` Alex Song
  1 sibling, 1 reply; 4+ messages in thread
From: Alex Song @ 2002-02-20  5:10 UTC (permalink / raw)
  To: Sandeep Gopal Nijsure, linux-kernel

you don't have to change and part of the kernel, you can do what you want
with ipchains (2.2 kernels) or iptables (2.4 kernels).

cheers,

alex

> -----Original Message-----
> From: linux-kernel-owner@vger.kernel.org
> [mailto:linux-kernel-owner@vger.kernel.org]On Behalf Of Sandeep Gopal
> Nijsure
> Sent: Wednesday, 20 February 2002 2:59 PM
> To: linux-kernel@vger.kernel.org
> Subject: About net part of the kernel
>
>
> Hi,
>
> I want to make, say, a machine 10.0.0.5 accept an IP packet with the
> destination address of 10.0.0.2. I hope I can do this by changing a bit of
> kernel networking code, where it's decided whether to accept an IP packet
> as a local packet.. I could not locate the code.. could anybody tell me
> where exactly the decision process take place?
>
> Thanks a lot..
> Sandeep
>
>
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/
>


^ permalink raw reply	[flat|nested] 4+ messages in thread

* RE: About net part of the kernel
  2002-02-20  5:10 ` Alex Song
@ 2002-02-20  5:13   ` Alex Song
  0 siblings, 0 replies; 4+ messages in thread
From: Alex Song @ 2002-02-20  5:13 UTC (permalink / raw)
  To: Alex Song, Sandeep Gopal Nijsure, linux-kernel

ignore what i said before, i misread the question.

cheers,

alex

> -----Original Message-----
> From: linux-kernel-owner@vger.kernel.org
> [mailto:linux-kernel-owner@vger.kernel.org]On Behalf Of Alex Song
> Sent: Wednesday, 20 February 2002 3:10 PM
> To: Sandeep Gopal Nijsure; linux-kernel@vger.kernel.org
> Subject: RE: About net part of the kernel
>
>
> you don't have to change and part of the kernel, you can do what you want
> with ipchains (2.2 kernels) or iptables (2.4 kernels).
>
> cheers,
>
> alex
>
> > -----Original Message-----
> > From: linux-kernel-owner@vger.kernel.org
> > [mailto:linux-kernel-owner@vger.kernel.org]On Behalf Of Sandeep Gopal
> > Nijsure
> > Sent: Wednesday, 20 February 2002 2:59 PM
> > To: linux-kernel@vger.kernel.org
> > Subject: About net part of the kernel
> >
> >
> > Hi,
> >
> > I want to make, say, a machine 10.0.0.5 accept an IP packet with the
> > destination address of 10.0.0.2. I hope I can do this by
> changing a bit of
> > kernel networking code, where it's decided whether to accept an
> IP packet
> > as a local packet.. I could not locate the code.. could anybody tell me
> > where exactly the decision process take place?
> >
> > Thanks a lot..
> > Sandeep
> >
> >
> > -
> > To unsubscribe from this list: send the line "unsubscribe
> linux-kernel" in
> > the body of a message to majordomo@vger.kernel.org
> > More majordomo info at  http://vger.kernel.org/majordomo-info.html
> > Please read the FAQ at  http://www.tux.org/lkml/
> >
>
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/
>


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2002-02-20  5:14 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-02-20  4:58 About net part of the kernel Sandeep Gopal Nijsure
2002-02-20  5:05 ` Ben Collins
2002-02-20  5:10 ` Alex Song
2002-02-20  5:13   ` Alex Song

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®