KeyPair pair = null;
try {
KeyPairGenerator keyGen = KeyPairGenerator.getInstance("DSA");
keyGen.initialize(1024, new SecureRandom());
pair = keyGen.generateKeyPair();
} catch (Exception e) {
ErrorMessages.error("Cannot sign cards. Continuing anyway.");
}
priv = pair.getPrivate();
pub = pair.getPublic();