Home / Class/ SslSessionTicketKey Class — netty Architecture

SslSessionTicketKey Class — netty Architecture

Architecture documentation for the SslSessionTicketKey class in SslSessionTicketKey.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  d3c243c3_5759_f12a_c58d_5bfdbababc21["SslSessionTicketKey"]
  b473aea8_4970_e9cf_fbc2_8bba30a84195["SslSessionTicketKey.java"]
  d3c243c3_5759_f12a_c58d_5bfdbababc21 -->|defined in| b473aea8_4970_e9cf_fbc2_8bba30a84195
  b5c18fee_ec56_0263_f3bd_c7de90ce710c["SslSessionTicketKey()"]
  d3c243c3_5759_f12a_c58d_5bfdbababc21 -->|method| b5c18fee_ec56_0263_f3bd_c7de90ce710c
  85f59ddb_f452_3480_b312_ca737441ac0d["name()"]
  d3c243c3_5759_f12a_c58d_5bfdbababc21 -->|method| 85f59ddb_f452_3480_b312_ca737441ac0d
  c9a52950_7891_ff2b_f6ef_613748ce807d["hmacKey()"]
  d3c243c3_5759_f12a_c58d_5bfdbababc21 -->|method| c9a52950_7891_ff2b_f6ef_613748ce807d
  cff0f254_e199_c6fd_70a9_58ce6694e33e["aesKey()"]
  d3c243c3_5759_f12a_c58d_5bfdbababc21 -->|method| cff0f254_e199_c6fd_70a9_58ce6694e33e
  de528d07_25b9_c057_0fa0_3adbbf7f45ee["equals()"]
  d3c243c3_5759_f12a_c58d_5bfdbababc21 -->|method| de528d07_25b9_c057_0fa0_3adbbf7f45ee
  dde37d25_fa87_6eac_b898_5f3cf1825257["hashCode()"]
  d3c243c3_5759_f12a_c58d_5bfdbababc21 -->|method| dde37d25_fa87_6eac_b898_5f3cf1825257
  2ff674a2_731f_768c_9ce2_49e6e6e7bb6b["String()"]
  d3c243c3_5759_f12a_c58d_5bfdbababc21 -->|method| 2ff674a2_731f_768c_9ce2_49e6e6e7bb6b

Relationship Graph

Source Code

codec-classes-quic/src/main/java/io/netty/handler/codec/quic/SslSessionTicketKey.java lines 24–129

public final class SslSessionTicketKey {
    /**
     * Size of session ticket key name
     */
    public static final int NAME_SIZE = 16;
    /**
     * Size of session ticket key HMAC key
     */
    public static final int HMAC_KEY_SIZE = 16;
    /**
     * Size of session ticket key AES key
     */
    public static final int AES_KEY_SIZE = 16;
    /**
     * Size of session ticket key
     */
    public static final int TICKET_KEY_SIZE = NAME_SIZE + HMAC_KEY_SIZE + AES_KEY_SIZE;

    // package private so we can access these in BoringSSLSessionTicketCallback without calling clone() on the byte[].
    final byte[] name;
    final byte[] hmacKey;
    final byte[] aesKey;

    /**
     * Construct SessionTicketKey.
     * @param name the name of the session ticket key
     * @param hmacKey the HMAC key of the session ticket key
     * @param aesKey the AES key of the session ticket key
     */
    public SslSessionTicketKey(byte[] name, byte[] hmacKey, byte[] aesKey) {
        if (name == null || name.length != NAME_SIZE) {
            throw new IllegalArgumentException("Length of name must be " + NAME_SIZE);
        }
        if (hmacKey == null || hmacKey.length != HMAC_KEY_SIZE) {
            throw new IllegalArgumentException("Length of hmacKey must be " + HMAC_KEY_SIZE);
        }
        if (aesKey == null || aesKey.length != AES_KEY_SIZE) {
            throw new IllegalArgumentException("Length of aesKey must be " + AES_KEY_SIZE);
        }
        this.name = name.clone();
        this.hmacKey = hmacKey.clone();
        this.aesKey = aesKey.clone();
    }

    /**
     * Get name.
     *
     * @return the name of the session ticket key
     */
    public byte[] name() {
        return name.clone();
    }

    /**
     * Get HMAC key.
     * @return the HMAC key of the session ticket key
     */
    public byte[] hmacKey() {
        return hmacKey.clone();
    }

    /**
     * Get AES Key.
     * @return the AES key of the session ticket key
     */
    public byte[] aesKey() {
        return aesKey.clone();
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }

        SslSessionTicketKey that = (SslSessionTicketKey) o;

        if (!Arrays.equals(name, that.name)) {

Frequently Asked Questions

What is the SslSessionTicketKey class?
SslSessionTicketKey is a class in the netty codebase, defined in codec-classes-quic/src/main/java/io/netty/handler/codec/quic/SslSessionTicketKey.java.
Where is SslSessionTicketKey defined?
SslSessionTicketKey is defined in codec-classes-quic/src/main/java/io/netty/handler/codec/quic/SslSessionTicketKey.java at line 24.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free