Represents a session with the Digital Rights Management (DRM) key system.
var session = oMediaKeys.createSession(type, initData, cdmData);
Inheritance HierarchyThe MediaKeySession does not inherit from any class or interface.
The MediaKeySession object has these types of members:
The MediaKeySession object has these events.
Fired when there has been a change in the keys in the session or their status.
Fired when the CDM has generated a message for the session.
Deprecated. Occurs after a call to update and a key has been added.
Deprecated. Occurs when a there is an error in the key session.
Deprecated. Occurs when a key message has been generated.
The MediaKeySession object has these methods.
Closes the media key session and release any resources associated with it.
Generates a request based on the initialization data.
Loads the data stored for the specified session.
Removes stored session data.
Sends messages, including licenses, to the Content Decryption Module.
The MediaKeySession object has these properties.
Signals when a MediaKeySession object closes.
Deprecated. Gets the error state associated with the media key session.
The time after which the keys in the current session will expire and can no longer be used to decrypt media data, or NaN if no such time exists.
A reference to a read-only map of current session's key IDs and their statuses.
The identification string that identifies the media key session.
As of Microsoft Edge, the unprefixed version of MediaKeySession is supported. MSMediaKeySession is still supported in IE11. For more information on EME implementation updates in Microsoft Edge, see Encrypted Media Extensions updates.
An application can potentially have multiple sessions activate with the key system.