Can a secret be hidden in a 'safe' java class offering access credentials?

后端 未结 12 1740
北荒
北荒 2020-12-03 09:04

This is a brainstorming question about what\'s possible in Java (or not). I want to know if it is possible to hide a secret within a class and prevent anymore from accessing

12条回答
  •  没有蜡笔的小新
    2020-12-03 09:22

    You can obfuscate it from the .class file by using proguard or similar tools. You may also sign your JAR so other packages can't access it. Signing your JAR may help too.

提交回复
热议问题