]> granicus.if.org Git - libexpat/log
libexpat
7 years agoTest various errors in parameter entity values
Rhodri James [Fri, 3 Mar 2017 18:22:45 +0000 (18:22 +0000)]
Test various errors in parameter entity values

7 years agoTest invalid character in foreign DTD parameter entity
Rhodri James [Thu, 2 Mar 2017 19:59:41 +0000 (19:59 +0000)]
Test invalid character in foreign DTD parameter entity

7 years agoFix error reporting in external entity test handler
Rhodri James [Thu, 2 Mar 2017 19:58:54 +0000 (19:58 +0000)]
Fix error reporting in external entity test handler

7 years agoTest UTF-8 byte order mark in parameter entity value parsing
Rhodri James [Thu, 2 Mar 2017 19:08:27 +0000 (19:08 +0000)]
Test UTF-8 byte order mark in parameter entity value parsing

7 years agoTest aborting external entity value parser
Rhodri James [Thu, 2 Mar 2017 18:42:58 +0000 (18:42 +0000)]
Test aborting external entity value parser

7 years agoTest malformed XML/text declaration rejected by ext entity parser
Rhodri James [Thu, 2 Mar 2017 16:46:29 +0000 (16:46 +0000)]
Test malformed XML/text declaration rejected by ext entity parser

7 years agoTest XML declaration in external entity processing
Rhodri James [Thu, 2 Mar 2017 16:22:27 +0000 (16:22 +0000)]
Test XML declaration in external entity processing

7 years agoExtend external parameter entity nested parser testing
Rhodri James [Wed, 1 Mar 2017 17:22:24 +0000 (17:22 +0000)]
Extend external parameter entity nested parser testing

7 years agoruntests.c: Fix memleaks
Sebastian Pipping [Sat, 22 Jul 2017 19:28:20 +0000 (21:28 +0200)]
runtests.c: Fix memleaks

7 years agoTest nested external parser handling
Rhodri James [Tue, 28 Feb 2017 17:55:37 +0000 (17:55 +0000)]
Test nested external parser handling

7 years agoTest unknown encoding handling in external parameter entity handler
Rhodri James [Tue, 28 Feb 2017 16:51:42 +0000 (16:51 +0000)]
Test unknown encoding handling in external parameter entity handler

7 years agoTest a bad encoding is rejected at initialisation time
Rhodri James [Tue, 28 Feb 2017 15:33:55 +0000 (15:33 +0000)]
Test a bad encoding is rejected at initialisation time

7 years agoTest declaring a UTF-16 encoding while actually in UTF-8 is rejected
Rhodri James [Tue, 28 Feb 2017 15:07:07 +0000 (15:07 +0000)]
Test declaring a UTF-16 encoding while actually in UTF-8 is rejected

7 years agoTest XML declaration with long encoding name and failing allocator
Rhodri James [Tue, 28 Feb 2017 14:36:13 +0000 (14:36 +0000)]
Test XML declaration with long encoding name and failing allocator

7 years agoTest XML declaration handling with a duff allocator
Rhodri James [Tue, 28 Feb 2017 13:23:23 +0000 (13:23 +0000)]
Test XML declaration handling with a duff allocator

7 years agoTest external entity parsing suppressed with UNLESS_STANDALONE parameter
Rhodri James [Tue, 28 Feb 2017 12:23:19 +0000 (12:23 +0000)]
Test external entity parsing suppressed with UNLESS_STANDALONE parameter

7 years agoTest partial UTF-8 characters in IGNORE section
Rhodri James [Mon, 27 Feb 2017 17:58:29 +0000 (17:58 +0000)]
Test partial UTF-8 characters in IGNORE section

7 years agoRefactor to reduce proliferation of external entity handlers
Rhodri James [Mon, 27 Feb 2017 17:34:53 +0000 (17:34 +0000)]
Refactor to reduce proliferation of external entity handlers

