Re: Buffer overflow prevention

From: Tom 7 (twmat_private)
Date: Fri Aug 15 2003 - 11:41:10 PDT

  • Next message: Geoff Shively: "Re: CNN: 'Explores Possibility that Power Outage is Related to Internet Worm'"

    Crispin Cowan <crispinat_private> wrote:
    
    > Array bounds checking offers greater protection than any of these
    > protections (StackGuard, ProPolice, PointGuard, W^X, PAX/ASLR, etc.) The
    > problem is that the very fastest array bounds protection for C (Bounded
    > Pointers) imposes a 5X slowdown on performance, where as these other
    > techniques impose overheat somewhere between noise and 20%.
    
    This may be true. Doing "safe" pointers in C is difficult because of
    pointer arithmetic. But I think this is a bit unfair to bounds checking in
    general--type safe compiled languages like ML achieve array bounds
    checking (and other checks) at a much smaller penalty (less than 20% for
    array-oriented code in my experience).  These languages also provide
    protection against other common sources of holes, like integer overflow,
    double-frees (most are garbage collected) and printf formatting attacks.
    This protection is automatic and absolute; the only thing left to worry
    about is bugs in the compiler, system library, and kernel (things that C
    programmers already need to worry about, anyway).
    
    In my opinion these languages are utterly practical for Unix network
    daemons. Of course, this is a bit more work because you don't just
    recompile the program, you have to rewrite it from scratch! But there are
    other benefits to maintaining code in a modern, safe, high-level language.
    
     - Tom
    
     [ http://www.cs.cmu.edu/~tom7/ ]
    



    This archive was generated by hypermail 2b30 : Fri Aug 15 2003 - 14:44:56 PDT