Code example for SecureRandom

Methods: setSeed

0
		@Override 
		public void run() { 
			logger.info("Generating new PRNG seed"); 
			final byte[] seed = SecureRandom.getSeed(ENTROPY_UPDATE_SIZE);
			logger.info("Updating PRNG seed"); 
			random.setSeed(seed);
		} 
	} 
	 
	private static final Logger LOGGER = LoggerFactory.getLogger(SecureRandomProvider.class); 
	private static final String PRNG_ALGORITHM = "SHA1PRNG";
	private static final String PRNG_PROVIDER = "SUN";
	 
	private final SecureRandom random;
	private final ScheduledExecutorService pool;
	 
	public SecureRandomProvider() { 
		this.pool = Executors.newSingleThreadScheduledExecutor();
		 
		LOGGER.info("Creating PRNG");