online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code    Language
import javax.crypto.spec.*; import java.security.spec.*; import javax.crypto.*; import java.security.*; import java.util.*; import java.nio.charset.*; import java.io.*; class Main { public static void main(String args[]) { SecretKeyFactory instance = null; Cipher instance2 = null; try { instance = SecretKeyFactory.getInstance("PBKDF2WithHmacSHA1"); instance2 = Cipher.getInstance("AES/CBC/PKCS5Padding"); } catch (final NoSuchAlgorithmException ex9) {} catch (final NoSuchPaddingException ex10) {} Rnd.reSeed(); final byte[] array = new byte[16]; for (int i = 0; i < 16; ++i) { array[i] = (byte)Rnd.get(256); } final PBEKeySpec pbeKeySpec = new PBEKeySpec("1.01.001007".toCharArray(), array, 65536, 256); Key key2 = null; try { key2 = new SecretKeySpec(((SecretKeyFactory)instance).generateSecret(pbeKeySpec).getEncoded(), "AES"); } catch (final InvalidKeySpecException ex3) {} final byte[] array2 = new byte[16]; for (int j = 0; j < 16; ++j) { array2[j] = (byte)Rnd.get(256); } final IvParameterSpec ivParameterSpec = new IvParameterSpec(array2); try { instance2.init(2, key2, ivParameterSpec); } catch (final InvalidKeyException ex4) {} catch (final InvalidAlgorithmParameterException ex5) {} try { System.out.println(new String(instance2.doFinal(Base64.getDecoder().decode(new String("diDrBf4+uZMtDV+0k/3BCGM4xyTpEyGEuUFYegIaSjQyQcgfIfZRbvGQ9hHMqnuflNCKv4HW/NXq93j4QqLc/Q==").getBytes("UTF-8"))), StandardCharsets.UTF_8)); } catch (final IllegalBlockSizeException ex6) {} catch (final BadPaddingException ex7) {} catch (final UnsupportedEncodingException ex8) {} } } class Rnd { private static MTRandom rnd; static { Rnd.rnd = new MTRandom((long)(-1966625086)); } public Rnd() { super(); } public static float get() { return Rnd.rnd.nextFloat(); } public static int get(final int n) { final double nextDouble = Rnd.rnd.nextDouble(); final double n2 = n; Double.isNaN(n2); return (int)Math.floor(nextDouble * n2); } public static int get(final int n, final int n2) { final double nextDouble = Rnd.rnd.nextDouble(); final double n3 = n2 - n + 1; Double.isNaN(n3); return n + (int)Math.floor(nextDouble * n3); } public static boolean nextBoolean() { return Rnd.rnd.nextBoolean(); } public static double nextDouble() { return Rnd.rnd.nextDouble(); } public static double nextGaussian() { return Rnd.rnd.nextGaussian(); } public static int nextInt() { return Rnd.rnd.nextInt(); } public static int nextInt(final int n) { final double nextDouble = Rnd.rnd.nextDouble(); final double n2 = n; Double.isNaN(n2); return (int)Math.floor(nextDouble * n2); } public static void reSeed() { Rnd.rnd = new MTRandom((long)(-1966625086)); } } class MTRandom extends Random { private static final long DEFAULT_SEED = 5489L; private static final int LOWER_MASK = Integer.MAX_VALUE; private static final int M = 397; private static final int[] MAGIC; private static final int MAGIC_FACTOR1 = 1812433253; private static final int MAGIC_FACTOR2 = 1664525; private static final int MAGIC_FACTOR3 = 1566083941; private static final int MAGIC_MASK1 = -1658038656; private static final int MAGIC_MASK2 = -272236544; private static final int MAGIC_SEED = 19650218; private static final int N = 624; private static final int UPPER_MASK = Integer.MIN_VALUE; private static final long serialVersionUID = -515082678588212038L; private transient boolean compat; private transient int[] ibuf; private transient int[] mt; private transient int mti; static { MAGIC = new int[] { 0, -1727483681 }; } public MTRandom() { super(); this.compat = false; } public MTRandom(final long n) { super(n); this.compat = false; } public MTRandom(final boolean compat) { super(0L); this.compat = compat; long currentTimeMillis; if (compat) { currentTimeMillis = 5489L; } else { currentTimeMillis = System.currentTimeMillis(); } this.setSeed(currentTimeMillis); } public MTRandom(final byte[] seed) { super(0L); this.compat = false; this.setSeed(seed); } public MTRandom(final int[] seed) { super(0L); this.compat = false; this.setSeed(seed); } public static int[] pack(final byte[] array) { final int length = array.length; final int n = array.length + 3 >>> 2; final int[] array2 = new int[n]; int n2; for (int i = 0; i < n; i = n2) { n2 = i + 1; int n3; if ((n3 = n2 << 2) > length) { n3 = length; } int n4; int n5; for (n4 = n3 - 1, n5 = (array[n4] & 0xFF); (n4 & 0x3) != 0x0; --n4, n5 = (n5 << 8 | (array[n4] & 0xFF))) {} array2[i] = n5; } return array2; } private void setSeed(int mti) { if (this.mt == null) { this.mt = new int[624]; } this.mt[0] = mti; mti = 1; while (true) { this.mti = mti; mti = this.mti; if (mti >= 624) { break; } final int[] mt = this.mt; mt[mti] = (mt[mti - 1] ^ mt[mti - 1] >>> 30) * 1812433253 + mti; ++mti; } } @Override protected final int next(final int n) { try { if (this.mti >= 624) { int n2 = 0; int i; while (true) { i = n2; if (n2 >= 227) { break; } final int[] mt = this.mt; final int n3 = mt[n2]; final int n4 = n2 + 1; final int n5 = (Integer.MAX_VALUE & mt[n4]) | (Integer.MIN_VALUE & n3); mt[n2] = (MTRandom.MAGIC[n5 & 0x1] ^ (mt[n2 + 397] ^ n5 >>> 1)); n2 = n4; } while (i < 623) { final int[] mt2 = this.mt; final int n6 = mt2[i]; final int n7 = i + 1; final int n8 = (n6 & Integer.MIN_VALUE) | (mt2[n7] & Integer.MAX_VALUE); mt2[i] = (MTRandom.MAGIC[n8 & 0x1] ^ (mt2[i - 227] ^ n8 >>> 1)); i = n7; } final int[] mt3 = this.mt; final int n9 = (Integer.MAX_VALUE & mt3[0]) | (Integer.MIN_VALUE & mt3[623]); mt3[623] = (MTRandom.MAGIC[n9 & 0x1] ^ (mt3[396] ^ n9 >>> 1)); this.mti = 0; } final int n10 = this.mt[this.mti++]; final int n11 = n10 ^ n10 >>> 11; final int n12 = n11 ^ (n11 << 7 & 0x9D2C5680); final int n13 = n12 ^ (n12 << 15 & 0xEFC60000); return (n13 ^ n13 >>> 18) >>> 32 - n; } finally { } } @Override public final void setSeed(final long n) { synchronized (this) { if (this.compat) { this.setSeed((int)n); } else { if (this.ibuf == null) { this.ibuf = new int[2]; } final int[] ibuf = this.ibuf; ibuf[0] = (int)n; ibuf[1] = (int)(n >>> 32); this.setSeed(ibuf); } } } public final void setSeed(final byte[] array) { this.setSeed(pack(array)); } public final void setSeed(int[] mt) { try { final int length = mt.length; if (length != 0) { int n; if (624 > length) { n = 624; } else { n = length; } this.setSeed(19650218); int n2 = 1; int n3 = 0; int n7; for (int i = n; i > 0; --i, n3 = n7) { final int[] mt2 = this.mt; final int n4 = mt2[n2]; final int n5 = n2 - 1; mt2[n2] = (n4 ^ (mt2[n5] >>> 30 ^ mt2[n5]) * 1664525) + mt[n3] + n3; final int n6 = n2 + 1; ++n3; if ((n2 = n6) >= 624) { mt2[0] = mt2[623]; n2 = 1; } if ((n7 = n3) >= length) { n7 = 0; } } for (int j = 623; j > 0; --j) { mt = this.mt; final int n8 = mt[n2]; final int n9 = n2 - 1; mt[n2] = (n8 ^ (mt[n9] >>> 30 ^ mt[n9]) * 1566083941) - n2; if (++n2 >= 624) { mt[0] = mt[623]; n2 = 1; } } this.mt[0] = Integer.MIN_VALUE; return; } throw new IllegalArgumentException("Seed buffer may not be empty"); } finally { } } }

Compiling Program...

Command line arguments:
Standard Input: Interactive Console Text

                

                

Program is not being debugged. Click "Debug" button to start program in debug mode.

#FunctionFile:Line
VariableValue
RegisterValue
ExpressionValue