Readonly
closedThe closed
read-only property of the MediaKeySession interface returns a Promise signaling when a MediaKeySession closes.
Readonly
expirationThe expiration
read-only property of the MediaKeySession interface returns the time after which the keys in the current session can no longer be used to decrypt media data, or NaN if no such time exists.
Readonly
keyThe keyStatuses
read-only property of the MediaKeySession interface returns a reference to a read-only MediaKeyStatusMap of the current session's keys and their statuses.
Readonly
sessionThe sessionId
read-only property of the MediaKeySession interface contains a unique string generated by the content decryption module (CDM) for the current media object and its associated keys or licenses.
The addEventListener()
method of the EventTarget interface sets up a function that will be called whenever the specified event is delivered to the target.
Optional
options: boolean | AddEventListenerOptionsThe addEventListener()
method of the EventTarget interface sets up a function that will be called whenever the specified event is delivered to the target.
Optional
options: boolean | AddEventListenerOptionsThe close()
method of the MediaKeySession interface notifies that the current media session is no longer needed, and that the content decryption module should release any resources associated with this object and close it.
The dispatchEvent()
method of the EventTarget sends an Event to the object, (synchronously) invoking the affected event listeners in the appropriate order.
The generateRequest()
method of the MediaKeySession interface returns a Promise after generating a license request based on initialization data.
The load()
method of the MediaKeySession interface returns a Promise that resolves to a boolean value after loading data for a specified session object.
The remove()
method of the MediaKeySession interface returns a Promise after removing any session data associated with the current object.
The removeEventListener()
method of the EventTarget interface removes an event listener previously registered with EventTarget.addEventListener() from the target.
Optional
options: boolean | EventListenerOptionsThe removeEventListener()
method of the EventTarget interface removes an event listener previously registered with EventTarget.addEventListener() from the target.
Optional
options: boolean | EventListenerOptionsThe update()
method of the MediaKeySession interface loads messages and licenses to the CDM, and then returns a Promise.
The
MediaKeySession
interface of the Encrypted Media Extensions API represents a context for message exchange with a content decryption module (CDM). Available only in secure contexts.MDN Reference