diff options
author | joe <joe@61a7d7f5-40b7-0310-9c16-bb0ea8cb1845> | 2007-01-11 21:33:14 +0000 |
---|---|---|
committer | joe <joe@61a7d7f5-40b7-0310-9c16-bb0ea8cb1845> | 2007-01-11 21:33:14 +0000 |
commit | 47bc4f4f101bab626234c6c22bf102b077470032 (patch) | |
tree | b90d8914da3b4cb4fdc9a981e1a66cb37235804c /src/ne_uri.c | |
parent | ef296d8a637112a55e73b824b41f20cb71eddff3 (diff) | |
download | neon-47bc4f4f101bab626234c6c22bf102b077470032.tar.gz |
* src/ne_uri.c (uri_lookup): Fix cast to prevent buffer under-read on
non-ASCII characters (CVE-2007-0157, Laszlo Boszormenyi).
* test/uri-tests.c (parse): Add test case.
git-svn-id: http://svn.webdav.org/repos/projects/neon/trunk@1131 61a7d7f5-40b7-0310-9c16-bb0ea8cb1845
Diffstat (limited to 'src/ne_uri.c')
-rw-r--r-- | src/ne_uri.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ne_uri.c b/src/ne_uri.c index e7358a9..669e70b 100644 --- a/src/ne_uri.c +++ b/src/ne_uri.c @@ -110,7 +110,7 @@ static const unsigned int uri_chars[256] = { /* Fx */ OT, OT, OT, OT, OT, OT, OT, OT, OT, OT, OT, OT, OT, OT, OT, OT }; -#define uri_lookup(ch) (uri_chars[(unsigned)ch]) +#define uri_lookup(ch) (uri_chars[(unsigned char)ch]) char *ne_path_parent(const char *uri) { |