Class LinkGrant

java.lang.Object
lol.trq.alts.vault.LinkGrant

public final class LinkGrant extends Object
The answer of an existing owner device to a LinkRequest (AVP SPEC 11.6): the owner's mnemonic entropy, wrapped to the request's ephemeral key under avp/owner-link/v1. Only the new device's LinkSession opens it.

It carries the owner key, encrypted: carry it only to the device that showed the request, and do not log or keep it. toString() shows nothing of it.

Since:
1.0.0
  • Method Details

    • parse

      public static LinkGrant parse(String text)
      Reads a link grant from pasted text. Whitespace anywhere in the text is ignored.
      Parameters:
      text - the pasted text
      Returns:
      the grant
      Throws:
      AltsException - of kind INVALID_INPUT if the text is not a version 2 link grant
      Since:
      1.0.0
    • text

      public String text()
      The token text to carry back to the new device.
      Returns:
      the text
      Since:
      1.0.0
    • toString

      public String toString()
      Names the type only; the grant carries the owner key, encrypted.
      Overrides:
      toString in class Object
      Returns:
      a description
      Since:
      1.0.0