package 加密;
import java.io.BufferedInputStream;
import java.io.BufferedOutputStream;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;
public class 加密文件 {
public static void main(String[] args) throws IOException {
method();
}
private static void method() throws IOException {
BufferedInputStream bis = new BufferedInputStream(new FileInputStream(
"d:\\my.flv"));
BufferedOutputStream bos = new BufferedOutputStream(
new FileOutputStream("e:\\国产手机界谁将笑到最后 09_标清.flv"));
int by = 0;
while ((by = bis.read()) != -1) {
bos.write(by ^ 12);
}
bos.close();
bis.close();
}
} |
|