Can I use a keyfile with the Java API?

Discussion related to AES Crypt, the file encryption software for Windows, Linux, Mac, and Java.
Post Reply
multibobwork
Posts: 9
Joined: Fri Mar 28, 2014 1:12 am

Can I use a keyfile with the Java API?

Post by multibobwork »

Hi,

I would like to use a generated keyfile (keygen) with the Java API to encrypt and decrypt is this possible? If so can you send an example.

Also is there a way to generate the keyfile with the Java API?

Regards,

- Bob
User avatar
paulej
Posts: 595
Joined: Sun Aug 23, 2009 7:32 pm
Location: Research Triangle Park, NC, USA
Contact:

Re: Can I use a keyfile with the Java API?

Post by paulej »

The Java code doesn't have a routine to generate key files, but it should be easy to do. Just write out a proper UTF-16LE file with random characters. Don't forget to insert a BOM as the first two octets of the file.
multibobwork
Posts: 9
Joined: Fri Mar 28, 2014 1:12 am

Re: Can I use a keyfile with the Java API?

Post by multibobwork »

Hi,

Thanks for the reply but can the Java API use a keyfile that I generated with the Linux command line?

Regards,

- Bob
User avatar
paulej
Posts: 595
Joined: Sun Aug 23, 2009 7:32 pm
Location: Research Triangle Park, NC, USA
Contact:

Re: Can I use a keyfile with the Java API?

Post by paulej »

No, you'd have to write that logic yourself.
Post Reply