Make cc::SurfaceId unguessable

This CL makes surface IDs unguessable.

With this patch, surface ID consists of three components.

1. Namespace ID is a display compositor allocated 32-bit
   ID.

2. Nonce is a cryptographically secure random, unguessable
   64-bit integer generated by the client.

3. Local ID is a 32-bit sequentially increasing integer
   generated by the client.

With this CL, once a surface ID is allocated, its
components cannot be modified.

BUG=613300
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel

Review-Url: https://codereview.chromium.org/1996783002
Cr-Commit-Position: refs/heads/master@{#395926}


CrOS-Libchrome-Original-Commit: 845b871f4cfe95ebe15330a9dac32d3c69b598b9
2 files changed
tree: 8bd425615334b3870c3c023dc43e8d1935d684ac
  1. base/
  2. build/
  3. components/
  4. dbus/
  5. device/
  6. ipc/
  7. mojo/
  8. testing/
  9. third_party/
  10. ui/