All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.relayrides.pushy.apns.AuthenticationTokenHeader Maven / Gradle / Ivy

There is a newer version: 0.9.3
Show newest version
package com.relayrides.pushy.apns;

import com.google.gson.annotations.SerializedName;

/**
 * A model object representing the header section of a JWT payload.
 *
 * @author Jon Chambers
 *
 * @see RFC 7519: JSON Web Token (JWT), Section 4: JOSE Header
 *
 * @since 0.9
 */
class AuthenticationTokenHeader {
    @SerializedName("alg")
    private final String algorithm = "ES256";

    @SerializedName("typ")
    private final String tokenType = "JWT";

    @SerializedName("kid")
    private final String keyId;

    public AuthenticationTokenHeader(final String keyId) {
        this.keyId = keyId;
    }

    public String getAlgorithm() {
        return this.algorithm;
    }

    public String getTokenType() {
        return this.tokenType;
    }

    public String getKeyId() {
        return this.keyId;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy