[jira] [Resolved] (XERCESC-2188) Use-after-free on external DTD scan

2023-12-20 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2188?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2188.
---
Resolution: Fixed

> Use-after-free on external DTD scan
> ---
>
> Key: XERCESC-2188
> URL: https://issues.apache.org/jira/browse/XERCESC-2188
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Validating Parser (DTD)
>Affects Versions: 3.0.0, 3.0.1, 3.0.2, 3.1.0, 3.1.1, 3.1.2, 3.2.0, 3.1.3, 
> 3.1.4, 3.2.1, 3.2.2
>Reporter: Scott Cantor
>Assignee: Boris Kolpackov
>Priority: Major
> Fix For: 3.2.5
>
> Attachments: Apache-496067-disclosure-report.pdf
>
>
> This is a record of an unfixed bug reported in 2018 in the DTD scanner, per 
> the attached PDF, corresponding to CVE-2018-1311.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2188) Use-after-free on external DTD scan

2023-12-20 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2188?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2188.
-

> Use-after-free on external DTD scan
> ---
>
> Key: XERCESC-2188
> URL: https://issues.apache.org/jira/browse/XERCESC-2188
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Validating Parser (DTD)
>Affects Versions: 3.0.0, 3.0.1, 3.0.2, 3.1.0, 3.1.1, 3.1.2, 3.2.0, 3.1.3, 
> 3.1.4, 3.2.1, 3.2.2
>Reporter: Scott Cantor
>Assignee: Boris Kolpackov
>Priority: Major
> Fix For: 3.2.5
>
> Attachments: Apache-496067-disclosure-report.pdf
>
>
> This is a record of an unfixed bug reported in 2018 in the DTD scanner, per 
> the attached PDF, corresponding to CVE-2018-1311.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2244) DOMDocument::normalizeDocument() fails

2023-12-06 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2244?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17793875#comment-17793875
 ] 

Scott Cantor commented on XERCESC-2244:
---

You seemed to be suggesting there's a second place it was already removing the 
same hash key, but I didn't spot it, so I thought maybe you might know where 
that was. I don't think that would be enough to get me confident enough to 
change it, but one never knows.

> DOMDocument::normalizeDocument() fails
> --
>
> Key: XERCESC-2244
> URL: https://issues.apache.org/jira/browse/XERCESC-2244
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: DOM, Miscellaneous, Utilities
>Affects Versions: 3.2.0, 3.2.1, 3.2.2, 3.2.3, 3.2.4
>Reporter: Markus Friedrich
>Priority: Major
>
> The following XML file
>  
> {code:java}
> 
> http://a; xmlns:pre="http://a;>
>   http://b; xmlns:pre="http://a"/>
>  
> {code}
> fails when DOMDocument::normailzeDocument() gets called on its DOM.
> In DOMNormalizer.cpp:437 the "oldUri" gets removed from "fUriHash" twice, 
> which throws the second time since the key no longer exists in "fUriHash".



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Comment Edited] (XERCESC-2244) DOMDocument::normalizeDocument() fails

2023-12-06 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2244?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17793875#comment-17793875
 ] 

Scott Cantor edited comment on XERCESC-2244 at 12/6/23 6:27 PM:


You seemed to be suggesting there's a second place it was already removing the 
same hash key, but I didn't spot it, so I thought maybe you might know where 
that was. I don't think that would be enough to get me confident enough to 
change it, but one never knows.

Notably that specific line of code is not removing it from the same hashtable 
twice, but removing two different keys from two different hashtables, unless I 
misconstrued it.


was (Author: canto...@osu.edu):
You seemed to be suggesting there's a second place it was already removing the 
same hash key, but I didn't spot it, so I thought maybe you might know where 
that was. I don't think that would be enough to get me confident enough to 
change it, but one never knows.

> DOMDocument::normalizeDocument() fails
> --
>
> Key: XERCESC-2244
> URL: https://issues.apache.org/jira/browse/XERCESC-2244
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: DOM, Miscellaneous, Utilities
>Affects Versions: 3.2.0, 3.2.1, 3.2.2, 3.2.3, 3.2.4
>Reporter: Markus Friedrich
>Priority: Major
>
> The following XML file
>  
> {code:java}
> 
> http://a; xmlns:pre="http://a;>
>   http://b; xmlns:pre="http://a"/>
>  
> {code}
> fails when DOMDocument::normailzeDocument() gets called on its DOM.
> In DOMNormalizer.cpp:437 the "oldUri" gets removed from "fUriHash" twice, 
> which throws the second time since the key no longer exists in "fUriHash".



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2163) XercesMessages_en_US.cat is installed to wrong directory

2023-12-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2163?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2163:
--
Fix Version/s: 3.2.5

> XercesMessages_en_US.cat is installed to wrong directory
> 
>
> Key: XERCESC-2163
> URL: https://issues.apache.org/jira/browse/XERCESC-2163
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.0, 3.2.1, 3.2.2, 3.2.3, 3.2.4
>Reporter: Craig
>Priority: Major
>  Labels: cmake
> Fix For: 3.2.5
>
>
> When building with the
> {code}-Dmessage-loader=iconv{code}
> cmake option, {{XercesMessages_en_US.cat}} is installed to:
> {{/usr/msg/}}
> It should be installed to:
> {{/usr/share/xerces-c/msg/}}
> which is what previous versions of Xerces-C did.
> This change breaks downstream consumers of Xerces-C, such as Xalan-C (which 
> fails to build as it cannot find {{XercesMessages_en_US.cat}}).
> Originally reported at https://bugs.gentoo.org/673548



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2163) XercesMessages_en_US.cat is installed to wrong directory

2023-12-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2163?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2163.
-

> XercesMessages_en_US.cat is installed to wrong directory
> 
>
> Key: XERCESC-2163
> URL: https://issues.apache.org/jira/browse/XERCESC-2163
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.0, 3.2.1, 3.2.2, 3.2.3, 3.2.4
>Reporter: Craig
>Assignee: Scott Cantor
>Priority: Major
>  Labels: cmake
> Fix For: 3.2.5
>
>
> When building with the
> {code}-Dmessage-loader=iconv{code}
> cmake option, {{XercesMessages_en_US.cat}} is installed to:
> {{/usr/msg/}}
> It should be installed to:
> {{/usr/share/xerces-c/msg/}}
> which is what previous versions of Xerces-C did.
> This change breaks downstream consumers of Xerces-C, such as Xalan-C (which 
> fails to build as it cannot find {{XercesMessages_en_US.cat}}).
> Originally reported at https://bugs.gentoo.org/673548



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2163) XercesMessages_en_US.cat is installed to wrong directory

2023-12-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2163?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2163.
---
  Assignee: Scott Cantor
Resolution: Fixed

Applied to both master and 3.2 branches.

> XercesMessages_en_US.cat is installed to wrong directory
> 
>
> Key: XERCESC-2163
> URL: https://issues.apache.org/jira/browse/XERCESC-2163
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.0, 3.2.1, 3.2.2, 3.2.3, 3.2.4
>Reporter: Craig
>Assignee: Scott Cantor
>Priority: Major
>  Labels: cmake
> Fix For: 3.2.5
>
>
> When building with the
> {code}-Dmessage-loader=iconv{code}
> cmake option, {{XercesMessages_en_US.cat}} is installed to:
> {{/usr/msg/}}
> It should be installed to:
> {{/usr/share/xerces-c/msg/}}
> which is what previous versions of Xerces-C did.
> This change breaks downstream consumers of Xerces-C, such as Xalan-C (which 
> fails to build as it cannot find {{XercesMessages_en_US.cat}}).
> Originally reported at https://bugs.gentoo.org/673548



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2163) XercesMessages_en_US.cat is installed to wrong directory

2023-12-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2163?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2163:
--
Affects Version/s: 3.2.4

> XercesMessages_en_US.cat is installed to wrong directory
> 
>
> Key: XERCESC-2163
> URL: https://issues.apache.org/jira/browse/XERCESC-2163
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.0, 3.2.1, 3.2.2, 3.2.3, 3.2.4
>Reporter: Craig
>Priority: Major
>  Labels: cmake
>
> When building with the
> {code}-Dmessage-loader=iconv{code}
> cmake option, {{XercesMessages_en_US.cat}} is installed to:
> {{/usr/msg/}}
> It should be installed to:
> {{/usr/share/xerces-c/msg/}}
> which is what previous versions of Xerces-C did.
> This change breaks downstream consumers of Xerces-C, such as Xalan-C (which 
> fails to build as it cannot find {{XercesMessages_en_US.cat}}).
> Originally reported at https://bugs.gentoo.org/673548



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2188) Use-after-free on external DTD scan

2023-12-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2188?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2188:
--
Fix Version/s: 3.2.5

> Use-after-free on external DTD scan
> ---
>
> Key: XERCESC-2188
> URL: https://issues.apache.org/jira/browse/XERCESC-2188
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Validating Parser (DTD)
>Affects Versions: 3.0.0, 3.0.1, 3.0.2, 3.1.0, 3.1.1, 3.1.2, 3.2.0, 3.1.3, 
> 3.1.4, 3.2.1, 3.2.2
>Reporter: Scott Cantor
>Priority: Major
> Fix For: 3.2.5
>
> Attachments: Apache-496067-disclosure-report.pdf
>
>
> This is a record of an unfixed bug reported in 2018 in the DTD scanner, per 
> the attached PDF, corresponding to CVE-2018-1311.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Assigned] (XERCESC-2188) Use-after-free on external DTD scan

2023-12-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2188?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor reassigned XERCESC-2188:
-

Assignee: Boris Kolpackov

> Use-after-free on external DTD scan
> ---
>
> Key: XERCESC-2188
> URL: https://issues.apache.org/jira/browse/XERCESC-2188
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Validating Parser (DTD)
>Affects Versions: 3.0.0, 3.0.1, 3.0.2, 3.1.0, 3.1.1, 3.1.2, 3.2.0, 3.1.3, 
> 3.1.4, 3.2.1, 3.2.2
>Reporter: Scott Cantor
>Assignee: Boris Kolpackov
>Priority: Major
> Fix For: 3.2.5
>
> Attachments: Apache-496067-disclosure-report.pdf
>
>
> This is a record of an unfixed bug reported in 2018 in the DTD scanner, per 
> the attached PDF, corresponding to CVE-2018-1311.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2238) Missing AttributesImpl or AttributesListImpl or VecAttrListImpl copy constructor

2023-12-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2238?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2238:
--
Labels:   (was: easyfix)

> Missing AttributesImpl  or AttributesListImpl or VecAttrListImpl copy 
> constructor
> -
>
> Key: XERCESC-2238
> URL: https://issues.apache.org/jira/browse/XERCESC-2238
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: SAX/SAX2
>Affects Versions: 3.2.3, 3.2.4
>Reporter: Charles Shoopak
>Priority: Minor
> Fix For: 4.0.0
>
>
>    In VecAttributesImpl.hpp (and same for VecAttrListImpl):
>    //  Unimplemented constructors and operators
>     // ---
>     VecAttributesImpl(const VecAttributesImpl&);
>     VecAttributesImpl& operator=(const VecAttributesImpl&);
>  
> We can read of the storied AttributesImpl in Attributes.hpp, it says:
>    "The instance provided will return valid results only during the scope of 
> the startElement invocation (to save it for future use, the application must 
> make a copy: the AttributesImpl helper class provides a convenient 
> constructor for doing so)."
> And notes elsewhere say AttributesListImpl is deprecated, use (non existent) 
> AttributesImpl instead.
> Dom has cloneNode. I could go looking for an older version of xerces that 
> contains AttributesListImpl? Or write some hack for now. Am I missing 
> something obvious?
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2244) DOMDocument::normalizeDocument() fails

2023-12-06 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2244?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17793798#comment-17793798
 ] 

Scott Cantor commented on XERCESC-2244:
---

Unless you can propose a specific patch, I definitely don't know this code well 
enough to consider changing it.

> DOMDocument::normalizeDocument() fails
> --
>
> Key: XERCESC-2244
> URL: https://issues.apache.org/jira/browse/XERCESC-2244
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: DOM, Miscellaneous, Utilities
>Affects Versions: 3.2.0, 3.2.1, 3.2.2, 3.2.3, 3.2.4
>Reporter: Markus Friedrich
>Priority: Major
>
> The following XML file
>  
> {code:java}
> 
> http://a; xmlns:pre="http://a;>
>   http://b; xmlns:pre="http://a"/>
>  
> {code}
> fails when DOMDocument::normailzeDocument() gets called on its DOM.
> In DOMNormalizer.cpp:437 the "oldUri" gets removed from "fUriHash" twice, 
> which throws the second time since the key no longer exists in "fUriHash".



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2244) DOMDocument::normalizeDocument() fails

2023-12-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2244?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2244:
--
Affects Version/s: 3.2.3
   3.2.2
   3.2.1
   3.2.0

> DOMDocument::normalizeDocument() fails
> --
>
> Key: XERCESC-2244
> URL: https://issues.apache.org/jira/browse/XERCESC-2244
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: DOM, Miscellaneous, Utilities
>Affects Versions: 3.2.0, 3.2.1, 3.2.2, 3.2.3, 3.2.4
>Reporter: Markus Friedrich
>Priority: Major
>
> The following XML file
>  
> {code:java}
> 
> http://a; xmlns:pre="http://a;>
>   http://b; xmlns:pre="http://a"/>
>  
> {code}
> fails when DOMDocument::normailzeDocument() gets called on its DOM.
> In DOMNormalizer.cpp:437 the "oldUri" gets removed from "fUriHash" twice, 
> which throws the second time since the key no longer exists in "fUriHash".



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] (XERCESC-2237) NetAccessors do not work

2023-12-06 Thread Scott Cantor (Jira)


