All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.canoo.dp.impl.server.security.SecurityModule Maven / Gradle / Ivy

Go to download

The Dolphin Platform is a framework that implements the presentation model pattern and provides amodern way to create enterprise applications. The Platform provides several client implementations that all canbe used in combination with a general sever API.

There is a newer version: 1.0.0.CR5
Show newest version
package com.canoo.dp.impl.server.security;

import com.canoo.dp.impl.platform.core.Assert;
import com.canoo.platform.server.spi.AbstractBaseModule;
import com.canoo.platform.server.spi.ModuleDefinition;
import com.canoo.platform.server.spi.ModuleInitializationException;
import com.canoo.platform.server.spi.ServerCoreComponents;

@ModuleDefinition(SecurityModule.MODULE_NAME)
public class SecurityModule extends AbstractBaseModule {

    public final static String MODULE_NAME = "SecurityModule";

    private final static String MODULE_ACTIVE_PROPERTY= "security.active";

    @Override
    public void initialize(final ServerCoreComponents coreComponents) throws ModuleInitializationException {
        Assert.requireNonNull(coreComponents, "coreComponents");
        final KeycloakConfiguration configuration = new KeycloakConfiguration(coreComponents.getConfiguration());
        final DolphinSecurityBootstrap bootstrap = DolphinSecurityBootstrap.getInstance();
        bootstrap.init(coreComponents.getServletContext(), coreComponents.getConfiguration());
    }

    @Override
    protected String getActivePropertyName() {
        return MODULE_ACTIVE_PROPERTY;
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy