{"action":"created","issue":{"url":"https://api.github.com/repos/tc39/proposal-temporal/issues/73","repository_url":"https://api.github.com/repos/tc39/proposal-temporal","labels_url":"https://api.github.com/repos/tc39/proposal-temporal/issues/73/labels{/name}","comments_url":"https://api.github.com/repos/tc39/proposal-temporal/issues/73/comments","events_url":"https://api.github.com/repos/tc39/proposal-temporal/issues/73/events","html_url":"https://github.com/tc39/proposal-temporal/issues/73","id":344374527,"node_id":"MDU6SXNzdWUzNDQzNzQ1Mjc=","number":73,"title":"new Instant() or Instant.now()?","user":{"login":"ljqx","id":5836327,"node_id":"MDQ6VXNlcjU4MzYzMjc=","avatar_url":"https://avatars1.githubusercontent.com/u/5836327?v=4","gravatar_id":"","url":"https://api.github.com/users/ljqx","html_url":"https://github.com/ljqx","followers_url":"https://api.github.com/users/ljqx/followers","following_url":"https://api.github.com/users/ljqx/following{/other_user}","gists_url":"https://api.github.com/users/ljqx/gists{/gist_id}","starred_url":"https://api.github.com/users/ljqx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ljqx/subscriptions","organizations_url":"https://api.github.com/users/ljqx/orgs","repos_url":"https://api.github.com/users/ljqx/repos","events_url":"https://api.github.com/users/ljqx/events{/privacy}","received_events_url":"https://api.github.com/users/ljqx/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2018-07-25T09:57:24Z","updated_at":"2018-07-27T10:33:28Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"Hi, @pipobscure , it seems [`now` family is removed](https://github.com/tc39/proposal-temporal/pull/64) without explanation. \r\n\r\nWould this proposal cover `now` in the future? \r\nOtherwise user could only fallback to `Date.now()` or `new Date()`."},"comment":{"url":"https://api.github.com/repos/tc39/proposal-temporal/issues/comments/408380385","html_url":"https://github.com/tc39/proposal-temporal/issues/73#issuecomment-408380385","issue_url":"https://api.github.com/repos/tc39/proposal-temporal/issues/73","id":408380385,"node_id":"MDEyOklzc3VlQ29tbWVudDQwODM4MDM4NQ==","user":{"login":"erights","id":273868,"node_id":"MDQ6VXNlcjI3Mzg2OA==","avatar_url":"https://avatars3.githubusercontent.com/u/273868?v=4","gravatar_id":"","url":"https://api.github.com/users/erights","html_url":"https://github.com/erights","followers_url":"https://api.github.com/users/erights/followers","following_url":"https://api.github.com/users/erights/following{/other_user}","gists_url":"https://api.github.com/users/erights/gists{/gist_id}","starred_url":"https://api.github.com/users/erights/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/erights/subscriptions","organizations_url":"https://api.github.com/users/erights/orgs","repos_url":"https://api.github.com/users/erights/repos","events_url":"https://api.github.com/users/erights/events{/privacy}","received_events_url":"https://api.github.com/users/erights/received_events","type":"User","site_admin":false},"created_at":"2018-07-27T10:33:28Z","updated_at":"2018-07-27T10:33:28Z","author_association":"NONE","body":"Hi @littledan , thanks for bringing my attention to this issue. It is indeed crucial that this proposal exclude and direct access to the current time.\r\n\r\nAn important high level invariant of JavaScript, with a small and fixed number of grandfathered exceptions(*), is \"no I/O powers or hidden mutable state among the primordials\". As a result, JavaScript that language is analogous to the user-mode instructions portion of a processor. All abilities to cause or sense effects to/from the world outside those JavaScript objects are only via host-provided objects, which are only initially obtained by looking them up in the global scope or global object, by names other than the JavaScript standard globals.\r\n\r\nAt https://youtu.be/pig-sIS8_Wc?t=1h25m , 1 hour, 25 min into my Stopping Exfiltration talk (a recorded re-presentation of the talk I gave at the May 2018 tc39 meeting), I specifically call out the unconditional safety of date arithmetic, parsers, and renderers, vs the unsafety of, for example, `Date.now`.\r\n\r\nOur ability to pleasantly secure JavaScript comes largely from the strict separation between those APIs presenting computational conveniences vs those providing access to the outside world. Thus, we must not repeat the `Date.now` mistake. Secure EcmaScript indeed censors Date.now by default, while leaving intact its abilities to represent, parse, and render dates. \r\n\r\nhttps://rawgit.com/Agoric/SES/master/demo/?dateNow=enabled is our challenge page, showing how its presence unsurprisingly enables one to read timing channels, while in its absence together with the absence of various host services that transformational libraries don't need, we can run transformational libraries in a mode that ensures they cannot sense the passage or duration of time, and so cannot read side channels built on timing channels.\r\n\r\n(*) The grandfathered exceptions are\r\n   * `Date.now()` and `Date()`, and `new Date()` providing access to the current time. SES instead has `Date.now()` return `NaN` and the others return results consistent with that. The moment library, run under SES, works fine except for those parts that directly rely on access to the current time.\r\n   * `Math.random()`. If this were a cryptographically strong pseudo-random number generator, not observably different from a source of genuine entropy, then it would not provide a global communications channel.\r\n   * Access to the current time zone. Actually, I'm unclear on this. As I carry my computer between time zones, is this supposed to dynamically update? In any case, it is hard to imagine that this provides a practical way to read side channels. Our challenge page does not censor this, so please feel free to use it to try to read the side channel provided by the challenge.\r\n\r\nAttn @jfparadis @warner @fudco @tribble "}}
{"actor":{"display_login":"erights"}}