W3C home > Mailing lists > Public > public-html-media@w3.org > May 2015

[encrypted-media] Clarify that the value of |expiration| should be "NaN" for licenses that never expire

From: ddorwin via GitHub <sysbot+gh@w3.org>
Date: Thu, 21 May 2015 20:43:21 +0000
To: public-html-media@w3.org
Message-ID: <issues.opened-79154433-1432240998-sysbot+gh@w3.org>
ddorwin has just created a new issue for 
https://github.com/w3c/encrypted-media:

== Clarify that the value of |expiration| should be "NaN" for licenses
 that never expire ==
The definition of the `expiration` attribute currently says:
>The time, in milliseconds since 01 January, 1970 UTC, after which the
 key(s) in the session will no longer be usable to decrypt media data,
 or `NaN` if no such time exists, as determined by the CDM.

We should clarify that "no such time exists" includes licenses that 
(explicitly) never expire. Also, `Infinity` should never be used.

Note: `NaN` can be difficult to deal with in JavaScript, but I still 
think it is the best option. `Date(0)` and `Date(null)` both result in
 the Unix Epoch. `Date(undefined)` results in an invalid time like 
`Date(NaN)`, but I don't think Web IDL allows attributes to have the 
value `undefined`.

See https://github.com/w3c/encrypted-media/issues/58
Received on Thursday, 21 May 2015 20:43:22 UTC

This archive was generated by hypermail 2.3.1 : Thursday, 21 May 2015 20:43:23 UTC