bbc / pydvbcss

Python library that implements DVB protocols for companion synchronisation

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Enable CII server to match wcUrl, tsUrl, teUrl with interface client connects on

matt-hammond-001 opened this issue · comments

At the moment the tsUrl, wcUrl and teUrl reported by a CII Server are set by the application using pydvbcss and they are the same for all clients that connect.

However, if the CII Server is bound to 0.0.0.0 then clients could connect via multiple different interfaces, each with different IP addresses. For example, a client connecting to local loopback (eg. 127.0.0.1) vs a client connecting via the LAN (e.g. 192.168.1.26). To work, each ought to receive a value for wcUrl and tsUrl where the hostname/IP address matches the one they used when they connected.

Add an ability for CIIServer to transparently rewrite the wcUrl and tsUrl on a per client connection basis to match the IP address of the local interface on which the client connected.

This should be an optional extension. Existing behaviour should be preserved to maintain backward compatibility.