0

I want to decrypt a file that is decrypted using this command line

openssl.exe enc -d -in input.ENC -out output.txt -pass file:keyfile.key -des3

I want to be able to decrypt it using Java. (JDK8)

Thanks in advance for tips.

  • 2
    ...so are you expecting us to just give you a list of libraries, approaches, tips, tricks and code with unit tests that solves your problem? I do apologize if that came across as impolite, but I personally see it as impolite to ask a question as broad as this without any prior work done on your part. C'mon; we're volunteers here. Respect our time too. – Makoto Feb 20 '18 at 17:16
  • See this answer: https://stackoverflow.com/questions/20227/how-do-i-use-3des-encryption-decryption-in-java – diginoise Feb 20 '18 at 17:18
  • [Java AES 128 encrypting differently to openssl](http://stackoverflow.com/q/21086103/608639), [Java equivalent of an OpenSSL AES CBC encryption](http://stackoverflow.com/q/32508961/608639), [How to decode a string encoded with openssl aes-128-cbc using java?](http://stackoverflow.com/q/31947256/608639), [Using Java to decrypt openssl aes-256-cbc using provided key and iv](http://stackoverflow.com/q/15594518/608639), etc. – jww Feb 20 '18 at 19:23
  • Usually [`EVP_BytesToKey`](http://wiki.openssl.org/index.php/Manual:EVP_BytesToKey(3)) is one of the issues. See [Java equivalent of C++ encryption](http://stackoverflow.com/q/12920740/608639), [How to use OpenSSL generated keys in Java?](http://security.stackexchange.com/q/9600/29925), [Java openssl encryption / decryption key generation](http://stackoverflow.com/q/34502705/608639), [Password to key function compatible with OpenSSL commands?](http://stackoverflow.com/q/9488919), [How to decrypt file in Java encrypted with openssl command using AES?](http://stackoverflow.com/q/11783062), etc. – jww Feb 20 '18 at 19:23
  • @Makoto - OpenSSL gets so many of the *"write the code me for in {language}"* questions I have a cheat sheet with copy/paste for the dups... As soon as we figure out the match we can close it. – jww Feb 20 '18 at 19:25

0 Answers0