How I brute-forced my own keystore password
How I brute-forced my own keystore password If, like me, you've been in the unfortunate siutation where you have forgotten your own keystore (or certificate key) password then help may be at hand. After some fruitless searching I decide to write my own piece of software to brute force my keystore certificate. As I am/have been a Java programmer I decided to write it in the language I knew best, and this is how I did it. I have made the source code available for anyone who wants it Loading the keystore The Java API already has code for loading a keystore, java.security.KeyStore. The keystore needs to be placed on the classpath (I just stuck it in the root on my Eclipse project) // Load the keystore in the user's home directory File file = new File(keystoreName); is = new FileInputStream(file); KeyStore keystore = KeyStore.getInstance(KeyStore.getDefaultType()); keystore.load(is, keystorePassword.toCharArray()); return keystore; The above code sim...