Problem with Writing text to a File

I have a problem when I want to write text to a file. This isn’t really “normal” text as it has been run through a RSA-crypto but no matter what I do I can’t seem to save the data in the same way that I have it in my Java program so when I read it from the file and run it through the decryption it becomes wierd. And just to make sure, as long as I don’t write and read the data to a file the decryption works perfectly so it’s not that which is a problem.

The lines I encrypt: Ok
we are testing if this works
and I hope the different rows come in

What the encrypted data looks like if you use println on it: 5Ù4ÔU+?Y_+?3+:3O??OÉ?3?O:?UP_Ù:4ÔY?í?Õ??P,+?3?+?íOÉÉ+_+?3?_PU:?âPV+?O?

What it looks like after writing, reading and decryption: Ok
we¼are¼testi¼g¼if¼t¼is¼works
a¼d¼I¼¼ope¼t¼e¼differe¼t¼rows¼come¼i¼

My writing function:
public static void writeFile(String path, String text) throws IOException{
OutputStream out = null;
try{
out = new FileOutputStream(path);
byte[] totalBytes = text.getBytes();
out.write(totalBytes);
}
finally{
if(out !=null)
out.close();
}
}

My reading function:
public static String readFile(String path) throws IOException{
String sContent=null;
byte [] buffer =null;
File a_file = new File(path);
try
{
FileInputStream fis = new FileInputStream(path);
int length = (int)a_file.length();
buffer = new byte [length];
fis.read(buffer);
fis.close();
}
catch(IOException e){e.printStackTrace();}

	 sContent = new String(buffer);  
	 return sContent;  
	 }