2016-08-07 7 views
0

Java 코드를 난처하게 만들고 Proguard 5.2.1을 사용하고 있습니다. 나는 -dontwarn 옵션을 사용하여 명령 줄에서 실행하려고 노력하고 난처 작동하지 않았다구성 파일을 사용하지 않고 Proguard GUI로 유지 관리하는 클래스로 난독 화

ProGuard, version 5.2.1 
Reading program jar [/root/Desktop/ACGPlain.jar] 
Reading library jar [/usr/lib/jvm/java-7-openjdk-amd64/jre/lib/rt.jar] 
Warning: connection.HttpURLClient: can't find referenced class javax.crypto.SecretKey 
Warning: connection.HttpURLClient: can't find referenced class javax.crypto.SecretKey 
Warning: connection.HttpURLClient: can't find referenced class javax.crypto.SecretKey 
Warning: connection.HttpURLClient: can't find referenced class javax.crypto.SecretKey 
Warning: connection.HttpURLClient: can't find referenced class javax.crypto.SecretKey 
Warning: there were 5 unresolved references to classes or interfaces. 
     You may need to add missing library jars or update their versions. 
     If your code works fine without the missing classes, you can suppress 
     the warnings with '-dontwarn' options. 
     (http://proguard.sourceforge.net/manual/troubleshooting.html#unresolvedclass) 
Please correct the above warnings first. 

: GUI를 사용하는 동안 그러나, 와서 경고가있다. 나는 시도 너무 다음

java -jar proguard.jar -injar /root/Desktop/ACGPlain.jar -outjar /root/Desktop/ACGOB.jar -keepclass javax.crypto.SecretKey 

경우, javax.crypto.SecretKey 클래스를 숨기고에서 난독 화를 막을 수있는 방법이 있나요? GUI 솔루션을 찾고 있는데 구성 파일이 아닙니다. 내 자바 코드는 안드로이드를위한 것이 아니며 서버와 클라이언트 간의 전송을 안전하게하는 프로그램입니다.

답변

1

암호 관련 클래스는 다른 jar 파일에 있습니다. 당신은 당신의 구성 파일에 다른 -libraryjar 구성을 추가해야합니다

-libraryjar /usr/lib/jvm/java-7-openjdk-amd64/jre/lib/jce.jar 

또 다른 옵션은 귀하의 경우 무해으로, 오류를 무시하는 것 :

-ignorewarnings 

또는

-dontwarn javax.crypto.**