this.cipher.init(Cipher.ENCRYPT_MODE, key.getKey(), this.ivSpec);
this.encryptMode = true;
} catch (InvalidKeyException e) {
String errorMessage = HDIVUtil.getMessage("cipher.init.encrypt", e.getMessage());
throw new HDIVException(errorMessage, e);
} catch (InvalidAlgorithmParameterException e) {
String errorMessage = HDIVUtil.getMessage("cipher.init.encrypt", e.getMessage());
throw new HDIVException(errorMessage, e);
}
}