diff --git a/cmd/serve/dlna/cm-service-desc.go b/cmd/serve/dlna/cm-service-desc.go
new file mode 100644
index 000000000..8147d0317
--- /dev/null
+++ b/cmd/serve/dlna/cm-service-desc.go
@@ -0,0 +1,184 @@
+package dlna
+
+const connectionManagerServiceDescription = `
+
+
+ 1
+ 0
+
+
+
+ GetProtocolInfo
+
+
+ Source
+ out
+ SourceProtocolInfo
+
+
+ Sink
+ out
+ SinkProtocolInfo
+
+
+
+
+ PrepareForConnection
+
+
+ RemoteProtocolInfo
+ in
+ A_ARG_TYPE_ProtocolInfo
+
+
+ PeerConnectionManager
+ in
+ A_ARG_TYPE_ConnectionManager
+
+
+ PeerConnectionID
+ in
+ A_ARG_TYPE_ConnectionID
+
+
+ Direction
+ in
+ A_ARG_TYPE_Direction
+
+
+ ConnectionID
+ out
+ A_ARG_TYPE_ConnectionID
+
+
+ AVTransportID
+ out
+ A_ARG_TYPE_AVTransportID
+
+
+ RcsID
+ out
+ A_ARG_TYPE_RcsID
+
+
+
+
+ ConnectionComplete
+
+
+ ConnectionID
+ in
+ A_ARG_TYPE_ConnectionID
+
+
+
+
+ GetCurrentConnectionIDs
+
+
+ ConnectionIDs
+ out
+ CurrentConnectionIDs
+
+
+
+
+ GetCurrentConnectionInfo
+
+
+ ConnectionID
+ in
+ A_ARG_TYPE_ConnectionID
+
+
+ RcsID
+ out
+ A_ARG_TYPE_RcsID
+
+
+ AVTransportID
+ out
+ A_ARG_TYPE_AVTransportID
+
+
+ ProtocolInfo
+ out
+ A_ARG_TYPE_ProtocolInfo
+
+
+ PeerConnectionManager
+ out
+ A_ARG_TYPE_ConnectionManager
+
+
+ PeerConnectionID
+ out
+ A_ARG_TYPE_ConnectionID
+
+
+ Direction
+ out
+ A_ARG_TYPE_Direction
+
+
+ Status
+ out
+ A_ARG_TYPE_ConnectionStatus
+
+
+
+
+
+
+ SourceProtocolInfo
+ string
+
+
+ SinkProtocolInfo
+ string
+
+
+ CurrentConnectionIDs
+ string
+
+
+ A_ARG_TYPE_ConnectionStatus
+ string
+
+ OK
+ ContentFormatMismatch
+ InsufficientBandwidth
+ UnreliableChannel
+ Unknown
+
+
+
+ A_ARG_TYPE_ConnectionManager
+ string
+
+
+ A_ARG_TYPE_Direction
+ string
+
+ Input
+ Output
+
+
+
+ A_ARG_TYPE_ProtocolInfo
+ string
+
+
+ A_ARG_TYPE_ConnectionID
+ i4
+
+
+ A_ARG_TYPE_AVTransportID
+ i4
+
+
+ A_ARG_TYPE_RcsID
+ i4
+
+
+`
diff --git a/cmd/serve/dlna/dlna.go b/cmd/serve/dlna/dlna.go
index b430634a4..df8dec1bd 100644
--- a/cmd/serve/dlna/dlna.go
+++ b/cmd/serve/dlna/dlna.go
@@ -84,6 +84,14 @@ var services = []*service{
},
SCPD: contentDirectoryServiceDescription,
},
+ {
+ Service: upnp.Service{
+ ServiceType: "urn:schemas-upnp-org:service:ConnectionManager:1",
+ ServiceId: "urn:upnp-org:serviceId:ConnectionManager",
+ ControlURL: serviceControlURL,
+ },
+ SCPD: connectionManagerServiceDescription,
+ },
}
func init() {
diff --git a/cmd/serve/dlna/dlna_test.go b/cmd/serve/dlna/dlna_test.go
index a2ef03445..8c5492117 100644
--- a/cmd/serve/dlna/dlna_test.go
+++ b/cmd/serve/dlna/dlna_test.go
@@ -59,6 +59,9 @@ func TestRootSCPD(t *testing.T) {
// Make sure that the SCPD contains a CDS service.
require.Contains(t, string(body),
"urn:schemas-upnp-org:service:ContentDirectory:1")
+ // Make sure that the SCPD contains a CM service.
+ require.Contains(t, string(body),
+ "urn:schemas-upnp-org:service:ConnectionManager:1")
// Ensure that the SCPD url is configured.
require.Regexp(t, "/.*", string(body))
}