Module TryExcept body Expr NameLoad handlers ExceptHandler type NameLoad body Assign NameStore NameLoad ImportFrom alias ImportFrom alias Import alias Import alias Import alias TryExcept body Import alias handlers ExceptHandler type NameLoad body Import alias identifier Import alias Import alias Import alias Assign NameStore ListLoad Str Assign NameStore Num Assign NameStore Str Assign NameStore Dict Str Str Str Str Str Str Str Str Str Str FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str If UnaryOpNot Call NameLoad NameLoad NameLoad body Raise Call NameLoad Str If BoolOpAnd UnaryOpNot NameLoad UnaryOpNot NameLoad body Raise Call NameLoad Str If UnaryOpNot NameLoad body Assign NameStore Dict Assign NameStore BoolOpAnd CompareIn Str NameLoad CompareEq SubscriptLoad NameLoad Index Str NameLoad Expr Call NameLoad NameLoad NameLoad Assign NameStore Call NameLoad NameLoad Assign SubscriptStore NameLoad Index Str NameLoad Assign SubscriptStore NameLoad Index Str Call NameLoad Call AttributeLoad NameLoad attr Assign SubscriptStore NameLoad Index Str NameLoad Assign NameStore Call NameLoad NameLoad NameLoad If CompareGt Call NameLoad NameLoad Num body Raise Call NameLoad Str Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body If BoolOpAnd CompareIsNot NameLoad NameLoad UnaryOpNot Call NameLoad NameLoad NameLoad body Raise Call NameLoad Str Assign NameStore BoolOpAnd CompareIsNot NameLoad NameLoad CompareIn Str NameLoad If BoolOpOr BoolOpAnd UnaryOpNot NameLoad UnaryOpNot NameLoad BoolOpAnd NameLoad UnaryOpNot Call NameLoad SubscriptLoad NameLoad Index Str NameLoad body Raise Call NameLoad Str If BoolOpAnd NameLoad CompareGt Call NameLoad SubscriptLoad NameLoad Index Str Num body Raise Call NameLoad Str decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Dict For NameStore NameLoad body If Call NameLoad SubscriptLoad NameLoad Index NameLoad AttributeLoad NameLoad attr body Assign SubscriptStore NameLoad Index NameLoad Call NameLoad Call AttributeLoad NameLoad attr Call AttributeLoad SubscriptLoad NameLoad Index NameLoad attr If CompareIn NameLoad NameLoad body Assign SubscriptStore NameLoad Index SubscriptLoad NameLoad Index NameLoad SubscriptLoad NameLoad Index NameLoad orelse Raise Call NameLoad BinOpMod Str NameLoad Return NameLoad decorator_list If CompareLt AttributeLoad NameLoad attr TupleLoad Num Num body FunctionDef arguments args NameParam defaults body Assign NameStore Call NameLoad Call NameLoad NameLoad Return Call AttributeLoad Call AttributeLoad NameLoad attr Str attr Str Str decorator_list orelse FunctionDef arguments args NameParam defaults body Assign NameStore Call NameLoad NameLoad Return Call AttributeLoad Call AttributeLoad NameLoad attr Str attr Str Str decorator_list FunctionDef arguments args NameParam defaults body Return Call NameLoad Call NameLoad Call AttributeLoad NameLoad attr NameLoad keyword TupleLoad Str Str Str decorator_list FunctionDef arguments args NameParam NameParam defaults body FunctionDef arguments args NameParam defaults body TryExcept body Return Call NameLoad NameLoad Str handlers ExceptHandler type NameLoad body Return Call NameLoad NameLoad decorator_list Return Call NameLoad Call AttributeLoad Call AttributeLoad NameLoad attr Call NameLoad NameLoad Call NameLoad NameLoad AttributeLoad NameLoad attr attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Assign NameStore Call NameLoad Dict Str Str Str Str Assign NameStore Call NameLoad NameLoad Assign NameStore BinOpMod Str TupleLoad NameLoad NameLoad NameLoad Assign NameStore Call NameLoad NameLoad NameLoad Return BinOpMod Str TupleLoad NameLoad NameLoad NameLoad decorator_list
N/A N/A N/A N/A basestring N/A N/A N/A NameError N/A N/A basestring str array array base64 urlsafe_b64encode N/A hashlib N/A hmac N/A sys N/A N/A N/A json N/A N/A N/A ImportError N/A N/A simplejson json N/A calendar N/A time N/A datetime N/A __all__ N/A create_token N/A TOKEN_VERSION 0 N/A TOKEN_SEP . N/A CLAIMS_MAP N/A expires notBefore admin debug simulate exp nbf admin debug simulate create_token N/A N/A secret data options N/A None N/A N/A 
    Generates a secure authentication token.
 
    Our token format follows the JSON Web Token (JWT) standard:
    header.claims.signature
  
    Where:
    1) "header" is a stringified, base64-encoded JSON object containing version and algorithm information.
    2) "claims" is a stringified, base64-encoded JSON object containing a set of claims:
      Library-generated claims:
      "iat" -> The issued at time in seconds since the epoch as a number
      "d" -> The arbitrary JSON object supplied by the user.
      User-supplied claims (these are all optional):
      "exp" (optional) -> The expiration time of this token, as a number of seconds since the epoch.
      "nbf" (optional) -> The "not before" time before which the token should be rejected (seconds since the epoch)
      "admin" (optional) -> If set to true, this client will bypass all security rules (use this to authenticate servers)
      "debug" (optional) -> "set to true to make this client receive debug information about security rule execution.
      "simulate" (optional, internal-only for now) -> Set to true to neuter all API operations (listens / puts
                 will run security rules but not actually write or return data).
    3) A signature that proves the validity of this token (see: http://tools.ietf.org/html/draft-ietf-jose-json-web-signature-07)
  
    For base64-encoding we use URL-safe base64 encoding. This ensures that the entire token is URL-safe
    and could, for instance, be placed as a query argument without any encoding (and this is what the JWT spec requires).
  
    Args:
        secret - the Firebase Application secret
        data - a json serializable object of data to be included in the token
        options - An optional dictionary of additional claims for the token. Possible keys include:
            a) "expires" -- A datetime or timestamp (as a number of seconds since the epoch) denoting a time after
                            which this token should no longer be valid.
            b) "notBefore" -- A datetime or timestamp (as a number of seconds since the epoch) denoting a time before
                            which this token should be rejected by the server.
            c) "admin" -- Set to true to bypass all security rules (use this for your trusted servers).
            d) "debug" -- Set to true to enable debug mode (so you can see the results of Rules API operations)
            e) "simulate" -- (internal-only for now) Set to true to neuter all API operations (listens / puts
                            will run security rules but not actually write or return data)
    Returns:
        A signed Firebase Authentication Token
    Raises:
        ValueError: if an invalid key is specified in options

     N/A N/A N/A isinstance secret basestring N/A N/A N/A ValueError firebase_token_generator.create_token: secret must be a string. N/A N/A N/A options N/A data N/A N/A N/A ValueError firebase_token_generator.create_token: data is empty and no options are set.  This token will have no effect on Firebase. N/A N/A options N/A N/A options N/A N/A is_admin_token N/A N/A admin options N/A N/A options N/A admin True N/A N/A _validate_data data is_admin_token N/A claims N/A _create_options_claims options N/A N/A claims N/A v TOKEN_VERSION N/A N/A claims N/A iat N/A int N/A N/A time time N/A N/A claims N/A d data N/A token N/A _encode_token secret claims N/A N/A N/A len token 1024 N/A N/A N/A RuntimeError firebase_token_generator.create_token: generated token is too long. N/A token N/A _validate_data N/A N/A data is_admin_token N/A N/A N/A N/A N/A data None N/A N/A isinstance data dict N/A N/A N/A ValueError firebase_token_generator.create_token: data must be a dictionary N/A contains_uid N/A N/A data None N/A uid data N/A N/A N/A N/A contains_uid N/A is_admin_token N/A contains_uid N/A N/A isinstance N/A data N/A uid basestring N/A N/A N/A ValueError firebase_token_generator.create_token: data must contain a "uid" key that must be a string. N/A N/A contains_uid N/A N/A len N/A data N/A uid 256 N/A N/A N/A ValueError firebase_token_generator.create_token: data must contain a "uid" key that must not be longer than 256 bytes. N/A _create_options_claims N/A N/A opts N/A N/A N/A claims N/A N/A k opts N/A N/A N/A isinstance N/A opts N/A k N/A datetime datetime N/A N/A N/A opts N/A k N/A int N/A N/A calendar timegm N/A N/A N/A opts N/A k utctimetuple N/A N/A k CLAIMS_MAP N/A N/A N/A claims N/A N/A CLAIMS_MAP N/A k N/A opts N/A k N/A N/A N/A ValueError N/A Unrecognized Option: %s k N/A claims N/A N/A N/A N/A sys version_info N/A 2 7 N/A _encode N/A N/A bytes_data N/A N/A N/A encoded N/A urlsafe_b64encode N/A bytes bytes_data N/A N/A N/A N/A N/A encoded decode utf-8 replace = N/A N/A _encode N/A N/A bytes N/A N/A N/A encoded N/A urlsafe_b64encode bytes N/A N/A N/A N/A N/A encoded decode utf-8 replace = N/A _encode_json N/A N/A obj N/A N/A N/A N/A _encode N/A bytearray N/A N/A json dumps obj separators N/A , : utf-8 N/A _sign N/A N/A secret to_sign N/A N/A portable_bytes N/A N/A s N/A N/A N/A N/A N/A N/A bytes s utf-8 N/A N/A N/A TypeError N/A N/A N/A bytes s N/A N/A N/A _encode N/A N/A N/A N/A hmac new N/A portable_bytes secret N/A portable_bytes to_sign N/A hashlib sha256 digest N/A _encode_token N/A N/A secret claims N/A N/A N/A encoded_header N/A _encode_json N/A typ alg JWT HS256 N/A encoded_claims N/A _encode_json claims N/A secure_bits N/A %s%s%s N/A encoded_header TOKEN_SEP encoded_claims N/A sig N/A _sign secret secure_bits N/A N/A %s%s%s N/A secure_bits TOKEN_SEP sig N/A