Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SimpleXMLElement::simplexml_load_string fails on illegal char #1

Closed
Vaalyn opened this issue Nov 9, 2018 · 2 comments
Closed

SimpleXMLElement::simplexml_load_string fails on illegal char #1

Vaalyn opened this issue Nov 9, 2018 · 2 comments
Labels
bug Something isn't working

Comments

@Vaalyn
Copy link
Sponsor Member

Vaalyn commented Nov 9, 2018

As mentioned in this issue for AzuraCast it is possible that the XML response from IceCast contains an illegal character which leads to a failure to decode the response via the simplexml_load_string function.

In the issue mentioned above this illegal character gets send by a faulty streaming software to IceCast but regardless of what is sending this illegal char to IceCast since IceCast itself has no problem with the char and happily returns an XML containing it this library should be able to deal with cases like this. It could make sense to switch from using simplexml to something like sabre/xml which uses the DOM API which is much more robust than simplexml.

@BusterNeece BusterNeece added the bug Something isn't working label Jan 27, 2019
@BusterNeece
Copy link
Member

@Vaalyn sabre/xml is a cool library but it seems to be a bit much for what we're doing. I wonder if there's something halfway between the two...something that will more loosely allow traversal/parsing of XML trees but won't just flop on illegal characters.

@Vaalyn
Copy link
Sponsor Member Author

Vaalyn commented Feb 1, 2019

@SlvrEagle23 If sabre/xml is too much then maybe something like imangazaliev/didom could be more suited. It still uses the DOM to parse XML so should be as resilient as sabre/xml.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants