@Test(expectedExceptions = Error.class, expectedExceptionsMessageRegExp = "This cipher is not compatible with the current runtime: .*") public void throwsUncheckedErrorsForAnyMethodCall() { LocallyIllegalAesCipherDetails illegalAesCipherDetails = new LocallyIllegalAesCipherDetails(0); illegalAesCipherDetails.getCipher(); }
@Override public Cipher getCipher() { fail(); return null; }
LocallyIllegalAesCipherDetails implements SupportedCipherDetails { @Override public Cipher getCipher() { fail(); return null; } }
LocallyIllegalAesCipherDetails implements SupportedCipherDetails { @Override public Cipher getCipher() { fail(); return null; } LocallyIllegalAesCipherDetails(final int keyLengthBits); }
LocallyIllegalAesCipherDetails implements SupportedCipherDetails { @Override public Cipher getCipher() { fail(); return null; } LocallyIllegalAesCipherDetails(final int keyLengthBits); @Override String getKeyGenerationAlgorithm(); @Override String getCipherId(); @Override String getCipherAlgorithm(); @Override int getKeyLengthBits(); @Override int getBlockSizeInBytes(); @Override int getIVLengthInBytes(); @Override int getAuthenticationTagOrHmacLengthInBytes(); @Override long getMaximumPlaintextSizeInBytes(); @Override Cipher getCipher(); @Deprecated @Override Cipher getBouncyCastleCipher(); @Override Cipher getCloneableCipher(); @Override long ciphertextSize(final long plaintextSize); @Override long plaintextSize(final long ciphertextSize); @Override boolean plaintextSizeCalculationIsAnEstimate(); @Override boolean isAEADCipher(); @Override AlgorithmParameterSpec getEncryptionParameterSpec(final byte[] iv); @Override AlgorithmParameterSpec getEncryptionParameterSpec(final byte[] iv, final long counter); @Override HMac getAuthenticationHmac(); @Override ByteRangeConversion translateByteRange(final long startPositionInclusive, final long endPositionInclusive); @Override long updateCipherToPosition(final Cipher cipher, final long position); @Override byte[] generateIv(); @Override boolean supportsRandomAccess(); }
LocallyIllegalAesCipherDetails implements SupportedCipherDetails { @Override public Cipher getCipher() { fail(); return null; } LocallyIllegalAesCipherDetails(final int keyLengthBits); @Override String getKeyGenerationAlgorithm(); @Override String getCipherId(); @Override String getCipherAlgorithm(); @Override int getKeyLengthBits(); @Override int getBlockSizeInBytes(); @Override int getIVLengthInBytes(); @Override int getAuthenticationTagOrHmacLengthInBytes(); @Override long getMaximumPlaintextSizeInBytes(); @Override Cipher getCipher(); @Deprecated @Override Cipher getBouncyCastleCipher(); @Override Cipher getCloneableCipher(); @Override long ciphertextSize(final long plaintextSize); @Override long plaintextSize(final long ciphertextSize); @Override boolean plaintextSizeCalculationIsAnEstimate(); @Override boolean isAEADCipher(); @Override AlgorithmParameterSpec getEncryptionParameterSpec(final byte[] iv); @Override AlgorithmParameterSpec getEncryptionParameterSpec(final byte[] iv, final long counter); @Override HMac getAuthenticationHmac(); @Override ByteRangeConversion translateByteRange(final long startPositionInclusive, final long endPositionInclusive); @Override long updateCipherToPosition(final Cipher cipher, final long position); @Override byte[] generateIv(); @Override boolean supportsRandomAccess();  }