[ https://issues.apache.org/jira/browse/XERCESC-2237 ]


Scott Cantor deleted comment on XERCESC-2237:
---

was (Author: canto...@osu.edu):
I do not believe this is a true report, but I will at least take a look given 
the sample attached.

> NetAccessors do not work
> 
>
> Key: XERCESC-2237
> URL: https://issues.apache.org/jira/browse/XERCESC-2237
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Utilities
>Affects Versions: 3.0.1, 3.1.0, 3.1.1, 3.1.2, 3.2.0, 3.1.3, 3.1.4, 3.2.1, 
> 3.2.2, 3.2.3, 3.2.4, 3.2.5
> Environment: Mainly Linux, but could reproduce the issue on Windows 
> too.
>Reporter: Guillaume BOTTEX
>Assignee: Scott Cantor
>Priority: Critical
> Attachments: test-1.xhtml
>
>
> Hello,
> We are using xerces in our project to parse XHTML files.
> However, we noticed that none of the NetAccessors (Socket, Curl, WinSock, 
> could not try on MacOS) are working in our case, and are freezing our 
> application.
> You can reproduce the issue by using the attached sample XHTML file, and use 
> it as input of the xerces "PParse" sample.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2237) NetAccessors do not work

2023-12-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2237?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2237:
--
Affects Version/s: 3.2.5

> NetAccessors do not work
> 
>
> Key: XERCESC-2237
> URL: https://issues.apache.org/jira/browse/XERCESC-2237
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Utilities
>Affects Versions: 3.0.1, 3.1.0, 3.1.1, 3.1.2, 3.2.0, 3.1.3, 3.1.4, 3.2.1, 
> 3.2.2, 3.2.3, 3.2.4, 3.2.5
> Environment: Mainly Linux, but could reproduce the issue on Windows 
> too.
>Reporter: Guillaume BOTTEX
>Assignee: Scott Cantor
>Priority: Critical
> Attachments: test-1.xhtml
>
>
> Hello,
> We are using xerces in our project to parse XHTML files.
> However, we noticed that none of the NetAccessors (Socket, Curl, WinSock, 
> could not try on MacOS) are working in our case, and are freezing our 
> application.
> You can reproduce the issue by using the attached sample XHTML file, and use 
> it as input of the xerces "PParse" sample.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Comment Edited] (XERCESC-2188) Use-after-free on external DTD scan

2023-04-26 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2188?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17716910#comment-17716910
 ] 

Scott Cantor edited comment on XERCESC-2188 at 4/26/23 8:50 PM:


I will update the advisory tonight or tomorrow with some information about it 
but it's not going to keep getting updated like this because some scanner is 
broken and misused. Since patches are infrequent, hopefully that will hold it 
for a while.

ETA: this is done.


was (Author: canto...@osu.edu):
I will update the advisory tonight or tomorrow with some information about it 
but it's not going to keep getting updated like this because some scanner is 
broken and misused. Since patches are infrequent, hopefully that will hold it 
for a while.

> Use-after-free on external DTD scan
> ---
>
> Key: XERCESC-2188
> URL: https://issues.apache.org/jira/browse/XERCESC-2188
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Validating Parser (DTD)
>Affects Versions: 3.0.0, 3.0.1, 3.0.2, 3.1.0, 3.1.1, 3.1.2, 3.2.0, 3.1.3, 
> 3.1.4, 3.2.1, 3.2.2
>Reporter: Scott Cantor
>Priority: Major
> Attachments: Apache-496067-disclosure-report.pdf
>
>
> This is a record of an unfixed bug reported in 2018 in the DTD scanner, per 
> the attached PDF, corresponding to CVE-2018-1311.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2188) Use-after-free on external DTD scan

2023-04-26 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2188?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17716910#comment-17716910
 ] 

Scott Cantor commented on XERCESC-2188:
---

I will update the advisory tonight or tomorrow with some information about it 
but it's not going to keep getting updated like this because some scanner is 
broken and misused. Since patches are infrequent, hopefully that will hold it 
for a while.

> Use-after-free on external DTD scan
> ---
>
> Key: XERCESC-2188
> URL: https://issues.apache.org/jira/browse/XERCESC-2188
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Validating Parser (DTD)
>Affects Versions: 3.0.0, 3.0.1, 3.0.2, 3.1.0, 3.1.1, 3.1.2, 3.2.0, 3.1.3, 
> 3.1.4, 3.2.1, 3.2.2
>Reporter: Scott Cantor
>Priority: Major
> Attachments: Apache-496067-disclosure-report.pdf
>
>
> This is a record of an unfixed bug reported in 2018 in the DTD scanner, per 
> the attached PDF, corresponding to CVE-2018-1311.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2188) Use-after-free on external DTD scan

2023-04-26 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2188?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17716859#comment-17716859
 ] 

Scott Cantor commented on XERCESC-2188:
---

I have no control over any CVEs, and their total inaccuracy across the board is 
why I don't use them. Our advisory is accurate so far as I can see but I can 
adjust that if there's something off in it.

https://xerces.apache.org/xerces-c/secadv/CVE-2018-1311.txt

There are not likely to ever be any 4.0 releases, this library is effectively 
frozen pending a change in committers.

> Use-after-free on external DTD scan
> ---
>
> Key: XERCESC-2188
> URL: https://issues.apache.org/jira/browse/XERCESC-2188
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Validating Parser (DTD)
>Affects Versions: 3.0.0, 3.0.1, 3.0.2, 3.1.0, 3.1.1, 3.1.2, 3.2.0, 3.1.3, 
> 3.1.4, 3.2.1, 3.2.2
>Reporter: Scott Cantor
>Priority: Major
> Attachments: Apache-496067-disclosure-report.pdf
>
>
> This is a record of an unfixed bug reported in 2018 in the DTD scanner, per 
> the attached PDF, corresponding to CVE-2018-1311.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2241) Integer overflows in DFAContentModel class

2022-10-10 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2241?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2241.
-

> Integer overflows in DFAContentModel class
> --
>
> Key: XERCESC-2241
> URL: https://issues.apache.org/jira/browse/XERCESC-2241
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Validating Parser (XML Schema)
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> On .xsd files like the following ones (generated by ossfuzz, so broken), 
> integer overflows can happen in DFAContentModel::countLeafNodes() and 
> DFAContentModel::buildDFA() which can later cause out-of-bounds access.
> Found in [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=52025]
>  
> ```
> http://www.w3.org/2001/XMLSchema;
>            xmlns:myns="http://myns;
>            targetNamespace="http://myns;
>            elementFormDefault="qualified" attributeFormDefault="unqualified">
> 
>   
>      
>         
>       
>   
> 
> 
>   
>       
>       
>         
>             
>  ame="x" type="xs:int" maxOccurs="1"/>
>             
>         
>       
>   
> 
> 
> ```



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2241) Integer overflows in DFAContentModel class

2022-10-10 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2241?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2241.
---
Resolution: Fixed

Applied to both branches.

> Integer overflows in DFAContentModel class
> --
>
> Key: XERCESC-2241
> URL: https://issues.apache.org/jira/browse/XERCESC-2241
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Validating Parser (XML Schema)
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> On .xsd files like the following ones (generated by ossfuzz, so broken), 
> integer overflows can happen in DFAContentModel::countLeafNodes() and 
> DFAContentModel::buildDFA() which can later cause out-of-bounds access.
> Found in [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=52025]
>  
> ```
> http://www.w3.org/2001/XMLSchema;
>            xmlns:myns="http://myns;
>            targetNamespace="http://myns;
>            elementFormDefault="qualified" attributeFormDefault="unqualified">
> 
>   
>      
>         
>       
>   
> 
> 
>   
>       
>       
>         
>             
>  ame="x" type="xs:int" maxOccurs="1"/>
>             
>         
>       
>   
> 
> 
> ```



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2237) NetAccessors do not work

2022-10-10 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2237?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17615170#comment-17615170
 ] 

Scott Cantor commented on XERCESC-2237:
---

All I can tell from debugging is that recv never returns (and this seems to be 
consistent across all the NetAccessors).

My best guess is that the HTTP requests it's formulating are missing something 
that modern servers need and it's preventing it from getting a response back 
(like perhaps the server is awaiting something it's not sending).

I do not have the ability to spend time on this since it doesn't affect my 
projects so I'm afraid leaving the bug report open is all I can do.

> NetAccessors do not work
> 
>
> Key: XERCESC-2237
> URL: https://issues.apache.org/jira/browse/XERCESC-2237
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Utilities
>Affects Versions: 3.0.1, 3.1.0, 3.1.1, 3.1.2, 3.2.0, 3.1.3, 3.1.4, 3.2.1, 
> 3.2.2, 3.2.3, 3.2.4
> Environment: Mainly Linux, but could reproduce the issue on Windows 
> too.
>Reporter: Guillaume BOTTEX
>Assignee: Scott Cantor
>Priority: Blocker
> Attachments: test-1.xhtml
>
>
> Hello,
> We are using xerces in our project to parse XHTML files.
> However, we noticed that none of the NetAccessors (Socket, Curl, WinSock, 
> could not try on MacOS) are working in our case, and are freezing our 
> application.
> You can reproduce the issue by using the attached sample XHTML file, and use 
> it as input of the xerces "PParse" sample.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2237) NetAccessors do not work

2022-10-10 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2237?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2237:
--
Priority: Critical  (was: Blocker)

> NetAccessors do not work
> 
>
> Key: XERCESC-2237
> URL: https://issues.apache.org/jira/browse/XERCESC-2237
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Utilities
>Affects Versions: 3.0.1, 3.1.0, 3.1.1, 3.1.2, 3.2.0, 3.1.3, 3.1.4, 3.2.1, 
> 3.2.2, 3.2.3, 3.2.4
> Environment: Mainly Linux, but could reproduce the issue on Windows 
> too.
>Reporter: Guillaume BOTTEX
>Assignee: Scott Cantor
>Priority: Critical
> Attachments: test-1.xhtml
>
>
> Hello,
> We are using xerces in our project to parse XHTML files.
> However, we noticed that none of the NetAccessors (Socket, Curl, WinSock, 
> could not try on MacOS) are working in our case, and are freezing our 
> application.
> You can reproduce the issue by using the attached sample XHTML file, and use 
> it as input of the xerces "PParse" sample.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2237) NetAccessors do not work

2022-10-10 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2237?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2237:
--
Language: C++  (was: C)

> NetAccessors do not work
> 
>
> Key: XERCESC-2237
> URL: https://issues.apache.org/jira/browse/XERCESC-2237
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Utilities
>Affects Versions: 3.0.1, 3.1.0, 3.1.1, 3.1.2, 3.2.0, 3.1.3, 3.1.4, 3.2.1, 
> 3.2.2, 3.2.3, 3.2.4
> Environment: Mainly Linux, but could reproduce the issue on Windows 
> too.
>Reporter: Guillaume BOTTEX
>Assignee: Scott Cantor
>Priority: Blocker
> Attachments: test-1.xhtml
>
>
> Hello,
> We are using xerces in our project to parse XHTML files.
> However, we noticed that none of the NetAccessors (Socket, Curl, WinSock, 
> could not try on MacOS) are working in our case, and are freezing our 
> application.
> You can reproduce the issue by using the attached sample XHTML file, and use 
> it as input of the xerces "PParse" sample.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2237) NetAccessors do not work

2022-10-10 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2237?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2237:
--
Fix Version/s: (was: 3.2.4)

> NetAccessors do not work
> 
>
> Key: XERCESC-2237
> URL: https://issues.apache.org/jira/browse/XERCESC-2237
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Utilities
>Affects Versions: 3.0.1, 3.1.0, 3.1.1, 3.1.2, 3.2.0, 3.1.3, 3.1.4, 3.2.1, 
> 3.2.2, 3.2.3
> Environment: Mainly Linux, but could reproduce the issue on Windows 
> too.
>Reporter: Guillaume BOTTEX
>Assignee: Scott Cantor
>Priority: Blocker
> Attachments: test-1.xhtml
>
>
> Hello,
> We are using xerces in our project to parse XHTML files.
> However, we noticed that none of the NetAccessors (Socket, Curl, WinSock, 
> could not try on MacOS) are working in our case, and are freezing our 
> application.
> You can reproduce the issue by using the attached sample XHTML file, and use 
> it as input of the xerces "PParse" sample.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2237) NetAccessors do not work

2022-10-10 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2237?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2237:
--
Affects Version/s: 3.2.4

> NetAccessors do not work
> 
>
> Key: XERCESC-2237
> URL: https://issues.apache.org/jira/browse/XERCESC-2237
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Utilities
>Affects Versions: 3.0.1, 3.1.0, 3.1.1, 3.1.2, 3.2.0, 3.1.3, 3.1.4, 3.2.1, 
> 3.2.2, 3.2.3, 3.2.4
> Environment: Mainly Linux, but could reproduce the issue on Windows 
> too.
>Reporter: Guillaume BOTTEX
>Assignee: Scott Cantor
>Priority: Blocker
> Attachments: test-1.xhtml
>
>
> Hello,
> We are using xerces in our project to parse XHTML files.
> However, we noticed that none of the NetAccessors (Socket, Curl, WinSock, 
> could not try on MacOS) are working in our case, and are freezing our 
> application.
> You can reproduce the issue by using the attached sample XHTML file, and use 
> it as input of the xerces "PParse" sample.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2180) Handle surrogate pairs when reading a QName instead of ASSERTing

2022-10-10 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2180?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2180.
-

> Handle surrogate pairs when reading a QName instead of ASSERTing
> 
>
> Key: XERCESC-2180
> URL: https://issues.apache.org/jira/browse/XERCESC-2180
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Miscellaneous
>Affects Versions: 3.2.0, 3.2.1, 3.2.2
>Reporter: Alberto Massari
>Assignee: Alberto Massari
>Priority: Major
> Fix For: 3.2.3
>
> Attachments: crash.xml
>
>
> As discovered by Vincent Ulitzsch:
>  {quote}The assertion fails when parsing a malformed xml-file, we attached a 
> crashing testcase. We would suggest fixing this assertion, since it opens up 
> the possibility
> for Denial of Service attacks via malformed xml files.{quote}
> The code expects that tre transcoder places a pair of surrogate characters in 
> the Unicode buffers, but the UTF16 transcoder simply copies the data without 
> checking if it ends in the middle of a surrogate pair. So the fix is to 
> replace the assertion with a request for more data, and if there is no data 
> or if it's not the other part of the surrogate, exit the method as we would 
> be doing if we found the invalid character inside the buffer



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2176) Incorrect symbolic links created for Linux static library and MacOS static and shared libraries

2022-10-10 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2176?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2176.
-

> Incorrect symbolic links created for Linux static library and MacOS static 
> and shared libraries
> ---
>
> Key: XERCESC-2176
> URL: https://issues.apache.org/jira/browse/XERCESC-2176
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.0, 3.2.1, 3.2.2
> Environment: Linux, MacOS
>Reporter: Brent Davis
>Assignee: Roger Leigh
>Priority: Minor
> Fix For: 3.2.3, 4.0.0
>
>
> We build Xerces-C++ for both the Linux and MacOS platforms, with both static 
> and shared libraries.  There are arguably some dubiously named symbolic links 
> created by src/CMakeLists.txt.  The symlinks are always named 
> 'libxerces-c.so' regardless or library type, or use of the .dylib extension 
> on MacOS.
> ||Platform||Library Type||Symbolic Link||Comment||
> |{color:#de350b}Linux{color}|{color:#de350b}static{color}|{color:#de350b}libxerces-c.so
>  -> libxerces-c-3.2.a{color}|{color:#de350b}symbolic link should either be 
> libxerces-c.a or not created{color}|
> |{color:#00875a} 
> {color}|{color:#00875a}shared{color}|{color:#00875a}libxerces-c.so -> 
> libxerces-c-3.2.so{color}|{color:#00875a}good{color}|
> |{color:#de350b}MacOS{color}|{color:#de350b}static{color}|{color:#de350b}libxerces-c.so
>  -> libxerces-c-3.2.a{color}|{color:#de350b}symbolic link should either be 
> libxerces-c.a or not created{color}|
> |{color:#de350b} 
> {color}|{color:#de350b}shared{color}|{color:#de350b}libxerces-c.so -> 
> libxerces-c-3.2.dylib{color}|{color:#de350b}symbolic link should best be 
> named libxerces-c.dylib{color}|
> Curiously, the Microsoft _vcpkg_ folks just recently ran into the Linux 
> static library portion of this issue and elected to not create the symlink in 
> that case.  See [[xerces-c] produces strange files in 
> installed/x64-linux/lib|[https://github.com/microsoft/vcpkg/issues/7490]].
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2218) CurlURLInputStream constructor memory leak

2022-10-10 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2218?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2218.
-

> CurlURLInputStream constructor memory leak
> --
>
> Key: XERCESC-2218
> URL: https://issues.apache.org/jira/browse/XERCESC-2218
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Roger Leigh
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> CurlURLInputStream constructor calls the readMore() method, which can
> throw exceptions. In that situation, the destructor is not called, which
> results in resource/memory leaks. To fix that, catch the exceptions,
> manually do the cleanup and rethrow the exceptions.
> Found by ossfuzz (locally)



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2228) DFAContentModel: fix memory leaks when OutOfMemoryException occurs

2022-10-10 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2228?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2228.
-

> DFAContentModel: fix memory leaks when OutOfMemoryException occurs
> --
>
> Key: XERCESC-2228
> URL: https://issues.apache.org/jira/browse/XERCESC-2228
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> Fixes GDAL's [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=39159]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2227) Memleak fixes in ContentSpecNode and ComplexTypeInfo classes

2022-10-10 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2227?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2227.
-

> Memleak fixes in ContentSpecNode and ComplexTypeInfo classes
> 
>
> Key: XERCESC-2227
> URL: https://issues.apache.org/jira/browse/XERCESC-2227
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> when a OutOfMemory exception occurs.
> Spotted by [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=39127] (on 
> GDAL)
> The commits are a bit in increasing order of triviality. The ownership rules 
> of ContentSpecNode first and second members, as used by ComplexTypeInfo, are 
> super complex. shared_ptr would be much welcome here! I can just tell that 
> valgrind on my test case reports no double-free nor memory leak after those 
> fixes



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2212) AbstractDOMParser::parse potentially throws undocumented OutOfMemoryException

2022-10-10 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2212?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2212.
---
Fix Version/s: (was: 3.2.4)
   Resolution: Won't Fix

I checked and there is no clear evidence that it was intended that this be 
documented. Half the API does indeed raise that exception type and I don't see 
it noted. It's just the way it works.

> AbstractDOMParser::parse potentially throws undocumented OutOfMemoryException
> -
>
> Key: XERCESC-2212
> URL: https://issues.apache.org/jira/browse/XERCESC-2212
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: DOM
>Affects Versions: 3.2.2, 3.2.3
>Reporter: Tamir Yehuda
>Assignee: Scott Cantor
>Priority: Minor
>
> the code shows that 
> {code:java}
> try
> {
> // ...
> }
> catch(const OutOfMemoryException&)
> {
> resetInProgress.release();
>     throw;
> }
> {code}
> and the OutOfMemoryException could be thrown. However this is not shown in 
> the documentation



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2212) AbstractDOMParser::parse potentially throws undocumented OutOfMemoryException

2022-10-10 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2212?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2212.
-

> AbstractDOMParser::parse potentially throws undocumented OutOfMemoryException
> -
>
> Key: XERCESC-2212
> URL: https://issues.apache.org/jira/browse/XERCESC-2212
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: DOM
>Affects Versions: 3.2.2, 3.2.3
>Reporter: Tamir Yehuda
>Assignee: Scott Cantor
>Priority: Minor
>
> the code shows that 
> {code:java}
> try
> {
> // ...
> }
> catch(const OutOfMemoryException&)
> {
> resetInProgress.release();
>     throw;
> }
> {code}
> and the OutOfMemoryException could be thrown. However this is not shown in 
> the documentation



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2197) Key Identity Constraint error reporting

2022-10-06 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2197?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17613543#comment-17613543
 ] 

Scott Cantor commented on XERCESC-2197:
---

This is an API change, so it not eligible for a patch. It can be applied to the 
master branch, but the chances of a release there are pretty low at this point.

> Key Identity Constraint error reporting
> ---
>
> Key: XERCESC-2197
> URL: https://issues.apache.org/jira/browse/XERCESC-2197
> Project: Xerces-C++
>  Issue Type: Improvement
>  Components: Validating Parser (XML Schema)
>Reporter: Stefan de Konink
>Priority: Major
> Fix For: 4.0.0
>
> Attachments: XERCESC-2197.patch
>
>
> The current Java version of Xerces has a significant better error reporting 
> on Identity Constraints, if compared with the C++ version. The primary issue 
> is that the the C++ version is only reporting the name of the element the key 
> identity constraint has been defined, the secondary issue is that the line 
> number reported is of the element closing the tag. A properly failing 
> document will therefore show oceans of duplicated lines in the output, while 
> in fact they are different elements tested, in different parts of the 
> document.
>  
> As example the following error is presented:
> Error at file /tmp/cxx.xml, line 5009571, char 24
>  Message: identity constraint key for element 'ServiceFrame' not found
> The expected error would be:
> Error at file /tmp/cxx.xml, line 1495133, char 51
> Key 'ToPointRef' with value 'CXX-ALL:RoutePoint:78210040' not found for 
> identity constraint of element 'ServiceFrame'.
>  
> Since the above is quite a difference I started to fiddle with GDB a bit:
>  
> {code:java}
> 302 {
> 303 FieldValueMap& valueMap = iter.nextElement();
> 304
> 305 if (!keyValueStore->contains() && fDoReportError) {
> 306
> 307 fScanner->getValidator()->emitError(XMLValid::IC_KeyNotFound,
> 308 fIdentityConstraint->getElementName());
> 309 }
> 310 }
> 311 }
> {code}
>  
>  
>  
> {code:java}
> p fIdentityConstraint.fIdentityConstraintName
> $34 = (XMLCh *) 0x590070 u"ToPointRef"
>  
> p fIdentityConstraint.fSelector.fXPath.fExpression
> $40 = (XMLCh *) 0x590390 u".//netex:ToPointRef"
>  
> p fIdentityConstraint.fFields.fElemList[0].fXPath.fExpression
> $32 = (XMLCh *) 0x590930 u"@ref"
>  
> p keyValueStore.fIdentityConstraint.fIdentityConstraintName
> $70 = (XMLCh *) 0x57cf10 u"ScheduledStopPointId"
>  
> p *valueMap.fValues.fElemList
> $41 = 0x8ce9d90 u"CXX-ALL:RoutePoint:78210040"
> p fIdentityConstraint->getElementName()
> $77 = (XMLCh *) 0x5902f0 u"ServiceFrame"
> {code}
>  
> So I would state that making this error on par with Java is quite trivial. 
> The only thing I did not find yet how to retrieve the line number for the 
> element that is currently being searched for. Would be nice to get a hand in 
> that direction for crafting a decent patch! 
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2197) Key Identity Constraint error reporting

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2197?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2197:
--
Fix Version/s: 4.0.0
   (was: 3.2.4)

> Key Identity Constraint error reporting
> ---
>
> Key: XERCESC-2197
> URL: https://issues.apache.org/jira/browse/XERCESC-2197
> Project: Xerces-C++
>  Issue Type: Improvement
>  Components: Validating Parser (XML Schema)
>Reporter: Stefan de Konink
>Priority: Major
> Fix For: 4.0.0
>
> Attachments: XERCESC-2197.patch
>
>
> The current Java version of Xerces has a significant better error reporting 
> on Identity Constraints, if compared with the C++ version. The primary issue 
> is that the the C++ version is only reporting the name of the element the key 
> identity constraint has been defined, the secondary issue is that the line 
> number reported is of the element closing the tag. A properly failing 
> document will therefore show oceans of duplicated lines in the output, while 
> in fact they are different elements tested, in different parts of the 
> document.
>  
> As example the following error is presented:
> Error at file /tmp/cxx.xml, line 5009571, char 24
>  Message: identity constraint key for element 'ServiceFrame' not found
> The expected error would be:
> Error at file /tmp/cxx.xml, line 1495133, char 51
> Key 'ToPointRef' with value 'CXX-ALL:RoutePoint:78210040' not found for 
> identity constraint of element 'ServiceFrame'.
>  
> Since the above is quite a difference I started to fiddle with GDB a bit:
>  
> {code:java}
> 302 {
> 303 FieldValueMap& valueMap = iter.nextElement();
> 304
> 305 if (!keyValueStore->contains() && fDoReportError) {
> 306
> 307 fScanner->getValidator()->emitError(XMLValid::IC_KeyNotFound,
> 308 fIdentityConstraint->getElementName());
> 309 }
> 310 }
> 311 }
> {code}
>  
>  
>  
> {code:java}
> p fIdentityConstraint.fIdentityConstraintName
> $34 = (XMLCh *) 0x590070 u"ToPointRef"
>  
> p fIdentityConstraint.fSelector.fXPath.fExpression
> $40 = (XMLCh *) 0x590390 u".//netex:ToPointRef"
>  
> p fIdentityConstraint.fFields.fElemList[0].fXPath.fExpression
> $32 = (XMLCh *) 0x590930 u"@ref"
>  
> p keyValueStore.fIdentityConstraint.fIdentityConstraintName
> $70 = (XMLCh *) 0x57cf10 u"ScheduledStopPointId"
>  
> p *valueMap.fValues.fElemList
> $41 = 0x8ce9d90 u"CXX-ALL:RoutePoint:78210040"
> p fIdentityConstraint->getElementName()
> $77 = (XMLCh *) 0x5902f0 u"ServiceFrame"
> {code}
>  
> So I would state that making this error on par with Java is quite trivial. 
> The only thing I did not find yet how to retrieve the line number for the 
> element that is currently being searched for. Would be nice to get a hand in 
> that direction for crafting a decent patch! 
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2195) Invalid attribute in .gitattributes file

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2195?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2195.
---
Resolution: Fixed

Applied to both branches.

> Invalid attribute in .gitattributes file
> 
>
> Key: XERCESC-2195
> URL: https://issues.apache.org/jira/browse/XERCESC-2195
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Miscellaneous
>Affects Versions: 3.2.3
>Reporter: Karen Arutyunov
>Assignee: Scott Cantor
>Priority: Minor
> Fix For: 4.0.0, 3.2.4
>
>
> The attribute name 'eol' is misspelled in the .gitattributes file.
> The line
> *.bat text eof=crlf
> should be changed to
> *.bat text eol=crlf
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2196) cross-compiling issue

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2196?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2196.
---
Fix Version/s: 4.0.0
 Assignee: Scott Cantor
   Resolution: Fixed

Applied to both branches.

> cross-compiling issue
> -
>
> Key: XERCESC-2196
> URL: https://issues.apache.org/jira/browse/XERCESC-2196
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.3
> Environment: ubuntu18.04,cross-compilation
>Reporter: ayoub serti
>Assignee: Scott Cantor
>Priority: Trivial
>  Labels: build, easyfix, github-import, pull-request-available, 
> ready-to-commit
> Fix For: 4.0.0, 3.2.4
>
>
> When cross-compiling xerces on linux ubuntu, the configure script fails 
> because of a test program that try to run.
> The problem came from `configure.ac` where there is an AC_RUN_IFELSE without 
> action-if-cross-compiling action.
> the pull request fix this issue [https://github.com/apache/xerces-c/pull/11]
> No problem within CMake cross-compilation 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2196) cross-compiling issue

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2196?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2196.
-

> cross-compiling issue
> -
>
> Key: XERCESC-2196
> URL: https://issues.apache.org/jira/browse/XERCESC-2196
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.3
> Environment: ubuntu18.04,cross-compilation
>Reporter: ayoub serti
>Assignee: Scott Cantor
>Priority: Trivial
>  Labels: build, easyfix, github-import, pull-request-available, 
> ready-to-commit
> Fix For: 4.0.0, 3.2.4
>
>
> When cross-compiling xerces on linux ubuntu, the configure script fails 
> because of a test program that try to run.
> The problem came from `configure.ac` where there is an AC_RUN_IFELSE without 
> action-if-cross-compiling action.
> the pull request fix this issue [https://github.com/apache/xerces-c/pull/11]
> No problem within CMake cross-compilation 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2195) Invalid attribute in .gitattributes file

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2195?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2195.
-

> Invalid attribute in .gitattributes file
> 
>
> Key: XERCESC-2195
> URL: https://issues.apache.org/jira/browse/XERCESC-2195
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Miscellaneous
>Affects Versions: 3.2.3
>Reporter: Karen Arutyunov
>Assignee: Scott Cantor
>Priority: Minor
> Fix For: 4.0.0, 3.2.4
>
>
> The attribute name 'eol' is misspelled in the .gitattributes file.
> The line
> *.bat text eof=crlf
> should be changed to
> *.bat text eol=crlf
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2196) cross-compiling issue

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2196?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2196:
--
Description: 
When cross-compiling xerces on linux ubuntu, the configure script fails because 
of a test program that try to run.

The problem came from `configure.ac` where there is an AC_RUN_IFELSE without 
action-if-cross-compiling action.

the pull request fix this issue [https://github.com/apache/xerces-c/pull/11]

No problem within CMake cross-compilation 

  was:
When cross-compiling xerces on linux ubuntu, the configure script fails because 
of a test program that try to run.

The problem came from `configure.ac` where there is an AC_RUN_IFELSE without 
action-if-cross-compiling action.

the pull request fix this issue 
[https://github.com/apache/xerces-c/pull/11|http://example.com/]

No problem within CMake cross-compilation 


> cross-compiling issue
> -
>
> Key: XERCESC-2196
> URL: https://issues.apache.org/jira/browse/XERCESC-2196
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.3
> Environment: ubuntu18.04,cross-compilation
>Reporter: ayoub serti
>Priority: Trivial
>  Labels: build, easyfix, github-import, pull-request-available, 
> ready-to-commit
> Fix For: 3.2.4
>
>
> When cross-compiling xerces on linux ubuntu, the configure script fails 
> because of a test program that try to run.
> The problem came from `configure.ac` where there is an AC_RUN_IFELSE without 
> action-if-cross-compiling action.
> the pull request fix this issue [https://github.com/apache/xerces-c/pull/11]
> No problem within CMake cross-compilation 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2195) Invalid attribute in .gitattributes file

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2195?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2195:
--
Fix Version/s: 4.0.0

> Invalid attribute in .gitattributes file
> 
>
> Key: XERCESC-2195
> URL: https://issues.apache.org/jira/browse/XERCESC-2195
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Miscellaneous
>Affects Versions: 3.2.3
>Reporter: Karen Arutyunov
>Assignee: Scott Cantor
>Priority: Minor
> Fix For: 4.0.0, 3.2.4
>
>
> The attribute name 'eol' is misspelled in the .gitattributes file.
> The line
> *.bat text eof=crlf
> should be changed to
> *.bat text eol=crlf
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2120) DOM Serialization does not correctly validate Surrogate Pairs

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2120?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2120:
--
Affects Version/s: 3.2.3
   3.2.2
   3.2.1
   3.2.4

> DOM Serialization does not correctly validate Surrogate Pairs
> -
>
> Key: XERCESC-2120
> URL: https://issues.apache.org/jira/browse/XERCESC-2120
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: DOM
>Affects Versions: 3.2.0, 3.2.1, 3.2.2, 3.2.3, 3.2.4
>Reporter: Andrew Blackton
>Priority: Major
> Attachments: DOMCharacterValidationTest.cpp, DomStringValidation.patch
>
>
> When attempting to write an xml document containing valid UTF-16 surrogate 
> pairs an error occurs during validation. This causes the write to fail.
> It appears as though this issue was introduced with 
> https://issues.apache.org/jira/browse/XERCESC-1854 in the following commit 
> http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/dom/impl/DOMLSSerializerImpl.cpp?r1=768978=1226891.
> I have supplied a reproducible and a potential patch. The string validator 
> should be responsible for determining if the codepoint is part of a surrogate 
> pair. However, I may also like to make the argument that this may not be the 
> right location to be doing the string validation. As it will leave the output 
> document in an inconsistent (half-written) state.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2197) Key Identity Constraint error reporting

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2197?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2197:
--
Fix Version/s: 3.2.4

> Key Identity Constraint error reporting
> ---
>
> Key: XERCESC-2197
> URL: https://issues.apache.org/jira/browse/XERCESC-2197
> Project: Xerces-C++
>  Issue Type: Improvement
>  Components: Validating Parser (XML Schema)
>Reporter: Stefan de Konink
>Priority: Major
> Fix For: 3.2.4
>
> Attachments: XERCESC-2197.patch
>
>
> The current Java version of Xerces has a significant better error reporting 
> on Identity Constraints, if compared with the C++ version. The primary issue 
> is that the the C++ version is only reporting the name of the element the key 
> identity constraint has been defined, the secondary issue is that the line 
> number reported is of the element closing the tag. A properly failing 
> document will therefore show oceans of duplicated lines in the output, while 
> in fact they are different elements tested, in different parts of the 
> document.
>  
> As example the following error is presented:
> Error at file /tmp/cxx.xml, line 5009571, char 24
>  Message: identity constraint key for element 'ServiceFrame' not found
> The expected error would be:
> Error at file /tmp/cxx.xml, line 1495133, char 51
> Key 'ToPointRef' with value 'CXX-ALL:RoutePoint:78210040' not found for 
> identity constraint of element 'ServiceFrame'.
>  
> Since the above is quite a difference I started to fiddle with GDB a bit:
>  
> {code:java}
> 302 {
> 303 FieldValueMap& valueMap = iter.nextElement();
> 304
> 305 if (!keyValueStore->contains() && fDoReportError) {
> 306
> 307 fScanner->getValidator()->emitError(XMLValid::IC_KeyNotFound,
> 308 fIdentityConstraint->getElementName());
> 309 }
> 310 }
> 311 }
> {code}
>  
>  
>  
> {code:java}
> p fIdentityConstraint.fIdentityConstraintName
> $34 = (XMLCh *) 0x590070 u"ToPointRef"
>  
> p fIdentityConstraint.fSelector.fXPath.fExpression
> $40 = (XMLCh *) 0x590390 u".//netex:ToPointRef"
>  
> p fIdentityConstraint.fFields.fElemList[0].fXPath.fExpression
> $32 = (XMLCh *) 0x590930 u"@ref"
>  
> p keyValueStore.fIdentityConstraint.fIdentityConstraintName
> $70 = (XMLCh *) 0x57cf10 u"ScheduledStopPointId"
>  
> p *valueMap.fValues.fElemList
> $41 = 0x8ce9d90 u"CXX-ALL:RoutePoint:78210040"
> p fIdentityConstraint->getElementName()
> $77 = (XMLCh *) 0x5902f0 u"ServiceFrame"
> {code}
>  
> So I would state that making this error on par with Java is quite trivial. 
> The only thing I did not find yet how to retrieve the line number for the 
> element that is currently being searched for. Would be nice to get a hand in 
> that direction for crafting a decent patch! 
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Assigned] (XERCESC-2195) Invalid attribute in .gitattributes file

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2195?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor reassigned XERCESC-2195:
-

Assignee: Scott Cantor

> Invalid attribute in .gitattributes file
> 
>
> Key: XERCESC-2195
> URL: https://issues.apache.org/jira/browse/XERCESC-2195
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Miscellaneous
>Affects Versions: 3.2.3
>Reporter: Karen Arutyunov
>Assignee: Scott Cantor
>Priority: Minor
> Fix For: 3.2.4
>
>
> The attribute name 'eol' is misspelled in the .gitattributes file.
> The line
> *.bat text eof=crlf
> should be changed to
> *.bat text eol=crlf
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2196) cross-compiling issue

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2196?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2196:
--
Fix Version/s: 3.2.4

> cross-compiling issue
> -
>
> Key: XERCESC-2196
> URL: https://issues.apache.org/jira/browse/XERCESC-2196
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.3
> Environment: ubuntu18.04,cross-compilation
>Reporter: ayoub serti
>Priority: Blocker
>  Labels: build, easyfix, github-import, pull-request-available, 
> ready-to-commit
> Fix For: 3.2.4
>
>
> When cross-compiling xerces on linux ubuntu, the configure script fails 
> because of a test program that try to run.
> The problem came from `configure.ac` where there is an AC_RUN_IFELSE without 
> action-if-cross-compiling action.
> the pull request fix this issue 
> [https://github.com/apache/xerces-c/pull/11|http://example.com/]
> No problem within CMake cross-compilation 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2196) cross-compiling issue

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2196?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2196:
--
Priority: Trivial  (was: Blocker)

> cross-compiling issue
> -
>
> Key: XERCESC-2196
> URL: https://issues.apache.org/jira/browse/XERCESC-2196
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.3
> Environment: ubuntu18.04,cross-compilation
>Reporter: ayoub serti
>Priority: Trivial
>  Labels: build, easyfix, github-import, pull-request-available, 
> ready-to-commit
> Fix For: 3.2.4
>
>
> When cross-compiling xerces on linux ubuntu, the configure script fails 
> because of a test program that try to run.
> The problem came from `configure.ac` where there is an AC_RUN_IFELSE without 
> action-if-cross-compiling action.
> the pull request fix this issue 
> [https://github.com/apache/xerces-c/pull/11|http://example.com/]
> No problem within CMake cross-compilation 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2195) Invalid attribute in .gitattributes file

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2195?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2195:
--
Fix Version/s: 3.2.4

> Invalid attribute in .gitattributes file
> 
>
> Key: XERCESC-2195
> URL: https://issues.apache.org/jira/browse/XERCESC-2195
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Miscellaneous
>Affects Versions: 3.2.3
>Reporter: Karen Arutyunov
>Priority: Minor
> Fix For: 3.2.4
>
>
> The attribute name 'eol' is misspelled in the .gitattributes file.
> The line
> *.bat text eof=crlf
> should be changed to
> *.bat text eol=crlf
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2239) When XMLUni::fgDOMWRTSplitCdataSections is true (the default), invalid XML characters are allowed by DOMWriter

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2239?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2239:
--
Affects Version/s: 3.2.3
   3.2.2
   3.2.1
   3.2.4

> When XMLUni::fgDOMWRTSplitCdataSections is true (the default), invalid XML 
> characters are allowed by DOMWriter
> --
>
> Key: XERCESC-2239
> URL: https://issues.apache.org/jira/browse/XERCESC-2239
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: DOM
>Affects Versions: 3.2.0, 3.2.1, 3.2.2, 3.2.3, 3.2.4
> Environment: Operating System: All
> Platform: All
>Reporter: David Leffingwell
>Priority: Major
>
> // Create a Document with a CDATA section that contains an invalid XML 
> character (e.g. 0x1b). 
> // This should fail when serializing the Document, but it does not when 
> XMLUni::fgDOMWRTSplitCdataSections is true.
> struct XercesDeleter
> {
> template
> void operator()(T* data) const
> {
> if (data) { data->release(); };
> }
> };
> typedef std::unique_ptr  
>  DOMWriterPtr;
> typedef std::unique_ptr 
> DOMDocumentPtr;
> XMLPlatformUtils::Initialize();
> DOMImplementation* impl = 
> DOMImplementationRegistry::getDOMImplementation(XMLString::transcode("LS"));
>  // Create DOM with a CDATA section
> DOMDocumentPtr document(impl->createDocument());
> DOMElement* element = 
> document->createElementNS(XMLString::transcode("http://schemas.openxmlformats.org/wordprocessingml/2006/main;),
>  XMLString::transcode("w:t"));
> document->appendChild(element);
> DOMCDATASection* codesection = document->createCDATASection(XercesString("c = 
> '';")); // 0x1B is not a valid XML 1.0 character
> element->appendChild(codesection); 
> DOMWriterPtr writer(impl->createLSSerializer());
> writer->writeToString(document.get())



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2239) When XMLUni::fgDOMWRTSplitCdataSections is true (the default), invalid XML characters are allowed by DOMWriter

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2239?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2239:
--
Fix Version/s: (was: 3.2.4)

> When XMLUni::fgDOMWRTSplitCdataSections is true (the default), invalid XML 
> characters are allowed by DOMWriter
> --
>
> Key: XERCESC-2239
> URL: https://issues.apache.org/jira/browse/XERCESC-2239
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: DOM
>Affects Versions: 3.2.0
> Environment: Operating System: All
> Platform: All
>Reporter: David Leffingwell
>Priority: Major
>
> // Create a Document with a CDATA section that contains an invalid XML 
> character (e.g. 0x1b). 
> // This should fail when serializing the Document, but it does not when 
> XMLUni::fgDOMWRTSplitCdataSections is true.
> struct XercesDeleter
> {
> template
> void operator()(T* data) const
> {
> if (data) { data->release(); };
> }
> };
> typedef std::unique_ptr  
>  DOMWriterPtr;
> typedef std::unique_ptr 
> DOMDocumentPtr;
> XMLPlatformUtils::Initialize();
> DOMImplementation* impl = 
> DOMImplementationRegistry::getDOMImplementation(XMLString::transcode("LS"));
>  // Create DOM with a CDATA section
> DOMDocumentPtr document(impl->createDocument());
> DOMElement* element = 
> document->createElementNS(XMLString::transcode("http://schemas.openxmlformats.org/wordprocessingml/2006/main;),
>  XMLString::transcode("w:t"));
> document->appendChild(element);
> DOMCDATASection* codesection = document->createCDATASection(XercesString("c = 
> '';")); // 0x1B is not a valid XML 1.0 character
> element->appendChild(codesection); 
> DOMWriterPtr writer(impl->createLSSerializer());
> writer->writeToString(document.get())



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2239) When XMLUni::fgDOMWRTSplitCdataSections is true (the default), invalid XML characters are allowed by DOMWriter

2022-10-06 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2239?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17613505#comment-17613505
 ] 

Scott Cantor commented on XERCESC-2239:
---

I suspect there's an intended distinction between "illegal" characters and 
"unrepresentable" ones. The feature apparently controls how unrepresentable 
characters are handled, and explicitly changes the behavior such that they're 
output numerically and don't cause an error.

I don't know the specs well enough to even consider making a change to this 
code, or even if a change is in fact the right thing to do. I'm pretty sure the 
current behavior is intentional.

> When XMLUni::fgDOMWRTSplitCdataSections is true (the default), invalid XML 
> characters are allowed by DOMWriter
> --
>
> Key: XERCESC-2239
> URL: https://issues.apache.org/jira/browse/XERCESC-2239
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: DOM
>Affects Versions: 3.2.0
> Environment: Operating System: All
> Platform: All
>Reporter: David Leffingwell
>Priority: Major
> Fix For: 3.2.4
>
>
> // Create a Document with a CDATA section that contains an invalid XML 
> character (e.g. 0x1b). 
> // This should fail when serializing the Document, but it does not when 
> XMLUni::fgDOMWRTSplitCdataSections is true.
> struct XercesDeleter
> {
> template
> void operator()(T* data) const
> {
> if (data) { data->release(); };
> }
> };
> typedef std::unique_ptr  
>  DOMWriterPtr;
> typedef std::unique_ptr 
> DOMDocumentPtr;
> XMLPlatformUtils::Initialize();
> DOMImplementation* impl = 
> DOMImplementationRegistry::getDOMImplementation(XMLString::transcode("LS"));
>  // Create DOM with a CDATA section
> DOMDocumentPtr document(impl->createDocument());
> DOMElement* element = 
> document->createElementNS(XMLString::transcode("http://schemas.openxmlformats.org/wordprocessingml/2006/main;),
>  XMLString::transcode("w:t"));
> document->appendChild(element);
> DOMCDATASection* codesection = document->createCDATASection(XercesString("c = 
> '';")); // 0x1B is not a valid XML 1.0 character
> element->appendChild(codesection); 
> DOMWriterPtr writer(impl->createLSSerializer());
> writer->writeToString(document.get())



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2235) DFAContentModel::buildDFA(): correctly zero-initialize fFollowList

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2235?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2235.
-

> DFAContentModel::buildDFA(): correctly zero-initialize fFollowList
> --
>
> Key: XERCESC-2235
> URL: https://issues.apache.org/jira/browse/XERCESC-2235
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> Due to a copy issue, the intended zero-initialization of
> fFollowList wasn't done (copy issue), and thus in case of
> OutOfMemory exception when initializing the array, the memory freeing in
> cleanup() could access uninitialized elements.
> Follow-up of https://github.com/apache/xerces-c/pull/40 / 
> a65990d79d3fc333d7481f010da4e165a88b6cb3
> Fixes GDAL's https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=42636



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2235) DFAContentModel::buildDFA(): correctly zero-initialize fFollowList

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2235?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2235.
---
Fix Version/s: 4.0.0
   Resolution: Fixed

Applied to both branches.

> DFAContentModel::buildDFA(): correctly zero-initialize fFollowList
> --
>
> Key: XERCESC-2235
> URL: https://issues.apache.org/jira/browse/XERCESC-2235
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> Due to a copy issue, the intended zero-initialization of
> fFollowList wasn't done (copy issue), and thus in case of
> OutOfMemory exception when initializing the array, the memory freeing in
> cleanup() could access uninitialized elements.
> Follow-up of https://github.com/apache/xerces-c/pull/40 / 
> a65990d79d3fc333d7481f010da4e165a88b6cb3
> Fixes GDAL's https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=42636



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2233) DFAContentModel::buildDFA(): fix memory leaks when OutOfMemoryException occurs

2022-10-06 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2233?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17613496#comment-17613496
 ] 

Scott Cantor commented on XERCESC-2233:
---

This is a bit of bigger change to fix something that's really not much of a 
risk so skipping for the latest patch.

> DFAContentModel::buildDFA(): fix memory leaks when OutOfMemoryException occurs
> --
>
> Key: XERCESC-2233
> URL: https://issues.apache.org/jira/browse/XERCESC-2233
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3, 3.2.4
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0
>
>
> Fixes GDAL's [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=41335]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2233) DFAContentModel::buildDFA(): fix memory leaks when OutOfMemoryException occurs

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2233?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2233:
--
Affects Version/s: 3.2.4

> DFAContentModel::buildDFA(): fix memory leaks when OutOfMemoryException occurs
> --
>
> Key: XERCESC-2233
> URL: https://issues.apache.org/jira/browse/XERCESC-2233
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3, 3.2.4
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0
>
>
> Fixes GDAL's [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=41335]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2233) DFAContentModel::buildDFA(): fix memory leaks when OutOfMemoryException occurs

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2233?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2233:
--
Fix Version/s: 4.0.0
   (was: 3.2.4)

> DFAContentModel::buildDFA(): fix memory leaks when OutOfMemoryException occurs
> --
>
> Key: XERCESC-2233
> URL: https://issues.apache.org/jira/browse/XERCESC-2233
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0
>
>
> Fixes GDAL's [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=41335]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2227) Memleak fixes in ContentSpecNode and ComplexTypeInfo classes

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2227?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2227.
---
Resolution: Fixed

Applied to both branches.

> Memleak fixes in ContentSpecNode and ComplexTypeInfo classes
> 
>
> Key: XERCESC-2227
> URL: https://issues.apache.org/jira/browse/XERCESC-2227
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> when a OutOfMemory exception occurs.
> Spotted by [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=39127] (on 
> GDAL)
> The commits are a bit in increasing order of triviality. The ownership rules 
> of ContentSpecNode first and second members, as used by ComplexTypeInfo, are 
> super complex. shared_ptr would be much welcome here! I can just tell that 
> valgrind on my test case reports no double-free nor memory leak after those 
> fixes



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2218) CurlURLInputStream constructor memory leak

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2218?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2218.
---
Resolution: Fixed

Reapplied to branch after ABI discussion pending confirmation on Windows.

> CurlURLInputStream constructor memory leak
> --
>
> Key: XERCESC-2218
> URL: https://issues.apache.org/jira/browse/XERCESC-2218
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Roger Leigh
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> CurlURLInputStream constructor calls the readMore() method, which can
> throw exceptions. In that situation, the destructor is not called, which
> results in resource/memory leaks. To fix that, catch the exceptions,
> manually do the cleanup and rethrow the exceptions.
> Found by ossfuzz (locally)



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2228) DFAContentModel: fix memory leaks when OutOfMemoryException occurs

2022-10-06 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2228?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2228.
---
Fix Version/s: 4.0.0
   Resolution: Fixed

For now I'm reapplying this to the branch given the apparent misunderstanding I 
was operating under about Windows linkage. We'll revisit the patch if need be, 
which is not a big deal.

> DFAContentModel: fix memory leaks when OutOfMemoryException occurs
> --
>
> Key: XERCESC-2228
> URL: https://issues.apache.org/jira/browse/XERCESC-2228
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> Fixes GDAL's [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=39159]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2212) AbstractDOMParser::parse potentially throws undocumented OutOfMemoryException

2022-10-05 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2212?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17613224#comment-17613224
 ] 

Scott Cantor commented on XERCESC-2212:
---

I'll review but it would save some time if you can identify exactly what 
functions are needing of an API update.

I would have to say though that any caller of just about any method in a 
library like this should assume an OOM exception is a possibility. That may be 
why it isn't listed, but if it's listed in other places than I may not be 
correct about that.

> AbstractDOMParser::parse potentially throws undocumented OutOfMemoryException
> -
>
> Key: XERCESC-2212
> URL: https://issues.apache.org/jira/browse/XERCESC-2212
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: DOM
>Affects Versions: 3.2.2, 3.2.3
>Reporter: Tamir Yehuda
>Assignee: Scott Cantor
>Priority: Minor
> Fix For: 3.2.4
>
>
> the code shows that 
> {code:java}
> try
> {
> // ...
> }
> catch(const OutOfMemoryException&)
> {
> resetInProgress.release();
>     throw;
> }
> {code}
> and the OutOfMemoryException could be thrown. However this is not shown in 
> the documentation



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Assigned] (XERCESC-2212) AbstractDOMParser::parse potentially throws undocumented OutOfMemoryException

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2212?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor reassigned XERCESC-2212:
-

Assignee: Scott Cantor

> AbstractDOMParser::parse potentially throws undocumented OutOfMemoryException
> -
>
> Key: XERCESC-2212
> URL: https://issues.apache.org/jira/browse/XERCESC-2212
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: DOM
>Affects Versions: 3.2.2, 3.2.3
>Reporter: Tamir Yehuda
>Assignee: Scott Cantor
>Priority: Minor
> Fix For: 3.2.4
>
>
> the code shows that 
> {code:java}
> try
> {
> // ...
> }
> catch(const OutOfMemoryException&)
> {
> resetInProgress.release();
>     throw;
> }
> {code}
> and the OutOfMemoryException could be thrown. However this is not shown in 
> the documentation



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2214) Wrong delete[] in MemBufInputSource dtor

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2214?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2214.
---
Fix Version/s: 4.0.0
   Resolution: Fixed

Added a note to the docs for both branches.

> Wrong delete[] in MemBufInputSource dtor
> 
>
> Key: XERCESC-2214
> URL: https://issues.apache.org/jira/browse/XERCESC-2214
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Miscellaneous
>Affects Versions: 3.2.3
>Reporter: Tobias Elbrandt
>Assignee: Scott Cantor
>Priority: Minor
> Fix For: 4.0.0, 3.2.4
>
>
> Our address sanatizer found a mismatching delete[] for memory allocated via 
> {{new}} (not {{new[]}}) in the destructor of 
> {color:#00}MemBufInputSource{color}.
> I looked at the code to find places where {{new[]}} is used which would make 
> it necessary to use {{delete[]}} instead of {{delete}} - without success. It 
> seems to me that using {{delete[]}} is simply wrong here.
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2214) Wrong delete[] in MemBufInputSource dtor

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2214?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2214.
-

> Wrong delete[] in MemBufInputSource dtor
> 
>
> Key: XERCESC-2214
> URL: https://issues.apache.org/jira/browse/XERCESC-2214
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Miscellaneous
>Affects Versions: 3.2.3
>Reporter: Tobias Elbrandt
>Assignee: Scott Cantor
>Priority: Minor
> Fix For: 4.0.0, 3.2.4
>
>
> Our address sanatizer found a mismatching delete[] for memory allocated via 
> {{new}} (not {{new[]}}) in the destructor of 
> {color:#00}MemBufInputSource{color}.
> I looked at the code to find places where {{new[]}} is used which would make 
> it necessary to use {{delete[]}} instead of {{delete}} - without success. It 
> seems to me that using {{delete[]}} is simply wrong here.
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2214) Wrong delete[] in MemBufInputSource dtor

2022-10-05 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2214?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17613216#comment-17613216
 ] 

Scott Cantor commented on XERCESC-2214:
---

Actually I think it's underdocumented, not so much wrong.

My review suggests that nothing is calling this with the adopt flag set to 
true, so in fact nothing is running that code. But I suspect the underlying 
thought was that if it were somebody doing that, it's a memory buffer and would 
be allocated as an array. Of course that's an arbitrary assumption given no 
flag to signal that.

I'm inclined to add a note to the API documentation comments about it and leave 
the code as is.

> Wrong delete[] in MemBufInputSource dtor
> 
>
> Key: XERCESC-2214
> URL: https://issues.apache.org/jira/browse/XERCESC-2214
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Miscellaneous
>Affects Versions: 3.2.3
>Reporter: Tobias Elbrandt
>Assignee: Scott Cantor
>Priority: Minor
> Fix For: 3.2.4
>
>
> Our address sanatizer found a mismatching delete[] for memory allocated via 
> {{new}} (not {{new[]}}) in the destructor of 
> {color:#00}MemBufInputSource{color}.
> I looked at the code to find places where {{new[]}} is used which would make 
> it necessary to use {{delete[]}} instead of {{delete}} - without success. It 
> seems to me that using {{delete[]}} is simply wrong here.
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2241) Integer overflows in DFAContentModel class

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2241?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2241:
--
Fix Version/s: 4.0.0

> Integer overflows in DFAContentModel class
> --
>
> Key: XERCESC-2241
> URL: https://issues.apache.org/jira/browse/XERCESC-2241
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Validating Parser (XML Schema)
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> On .xsd files like the following ones (generated by ossfuzz, so broken), 
> integer overflows can happen in DFAContentModel::countLeafNodes() and 
> DFAContentModel::buildDFA() which can later cause out-of-bounds access.
> Found in [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=52025]
>  
> ```
> http://www.w3.org/2001/XMLSchema;
>            xmlns:myns="http://myns;
>            targetNamespace="http://myns;
>            elementFormDefault="qualified" attributeFormDefault="unqualified">
> 
>   
>      
>         
>       
>   
> 
> 
>   
>       
>       
>         
>             
>  ame="x" type="xs:int" maxOccurs="1"/>
>             
>         
>       
>   
> 
> 
> ```



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2242) Non-default curl location breaks autoconf link detection

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2242?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2242.
-

> Non-default curl location breaks autoconf link detection
> 
>
> Key: XERCESC-2242
> URL: https://issues.apache.org/jira/browse/XERCESC-2242
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.3
>Reporter: Scott Cantor
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 3.2.4
>
>




--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2236) Dependencies aren't loaded when using provided CMake config package

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2236?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2236.
---
Resolution: Fixed

Thanks, applied to branch as well.

