@Override
    protected boolean isSecure(String key) {
        AuthorizationPluginInfo pluginInfo = this.metadataStore().getPluginInfo(getPluginId());

        if (pluginInfo == null
                || pluginInfo.getAuthConfigSettings() == null
                || pluginInfo.getAuthConfigSettings().getConfiguration(key) == null) {
            return false;
        }

        return pluginInfo.getAuthConfigSettings().getConfiguration(key).isSecure();
    }
@Test
    public void postConstruct_shouldIgnoreEncryptionIfPluginInfoIsNotDefined() throws Exception {
        SecurityAuthConfig authConfig = new SecurityAuthConfig("id", "plugin_id", new ConfigurationProperty(new ConfigurationKey("password"), new ConfigurationValue("pass")));

        authConfig.encryptSecureConfigurations();

        assertThat(authConfig.size(), is(1));
        assertFalse(authConfig.first().isSecure());
    }