怎样防止.class文件被反编译? 我们写的java文件编译成.class文件后,可以利用反编译软件,例如小颖反编译。请问大家怎样防止.class文件被反编译?jre包中的.class文件怎么不能别反编译? 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 使用java的混淆器对字节码进行混淆。现在java的混淆器很多。楼主可以google一下。 用混淆器http://www.dudu.com/wangluogongju/javachengxu/javahunxiaoqi_51377.shtml 有三种办法的.一种就是混淆器.使反编译的时候崩溃一种是把核心的class放在远程..另一种忘记了... jre包中的.class文件怎么不能反编译吗?可以的吧?除了 JNI 实现的部分。除了上面说的办法,还有一个办法,就是把自己的 .class 进行加密变换,然后在 run-time 用自己的 ClassLoader(可以用 JNI 实现)来 load。不过,话说回来,所有这些方法,最终是要在 run-time 的 JVM 内存中存在一个 class binary,如果有人从 JVM 入手,还是能找到它。说到底,只要你的程序是用 Java 写的,最终总逃不过反编译。混淆也许是个办法,就算你反编译了,看着也会晕菜。不知道有没有软件工具能对混淆过的东西进行“整理”的…… 请楼上的兄弟们给我一个能很成功地反编译JAVA1.4以上版本的.class文件的反编译器!反正我是没有发现过~ 一般都用混淆器的 混淆器种类也很多 上网google一下 呵呵 > 请楼上的兄弟们给我一个能很成功地反编译JAVA1.4以上版本的.class文件的反编译器!以下是我做的一个反编译,Ojbect.class 来自于 JDK 1.4.2-01 的 rt.jar不知道这样算不算“成功”?// Decompiled by Jad v1.5.8e. Copyright 2001 Pavel Kouznetsov.// Jad home page: http://www.geocities.com/kpdus/jad.html// Decompiler options: packimports(3) fieldsfirst nonlb nofldis // Source File Name: Object.javapackage java.lang;// Referenced classes of package java.lang:// Class, CloneNotSupportedException, IllegalArgumentException, Integer, // InterruptedException, StringBuffer, Throwable, Stringpublic class Object { public native int hashCode(); public Object() { } protected void finalize() throws Throwable { } public final native void notify(); public final native void notifyAll(); private static native void registerNatives(); public final void wait() throws InterruptedException { wait(0L); } public final native void wait(long l) throws InterruptedException; public final void wait(long l, int i) throws InterruptedException { if(l < 0L) throw new IllegalArgumentException("timeout value is negative"); if(i < 0 || i > 0xf423f) throw new IllegalArgumentException("nanosecond timeout value out of range"); if(i >= 0x7a120 || i != 0 && l == 0L) l++; wait(l); } public final native Class getClass(); protected native Object clone() throws CloneNotSupportedException; public boolean equals(Object obj) { return this == obj; } public String toString() { return getClass().getName() + "@" + Integer.toHexString(hashCode()); } static { registerNatives(); }} 用jsp写了个连接oracle的报表,怎么把连接oracle的用户名和密码隐藏起来,让其他人打开jsp也看不到? 关于日期的问题,请指教! 在JAVA中如何用语句打开一个文档?? 急急急!!!!!!!!! exe4j是否支持jdk1.5的打包? 赐教:java分析apache日志 请问考SCJD有什么条件? 不再用到的对象要置成null,请举个例子 用什么方法把一个文本文件中的内容全部清空?(急) 求一个50阶层的算法 聊天程序传输字体颜色的问题 一个有关JSP的问题
http://www.dudu.com/wangluogongju/javachengxu/javahunxiaoqi_51377.shtml
一种是把核心的class放在远程..
另一种忘记了...
不知道这样算不算“成功”?// Decompiled by Jad v1.5.8e. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://www.geocities.com/kpdus/jad.html
// Decompiler options: packimports(3) fieldsfirst nonlb nofldis
// Source File Name: Object.javapackage java.lang;// Referenced classes of package java.lang:
// Class, CloneNotSupportedException, IllegalArgumentException, Integer,
// InterruptedException, StringBuffer, Throwable, Stringpublic class Object { public native int hashCode(); public Object() {
} protected void finalize() throws Throwable {
} public final native void notify(); public final native void notifyAll(); private static native void registerNatives(); public final void wait() throws InterruptedException {
wait(0L);
} public final native void wait(long l) throws InterruptedException; public final void wait(long l, int i) throws InterruptedException {
if(l < 0L)
throw new IllegalArgumentException("timeout value is negative");
if(i < 0 || i > 0xf423f)
throw new IllegalArgumentException("nanosecond timeout value out of range");
if(i >= 0x7a120 || i != 0 && l == 0L)
l++;
wait(l);
} public final native Class getClass(); protected native Object clone() throws CloneNotSupportedException; public boolean equals(Object obj) {
return this == obj;
} public String toString() {
return getClass().getName() + "@" + Integer.toHexString(hashCode());
} static {
registerNatives();
}
}