> Dependencies aren't loaded when using provided CMake config package
> ---
>
> Key: XERCESC-2236
> URL: https://issues.apache.org/jira/browse/XERCESC-2236
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.3
> Environment: Ubuntu 18.04, CMake 3.22.2
>Reporter: Fred Hornsey
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 3.2.4
>
> Attachments: xercesc-2236-fix.patch
>
>
> We have a CMake config package for our libraries that tries to load Xerces 
> support like so:
> {code:java}
> find_package(XercesC PATHS "${OPENDDS_XERCES3}" NO_DEFAULT_PATH)
> if (NOT XercesC_FOUND)
>   find_package(XercesC)
> endif(){code}
> Where {{OPENDDS_XERCES3}} is the path to the Xerces our libraries were built 
> with. This works on Windows and Linux when using system-provided package. 
> When building and installing from source on Linux it seem this doesn't work. 
> In this case it's trying to use the CMake package provided by Xerces instead 
> of the one builtin to CMake.
> I've created an example to demonstrate this. Xerces is built and installed to 
> a location on Linux using CMake. Then we create a {{{}CMakeLists.txt{}}}:
> {code:java}
> cmake_minimum_required(VERSION 3.12.0)
> project(xerces_cmake_config_pkg_test)
> find_package(XercesC PATHS "${THE_XERCES_ROOT}" NO_DEFAULT_PATH)
> add_executable(testexe test.cpp)
> target_link_libraries(testexe XercesC::XercesC)
> {code}
> {{test.cpp}} has to be created, but it doesn't matter what it contains 
> because CMake doesn't get far enough to allow us to attempt to build. When 
> configuring, setting {{THE_XERCES_ROOT}} to the installed Xerces, CMake gives 
> these errors:
> {code:java}
> CMake Error at CMakeLists.txt:10 (add_executable):
>   Target "testexe" links to target "ICU::uc" but the target was not found.
>   Perhaps a find_package() call is missing for an IMPORTED target, or an
>   ALIAS target is missing?
> CMake Error at CMakeLists.txt:10 (add_executable):
>   Target "testexe" links to target "ICU::data" but the target was not found.
>   Perhaps a find_package() call is missing for an IMPORTED target, or an
>   ALIAS target is missing?
> CMake Error at CMakeLists.txt:10 (add_executable):
>   Target "testexe" links to target "Threads::Threads" but the target was not
>   found.  Perhaps a find_package() call is missing for an IMPORTED target, or 
> an ALIAS target is missing? {code}
>  
> This seems to be caused by the packages being specified by Xerces during its 
> configure ([like 
> ICU|https://github.com/apache/xerces-c/blob/045bdf8ac7755e1ce2735d5ef3f6741ec4718df9/src/CMakeLists.txt#L1113])
>  being referenced in the Config package, but not being loaded for the using 
> {{find_package}} or equivalent. [CMake 
> documenation|https://cmake.org/cmake/help/latest/manual/cmake-packages.7.html#creating-a-package-configuration-file]
>  suggests that this should be done in somewhere in the [config 
> file|https://github.com/apache/xerces-c/blob/master/src/xercesc/util/XercesVersion.hpp.in].
>  
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2236) Dependencies aren't loaded when using provided CMake config package

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2236?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2236.
-

> Dependencies aren't loaded when using provided CMake config package
> ---
>
> Key: XERCESC-2236
> URL: https://issues.apache.org/jira/browse/XERCESC-2236
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.3
> Environment: Ubuntu 18.04, CMake 3.22.2
>Reporter: Fred Hornsey
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 3.2.4
>
> Attachments: xercesc-2236-fix.patch
>
>
> We have a CMake config package for our libraries that tries to load Xerces 
> support like so:
> {code:java}
> find_package(XercesC PATHS "${OPENDDS_XERCES3}" NO_DEFAULT_PATH)
> if (NOT XercesC_FOUND)
>   find_package(XercesC)
> endif(){code}
> Where {{OPENDDS_XERCES3}} is the path to the Xerces our libraries were built 
> with. This works on Windows and Linux when using system-provided package. 
> When building and installing from source on Linux it seem this doesn't work. 
> In this case it's trying to use the CMake package provided by Xerces instead 
> of the one builtin to CMake.
> I've created an example to demonstrate this. Xerces is built and installed to 
> a location on Linux using CMake. Then we create a {{{}CMakeLists.txt{}}}:
> {code:java}
> cmake_minimum_required(VERSION 3.12.0)
> project(xerces_cmake_config_pkg_test)
> find_package(XercesC PATHS "${THE_XERCES_ROOT}" NO_DEFAULT_PATH)
> add_executable(testexe test.cpp)
> target_link_libraries(testexe XercesC::XercesC)
> {code}
> {{test.cpp}} has to be created, but it doesn't matter what it contains 
> because CMake doesn't get far enough to allow us to attempt to build. When 
> configuring, setting {{THE_XERCES_ROOT}} to the installed Xerces, CMake gives 
> these errors:
> {code:java}
> CMake Error at CMakeLists.txt:10 (add_executable):
>   Target "testexe" links to target "ICU::uc" but the target was not found.
>   Perhaps a find_package() call is missing for an IMPORTED target, or an
>   ALIAS target is missing?
> CMake Error at CMakeLists.txt:10 (add_executable):
>   Target "testexe" links to target "ICU::data" but the target was not found.
>   Perhaps a find_package() call is missing for an IMPORTED target, or an
>   ALIAS target is missing?
> CMake Error at CMakeLists.txt:10 (add_executable):
>   Target "testexe" links to target "Threads::Threads" but the target was not
>   found.  Perhaps a find_package() call is missing for an IMPORTED target, or 
> an ALIAS target is missing? {code}
>  
> This seems to be caused by the packages being specified by Xerces during its 
> configure ([like 
> ICU|https://github.com/apache/xerces-c/blob/045bdf8ac7755e1ce2735d5ef3f6741ec4718df9/src/CMakeLists.txt#L1113])
>  being referenced in the Config package, but not being loaded for the using 
> {{find_package}} or equivalent. [CMake 
> documenation|https://cmake.org/cmake/help/latest/manual/cmake-packages.7.html#creating-a-package-configuration-file]
>  suggests that this should be done in somewhere in the [config 
> file|https://github.com/apache/xerces-c/blob/master/src/xercesc/util/XercesVersion.hpp.in].
>  
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Assigned] (XERCESC-2236) Dependencies aren't loaded when using provided CMake config package

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2236?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor reassigned XERCESC-2236:
-

Assignee: Scott Cantor  (was: Roger Leigh)

> Dependencies aren't loaded when using provided CMake config package
> ---
>
> Key: XERCESC-2236
> URL: https://issues.apache.org/jira/browse/XERCESC-2236
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.3
> Environment: Ubuntu 18.04, CMake 3.22.2
>Reporter: Fred Hornsey
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 3.2.4
>
> Attachments: xercesc-2236-fix.patch
>
>
> We have a CMake config package for our libraries that tries to load Xerces 
> support like so:
> {code:java}
> find_package(XercesC PATHS "${OPENDDS_XERCES3}" NO_DEFAULT_PATH)
> if (NOT XercesC_FOUND)
>   find_package(XercesC)
> endif(){code}
> Where {{OPENDDS_XERCES3}} is the path to the Xerces our libraries were built 
> with. This works on Windows and Linux when using system-provided package. 
> When building and installing from source on Linux it seem this doesn't work. 
> In this case it's trying to use the CMake package provided by Xerces instead 
> of the one builtin to CMake.
> I've created an example to demonstrate this. Xerces is built and installed to 
> a location on Linux using CMake. Then we create a {{{}CMakeLists.txt{}}}:
> {code:java}
> cmake_minimum_required(VERSION 3.12.0)
> project(xerces_cmake_config_pkg_test)
> find_package(XercesC PATHS "${THE_XERCES_ROOT}" NO_DEFAULT_PATH)
> add_executable(testexe test.cpp)
> target_link_libraries(testexe XercesC::XercesC)
> {code}
> {{test.cpp}} has to be created, but it doesn't matter what it contains 
> because CMake doesn't get far enough to allow us to attempt to build. When 
> configuring, setting {{THE_XERCES_ROOT}} to the installed Xerces, CMake gives 
> these errors:
> {code:java}
> CMake Error at CMakeLists.txt:10 (add_executable):
>   Target "testexe" links to target "ICU::uc" but the target was not found.
>   Perhaps a find_package() call is missing for an IMPORTED target, or an
>   ALIAS target is missing?
> CMake Error at CMakeLists.txt:10 (add_executable):
>   Target "testexe" links to target "ICU::data" but the target was not found.
>   Perhaps a find_package() call is missing for an IMPORTED target, or an
>   ALIAS target is missing?
> CMake Error at CMakeLists.txt:10 (add_executable):
>   Target "testexe" links to target "Threads::Threads" but the target was not
>   found.  Perhaps a find_package() call is missing for an IMPORTED target, or 
> an ALIAS target is missing? {code}
>  
> This seems to be caused by the packages being specified by Xerces during its 
> configure ([like 
> ICU|https://github.com/apache/xerces-c/blob/045bdf8ac7755e1ce2735d5ef3f6741ec4718df9/src/CMakeLists.txt#L1113])
>  being referenced in the Config package, but not being loaded for the using 
> {{find_package}} or equivalent. [CMake 
> documenation|https://cmake.org/cmake/help/latest/manual/cmake-packages.7.html#creating-a-package-configuration-file]
>  suggests that this should be done in somewhere in the [config 
> file|https://github.com/apache/xerces-c/blob/master/src/xercesc/util/XercesVersion.hpp.in].
>  
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2236) Dependencies aren't loaded when using provided CMake config package

2022-10-05 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2236?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17613121#comment-17613121
 ] 

Scott Cantor commented on XERCESC-2236:
---

I don't use CMake so I would not be comfortable applying this, but will leave 
for possible review if it's done in time for a 3.2.4.

> Dependencies aren't loaded when using provided CMake config package
> ---
>
> Key: XERCESC-2236
> URL: https://issues.apache.org/jira/browse/XERCESC-2236
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.3
> Environment: Ubuntu 18.04, CMake 3.22.2
>Reporter: Fred Hornsey
>Assignee: Roger Leigh
>Priority: Major
> Fix For: 3.2.4
>
> Attachments: xercesc-2236-fix.patch
>
>
> We have a CMake config package for our libraries that tries to load Xerces 
> support like so:
> {code:java}
> find_package(XercesC PATHS "${OPENDDS_XERCES3}" NO_DEFAULT_PATH)
> if (NOT XercesC_FOUND)
>   find_package(XercesC)
> endif(){code}
> Where {{OPENDDS_XERCES3}} is the path to the Xerces our libraries were built 
> with. This works on Windows and Linux when using system-provided package. 
> When building and installing from source on Linux it seem this doesn't work. 
> In this case it's trying to use the CMake package provided by Xerces instead 
> of the one builtin to CMake.
> I've created an example to demonstrate this. Xerces is built and installed to 
> a location on Linux using CMake. Then we create a {{{}CMakeLists.txt{}}}:
> {code:java}
> cmake_minimum_required(VERSION 3.12.0)
> project(xerces_cmake_config_pkg_test)
> find_package(XercesC PATHS "${THE_XERCES_ROOT}" NO_DEFAULT_PATH)
> add_executable(testexe test.cpp)
> target_link_libraries(testexe XercesC::XercesC)
> {code}
> {{test.cpp}} has to be created, but it doesn't matter what it contains 
> because CMake doesn't get far enough to allow us to attempt to build. When 
> configuring, setting {{THE_XERCES_ROOT}} to the installed Xerces, CMake gives 
> these errors:
> {code:java}
> CMake Error at CMakeLists.txt:10 (add_executable):
>   Target "testexe" links to target "ICU::uc" but the target was not found.
>   Perhaps a find_package() call is missing for an IMPORTED target, or an
>   ALIAS target is missing?
> CMake Error at CMakeLists.txt:10 (add_executable):
>   Target "testexe" links to target "ICU::data" but the target was not found.
>   Perhaps a find_package() call is missing for an IMPORTED target, or an
>   ALIAS target is missing?
> CMake Error at CMakeLists.txt:10 (add_executable):
>   Target "testexe" links to target "Threads::Threads" but the target was not
>   found.  Perhaps a find_package() call is missing for an IMPORTED target, or 
> an ALIAS target is missing? {code}
>  
> This seems to be caused by the packages being specified by Xerces during its 
> configure ([like 
> ICU|https://github.com/apache/xerces-c/blob/045bdf8ac7755e1ce2735d5ef3f6741ec4718df9/src/CMakeLists.txt#L1113])
>  being referenced in the Config package, but not being loaded for the using 
> {{find_package}} or equivalent. [CMake 
> documenation|https://cmake.org/cmake/help/latest/manual/cmake-packages.7.html#creating-a-package-configuration-file]
>  suggests that this should be done in somewhere in the [config 
> file|https://github.com/apache/xerces-c/blob/master/src/xercesc/util/XercesVersion.hpp.in].
>  
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Assigned] (XERCESC-2236) Dependencies aren't loaded when using provided CMake config package

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2236?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor reassigned XERCESC-2236:
-

Assignee: Roger Leigh  (was: Scott Cantor)

> Dependencies aren't loaded when using provided CMake config package
> ---
>
> Key: XERCESC-2236
> URL: https://issues.apache.org/jira/browse/XERCESC-2236
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.3
> Environment: Ubuntu 18.04, CMake 3.22.2
>Reporter: Fred Hornsey
>Assignee: Roger Leigh
>Priority: Major
> Fix For: 3.2.4
>
> Attachments: xercesc-2236-fix.patch
>
>
> We have a CMake config package for our libraries that tries to load Xerces 
> support like so:
> {code:java}
> find_package(XercesC PATHS "${OPENDDS_XERCES3}" NO_DEFAULT_PATH)
> if (NOT XercesC_FOUND)
>   find_package(XercesC)
> endif(){code}
> Where {{OPENDDS_XERCES3}} is the path to the Xerces our libraries were built 
> with. This works on Windows and Linux when using system-provided package. 
> When building and installing from source on Linux it seem this doesn't work. 
> In this case it's trying to use the CMake package provided by Xerces instead 
> of the one builtin to CMake.
> I've created an example to demonstrate this. Xerces is built and installed to 
> a location on Linux using CMake. Then we create a {{{}CMakeLists.txt{}}}:
> {code:java}
> cmake_minimum_required(VERSION 3.12.0)
> project(xerces_cmake_config_pkg_test)
> find_package(XercesC PATHS "${THE_XERCES_ROOT}" NO_DEFAULT_PATH)
> add_executable(testexe test.cpp)
> target_link_libraries(testexe XercesC::XercesC)
> {code}
> {{test.cpp}} has to be created, but it doesn't matter what it contains 
> because CMake doesn't get far enough to allow us to attempt to build. When 
> configuring, setting {{THE_XERCES_ROOT}} to the installed Xerces, CMake gives 
> these errors:
> {code:java}
> CMake Error at CMakeLists.txt:10 (add_executable):
>   Target "testexe" links to target "ICU::uc" but the target was not found.
>   Perhaps a find_package() call is missing for an IMPORTED target, or an
>   ALIAS target is missing?
> CMake Error at CMakeLists.txt:10 (add_executable):
>   Target "testexe" links to target "ICU::data" but the target was not found.
>   Perhaps a find_package() call is missing for an IMPORTED target, or an
>   ALIAS target is missing?
> CMake Error at CMakeLists.txt:10 (add_executable):
>   Target "testexe" links to target "Threads::Threads" but the target was not
>   found.  Perhaps a find_package() call is missing for an IMPORTED target, or 
> an ALIAS target is missing? {code}
>  
> This seems to be caused by the packages being specified by Xerces during its 
> configure ([like 
> ICU|https://github.com/apache/xerces-c/blob/045bdf8ac7755e1ce2735d5ef3f6741ec4718df9/src/CMakeLists.txt#L1113])
>  being referenced in the Config package, but not being loaded for the using 
> {{find_package}} or equivalent. [CMake 
> documenation|https://cmake.org/cmake/help/latest/manual/cmake-packages.7.html#creating-a-package-configuration-file]
>  suggests that this should be done in somewhere in the [config 
> file|https://github.com/apache/xerces-c/blob/master/src/xercesc/util/XercesVersion.hpp.in].
>  
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2235) DFAContentModel::buildDFA(): correctly zero-initialize fFollowList

2022-10-05 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2235?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17613120#comment-17613120
 ] 

Scott Cantor commented on XERCESC-2235:
---

This is a fix to a patch I need to rework, so I'll pick up then.

> DFAContentModel::buildDFA(): correctly zero-initialize fFollowList
> --
>
> Key: XERCESC-2235
> URL: https://issues.apache.org/jira/browse/XERCESC-2235
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 3.2.4
>
>
> Due to a copy issue, the intended zero-initialization of
> fFollowList wasn't done (copy issue), and thus in case of
> OutOfMemory exception when initializing the array, the memory freeing in
> cleanup() could access uninitialized elements.
> Follow-up of https://github.com/apache/xerces-c/pull/40 / 
> a65990d79d3fc333d7481f010da4e165a88b6cb3
> Fixes GDAL's https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=42636



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Assigned] (XERCESC-2230) DFAContentModel::buildSyntaxTree(): fix memory leaks when OutOfMemoryException occurs

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2230?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor reassigned XERCESC-2230:
-

Assignee: Scott Cantor

> DFAContentModel::buildSyntaxTree(): fix memory leaks when 
> OutOfMemoryException occurs
> -
>
> Key: XERCESC-2230
> URL: https://issues.apache.org/jira/browse/XERCESC-2230
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> Fixes GDAL's [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=40866]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2230) DFAContentModel::buildSyntaxTree(): fix memory leaks when OutOfMemoryException occurs

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2230?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2230.
-

> DFAContentModel::buildSyntaxTree(): fix memory leaks when 
> OutOfMemoryException occurs
> -
>
> Key: XERCESC-2230
> URL: https://issues.apache.org/jira/browse/XERCESC-2230
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> Fixes GDAL's [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=40866]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2230) DFAContentModel::buildSyntaxTree(): fix memory leaks when OutOfMemoryException occurs

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2230?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2230:
--
Fix Version/s: 4.0.0

> DFAContentModel::buildSyntaxTree(): fix memory leaks when 
> OutOfMemoryException occurs
> -
>
> Key: XERCESC-2230
> URL: https://issues.apache.org/jira/browse/XERCESC-2230
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> Fixes GDAL's [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=40866]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2230) DFAContentModel::buildSyntaxTree(): fix memory leaks when OutOfMemoryException occurs

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2230?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2230.
---
Resolution: Fixed

Applied to both branches.

> DFAContentModel::buildSyntaxTree(): fix memory leaks when 
> OutOfMemoryException occurs
> -
>
> Key: XERCESC-2230
> URL: https://issues.apache.org/jira/browse/XERCESC-2230
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> Fixes GDAL's [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=40866]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2229) IGXMLScanner::scanDocTypeDecl(): fix memory leak on exception

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2229?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2229.
---
Resolution: Fixed

Applied to both branches.

> IGXMLScanner::scanDocTypeDecl(): fix memory leak on exception
> -
>
> Key: XERCESC-2229
> URL: https://issues.apache.org/jira/browse/XERCESC-2229
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> The method can leak pubId and sysId when subsequent call to
> fReaderMgr.skipPastSpaces() throws an exception (e.g. a
> TranscodingException)



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2229) IGXMLScanner::scanDocTypeDecl(): fix memory leak on exception

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2229?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2229:
--
Fix Version/s: 4.0.0

> IGXMLScanner::scanDocTypeDecl(): fix memory leak on exception
> -
>
> Key: XERCESC-2229
> URL: https://issues.apache.org/jira/browse/XERCESC-2229
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> The method can leak pubId and sysId when subsequent call to
> fReaderMgr.skipPastSpaces() throws an exception (e.g. a
> TranscodingException)



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2229) IGXMLScanner::scanDocTypeDecl(): fix memory leak on exception

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2229?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2229.
-

> IGXMLScanner::scanDocTypeDecl(): fix memory leak on exception
> -
>
> Key: XERCESC-2229
> URL: https://issues.apache.org/jira/browse/XERCESC-2229
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> The method can leak pubId and sysId when subsequent call to
> fReaderMgr.skipPastSpaces() throws an exception (e.g. a
> TranscodingException)



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2228) DFAContentModel: fix memory leaks when OutOfMemoryException occurs

2022-10-05 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2228?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17613114#comment-17613114
 ] 

Scott Cantor commented on XERCESC-2228:
---

Patch will need adjusting to avoid header change. The inlined method in the 
other header probably should be moved out, but the change itself is safe, 
albeit not sufficient to actually correct existing linked code in many cases.

> DFAContentModel: fix memory leaks when OutOfMemoryException occurs
> --
>
> Key: XERCESC-2228
> URL: https://issues.apache.org/jira/browse/XERCESC-2228
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 3.2.4
>
>
> Fixes GDAL's [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=39159]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2227) Memleak fixes in ContentSpecNode and ComplexTypeInfo classes

2022-10-05 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2227?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17613113#comment-17613113
 ] 

Scott Cantor commented on XERCESC-2227:
---

Patch will need adjusting for 3.2 branch to avoid method addition.

> Memleak fixes in ContentSpecNode and ComplexTypeInfo classes
> 
>
> Key: XERCESC-2227
> URL: https://issues.apache.org/jira/browse/XERCESC-2227
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 3.2.4
>
>
> when a OutOfMemory exception occurs.
> Spotted by [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=39127] (on 
> GDAL)
> The commits are a bit in increasing order of triviality. The ownership rules 
> of ContentSpecNode first and second members, as used by ComplexTypeInfo, are 
> super complex. shared_ptr would be much welcome here! I can just tell that 
> valgrind on my test case reports no double-free nor memory leak after those 
> fixes



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2227) Memleak fixes in ContentSpecNode and ComplexTypeInfo classes

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2227?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2227:
--
Fix Version/s: 4.0.0

> Memleak fixes in ContentSpecNode and ComplexTypeInfo classes
> 
>
> Key: XERCESC-2227
> URL: https://issues.apache.org/jira/browse/XERCESC-2227
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> when a OutOfMemory exception occurs.
> Spotted by [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=39127] (on 
> GDAL)
> The commits are a bit in increasing order of triviality. The ownership rules 
> of ContentSpecNode first and second members, as used by ComplexTypeInfo, are 
> super complex. shared_ptr would be much welcome here! I can just tell that 
> valgrind on my test case reports no double-free nor memory leak after those 
> fixes



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2226) Increment minimum CMake version to 3.12

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2226?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2226.
---
Resolution: Done

Applied to both branches.

> Increment minimum CMake version to 3.12
> ---
>
> Key: XERCESC-2226
> URL: https://issues.apache.org/jira/browse/XERCESC-2226
> Project: Xerces-C++
>  Issue Type: Improvement
>  Components: Build
>Reporter: Roger Leigh
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> Followup for XERCESC-2225



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2226) Increment minimum CMake version to 3.12

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2226?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2226.
-

> Increment minimum CMake version to 3.12
> ---
>
> Key: XERCESC-2226
> URL: https://issues.apache.org/jira/browse/XERCESC-2226
> Project: Xerces-C++
>  Issue Type: Improvement
>  Components: Build
>Reporter: Roger Leigh
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> Followup for XERCESC-2225



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2226) Increment minimum CMake version to 3.12

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2226?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2226:
--
Fix Version/s: 4.0.0

> Increment minimum CMake version to 3.12
> ---
>
> Key: XERCESC-2226
> URL: https://issues.apache.org/jira/browse/XERCESC-2226
> Project: Xerces-C++
>  Issue Type: Improvement
>  Components: Build
>Reporter: Roger Leigh
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> Followup for XERCESC-2225



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2225) Link to installed CMake targets of CURL

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2225?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2225:
--
Fix Version/s: 4.0.0

> Link to installed CMake targets of CURL
> ---
>
> Key: XERCESC-2225
> URL: https://issues.apache.org/jira/browse/XERCESC-2225
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.3
>Reporter: Roger Leigh
>Assignee: Roger Leigh
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> Match ICU behaviour.
> https://github.com/apache/xerces-c/pull/34



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2225) Link to installed CMake targets of CURL

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2225?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2225.
-

> Link to installed CMake targets of CURL
> ---
>
> Key: XERCESC-2225
> URL: https://issues.apache.org/jira/browse/XERCESC-2225
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.3
>Reporter: Roger Leigh
>Assignee: Roger Leigh
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> Match ICU behaviour.
> https://github.com/apache/xerces-c/pull/34



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2225) Link to installed CMake targets of CURL

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2225?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2225.
---
Resolution: Done

