use of org.apache.ignite.spi.encryption.keystore.KeystoreEncryptionSpi in project ignite by apache.
the class WalRecoveryWithPageCompressionAndTdeTest method getConfiguration.
/**
* {@inheritDoc}
*/
@Override
protected IgniteConfiguration getConfiguration(String gridName) throws Exception {
IgniteConfiguration cfg = super.getConfiguration(gridName);
for (CacheConfiguration<?, ?> ccfg : cfg.getCacheConfiguration()) ccfg.setEncryptionEnabled(true);
KeystoreEncryptionSpi encSpi = new KeystoreEncryptionSpi();
encSpi.setKeyStorePath(AbstractEncryptionTest.KEYSTORE_PATH);
encSpi.setKeyStorePassword(AbstractEncryptionTest.KEYSTORE_PASSWORD.toCharArray());
cfg.setEncryptionSpi(encSpi);
return cfg;
}
use of org.apache.ignite.spi.encryption.keystore.KeystoreEncryptionSpi in project ignite by apache.
the class DiskPageCompressionConfigValidationTest method getConfiguration.
/**
* {@inheritDoc}
*/
@Override
protected IgniteConfiguration getConfiguration(String igniteInstanceName) throws Exception {
IgniteConfiguration cfg = super.getConfiguration(igniteInstanceName);
KeystoreEncryptionSpi encSpi = new KeystoreEncryptionSpi();
encSpi.setKeyStorePath(KEYSTORE_PATH);
encSpi.setKeyStorePassword(KEYSTORE_PASSWORD.toCharArray());
cfg.setEncryptionSpi(encSpi);
DataStorageConfiguration dsCfg = new DataStorageConfiguration().setDefaultDataRegionConfiguration(new DataRegionConfiguration().setMaxSize(10L * 1024 * 1024).setPersistenceEnabled(true)).setPageSize(MAX_PAGE_SIZE).setWalMode(FSYNC);
cfg.setDataStorageConfiguration(dsCfg);
if (ccfg != null)
cfg.setCacheConfiguration(ccfg);
return cfg;
}
use of org.apache.ignite.spi.encryption.keystore.KeystoreEncryptionSpi in project ignite by apache.
the class PlatformConfigurationUtils method readEncryptionConfiguration.
/**
* Reads encryption configuration
* @param in Reader.
* @param cfg Configuration.
*/
private static void readEncryptionConfiguration(BinaryRawReaderEx in, IgniteConfiguration cfg) {
if (!in.readBoolean()) {
cfg.setEncryptionSpi(new NoopEncryptionSpi());
return;
}
KeystoreEncryptionSpi enc = new KeystoreEncryptionSpi();
enc.setMasterKeyName(in.readString());
enc.setKeySize(in.readInt());
enc.setKeyStorePath(in.readString());
enc.setKeyStorePassword(in.readCharArray());
cfg.setEncryptionSpi(enc);
}
use of org.apache.ignite.spi.encryption.keystore.KeystoreEncryptionSpi in project ignite by apache.
the class EncryptedCacheNodeJoinTest method getConfiguration.
/**
* {@inheritDoc}
*/
@Override
protected IgniteConfiguration getConfiguration(String grid) throws Exception {
IgniteConfiguration cfg = super.getConfiguration(grid);
cfg.setConsistentId(grid);
if (grid.equals(GRID_0) || grid.equals(GRID_2) || grid.equals(GRID_3) || grid.equals(GRID_4) || grid.equals(GRID_5) || grid.equals(GRID_6) || grid.equals(GRID_7)) {
KeystoreEncryptionSpi encSpi = new KeystoreEncryptionSpi();
encSpi.setKeyStorePath(grid.equals(GRID_2) ? KEYSTORE_PATH_2 : KEYSTORE_PATH);
encSpi.setKeyStorePassword(KEYSTORE_PASSWORD.toCharArray());
cfg.setEncryptionSpi(encSpi);
} else
cfg.setEncryptionSpi(null);
if (configureCache)
cfg.setCacheConfiguration(cacheConfiguration(grid));
return cfg;
}
use of org.apache.ignite.spi.encryption.keystore.KeystoreEncryptionSpi in project ignite by apache.
the class IgnitePdsDefragmentationEncryptionTest method getConfiguration.
/**
* {@inheritDoc}
*/
@Override
protected IgniteConfiguration getConfiguration(String igniteInstanceName) throws Exception {
IgniteConfiguration cfg = super.getConfiguration(igniteInstanceName);
KeystoreEncryptionSpi encSpi = new KeystoreEncryptionSpi();
encSpi.setKeyStorePath(AbstractEncryptionTest.KEYSTORE_PATH);
encSpi.setKeyStorePassword(AbstractEncryptionTest.KEYSTORE_PASSWORD.toCharArray());
cfg.setEncryptionSpi(encSpi);
for (CacheConfiguration<?, ?> ccfg : cfg.getCacheConfiguration()) ccfg.setEncryptionEnabled(true);
return cfg;
}
Aggregations