GetFeatureList (Samsung TV) Response not well formed
Brought to you by:
jmaggard
As you can see in this response the closing "Features" tag is missing.
Traced with tcpdump. In upnpsoap.c this bug is obvious too.
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<s:Body>
<u:X_GetFeatureListResponse xmlns:u="urn:schemas-upnp-org:service:ContentDirectory:1">
<FeatureList><?xml version="1.0" encoding="utf-8"?>
<Features xmlns="urn:schemas-upnp-org:av:avs" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="urn:schemas-upnp-org:av:avs http://www.upnp.org/schemas/av/avs.xsd">
<Feature name="samsung.com_BASICVIEW" version="1">
<container id="1" type="object.item.audioItem"/>
<container id="2" type="object.item.videoItem"/>
<container id="3" type="object.item.imageItem"/>
</Feature>
</FeatureList>
</u:X_GetFeatureListResponse>
</s:Body>
</s:Envelope>
Have looked at this patch and unsure why but it makes my E series go into a endless loop. So for me works fine without it, but I do agree the <features> tag should be terminated correctly.</features>
I have looked into this a bit more and all seems ok if we correctly escape "</Features>".
see https://github.com/ntfreak/minidlna/commit/4c7d158d79f14d8d26f42f157691cbbc4bede13d
There's another bug here. The namespace is wrong, it shows version 1 but GetFeatureList wasn't added to the UPnP standard until ContentDirectory:2 (current standard is ContentDirectory:4)