Applied to both branches.

> Link to installed CMake targets of CURL
> ---
>
> Key: XERCESC-2225
> URL: https://issues.apache.org/jira/browse/XERCESC-2225
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Build
>Affects Versions: 3.2.3
>Reporter: Roger Leigh
>Assignee: Roger Leigh
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> Match ICU behaviour.
> https://github.com/apache/xerces-c/pull/34



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2224) DFAContentModel::checkUniqueParticleAttribution (): speed enhancement

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2224?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2224.
-

> DFAContentModel::checkUniqueParticleAttribution (): speed enhancement
> -
>
> Key: XERCESC-2224
> URL: https://issues.apache.org/jira/browse/XERCESC-2224
> Project: Xerces-C++
>  Issue Type: Improvement
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> The complexity of this method is roughly O(n^3). Fuzzers can generate
> schemas with n = several thousands. The test fTransTable[i][j] == 
> XMLContentModel::gInvalidTrans
> is independant of the k loop, and can thus being moved at a upper level
> to improve runtime.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2224) DFAContentModel::checkUniqueParticleAttribution (): speed enhancement

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2224?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2224.
---
Resolution: Fixed

Applied to both branches.

> DFAContentModel::checkUniqueParticleAttribution (): speed enhancement
> -
>
> Key: XERCESC-2224
> URL: https://issues.apache.org/jira/browse/XERCESC-2224
> Project: Xerces-C++
>  Issue Type: Improvement
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> The complexity of this method is roughly O(n^3). Fuzzers can generate
> schemas with n = several thousands. The test fTransTable[i][j] == 
> XMLContentModel::gInvalidTrans
> is independant of the k loop, and can thus being moved at a upper level
> to improve runtime.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2224) DFAContentModel::checkUniqueParticleAttribution (): speed enhancement

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2224?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2224:
--
Fix Version/s: 4.0.0

> DFAContentModel::checkUniqueParticleAttribution (): speed enhancement
> -
>
> Key: XERCESC-2224
> URL: https://issues.apache.org/jira/browse/XERCESC-2224
> Project: Xerces-C++
>  Issue Type: Improvement
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> The complexity of this method is roughly O(n^3). Fuzzers can generate
> schemas with n = several thousands. The test fTransTable[i][j] == 
> XMLContentModel::gInvalidTrans
> is independant of the k loop, and can thus being moved at a upper level
> to improve runtime.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2223) SAX2XMLReaderImpl::error(): potential memory leak

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2223?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2223.
-

> SAX2XMLReaderImpl::error(): potential memory leak
> -
>
> Key: XERCESC-2223
> URL: https://issues.apache.org/jira/browse/XERCESC-2223
> Project: Xerces-C++
>  Issue Type: Bug
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> SAX2XMLReaderImpl::error() uses the regular memory manager to create the 
> SAXParseException. It might fail to fully initialize the object, and 
> potentially throw an exception when building it, causing it to leak a bit.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2223) SAX2XMLReaderImpl::error(): potential memory leak

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2223?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-2223.
---
Resolution: Fixed

Applied to both branches.

> SAX2XMLReaderImpl::error(): potential memory leak
> -
>
> Key: XERCESC-2223
> URL: https://issues.apache.org/jira/browse/XERCESC-2223
> Project: Xerces-C++
>  Issue Type: Bug
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> SAX2XMLReaderImpl::error() uses the regular memory manager to create the 
> SAXParseException. It might fail to fully initialize the object, and 
> potentially throw an exception when building it, causing it to leak a bit.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2223) SAX2XMLReaderImpl::error(): potential memory leak

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2223?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-2223:
--
Fix Version/s: 4.0.0

