class OtpKeyRequestProcessor extends AbstractGameBootProcessor<OtpKeyRequest> {

  private Response newKey(OtpKeyRequest message) throws Exception {
    Integer size = message.getKeySize() == null ? defaultKeySize : message.getKeySize();
    SystemIdKey systemId = new SystemIdKey(message.getOtpSystemId());

    log.debug("Creating new OTP key of size {} for {}", size, systemId);

    byte[] newKey = pad.generateKey(size);

    newKeyRegistry.put(systemId, newKey);

    return new Response(message, ResponseCode.SUCCESS, newKey);
  }

}