@Test public void testEnvBasedKeyLoading() throws Exception { SakuliPropertyPlaceholderConfigurer.ENCRYPTION_KEY_VALUE = "test-key"; CipherDelegator.loadEnvironmentVariables(); assertEquals(SakuliPropertyPlaceholderConfigurer.ENCRYPTION_KEY_VALUE, "test-key"); }
static void loadEnvironmentVariables() { if (isBlank(SakuliPropertyPlaceholderConfigurer.ENCRYPTION_KEY_VALUE)) { final String envKey = System.getenv(CipherProperties.ENCRYPTION_KEY_ENV); if (isNotBlank(envKey)) { SakuliPropertyPlaceholderConfigurer.ENCRYPTION_KEY_VALUE = envKey; LOGGER.info("use environment var '{}' for encryption", CipherProperties.ENCRYPTION_KEY_ENV); } } }
CipherDelegator { static void loadEnvironmentVariables() { if (isBlank(SakuliPropertyPlaceholderConfigurer.ENCRYPTION_KEY_VALUE)) { final String envKey = System.getenv(CipherProperties.ENCRYPTION_KEY_ENV); if (isNotBlank(envKey)) { SakuliPropertyPlaceholderConfigurer.ENCRYPTION_KEY_VALUE = envKey; LOGGER.info("use environment var '{}' for encryption", CipherProperties.ENCRYPTION_KEY_ENV); } } } }
CipherDelegator { static void loadEnvironmentVariables() { if (isBlank(SakuliPropertyPlaceholderConfigurer.ENCRYPTION_KEY_VALUE)) { final String envKey = System.getenv(CipherProperties.ENCRYPTION_KEY_ENV); if (isNotBlank(envKey)) { SakuliPropertyPlaceholderConfigurer.ENCRYPTION_KEY_VALUE = envKey; LOGGER.info("use environment var '{}' for encryption", CipherProperties.ENCRYPTION_KEY_ENV); } } }  }
CipherDelegator { static void loadEnvironmentVariables() { if (isBlank(SakuliPropertyPlaceholderConfigurer.ENCRYPTION_KEY_VALUE)) { final String envKey = System.getenv(CipherProperties.ENCRYPTION_KEY_ENV); if (isNotBlank(envKey)) { SakuliPropertyPlaceholderConfigurer.ENCRYPTION_KEY_VALUE = envKey; LOGGER.info("use environment var '{}' for encryption", CipherProperties.ENCRYPTION_KEY_ENV); } } }  static Map.Entry<String, String> encrypt(String strToEncrypt); }
CipherDelegator { static void loadEnvironmentVariables() { if (isBlank(SakuliPropertyPlaceholderConfigurer.ENCRYPTION_KEY_VALUE)) { final String envKey = System.getenv(CipherProperties.ENCRYPTION_KEY_ENV); if (isNotBlank(envKey)) { SakuliPropertyPlaceholderConfigurer.ENCRYPTION_KEY_VALUE = envKey; LOGGER.info("use environment var '{}' for encryption", CipherProperties.ENCRYPTION_KEY_ENV); } } }  static Map.Entry<String, String> encrypt(String strToEncrypt);  }