fork download
  1. /* package whatever; // don't place package name! */
  2.  
  3. /* The class name doesn't have to be Main, as long as the class is not public. */
  4. import sun.misc.BASE64Decoder;
  5. class Main
  6. {
  7. public static void main (String[] args) throws java.lang.Exception
  8. {
  9. String encodedBytes ="LyJwNh9iPil3MyMSGRhWCCpXBExXAWZBGg1eFjNcShpSCmZxCwJSAC9TBDxbBTRfCw9KRDNbHkxHCzISBwNBAyNcRkxJAWZfBQlHASgSDgkTEilAAwtWRCRTHg9bATUSBANURCRXHg1fASg=";
  10. String message = java.util.prefs.Base64.byteArrayToBase64(encodedBytes.getBytes("UTF-8"));
  11. String paramString = "jl3dF2";
  12. int paramInt= 2;
  13. String str= "";
  14.  
  15. System.out.println("----------------- START ---------------------");
  16. for (int i = 0; i < message.length(); i++)
  17. {
  18. int k = paramString.charAt(i % paramString.length());
  19. int j = message.charAt(i);
  20. k &= 1 << paramInt;
  21. str = str + (k ^ j);
  22. }
  23. System.out.println(str);
  24. }
  25. }
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
Main.java:4: warning: sun.misc.BASE64Decoder is Sun proprietary API and may be removed in a future release
import sun.misc.BASE64Decoder; 
               ^
Main.java:10: java.util.prefs.Base64 is not public in java.util.prefs; cannot be accessed from outside package
  String message = java.util.prefs.Base64.byteArrayToBase64(encodedBytes.getBytes("UTF-8")); 
                                  ^
1 error
1 warning
stdout
Standard output is empty