Removed project-integrations as it's moved to a separate repo
This commit is contained in:
parent
e17105cc8e
commit
f037aaa1af
29 changed files with 0 additions and 817 deletions
|
@ -1,4 +0,0 @@
|
||||||
Keycloak External Project Integrations
|
|
||||||
==========
|
|
||||||
|
|
||||||
Everthing in this directory is examples related to integration with non-keycloak projects. Its a sandbox we use to test integrations with third-party projects
|
|
|
@ -1,50 +0,0 @@
|
||||||
Self Bootstrapping Keycloak Server and Application
|
|
||||||
==========================================================
|
|
||||||
|
|
||||||
To get this running boot up JBoss AS7, EAP or WildFly.
|
|
||||||
|
|
||||||
To deploy to AS7 run:
|
|
||||||
|
|
||||||
mvn clean install jboss-as:deploy
|
|
||||||
|
|
||||||
To deploy to WildFly run:
|
|
||||||
|
|
||||||
mvn -Pwildfly clean install wildfly:deploy
|
|
||||||
|
|
||||||
This is an example of bundling two wars: a keycloak server war and application WAR together so that keycloak is bootstrapped out of the
|
|
||||||
box. The structure of the example is:
|
|
||||||
|
|
||||||
* The aerogear UPS application [http://localhost:8080/aerogear-ups/ups/view.jsp](http://localhost:8080/aerogear-ups/ups/view.jsp)
|
|
||||||
* The aerogear UPS admin [http://localhost:8080/aerogear-ups/admin/admin.html](http://localhost:8080/aerogear-ups/admin/admin.html)
|
|
||||||
* The aerogear security admin (keycloak) [http://localhost:8080/auth/admin/aerogear/console/index.html](http://localhost:8080/auth/admin/aerogear/console/index.html)
|
|
||||||
* The aerogear user account page (keycloak) [http://localhost:8080/auth/realms/aerogear/account](http://localhost:8080/auth/realms/aerogear/account)
|
|
||||||
* All of these are managed under one realm "aerogear"
|
|
||||||
* The login page, admin console, and account pages all use the "aerogear" theme
|
|
||||||
|
|
||||||
If you click on any of those URLS, you are brought to a log-in screen. Username: admin Password: admin. You will be asked
|
|
||||||
to change your password. Once you are logged in, you have SSO to any of those links.
|
|
||||||
|
|
||||||
Notes on implementation:
|
|
||||||
|
|
||||||
* There is a testrealm.json file that is used to bootstrap the realm in the auth-server/ project
|
|
||||||
* Notice that there is a context-param in auth-server/web.xml called keycloak.import.realm.resources. This sets up the import of the json file
|
|
||||||
* If you open up testrealm.json, notice that all urls are relative. Keycloak will now extrapolate the host and port based
|
|
||||||
on the request if the configured urls are just a path and don't have a schem, host, and port.
|
|
||||||
* In the auth project, there is a AerogearThemeProvider class. This sets up classloader access to the "aerogear" themes
|
|
||||||
* In the auth project, there is a UpsSecurityApplication class. The sole purpose of this class is to disable the "master"
|
|
||||||
realm by deleting the master realm's "admin" user
|
|
||||||
* In the auth project resources/, there are files there to set up all the themes
|
|
||||||
* In app, there is a BootstrapListener class. This obtains the config context of the adapter and initializes it.
|
|
||||||
* Notice that BootstrapListener class sets up a relative URL. Also notice that the application is a "public" client. This is so that
|
|
||||||
we don't have to query the database for the application's secret. Also notice that the realm key is not set. Keycloak adapter
|
|
||||||
will now query the auth server url for the public key of the realm.
|
|
||||||
|
|
||||||
Problems:
|
|
||||||
* Biggest problem is SSL. You have to crack open web.xml to set up a confidential security constraint. You also have
|
|
||||||
to change the adapter config and the realm config to make SSL required.
|
|
||||||
* You need to set this logging config in standalone.xml otherwise you will get a lot of warning messages when accessing the admin console
|
|
||||||
|
|
||||||
<logger category="org.jboss.resteasy.core.ResourceLocator">
|
|
||||||
<level name="ERROR"/>
|
|
||||||
</logger>
|
|
||||||
|
|
|
@ -1,135 +0,0 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
||||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
|
||||||
<parent>
|
|
||||||
<artifactId>keycloak-parent</artifactId>
|
|
||||||
<groupId>org.keycloak</groupId>
|
|
||||||
<version>1.2.0.RC1-SNAPSHOT</version>
|
|
||||||
<relativePath>../../../pom.xml</relativePath>
|
|
||||||
</parent>
|
|
||||||
|
|
||||||
<modelVersion>4.0.0</modelVersion>
|
|
||||||
<artifactId>ups-example-app</artifactId>
|
|
||||||
<packaging>war</packaging>
|
|
||||||
<name>Keycloak Secured App EAP 6.x</name>
|
|
||||||
<description/>
|
|
||||||
|
|
||||||
<dependencies>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.bouncycastle</groupId>
|
|
||||||
<artifactId>bcprov-jdk15on</artifactId>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.keycloak</groupId>
|
|
||||||
<artifactId>keycloak-core</artifactId>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.keycloak</groupId>
|
|
||||||
<artifactId>keycloak-adapter-core</artifactId>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.keycloak</groupId>
|
|
||||||
<artifactId>keycloak-jboss-adapter-core</artifactId>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>net.iharder</groupId>
|
|
||||||
<artifactId>base64</artifactId>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.jboss.spec.javax.servlet</groupId>
|
|
||||||
<artifactId>jboss-servlet-api_3.0_spec</artifactId>
|
|
||||||
<scope>provided</scope>
|
|
||||||
</dependency>
|
|
||||||
<!-- resteasy -->
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.jboss.resteasy</groupId>
|
|
||||||
<artifactId>resteasy-jaxrs</artifactId>
|
|
||||||
<scope>provided</scope>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.jboss.resteasy</groupId>
|
|
||||||
<artifactId>async-http-servlet-3.0</artifactId>
|
|
||||||
<scope>provided</scope>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.jboss.resteasy</groupId>
|
|
||||||
<artifactId>jaxrs-api</artifactId>
|
|
||||||
<scope>provided</scope>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.jboss.resteasy</groupId>
|
|
||||||
<artifactId>resteasy-jackson-provider</artifactId>
|
|
||||||
<scope>provided</scope>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<!-- CDI -->
|
|
||||||
<dependency>
|
|
||||||
<groupId>javax.enterprise</groupId>
|
|
||||||
<artifactId>cdi-api</artifactId>
|
|
||||||
<version>1.0-SP4</version>
|
|
||||||
<scope>provided</scope>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
</dependencies>
|
|
||||||
|
|
||||||
<build>
|
|
||||||
<finalName>aerogear-ups</finalName>
|
|
||||||
<plugins>
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.jboss.as.plugins</groupId>
|
|
||||||
<artifactId>jboss-as-maven-plugin</artifactId>
|
|
||||||
<configuration>
|
|
||||||
<skip>false</skip>
|
|
||||||
</configuration>
|
|
||||||
</plugin>
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.wildfly.plugins</groupId>
|
|
||||||
<artifactId>wildfly-maven-plugin</artifactId>
|
|
||||||
<configuration>
|
|
||||||
<skip>false</skip>
|
|
||||||
</configuration>
|
|
||||||
</plugin>
|
|
||||||
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
|
||||||
<artifactId>maven-deploy-plugin</artifactId>
|
|
||||||
<configuration>
|
|
||||||
<skip>true</skip>
|
|
||||||
</configuration>
|
|
||||||
</plugin>
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
|
||||||
<artifactId>maven-compiler-plugin</artifactId>
|
|
||||||
<configuration>
|
|
||||||
<source>${maven.compiler.source}</source>
|
|
||||||
<target>${maven.compiler.target}</target>
|
|
||||||
</configuration>
|
|
||||||
</plugin>
|
|
||||||
</plugins>
|
|
||||||
</build>
|
|
||||||
|
|
||||||
<profiles>
|
|
||||||
<profile>
|
|
||||||
<id>as7</id>
|
|
||||||
<activation>
|
|
||||||
<activeByDefault>true</activeByDefault>
|
|
||||||
</activation>
|
|
||||||
<dependencies>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.keycloak</groupId>
|
|
||||||
<artifactId>keycloak-as7-adapter</artifactId>
|
|
||||||
</dependency>
|
|
||||||
</dependencies>
|
|
||||||
</profile>
|
|
||||||
<profile>
|
|
||||||
<id>wildfly</id>
|
|
||||||
<dependencies>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.keycloak</groupId>
|
|
||||||
<artifactId>keycloak-wildfly-adapter</artifactId>
|
|
||||||
</dependency>
|
|
||||||
</dependencies>
|
|
||||||
</profile>
|
|
||||||
</profiles>
|
|
||||||
|
|
||||||
</project>
|
|
|
@ -1,24 +0,0 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<!--
|
|
||||||
|
|
||||||
JBoss, Home of Professional Open Source
|
|
||||||
Copyright Red Hat, Inc., and individual contributors.
|
|
||||||
|
|
||||||
Licensed under the Apache License, Version 2.0 (the "License");
|
|
||||||
you may not use this file except in compliance with the License.
|
|
||||||
You may obtain a copy of the License at
|
|
||||||
|
|
||||||
http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
|
|
||||||
Unless required by applicable law or agreed to in writing, software
|
|
||||||
distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
See the License for the specific language governing permissions and
|
|
||||||
limitations under the License.
|
|
||||||
|
|
||||||
-->
|
|
||||||
<beans xmlns="http://java.sun.com/xml/ns/javaee"
|
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
||||||
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://jboss.org/schema/cdi/beans_1_0.xsd">
|
|
||||||
|
|
||||||
</beans>
|
|
|
@ -1,12 +0,0 @@
|
||||||
<jboss-deployment-structure>
|
|
||||||
<deployment>
|
|
||||||
<dependencies>
|
|
||||||
<module name="org.apache.httpcomponents"/>
|
|
||||||
<module name="org.codehaus.jackson.jackson-core-asl"/>
|
|
||||||
<module name="org.codehaus.jackson.jackson-mapper-asl"/>
|
|
||||||
<module name="org.jboss.xnio"/>
|
|
||||||
</dependencies>
|
|
||||||
<exclusions>
|
|
||||||
</exclusions>
|
|
||||||
</deployment>
|
|
||||||
</jboss-deployment-structure>
|
|
|
@ -1,5 +0,0 @@
|
||||||
<jboss-web>
|
|
||||||
<valve>
|
|
||||||
<class-name>org.keycloak.adapters.jbossweb.KeycloakAuthenticatorValve</class-name>
|
|
||||||
</valve>
|
|
||||||
</jboss-web>
|
|
|
@ -1,8 +0,0 @@
|
||||||
{
|
|
||||||
"realm" : "aerogear",
|
|
||||||
"auth-server-url" : "/auth",
|
|
||||||
"ssl-required" : "external",
|
|
||||||
"resource" : "unified-push-server",
|
|
||||||
"public-client" : true,
|
|
||||||
"disable-trust-manager" : true
|
|
||||||
}
|
|
|
@ -1,41 +0,0 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<web-app xmlns="http://java.sun.com/xml/ns/javaee"
|
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
||||||
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"
|
|
||||||
version="3.0">
|
|
||||||
|
|
||||||
<module-name>aerogear-ups</module-name>
|
|
||||||
|
|
||||||
<security-constraint>
|
|
||||||
<web-resource-collection>
|
|
||||||
<web-resource-name>UPS</web-resource-name>
|
|
||||||
<url-pattern>/ups/*</url-pattern>
|
|
||||||
</web-resource-collection>
|
|
||||||
<auth-constraint>
|
|
||||||
<role-name>user</role-name>
|
|
||||||
</auth-constraint>
|
|
||||||
</security-constraint>
|
|
||||||
|
|
||||||
<security-constraint>
|
|
||||||
<web-resource-collection>
|
|
||||||
<web-resource-name>AdminConsole</web-resource-name>
|
|
||||||
<url-pattern>/admin/*</url-pattern>
|
|
||||||
</web-resource-collection>
|
|
||||||
<auth-constraint>
|
|
||||||
<role-name>admin</role-name>
|
|
||||||
</auth-constraint>
|
|
||||||
</security-constraint>
|
|
||||||
|
|
||||||
<login-config>
|
|
||||||
<auth-method>KEYCLOAK</auth-method>
|
|
||||||
<realm-name>demo</realm-name>
|
|
||||||
</login-config>
|
|
||||||
|
|
||||||
<security-role>
|
|
||||||
<role-name>admin</role-name>
|
|
||||||
</security-role>
|
|
||||||
<security-role>
|
|
||||||
<role-name>user</role-name>
|
|
||||||
</security-role>
|
|
||||||
|
|
||||||
</web-app>
|
|
|
@ -1 +0,0 @@
|
||||||
<h1>This would be the admin page for the UPS admin console.</h1>
|
|
|
@ -1,13 +0,0 @@
|
||||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
|
||||||
"http://www.w3.org/TR/html4/loose.dtd">
|
|
||||||
<html>
|
|
||||||
<head>
|
|
||||||
<title></title>
|
|
||||||
</head>
|
|
||||||
<body bgcolor="#E3F6CE">
|
|
||||||
<h1>Aerogear UPS Portal</h1>
|
|
||||||
|
|
||||||
<p><a href="ups/view.jsp">Play with Aerogear UPS</a></p>
|
|
||||||
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,13 +0,0 @@
|
||||||
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
|
|
||||||
pageEncoding="ISO-8859-1" %>
|
|
||||||
<html>
|
|
||||||
<head>
|
|
||||||
<title>Aerogear - UPS View Page</title>
|
|
||||||
</head>
|
|
||||||
<body bgcolor="#E3F6CE">
|
|
||||||
|
|
||||||
Protected page...
|
|
||||||
|
|
||||||
<br><br>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,90 +0,0 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
||||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
|
||||||
<parent>
|
|
||||||
<artifactId>keycloak-parent</artifactId>
|
|
||||||
<groupId>org.keycloak</groupId>
|
|
||||||
<version>1.2.0.RC1-SNAPSHOT</version>
|
|
||||||
<relativePath>../../../pom.xml</relativePath>
|
|
||||||
</parent>
|
|
||||||
|
|
||||||
<modelVersion>4.0.0</modelVersion>
|
|
||||||
<artifactId>ups-auth-server</artifactId>
|
|
||||||
<packaging>war</packaging>
|
|
||||||
<name>UPS Auth Server</name>
|
|
||||||
<description/>
|
|
||||||
|
|
||||||
<dependencies>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.keycloak</groupId>
|
|
||||||
<artifactId>keycloak-dependencies-server-min</artifactId>
|
|
||||||
<type>pom</type>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.jboss.resteasy</groupId>
|
|
||||||
<artifactId>resteasy-jaxrs</artifactId>
|
|
||||||
<scope>provided</scope>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.jboss.spec.javax.servlet</groupId>
|
|
||||||
<artifactId>jboss-servlet-api_3.0_spec</artifactId>
|
|
||||||
<scope>provided</scope>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.keycloak</groupId>
|
|
||||||
<artifactId>keycloak-connections-jpa</artifactId>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.keycloak</groupId>
|
|
||||||
<artifactId>keycloak-connections-jpa-liquibase</artifactId>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.keycloak</groupId>
|
|
||||||
<artifactId>keycloak-model-jpa</artifactId>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.keycloak</groupId>
|
|
||||||
<artifactId>keycloak-model-sessions-mem</artifactId>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.keycloak</groupId>
|
|
||||||
<artifactId>keycloak-model-sessions-jpa</artifactId>
|
|
||||||
</dependency>
|
|
||||||
</dependencies>
|
|
||||||
|
|
||||||
<build>
|
|
||||||
<finalName>auth-server</finalName>
|
|
||||||
<plugins>
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.jboss.as.plugins</groupId>
|
|
||||||
<artifactId>jboss-as-maven-plugin</artifactId>
|
|
||||||
<configuration>
|
|
||||||
<skip>false</skip>
|
|
||||||
</configuration>
|
|
||||||
</plugin>
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.wildfly.plugins</groupId>
|
|
||||||
<artifactId>wildfly-maven-plugin</artifactId>
|
|
||||||
<configuration>
|
|
||||||
<skip>false</skip>
|
|
||||||
</configuration>
|
|
||||||
</plugin>
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
|
||||||
<artifactId>maven-deploy-plugin</artifactId>
|
|
||||||
<configuration>
|
|
||||||
<skip>true</skip>
|
|
||||||
</configuration>
|
|
||||||
</plugin>
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
|
||||||
<artifactId>maven-compiler-plugin</artifactId>
|
|
||||||
<configuration>
|
|
||||||
<source>${maven.compiler.source}</source>
|
|
||||||
<target>${maven.compiler.target}</target>
|
|
||||||
</configuration>
|
|
||||||
</plugin>
|
|
||||||
</plugins>
|
|
||||||
</build>
|
|
||||||
</project>
|
|
|
@ -1,41 +0,0 @@
|
||||||
package org.aerogear.ups.security;
|
|
||||||
|
|
||||||
import org.jboss.resteasy.core.Dispatcher;
|
|
||||||
import org.keycloak.models.KeycloakSession;
|
|
||||||
import org.keycloak.models.RealmModel;
|
|
||||||
import org.keycloak.models.UserModel;
|
|
||||||
import org.keycloak.services.managers.RealmManager;
|
|
||||||
import org.keycloak.services.resources.KeycloakApplication;
|
|
||||||
|
|
||||||
import javax.servlet.ServletContext;
|
|
||||||
import javax.ws.rs.core.Context;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @author <a href="mailto:bill@burkecentral.com">Bill Burke</a>
|
|
||||||
* @version $Revision: 1 $
|
|
||||||
*/
|
|
||||||
public class UpsSecurityApplication extends KeycloakApplication {
|
|
||||||
public UpsSecurityApplication(@Context ServletContext context, @Context Dispatcher dispatcher) {
|
|
||||||
super(context, dispatcher);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
protected void setupDefaultRealm(String contextPath) {
|
|
||||||
super.setupDefaultRealm(contextPath);
|
|
||||||
|
|
||||||
KeycloakSession session = sessionFactory.create();
|
|
||||||
session.getTransaction().begin();
|
|
||||||
|
|
||||||
// disable master realm by deleting the admin user.
|
|
||||||
try {
|
|
||||||
RealmManager manager = new RealmManager(session);
|
|
||||||
RealmModel master = manager.getKeycloakAdminstrationRealm();
|
|
||||||
UserModel admin = session.users().getUserByUsername("admin", master);
|
|
||||||
if (admin != null) session.users().removeUser(master, admin);
|
|
||||||
session.getTransaction().commit();
|
|
||||||
} finally {
|
|
||||||
session.close();
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,65 +0,0 @@
|
||||||
{
|
|
||||||
"admin": {
|
|
||||||
"realm": "master"
|
|
||||||
},
|
|
||||||
|
|
||||||
"realm": {
|
|
||||||
"provider": "jpa"
|
|
||||||
},
|
|
||||||
|
|
||||||
"user": {
|
|
||||||
"provider": "jpa"
|
|
||||||
},
|
|
||||||
|
|
||||||
"userSessions": {
|
|
||||||
"provider" : "mem"
|
|
||||||
},
|
|
||||||
|
|
||||||
"realmCache": {
|
|
||||||
"provider": "mem"
|
|
||||||
},
|
|
||||||
|
|
||||||
"userCache": {
|
|
||||||
"provider": "mem",
|
|
||||||
"mem": {
|
|
||||||
"maxSize": 20000
|
|
||||||
}
|
|
||||||
},
|
|
||||||
|
|
||||||
"timer": {
|
|
||||||
"provider": "basic"
|
|
||||||
},
|
|
||||||
|
|
||||||
"theme": {
|
|
||||||
"default": "keycloak",
|
|
||||||
"staticMaxAge": 2592000,
|
|
||||||
"cacheTemplates": true,
|
|
||||||
"cacheThemes": true,
|
|
||||||
"folder": {
|
|
||||||
"dir": "${jboss.server.config.dir}/themes"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
|
|
||||||
"login": {
|
|
||||||
"provider": "freemarker"
|
|
||||||
},
|
|
||||||
|
|
||||||
"account": {
|
|
||||||
"provider": "freemarker"
|
|
||||||
},
|
|
||||||
|
|
||||||
"email": {
|
|
||||||
"provider": "freemarker"
|
|
||||||
},
|
|
||||||
|
|
||||||
"scheduled": {
|
|
||||||
"interval": 900
|
|
||||||
},
|
|
||||||
|
|
||||||
"connectionsJpa": {
|
|
||||||
"default": {
|
|
||||||
"dataSource": "java:jboss/datasources/ExampleDS",
|
|
||||||
"databaseSchema": "update"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,6 +0,0 @@
|
||||||
{
|
|
||||||
"themes": [{
|
|
||||||
"name" : "aerogear",
|
|
||||||
"types": [ "admin", "account", "login" ]
|
|
||||||
}]
|
|
||||||
}
|
|
|
@ -1,8 +0,0 @@
|
||||||
.navbar-title {
|
|
||||||
background-image: url('../img/logo.png');
|
|
||||||
height: 65px;
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
width: 203px;
|
|
||||||
margin: 3px 10px 5px;
|
|
||||||
text-indent: -99999px;
|
|
||||||
}
|
|
Binary file not shown.
Before Width: | Height: | Size: 6.2 KiB |
|
@ -1,4 +0,0 @@
|
||||||
parent=keycloak
|
|
||||||
import=common/keycloak
|
|
||||||
|
|
||||||
styles= ../patternfly/lib/patternfly/css/patternfly.css ../patternfly/css/account.css ../keycloak/css/account.css css/account.css
|
|
|
@ -1,45 +0,0 @@
|
||||||
@import url("../lib/patternfly/css/patternfly.css");
|
|
||||||
@import url("../lib/select2-3.4.1/select2.css");
|
|
||||||
|
|
||||||
@import url("admin-console.css");
|
|
||||||
@import url("tables.css");
|
|
||||||
@import url("sprites.css");
|
|
||||||
|
|
||||||
.navbar-pf {
|
|
||||||
background-image: url('../img/header-bkgrnd.png');
|
|
||||||
border-top: 3px solid rgba(255, 255, 255, 0.15);
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-pf .navbar-primary {
|
|
||||||
font-size: 13px;
|
|
||||||
background-image: -webkit-linear-gradient(top, rgba(0,0,0,0.1) 0%, rgba(0,0,0,.4) 100%);
|
|
||||||
background-image: linear-gradient(to bottom, rgba(0,0,0,.1) 0%, rgba(0,0,0,.4) 100%);
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-pf .navbar-header {
|
|
||||||
border-bottom: 1px solid rgba(255,255,255,.15);
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-pf .navbar-primary li.dropdown.context > a,
|
|
||||||
.navbar-pf .navbar-primary li.dropdown.context > a:hover,
|
|
||||||
.navbar-pf .navbar-primary li.dropdown.context.open > a,
|
|
||||||
.navbar-pf .navbar-primary > .active > a,
|
|
||||||
.navbar-pf .navbar-primary > .active > a:hover{
|
|
||||||
background-color: rgba(0,0,0,0.1);
|
|
||||||
background-image: -webkit-linear-gradient(top, rgba(0,0,0,0.1) 0%, rgba(0,0,0,0.1) 100%);
|
|
||||||
background-image: linear-gradient(to bottom, rgba(0,0,0,0.1) 0%, rgba(0,0,0,0.1) 100%);
|
|
||||||
border-bottom: none;
|
|
||||||
border-right-color: rgba(255,255,255,0.15);
|
|
||||||
border-top-color: rgba(255,255,255,0.05);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* this is what I added */
|
|
||||||
|
|
||||||
.navbar-title {
|
|
||||||
background-image: url('../img/logo.png');
|
|
||||||
height: 65px;
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
width: 203px;
|
|
||||||
margin: 3px 10px 5px;
|
|
||||||
text-indent: -99999px;
|
|
||||||
}
|
|
Binary file not shown.
Before Width: | Height: | Size: 6.2 KiB |
|
@ -1,4 +0,0 @@
|
||||||
parent=keycloak
|
|
||||||
import=common/keycloak
|
|
||||||
|
|
||||||
styles= ../keycloak/css/styles.css css/styles.css
|
|
|
@ -1,9 +0,0 @@
|
||||||
#kc-logo-wrapper {
|
|
||||||
background-image: url("../img/logo.png");
|
|
||||||
background-repeat: no-repeat;
|
|
||||||
background-position: top right;
|
|
||||||
|
|
||||||
height: 65px;
|
|
||||||
|
|
||||||
margin: 100px;
|
|
||||||
}
|
|
Binary file not shown.
Before Width: | Height: | Size: 6.2 KiB |
|
@ -1,4 +0,0 @@
|
||||||
parent=keycloak
|
|
||||||
import=common/keycloak
|
|
||||||
|
|
||||||
styles= ../patternfly/lib/patternfly/css/patternfly.css ../patternfly/css/login.css ../patternfly/lib/zocial/zocial.css ../keycloak/css/login.css css/login.css
|
|
|
@ -1,23 +0,0 @@
|
||||||
<jboss-deployment-structure>
|
|
||||||
<deployment>
|
|
||||||
<dependencies>
|
|
||||||
<module name="org.apache.httpcomponents"/>
|
|
||||||
<module name="org.jboss.resteasy.resteasy-jackson-provider" services="import"/>
|
|
||||||
<module name="org.codehaus.jackson.jackson-core-asl"/>
|
|
||||||
<module name="org.codehaus.jackson.jackson-mapper-asl"/>
|
|
||||||
<module name="org.infinispan"/>
|
|
||||||
</dependencies>
|
|
||||||
<exclusions>
|
|
||||||
<module name="org.jboss.resteasy.resteasy-jackson2-provider"/>
|
|
||||||
|
|
||||||
<!-- Exclude keycloak modules -->
|
|
||||||
<module name="org.keycloak.keycloak-core" />
|
|
||||||
<module name="org.keycloak.keycloak-adapter-core" />
|
|
||||||
<module name="org.keycloak.keycloak-undertow-adapter" />
|
|
||||||
<module name="org.keycloak.keycloak-as7-adapter" />
|
|
||||||
</exclusions>
|
|
||||||
<exclude-subsystems>
|
|
||||||
<subsystem name="webservices"/>
|
|
||||||
</exclude-subsystems>
|
|
||||||
</deployment>
|
|
||||||
</jboss-deployment-structure>
|
|
|
@ -1,80 +0,0 @@
|
||||||
{
|
|
||||||
"realm": "aerogear",
|
|
||||||
"enabled": true,
|
|
||||||
"accessTokenLifespan": 3000,
|
|
||||||
"accessCodeLifespan": 10,
|
|
||||||
"accessCodeLifespanUserAction": 6000,
|
|
||||||
"sslRequired": "external",
|
|
||||||
"registrationAllowed": false,
|
|
||||||
"adminTheme": "aerogear",
|
|
||||||
"accountTheme": "aerogear",
|
|
||||||
"loginTheme": "aerogear",
|
|
||||||
"requiredCredentials": [ "password" ],
|
|
||||||
"users" : [
|
|
||||||
{
|
|
||||||
"username" : "bburke@redhat.com",
|
|
||||||
"enabled": true,
|
|
||||||
"email" : "bburke@redhat.com",
|
|
||||||
"firstName": "Bill",
|
|
||||||
"lastName": "Burke",
|
|
||||||
"credentials" : [
|
|
||||||
{ "type" : "password",
|
|
||||||
"value" : "password" }
|
|
||||||
],
|
|
||||||
"realmRoles": [ "user" ],
|
|
||||||
"applicationRoles": {
|
|
||||||
"account": [ "manage-account" ]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"username" : "admin",
|
|
||||||
"enabled": true,
|
|
||||||
"firstName": "Meister",
|
|
||||||
"lastName": "Burke",
|
|
||||||
"credentials" : [
|
|
||||||
{ "type" : "password",
|
|
||||||
"value" : "admin" }
|
|
||||||
],
|
|
||||||
"requiredActions": [
|
|
||||||
"UPDATE_PASSWORD"
|
|
||||||
],
|
|
||||||
"realmRoles": [ "user","admin" ],
|
|
||||||
"applicationRoles": {
|
|
||||||
"realm-management": [ "realm-admin" ],
|
|
||||||
"account": [ "manage-account" ]
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"roles" : {
|
|
||||||
"realm" : [
|
|
||||||
{
|
|
||||||
"name": "user",
|
|
||||||
"description": "User privileges"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "admin",
|
|
||||||
"description": "Administrator privileges"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"scopeMappings": [
|
|
||||||
{
|
|
||||||
"client": "unified-push-server",
|
|
||||||
"roles": ["user", "admin"]
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"applications": [
|
|
||||||
{
|
|
||||||
"name": "unified-push-server",
|
|
||||||
"enabled": true,
|
|
||||||
"publicClient": true,
|
|
||||||
"adminUrl": "/aerogear-ups",
|
|
||||||
"baseUrl": "/aerogear-ups",
|
|
||||||
"redirectUris": [
|
|
||||||
"/aerogear-ups/*"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
]
|
|
||||||
|
|
||||||
}
|
|
|
@ -1,71 +0,0 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<web-app xmlns="http://java.sun.com/xml/ns/javaee"
|
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
||||||
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"
|
|
||||||
version="3.0">
|
|
||||||
|
|
||||||
<module-name>auth</module-name>
|
|
||||||
|
|
||||||
<context-param>
|
|
||||||
<param-name>keycloak.import.realm.resources</param-name>
|
|
||||||
<param-value>/WEB-INF/testrealm.json</param-value>
|
|
||||||
</context-param>
|
|
||||||
|
|
||||||
<servlet>
|
|
||||||
<servlet-name>Keycloak REST Interface</servlet-name>
|
|
||||||
<servlet-class>org.jboss.resteasy.plugins.server.servlet.HttpServlet30Dispatcher</servlet-class>
|
|
||||||
<init-param>
|
|
||||||
<param-name>javax.ws.rs.Application</param-name>
|
|
||||||
<param-value>org.aerogear.ups.security.UpsSecurityApplication</param-value>
|
|
||||||
</init-param>
|
|
||||||
<init-param>
|
|
||||||
<param-name>resteasy.servlet.mapping.prefix</param-name>
|
|
||||||
<param-value>/</param-value>
|
|
||||||
</init-param>
|
|
||||||
<load-on-startup>1</load-on-startup>
|
|
||||||
<async-supported>true</async-supported>
|
|
||||||
</servlet>
|
|
||||||
|
|
||||||
<listener>
|
|
||||||
<listener-class>org.keycloak.services.listeners.KeycloakSessionDestroyListener</listener-class>
|
|
||||||
</listener>
|
|
||||||
|
|
||||||
<filter>
|
|
||||||
<filter-name>Keycloak Client Connection Filter</filter-name>
|
|
||||||
<filter-class>org.keycloak.services.filters.ClientConnectionFilter</filter-class>
|
|
||||||
</filter>
|
|
||||||
|
|
||||||
<filter>
|
|
||||||
<filter-name>Keycloak Session Management</filter-name>
|
|
||||||
<filter-class>org.keycloak.services.filters.KeycloakSessionServletFilter</filter-class>
|
|
||||||
</filter>
|
|
||||||
|
|
||||||
<filter-mapping>
|
|
||||||
<filter-name>Keycloak Session Management</filter-name>
|
|
||||||
<url-pattern>/*</url-pattern>
|
|
||||||
</filter-mapping>
|
|
||||||
|
|
||||||
<filter-mapping>
|
|
||||||
<filter-name>Keycloak Client Connection Filter</filter-name>
|
|
||||||
<url-pattern>/*</url-pattern>
|
|
||||||
</filter-mapping>
|
|
||||||
|
|
||||||
<servlet-mapping>
|
|
||||||
<servlet-name>Keycloak REST Interface</servlet-name>
|
|
||||||
<url-pattern>/*</url-pattern>
|
|
||||||
</servlet-mapping>
|
|
||||||
|
|
||||||
<!--
|
|
||||||
|
|
||||||
<security-constraint>
|
|
||||||
<web-resource-collection>
|
|
||||||
<url-pattern>/*</url-pattern>
|
|
||||||
</web-resource-collection>
|
|
||||||
<user-data-constraint>
|
|
||||||
<transport-guarantee>CONFIDENTIAL</transport-guarantee>
|
|
||||||
</user-data-constraint>
|
|
||||||
</security-constraint>
|
|
||||||
-->
|
|
||||||
|
|
||||||
|
|
||||||
</web-app>
|
|
|
@ -1,31 +0,0 @@
|
||||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
||||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
|
||||||
<parent>
|
|
||||||
<artifactId>keycloak-parent</artifactId>
|
|
||||||
<groupId>org.keycloak</groupId>
|
|
||||||
<version>1.2.0.RC1-SNAPSHOT</version>
|
|
||||||
<relativePath>../../pom.xml</relativePath>
|
|
||||||
</parent>
|
|
||||||
<name>Aerogear UPS Parent</name>
|
|
||||||
<description/>
|
|
||||||
<modelVersion>4.0.0</modelVersion>
|
|
||||||
|
|
||||||
<artifactId>aerogear-ups-project-integrations-pom</artifactId>
|
|
||||||
<packaging>pom</packaging>
|
|
||||||
|
|
||||||
<build>
|
|
||||||
<plugins>
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
|
||||||
<artifactId>maven-deploy-plugin</artifactId>
|
|
||||||
<configuration>
|
|
||||||
<skip>true</skip>
|
|
||||||
</configuration>
|
|
||||||
</plugin>
|
|
||||||
</plugins>
|
|
||||||
</build>
|
|
||||||
<modules>
|
|
||||||
<module>auth-server</module>
|
|
||||||
<module>app</module>
|
|
||||||
</modules>
|
|
||||||
</project>
|
|
|
@ -1,30 +0,0 @@
|
||||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
||||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
|
|
||||||
<parent>
|
|
||||||
<artifactId>keycloak-parent</artifactId>
|
|
||||||
<groupId>org.keycloak</groupId>
|
|
||||||
<version>1.2.0.RC1-SNAPSHOT</version>
|
|
||||||
<relativePath>../pom.xml</relativePath>
|
|
||||||
</parent>
|
|
||||||
<name>Third-party Integration Parent</name>
|
|
||||||
<description/>
|
|
||||||
<modelVersion>4.0.0</modelVersion>
|
|
||||||
|
|
||||||
<artifactId>keycloak-project-integrations-pom</artifactId>
|
|
||||||
<packaging>pom</packaging>
|
|
||||||
|
|
||||||
<build>
|
|
||||||
<plugins>
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
|
||||||
<artifactId>maven-deploy-plugin</artifactId>
|
|
||||||
<configuration>
|
|
||||||
<skip>true</skip>
|
|
||||||
</configuration>
|
|
||||||
</plugin>
|
|
||||||
</plugins>
|
|
||||||
</build>
|
|
||||||
<modules>
|
|
||||||
<module>aerogear-ups</module>
|
|
||||||
</modules>
|
|
||||||
</project>
|
|
Loading…
Reference in a new issue