Re: [Lit.] Buffer overruns
From: infobahn (infobahn_at_btinternet.com)
Date: 01/30/05
- Next message: Mok-Kong Shen: "Re: [Lit.] Buffer overruns"
- Previous message: Mok-Kong Shen: "Re: [Lit.] Buffer overruns"
- In reply to: Mok-Kong Shen: "Re: [Lit.] Buffer overruns"
- Next in thread: Mok-Kong Shen: "Re: [Lit.] Buffer overruns"
- Reply: Mok-Kong Shen: "Re: [Lit.] Buffer overruns"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Sun, 30 Jan 2005 10:00:07 +0000 (UTC)
Mok-Kong Shen wrote:
>
> infobahn wrote:
>
> > The remaining examples are no different in principle to this one.
>
> O.k. That assumes that the caller always keeps or determines
> the length information of certain arguments to be passed to a
> function, right?
It assumes that the function's parameters are supplied by correct
code. Each function should take responsibility for introducing no
new security flaws, and the function's programmer should not call
a function without being fully aware of the interface requirement
for that function.
> Do you 'want' to enforce that discipline
> throughout your (possibly large) software project?
It should not be necessary to enforce anything, since responsible
programmers already write code the way I outlined above. The code
to which you refer currently ways in at half a meg of source, and
about half of that is the string library stuff. It'll take a long
time for me to convince myself that it's bug-free, so I would not
advocate that anyone should wait eagerly for its release, so that
they can "start writing bug-free code straight away"!
The programmer should take responsibility for the code he writes,
should document his interfaces, and should respect the interfaces
for functions he calls. This is not rocket science.
- Next message: Mok-Kong Shen: "Re: [Lit.] Buffer overruns"
- Previous message: Mok-Kong Shen: "Re: [Lit.] Buffer overruns"
- In reply to: Mok-Kong Shen: "Re: [Lit.] Buffer overruns"
- Next in thread: Mok-Kong Shen: "Re: [Lit.] Buffer overruns"
- Reply: Mok-Kong Shen: "Re: [Lit.] Buffer overruns"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|