Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 31 Oct 2000 17:16:13 -0800
From:      Mike Smith <msmith@freebsd.org>
To:        Lars Eggert <larse@ISI.EDU>
Cc:        hackers@freebsd.org
Subject:   Re: curproc question 
Message-ID:  <200011010116.eA11GD429727@mass.osd.bsdi.com>
In-Reply-To: Your message of "Tue, 31 Oct 2000 17:05:13 PST." <39FF6C49.31D1ABE8@isi.edu> 

next in thread | previous in thread | raw e-mail | index | archive | help
> Mike Smith wrote:
> > > During a system call inside the kernel, can I safely assume that curproc
> > > points to the process that issued the call? For example, will looking at
> > > curproc in ip_output() tell me which process is responsible for generating
> > > the packet?
> > 
> > No.
> 
> Too bad. In which cases wouldn't it point at the "correct" process? Maybe I
> could tolerate those.

Anytime the upcall process had been blocked, or when NATing, or when 
routing.

Have a look at the way that per-UID limites are implemented in ipfw...

-- 
... every activity meets with opposition, everyone who acts has his
rivals and unfortunately opponents also.  But not because people want
to be opponents, rather because the tasks and relationships force
people to take different points of view.  [Dr. Fritz Todt]
           V I C T O R Y   N O T   V E N G E A N C E




To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200011010116.eA11GD429727>