private static final IvParameterSpec generateIv(Cipher cipher) throws NoSuchAlgorithmException {
    SecureRandom randomSecureRandom = SecureRandom.getInstance("SHA1PRNG");
    byte[] iv = new byte[cipher.getBlockSize()];
    randomSecureRandom.nextBytes(iv);
    return new IvParameterSpec(iv);
  }
Provides AES and RSA-based encryption implementations. See {@link EncrypterFactory} to create.

The first block encrypted is a random salt so that we can ignore its value in the decrypter. This
makes it so we don't have to record the IV for AES.
libraries/security/src/main/java/org/datatransferproject/security/EncrypterImpl.java