Use SecureRandom and added print config options.