7 years agoMerge branch 'realloc-dangling-pointer' (pull request #85)
Sebastian Pipping [Thu, 20 Jul 2017 20:18:59 +0000 (22:18 +0200)]
Merge branch 'realloc-dangling-pointer' (pull request #85)

7 years agoChanges: Document dangling pointer fix
Sebastian Pipping [Thu, 20 Jul 2017 20:17:52 +0000 (22:17 +0200)]
Changes: Document dangling pointer fix

7 years agoxmlparse.c: Fix dangling pointer caused by use of realloc
Sebastian Pipping [Sat, 15 Jul 2017 21:44:48 +0000 (23:44 +0200)]
xmlparse.c: Fix dangling pointer caused by use of realloc

Variables pool->ptr and pool->start point to addresses
that may have been freed if realloc chose the path of
a new base address.  So we do the math on these pointers
while they are not dangling, yet.

For a related article:
http://trust-in-soft.com/dangling-pointer-indeterminate/

7 years agoMerge branch 'dll-hijacking' (pull request #83)
Sebastian Pipping [Wed, 19 Jul 2017 18:24:52 +0000 (20:24 +0200)]
Merge branch 'dll-hijacking' (pull request #83)

7 years agoxmlparse.c: Fix DLL hijacking vulnerability (#82)
Sebastian Pipping [Sat, 15 Jul 2017 13:47:10 +0000 (15:47 +0200)]
xmlparse.c: Fix DLL hijacking vulnerability (#82)

7 years agoxmlparse.c: Fix comment typo
Sebastian Pipping [Sat, 15 Jul 2017 13:47:46 +0000 (15:47 +0200)]
xmlparse.c: Fix comment typo

7 years agoMerge branch 'arc4random-osx-pre-10-7' (pull request #84)
Sebastian Pipping [Wed, 19 Jul 2017 13:44:52 +0000 (15:44 +0200)]
Merge branch 'arc4random-osx-pre-10-7' (pull request #84)

7 years agoSupport arc4random for pre-10.7/Lion macOS
Sebastian Pipping [Sat, 15 Jul 2017 14:44:46 +0000 (16:44 +0200)]
Support arc4random for pre-10.7/Lion macOS

7 years agoRely on HAVE_ARC4RANDOM_BUF for CloudABI
Sebastian Pipping [Wed, 19 Jul 2017 12:23:50 +0000 (14:23 +0200)]
Rely on HAVE_ARC4RANDOM_BUF for CloudABI

7 years agoMerge branch 'coverage'
Sebastian Pipping [Sun, 16 Jul 2017 21:07:23 +0000 (23:07 +0200)]
Merge branch 'coverage'

7 years agoruntests.c: Fix indentation
Sebastian Pipping [Sun, 16 Jul 2017 20:36:08 +0000 (22:36 +0200)]
runtests.c: Fix indentation

7 years agoChange all URLs to use example.org
Rhodri James [Tue, 7 Mar 2017 14:15:49 +0000 (14:15 +0000)]
Change all URLs to use example.org

7 years agoUse meaningful constants for return values from handlers
Rhodri James [Tue, 21 Feb 2017 16:04:56 +0000 (16:04 +0000)]
Use meaningful constants for return values from handlers

7 years agoTweak attribute list to improve test coverage
Rhodri James [Fri, 17 Feb 2017 12:54:50 +0000 (12:54 +0000)]
Tweak attribute list to improve test coverage

7 years agoTest reallocation of attribute list with failing reallocator
Rhodri James [Thu, 16 Feb 2017 18:28:37 +0000 (18:28 +0000)]
Test reallocation of attribute list with failing reallocator

7 years agoTweak test_alloc_external_entity to improve code coverage
Rhodri James [Tue, 14 Feb 2017 13:56:55 +0000 (13:56 +0000)]
Tweak test_alloc_external_entity to improve code coverage

7 years agoExtend skip handler test coverage
Rhodri James [Tue, 14 Feb 2017 12:20:08 +0000 (12:20 +0000)]
Extend skip handler test coverage

7 years agoTest features are appropriately set
Rhodri James [Wed, 15 Feb 2017 13:07:36 +0000 (13:07 +0000)]
Test features are appropriately set

7 years agoTest predefined entities
Rhodri James [Mon, 13 Feb 2017 19:35:22 +0000 (19:35 +0000)]
Test predefined entities

7 years agoMake final reallocation test safe
Rhodri James [Fri, 10 Feb 2017 16:37:22 +0000 (16:37 +0000)]
Make final reallocation test safe

7 years agoTest robustness against failing reallocator for parsing long names
Rhodri James [Wed, 8 Feb 2017 17:08:50 +0000 (17:08 +0000)]
Test robustness against failing reallocator for parsing long names

7 years agoRefactor long test data string
Rhodri James [Tue, 7 Mar 2017 15:39:37 +0000 (15:39 +0000)]
Refactor long test data string

7 years agoExtend XML_GetBuffer testing coverage
Rhodri James [Tue, 7 Feb 2017 18:05:55 +0000 (18:05 +0000)]
Extend XML_GetBuffer testing coverage

7 years agoFix message in XML declaration handler
Rhodri James [Tue, 21 Feb 2017 12:47:28 +0000 (12:47 +0000)]
Fix message in XML declaration handler

7 years agoRestore groupSize if (re)allocation of groupConnector fails
Rhodri James [Tue, 7 Mar 2017 15:28:58 +0000 (15:28 +0000)]
Restore groupSize if (re)allocation of groupConnector fails

7 years agoEnsure unparsed entity handler gets set
Rhodri James [Tue, 7 Mar 2017 15:23:52 +0000 (15:23 +0000)]
Ensure unparsed entity handler gets set

Revise dummy handlers to flag when they are executed, and ensure
that they are executed in the test.  Add XML to get the deprecated
unparsed entity handler executed, and ensure that the allocation
check fails each possible allocator in sequence despite the
caching of some allocations in the parser object.

NOTE that this commit does not pass check because of an allocation
bug.

7 years agoSplit combined triplet_count into two distinct flags
Rhodri James [Mon, 6 Feb 2017 15:49:43 +0000 (15:49 +0000)]
Split combined triplet_count into two distinct flags

7 years agoRevert "Fix structure initialisation not to cause warnings"
Sebastian Pipping [Sun, 16 Jul 2017 21:01:15 +0000 (23:01 +0200)]
Revert "Fix structure initialisation not to cause warnings"

This reverts commit 894033fab8487164d7e2f20141bca8ad75d28311.

7 years agoMerge branch 'coverage'
Sebastian Pipping [Sun, 16 Jul 2017 17:09:09 +0000 (19:09 +0200)]
Merge branch 'coverage'

7 years agoruntests.c: Fix memleaks
Sebastian Pipping [Sun, 16 Jul 2017 17:07:50 +0000 (19:07 +0200)]
runtests.c: Fix memleaks

7 years agoIncrease test coverage of ignore section processing
Rhodri James [Mon, 27 Feb 2017 15:39:47 +0000 (15:39 +0000)]
Increase test coverage of ignore section processing

7 years agoRefactor previous test to use existing test functions
Rhodri James [Mon, 27 Feb 2017 15:27:29 +0000 (15:27 +0000)]
Refactor previous test to use existing test functions

7 years agoTest a broken IGNORE section is faulted
Rhodri James [Fri, 24 Feb 2017 19:12:26 +0000 (19:12 +0000)]
Test a broken IGNORE section is faulted

7 years agoExercise conditional exclusion code
Rhodri James [Fri, 24 Feb 2017 18:39:38 +0000 (18:39 +0000)]
Exercise conditional exclusion code

7 years agoTest suspending the parse in the middle of CDATA handling
Rhodri James [Fri, 24 Feb 2017 17:05:37 +0000 (17:05 +0000)]
Test suspending the parse in the middle of CDATA handling

7 years agoTest aborting parse while processing CDATA
Rhodri James [Fri, 24 Feb 2017 16:58:44 +0000 (16:58 +0000)]
Test aborting parse while processing CDATA

7 years agoTest a variety of incomplete UTF-16 CDATA strings
Rhodri James [Fri, 24 Feb 2017 14:59:44 +0000 (14:59 +0000)]
Test a variety of incomplete UTF-16 CDATA strings

7 years agoTest handling of UTF-16 supplementary plane characters
Rhodri James [Fri, 24 Feb 2017 14:11:45 +0000 (14:11 +0000)]
Test handling of UTF-16 supplementary plane characters

7 years agoTest long UTF-16 CDATA (more than internal buffer size)
Rhodri James [Fri, 24 Feb 2017 13:12:41 +0000 (13:12 +0000)]
Test long UTF-16 CDATA (more than internal buffer size)

7 years agoTest CDATA correctly runs through a default handler
Rhodri James [Thu, 23 Feb 2017 17:48:39 +0000 (17:48 +0000)]
Test CDATA correctly runs through a default handler

In particular exercises a code path dealing with newlines

7 years agoTest handling of CDATA in an external entity parser
Rhodri James [Thu, 23 Feb 2017 16:57:12 +0000 (16:57 +0000)]
Test handling of CDATA in an external entity parser

7 years agoTest reallocation of URI in re-used binding with dodgy reallocator
Rhodri James [Thu, 23 Feb 2017 16:04:12 +0000 (16:04 +0000)]
Test reallocation of URI in re-used binding with dodgy reallocator

7 years agoTest w3.org xmlns URL is correctly rejected
Rhodri James [Thu, 23 Feb 2017 15:22:40 +0000 (15:22 +0000)]
Test w3.org xmlns URL is correctly rejected

7 years agoTest rejection of invalid attribute 'xml' and use of w3.org
Rhodri James [Thu, 23 Feb 2017 15:13:12 +0000 (15:13 +0000)]
Test rejection of invalid attribute 'xml' and use of w3.org

7 years agoTest for correct rejection of 'xmlns' as an attribute
Rhodri James [Thu, 23 Feb 2017 13:31:59 +0000 (13:31 +0000)]
Test for correct rejection of 'xmlns' as an attribute

7 years agoTest extension of URI buffer shared between element tags
Rhodri James [Wed, 22 Feb 2017 18:41:31 +0000 (18:41 +0000)]
Test extension of URI buffer shared between element tags

7 years agoTest medium-length element name with namespaces and a failing allocator
Rhodri James [Wed, 22 Feb 2017 17:49:11 +0000 (17:49 +0000)]
Test medium-length element name with namespaces and a failing allocator

7 years agoTest mixed prefixed and unprefixed attributes in a namespace
Rhodri James [Wed, 22 Feb 2017 16:54:35 +0000 (16:54 +0000)]
Test mixed prefixed and unprefixed attributes in a namespace

7 years agoTest allocator handling of attribute with long namespace
Rhodri James [Wed, 22 Feb 2017 16:24:18 +0000 (16:24 +0000)]
Test allocator handling of attribute with long namespace

7 years agoruntests.c: Fix memleaks
Sebastian Pipping [Sun, 16 Jul 2017 16:58:21 +0000 (18:58 +0200)]
runtests.c: Fix memleaks

7 years agoTest attribute table hash collision handling
Rhodri James [Wed, 22 Feb 2017 15:14:50 +0000 (15:14 +0000)]
Test attribute table hash collision handling

7 years agoTest long attribute names in a namespace with failing allocator
Rhodri James [Tue, 21 Feb 2017 19:36:07 +0000 (19:36 +0000)]
Test long attribute names in a namespace with failing allocator

7 years agoExtend test coverage of external entity handler parameters
Rhodri James [Tue, 21 Feb 2017 18:25:41 +0000 (18:25 +0000)]
Extend test coverage of external entity handler parameters

7 years agoComment change: explain why attribute count is twice what you expect
Rhodri James [Tue, 21 Feb 2017 17:24:39 +0000 (17:24 +0000)]
Comment change: explain why attribute count is twice what you expect

7 years agoCheck NULLing the encoding works before the parse is started
Rhodri James [Tue, 21 Feb 2017 16:33:01 +0000 (16:33 +0000)]
Check NULLing the encoding works before the parse is started

7 years agoTest for specific error from XML_UseForeignDTD()
Rhodri James [Tue, 21 Feb 2017 16:26:58 +0000 (16:26 +0000)]
Test for specific error from XML_UseForeignDTD()

7 years agoFix structure initialisation not to cause warnings
Rhodri James [Tue, 21 Feb 2017 15:29:31 +0000 (15:29 +0000)]
Fix structure initialisation not to cause warnings

7 years agoAdd test case for long URIs in attributes with failing allocator
Rhodri James [Fri, 17 Feb 2017 18:58:08 +0000 (18:58 +0000)]
Add test case for long URIs in attributes with failing allocator

7 years agoRestore original nsAttsSize if reallocation fails
Rhodri James [Fri, 17 Feb 2017 16:32:21 +0000 (16:32 +0000)]
Restore original nsAttsSize if reallocation fails

7 years agoTest reallocation failure in xmlns attribute handling
Rhodri James [Fri, 17 Feb 2017 16:21:17 +0000 (16:21 +0000)]
Test reallocation failure in xmlns attribute handling

Note that this commit provokes a segfault due to a bug in
storeAtts()

7 years agoTest rejection of unbound prefix, improve coverage of attribute handling
Rhodri James [Fri, 17 Feb 2017 15:18:34 +0000 (15:18 +0000)]
Test rejection of unbound prefix, improve coverage of attribute handling

7 years agoRevert recorded size of attribute memory when reallocation fails
Rhodri James [Fri, 17 Feb 2017 12:01:30 +0000 (12:01 +0000)]
Revert recorded size of attribute memory when reallocation fails

7 years agoTest long namespace names (1024 characters)
Rhodri James [Thu, 16 Feb 2017 17:44:53 +0000 (17:44 +0000)]
Test long namespace names (1024 characters)

7 years agoRefactor namespace allocation tests
Rhodri James [Thu, 16 Feb 2017 16:09:28 +0000 (16:09 +0000)]
Refactor namespace allocation tests

7 years agoExtend code path coverage of entity handling
Rhodri James [Tue, 14 Feb 2017 11:50:40 +0000 (11:50 +0000)]
Extend code path coverage of entity handling

7 years agoAdd test coverage for comments with a failing allocator
Rhodri James [Wed, 15 Feb 2017 19:11:19 +0000 (19:11 +0000)]
Add test coverage for comments with a failing allocator

7 years agoMore coverage of PIs with failing allocator
Rhodri James [Wed, 15 Feb 2017 18:49:24 +0000 (18:49 +0000)]
More coverage of PIs with failing allocator

7 years agoTest parsing a PI with a failing allocator
Rhodri James [Wed, 15 Feb 2017 18:17:25 +0000 (18:17 +0000)]
Test parsing a PI with a failing allocator

7 years agoExpand really long line test for encoded CDATA handling
Rhodri James [Wed, 15 Feb 2017 17:24:06 +0000 (17:24 +0000)]
Expand really long line test for encoded CDATA handling

7 years agoTest right square bracket handling in external entity parses
Rhodri James [Wed, 15 Feb 2017 15:48:00 +0000 (15:48 +0000)]
Test right square bracket handling in external entity parses

7 years agoMore tests for the right square bracket control paths
Rhodri James [Wed, 15 Feb 2017 15:02:45 +0000 (15:02 +0000)]
More tests for the right square bracket control paths

7 years agoTest handling of right square bracket at end of content data
Rhodri James [Wed, 15 Feb 2017 13:50:04 +0000 (13:50 +0000)]
Test handling of right square bracket at end of content data

7 years agoExtend ASCII CDATA test to cover a default handler
Rhodri James [Tue, 14 Feb 2017 18:22:53 +0000 (18:22 +0000)]
Extend ASCII CDATA test to cover a default handler

7 years agoAdd CDATA section handlers for increased test coverage
Rhodri James [Tue, 14 Feb 2017 17:57:58 +0000 (17:57 +0000)]
Add CDATA section handlers for increased test coverage

7 years agoAdd default handler to namespace failing allocation test
Rhodri James [Tue, 14 Feb 2017 17:36:38 +0000 (17:36 +0000)]
Add default handler to namespace failing allocation test

Increases code coverage.  Also tweaked allocation counts for
better coverage

7 years agoAdd default handlers to character entity tests to extend coverage
Rhodri James [Tue, 14 Feb 2017 16:40:55 +0000 (16:40 +0000)]
Add default handlers to character entity tests to extend coverage

7 years agoExtend coverage of namespace start and end handlers
Rhodri James [Tue, 14 Feb 2017 16:26:27 +0000 (16:26 +0000)]
Extend coverage of namespace start and end handlers

7 years agoTest external entity with no handler
Rhodri James [Tue, 14 Feb 2017 16:13:06 +0000 (16:13 +0000)]
Test external entity with no handler

7 years agoTweak tests for greater allocation failure coverage
Rhodri James [Tue, 14 Feb 2017 16:04:56 +0000 (16:04 +0000)]
Tweak tests for greater allocation failure coverage

7 years agoMore external entity allocation failure coverage
Rhodri James [Tue, 14 Feb 2017 15:31:31 +0000 (15:31 +0000)]
More external entity allocation failure coverage

7 years agoExtend coverage of partial character parsing
Rhodri James [Mon, 13 Feb 2017 18:05:54 +0000 (18:05 +0000)]
Extend coverage of partial character parsing

7 years agoTest trailing CR in external entity parse
Rhodri James [Mon, 13 Feb 2017 17:59:47 +0000 (17:59 +0000)]
Test trailing CR in external entity parse