Date: Sun, 9 Feb 1997 12:57:33 -0600 (CST) From: Richard Holland <rholland@freon.republic.k12.mo.us> To: freebsd-security@FreeBSD.ORG Subject: buffer overruns Message-ID: <Pine.LNX.3.91.970209124900.2336B-100000@freon.republic.k12.mo.us> In-Reply-To: <Pine.BSF.3.91.970209111131.2503B-100000@www.trifecta.com>
next in thread | previous in thread | raw e-mail | index | archive | help
With all of this locale stuff going on, it made me realize that I actually don't know what a buffer overrun is. However I am learning C at the moment and have a basic idea down: I know what in C, a variable takes up a certain amount of memory, like type char is usually 1 byte, so stating char var; in your code sets aside 1 byte of memory aside. So if you then said var = 'blah' You would step into other memory addresses right? So the set locale bug is this only put differently. It allocates X amount of bytes for the buffer, and people put to much junk into it, causing it to step into other memory addresses. If I am right here, How would you know just how far you have to go over and what the characters need to be once you get thus far? Of course I could be totally wrong here. Realize that I am just now covering pointers in the book I am reading on C :) ///////////////////////////////////////////////////////////////////////////// Richard A. Holland * Systems Administrator rholland@freon.republic.k12.mo.us * UNIX consulting HANGER@getonthe.net * Network Security hangar@irc --------------------(FreeBSD,OpenBSD,NetBSD,Linux,AIX)----------------------
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.LNX.3.91.970209124900.2336B-100000>