> SAX2XMLReaderImpl::error(): potential memory leak
> -
>
> Key: XERCESC-2223
> URL: https://issues.apache.org/jira/browse/XERCESC-2223
> Project: Xerces-C++
>  Issue Type: Bug
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> SAX2XMLReaderImpl::error() uses the regular memory manager to create the 
> SAXParseException. It might fail to fully initialize the object, and 
> potentially throw an exception when building it, causing it to leak a bit.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2222) DFAContentModel::checkUniqueParticleAttribution(): fix memory leak

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-.
-

> DFAContentModel::checkUniqueParticleAttribution(): fix memory leak
> --
>
> Key: XERCESC-
> URL: https://issues.apache.org/jira/browse/XERCESC-
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Validating Parser (XML Schema)
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> If a memory allocation of conflictTable[] fails, or later in the
>  function, the array is not freed.
>  Fixes [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=38533]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Resolved] (XERCESC-2222) DFAContentModel::checkUniqueParticleAttribution(): fix memory leak

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor resolved XERCESC-.
---
Resolution: Fixed

I applied this back to the 3.2 branch so it's applied to both.

> DFAContentModel::checkUniqueParticleAttribution(): fix memory leak
> --
>
> Key: XERCESC-
> URL: https://issues.apache.org/jira/browse/XERCESC-
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Validating Parser (XML Schema)
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> If a memory allocation of conflictTable[] fails, or later in the
>  function, the array is not freed.
>  Fixes [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=38533]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Updated] (XERCESC-2222) DFAContentModel::checkUniqueParticleAttribution(): fix memory leak

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor updated XERCESC-:
--
Fix Version/s: 4.0.0

> DFAContentModel::checkUniqueParticleAttribution(): fix memory leak
> --
>
> Key: XERCESC-
> URL: https://issues.apache.org/jira/browse/XERCESC-
> Project: Xerces-C++
>  Issue Type: Bug
>  Components: Validating Parser (XML Schema)
>Reporter: Even Rouault
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> If a memory allocation of conflictTable[] fails, or later in the
>  function, the array is not freed.
>  Fixes [https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=38533]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2219) XMLReader constructor: memory leak when refreshRawBuffer() throws

2022-10-05 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2219?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17613095#comment-17613095
 ] 

Scott Cantor commented on XERCESC-2219:
---

Another ABI change, this will have to be reverted and attacked a different way. 
Using internal static functions for cleanup in the interim releases is usually 
the best workaround for this kind of thing.

> XMLReader constructor: memory leak when refreshRawBuffer() throws
> -
>
> Key: XERCESC-2219
> URL: https://issues.apache.org/jira/browse/XERCESC-2219
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Roger Leigh
>Assignee: Roger Leigh
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> See https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=37529 on GDAL
> The backtrace of the exception that caused the memory leak was:
> {noformat}
> Catchpoint 1 (exception thrown), 0x75547672 in __cxa_throw () from 
> /lib/x86_64-linux-gnu/libstdc++.so.6
> (gdb) bt
> 0  0x75547672 in __cxa_throw () from 
> /lib/x86_64-linux-gnu/libstdc++.so.6
> 1  0x724447c4 in xercesc_4_0::PosixFileMgr::fileRead (this= out>, f=, byteCount=, buffer=, 
> manager=0x556df730)
>at xercesc/util/FileManagers/PosixFileMgr.cpp:160
> 2  0x724e6ec2 in xercesc_4_0::XMLReader::refreshRawBuffer 
> (this=0x557e49f8) at xercesc/internal/XMLReader.cpp:1891
> 3  0x724e70d4 in xercesc_4_0::XMLReader::XMLReader 
> (this=0x557e49f8, pubId=, sysId=0x55750920 u"/", 
> streamToAdopt=0x5574e838, from=,
>type=xercesc_4_0::XMLReader::Type_General, 
> source=xercesc_4_0::XMLReader::Source_External, throwAtEnd=false, 
> calculateSrcOfs=false, lowWaterMark=100, 
> version=xercesc_4_0::XMLReader::XMLV1_0,
>manager=0x556df730) at xercesc/internal/XMLReader.cpp:130
> 4  0x724ced75 in xercesc_4_0::ReaderMgr::createReader 
> (this=this@entry=0x557896d8, src=..., 
> refFrom=refFrom@entry=xercesc_4_0::XMLReader::RefFrom_NonLiteral,
>type=type@entry=xercesc_4_0::XMLReader::Type_General, 
> source=source@entry=xercesc_4_0::XMLReader::Source_External, 
> calcSrcOfs=false, lowWaterMark=100) at ./xercesc/sax/InputSource.hpp:314
> 5  0x724cb0af in xercesc_4_0::IGXMLScanner::scanReset 
> (this=0x55789608, src=...) at xercesc/internal/IGXMLScanner2.cpp:1286
> 6  0x724c36e9 in xercesc_4_0::IGXMLScanner::scanDocument 
> (this=0x55789608, src=...) at xercesc/internal/IGXMLScanner.cpp:198
> 7  0x7250abaf in xercesc_4_0::AbstractDOMParser::parse 
> (this=0x7fffc2d0, source=...) at xercesc/parsers/AbstractDOMParser.cpp:545
> 8  0x724cbdbe in xercesc_4_0::IGXMLScanner::resolveSchemaGrammar 
> (this=0x55792f78, loc=0x557dd694 u"/", uri=0x55737180 u"`", 
> ignoreLoadSchema=)
>at xercesc/internal/IGXMLScanner2.cpp:1895
>   0x724cce7c in xercesc_4_0::IGXMLScanner::parseSchemaLocation 
> (this=0x55792f78, schemaLocationStr=, 
> ignoreLoadSchema=false) at ./xercesc/framework/XMLBuffer.hpp:171
> 10 0x724cd182 in 
> xercesc_4_0::IGXMLScanner::scanRawAttrListforNameSpaces 
> (this=this@entry=0x55792f78, attCount=attCount@entry=9) at 
> xercesc/internal/IGXMLScanner2.cpp:1649
> 11 0x724c22cb in xercesc_4_0::IGXMLScanner::scanStartTagNS 
> (this=0x55792f78, gotData=@0x7fffc91f: true) at 
> xercesc/internal/IGXMLScanner.cpp:2213
> 12 0x724c3522 in xercesc_4_0::IGXMLScanner::scanContent 
> (this=0x55792f78) at xercesc/internal/IGXMLScanner.cpp:890
> 13 0x724c3760 in xercesc_4_0::IGXMLScanner::scanDocument 
> (this=0x55792f78, src=...) at xercesc/internal/IGXMLScanner.cpp:217
> 14 0x725158e3 in xercesc_4_0::SAX2XMLReaderImpl::parse 
> (this=0x55731828, source=...) at xercesc/parsers/SAX2XMLReaderImpl.cpp:409
> {noformat}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Assigned] (XERCESC-2219) XMLReader constructor: memory leak when refreshRawBuffer() throws

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2219?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor reassigned XERCESC-2219:
-

Assignee: Scott Cantor  (was: Roger Leigh)

> XMLReader constructor: memory leak when refreshRawBuffer() throws
> -
>
> Key: XERCESC-2219
> URL: https://issues.apache.org/jira/browse/XERCESC-2219
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Roger Leigh
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> See https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=37529 on GDAL
> The backtrace of the exception that caused the memory leak was:
> {noformat}
> Catchpoint 1 (exception thrown), 0x75547672 in __cxa_throw () from 
> /lib/x86_64-linux-gnu/libstdc++.so.6
> (gdb) bt
> 0  0x75547672 in __cxa_throw () from 
> /lib/x86_64-linux-gnu/libstdc++.so.6
> 1  0x724447c4 in xercesc_4_0::PosixFileMgr::fileRead (this= out>, f=, byteCount=, buffer=, 
> manager=0x556df730)
>at xercesc/util/FileManagers/PosixFileMgr.cpp:160
> 2  0x724e6ec2 in xercesc_4_0::XMLReader::refreshRawBuffer 
> (this=0x557e49f8) at xercesc/internal/XMLReader.cpp:1891
> 3  0x724e70d4 in xercesc_4_0::XMLReader::XMLReader 
> (this=0x557e49f8, pubId=, sysId=0x55750920 u"/", 
> streamToAdopt=0x5574e838, from=,
>type=xercesc_4_0::XMLReader::Type_General, 
> source=xercesc_4_0::XMLReader::Source_External, throwAtEnd=false, 
> calculateSrcOfs=false, lowWaterMark=100, 
> version=xercesc_4_0::XMLReader::XMLV1_0,
>manager=0x556df730) at xercesc/internal/XMLReader.cpp:130
> 4  0x724ced75 in xercesc_4_0::ReaderMgr::createReader 
> (this=this@entry=0x557896d8, src=..., 
> refFrom=refFrom@entry=xercesc_4_0::XMLReader::RefFrom_NonLiteral,
>type=type@entry=xercesc_4_0::XMLReader::Type_General, 
> source=source@entry=xercesc_4_0::XMLReader::Source_External, 
> calcSrcOfs=false, lowWaterMark=100) at ./xercesc/sax/InputSource.hpp:314
> 5  0x724cb0af in xercesc_4_0::IGXMLScanner::scanReset 
> (this=0x55789608, src=...) at xercesc/internal/IGXMLScanner2.cpp:1286
> 6  0x724c36e9 in xercesc_4_0::IGXMLScanner::scanDocument 
> (this=0x55789608, src=...) at xercesc/internal/IGXMLScanner.cpp:198
> 7  0x7250abaf in xercesc_4_0::AbstractDOMParser::parse 
> (this=0x7fffc2d0, source=...) at xercesc/parsers/AbstractDOMParser.cpp:545
> 8  0x724cbdbe in xercesc_4_0::IGXMLScanner::resolveSchemaGrammar 
> (this=0x55792f78, loc=0x557dd694 u"/", uri=0x55737180 u"`", 
> ignoreLoadSchema=)
>at xercesc/internal/IGXMLScanner2.cpp:1895
>   0x724cce7c in xercesc_4_0::IGXMLScanner::parseSchemaLocation 
> (this=0x55792f78, schemaLocationStr=, 
> ignoreLoadSchema=false) at ./xercesc/framework/XMLBuffer.hpp:171
> 10 0x724cd182 in 
> xercesc_4_0::IGXMLScanner::scanRawAttrListforNameSpaces 
> (this=this@entry=0x55792f78, attCount=attCount@entry=9) at 
> xercesc/internal/IGXMLScanner2.cpp:1649
> 11 0x724c22cb in xercesc_4_0::IGXMLScanner::scanStartTagNS 
> (this=0x55792f78, gotData=@0x7fffc91f: true) at 
> xercesc/internal/IGXMLScanner.cpp:2213
> 12 0x724c3522 in xercesc_4_0::IGXMLScanner::scanContent 
> (this=0x55792f78) at xercesc/internal/IGXMLScanner.cpp:890
> 13 0x724c3760 in xercesc_4_0::IGXMLScanner::scanDocument 
> (this=0x55792f78, src=...) at xercesc/internal/IGXMLScanner.cpp:217
> 14 0x725158e3 in xercesc_4_0::SAX2XMLReaderImpl::parse 
> (this=0x55731828, source=...) at xercesc/parsers/SAX2XMLReaderImpl.cpp:409
> {noformat}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Assigned] (XERCESC-2218) CurlURLInputStream constructor memory leak

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2218?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor reassigned XERCESC-2218:
-

Assignee: Scott Cantor  (was: Roger Leigh)

> CurlURLInputStream constructor memory leak
> --
>
> Key: XERCESC-2218
> URL: https://issues.apache.org/jira/browse/XERCESC-2218
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Roger Leigh
>Assignee: Scott Cantor
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> CurlURLInputStream constructor calls the readMore() method, which can
> throw exceptions. In that situation, the destructor is not called, which
> results in resource/memory leaks. To fix that, catch the exceptions,
> manually do the cleanup and rethrow the exceptions.
> Found by ossfuzz (locally)



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Commented] (XERCESC-2218) CurlURLInputStream constructor memory leak

2022-10-05 Thread Scott Cantor (Jira)


[ 
https://issues.apache.org/jira/browse/XERCESC-2218?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17613093#comment-17613093
 ] 

Scott Cantor commented on XERCESC-2218:
---

I reviewed this patch and it's not applicable to the 3.2 branch, you can't add 
methods to a class like this without breaking the ABI in general. I will roll 
it back and if there's time review whether it can be done a different way.

> CurlURLInputStream constructor memory leak
> --
>
> Key: XERCESC-2218
> URL: https://issues.apache.org/jira/browse/XERCESC-2218
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Roger Leigh
>Assignee: Roger Leigh
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> CurlURLInputStream constructor calls the readMore() method, which can
> throw exceptions. In that situation, the destructor is not called, which
> results in resource/memory leaks. To fix that, catch the exceptions,
> manually do the cleanup and rethrow the exceptions.
> Found by ossfuzz (locally)



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



[jira] [Closed] (XERCESC-2217) ICUTranscoder::transcodeFrom buffer overflow

2022-10-05 Thread Scott Cantor (Jira)


 [ 
https://issues.apache.org/jira/browse/XERCESC-2217?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Scott Cantor closed XERCESC-2217.
-

> ICUTranscoder::transcodeFrom buffer overflow
> 
>
> Key: XERCESC-2217
> URL: https://issues.apache.org/jira/browse/XERCESC-2217
> Project: Xerces-C++
>  Issue Type: Bug
>Affects Versions: 3.2.3
>Reporter: Roger Leigh
>Assignee: Roger Leigh
>Priority: Major
> Fix For: 4.0.0, 3.2.4
>
>
> See https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=35373
> When charsDecoded == 0, the line for (index = 0; index < charsDecoded - 1; 
> index++) will cause to read out of bounds of fSrcOffsets, due to unsigned 
> integer underflow rules.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

-
To unsubscribe, e-mail: c-dev-unsubscr...@xerces.apache.org
For additional commands, e-mail: c-dev-h...@xerces.apache.org



  1   2   3   4   5   6   7   8   9   10   >