PATCH: safe string copy and concetation
Chiaki Ishikawa
Chiaki.Ishikawa@personal-media.co.jp
Tue Aug 8 15:39:00 GMT 2000
X-PMC-CI-e-mail-id: 13401
For a newly written programs going through debugging,
I think Ultrich Drepper's argument makes sense.
However, on a running server, you may find, to our horror and
surprise, that a necessary daemon or production programs have
a str* related overflow. Ugh.
In such a case, strlcpy and friends can be a valuable tool
for a QUICK SHORTT-TERM BAND-AID.
We can BUY TIME TO FIX THE PROBLEMS at the root cause while
at least the program in question is limping along (not crashing, nor
being abused.).
Real world problems of B-news came to my mind when I looked the exchanges on
this topic.
(Once the Internet becme very large in a short time, Bnews experienced
internal buffer overflows because the size of buffers allocated for
news propagation paths was not long enough, etc..
I wish I had strlcpy and friends back when this happend.
I tried kludges for about 3 months each time a new problem surfaced
but gave up and switched to INN.)
--
Ishikawa, Chiaki ishikawa@personal-media.co.jp.NoSpam or
(family name, given name) Chiaki.Ishikawa@personal-media.co.jp.NoSpam
Personal Media Corp. ** Remove .NoSpam at the end before use **
Shinagawa, Tokyo, Japan 142-0051
More information about the Libc-alpha
mailing list