troubleshooting Question

CipherInputStream / CipherOutputStream and bytes (java 1.4)

Avatar of BenJanes
BenJanes asked on
9 Comments1 Solution906 ViewsLast Modified:

I am trying to use these two classes and everything works fine, have set up the key, initiated the Cipher class etc.

However when I want to write out to the file everything needs to be written in bytes, as how do you send longs, ints etc if you can only send bytes?

HOw do you send strings? Is there some easy conversion to an array of bytes then I am missing for these primitive data types?

Mick Barry
Java Developer
Join our community to see this answer!
Unlock 1 Answer and 9 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 9 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros