From: ken@coverity.com
To: viro@parcelfarce.linux.theplanet.co.uk
Cc: linux-kernel@vger.kernel.org, linux@coverity.com
Subject: Re: [CHECKER] Security reports involving isspace()
Date: Tue, 20 Apr 2004 16:57:49 -0700 (PDT) [thread overview]
Message-ID: <12913.24.6.86.122.1082505469.spork@webmail.coverity.com> (raw)
In-Reply-To: <20040420232545.GF17014@parcelfarce.linux.theplanet.co.uk>
> On Tue, Apr 20, 2004 at 03:14:21PM -0700, ken@coverity.com wrote:
>> All of the reports below deal with the isspace macro. It expands to an
>> access to a static array with 256 entries. If we use an unsigned char
>> to
>> index into the array, there are no problems. However, when that char is
>> signed, we can index off the left of the array.
>>
>> It seems like this isn't a big deal, but if the isspace array is located
>> after some important data structure, we could leak information.
>
> #define __ismask(x) (_ctype[(int)(unsigned char)(x)])
> #define isspace(c) ((__ismask(c)&(_S)) != 0)
Sorry, my mistake. I only saw the cast to int in __ismask(x). Thanks for
the quicky reply.
prev parent reply other threads:[~2004-04-20 23:57 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-04-20 22:14 ken
2004-04-20 23:25 ` viro
2004-04-20 23:57 ` ken [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=12913.24.6.86.122.1082505469.spork@webmail.coverity.com \
--to=ken@coverity.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@coverity.com \
--cc=viro@parcelfarce.linux.theplanet.co.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®