001package edu.boisestate.lowry.crypto; 002 003/** 004 * Represents the size for a symmetric secret key. Currently 005 * only 128, 192, and 256-bit key sizes are supported. 006 * 007 * @author Jayce Lowry 008 */ 009public enum KeySize { 010 /** 128-bit (16-byte) key */ 011 BITS_128(16), 012 /** 192-bit (24-byte) key */ 013 BITS_192(24), 014 /** 256-bit (32-byte) key */ 015 BITS_256(32); 016 017 /** 018 * The key size in bytes. 019 */ 020 public final int numBytes; 021 022 /** 023 * Internal constructor for KeySize presets. 024 * 025 * @param numBytes The number of bytes for the key. 026 */ 027 KeySize(int numBytes) { 028 this.numBytes = numBytes; 029 } 030}