Compartilhar via


Using WMDRM-ND from custom code (Windows CE 5.0)

Send Feedback

If you choose to write your own application, and not use the Media Query Engine and supplied sample application, you must do the following to support Windows DRM for Network Devices from your custom application.

  • create your own Unique Device Name (UDN) within the registry. The UDN must be persistent. If the UDN changes, then you cannot play protected content on this device any longer.
  • Manage State Variable Change messages. On the WMC server, the end user selects the options to allow this device to play content, or not. This triggers the State Variable Change messages. The device should implement code to handle these messages. Look to the MQE code to determine how an application calls these APIs. There is sample code within the Media Query Engine that provides the order you should make the calls and what you should do for each status returned.
  • Create a Description Document host in a folder specified in registry.
  • NMD apps must check the res@protection attribute of each audio/video file. If the attribute contains "Microsoft WM DRM", then the file is DRM protected.
  • For DRM protected files, an extra modifier "WMDRM=1" must be added to the end of the URL that is passed to the HTTP streamer. This modifier identifies the file as being DRM protected. This is the only way for the HTTP streamer to distinguish between protected and non-protected content. DRM-protected files will not play back properly on the device if the modifier is not added.
  • Your application can no longer assume that the media server will throw an error when requesting protected data. For WMC on Windows XP this is the default behavior, so your application could assume that an error code means encrypted content, and try to acquire a license for it. This behavior may change in future versions of WMC, so you should not rely on it.

See Also

Windows Media DRM for Network Devices

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.