Compare commits
7 commits
d38c4ab6a6
...
149d98f90e
| Author | SHA1 | Date | |
|---|---|---|---|
| 149d98f90e | |||
| 1c2adb1a92 | |||
| cd31ec8a20 | |||
| a540e63bf3 | |||
| 9073ef086a | |||
| 464c02dfb0 | |||
| 2c3c0a3dab |
5 changed files with 27 additions and 27 deletions
|
|
@ -1,12 +1,10 @@
|
|||
on:
|
||||
pull_request:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
ansible-lint:
|
||||
name: Verify
|
||||
test:
|
||||
name: Test
|
||||
runs-on: docker
|
||||
steps:
|
||||
- uses: actions/checkout@v7
|
||||
|
|
@ -14,6 +12,6 @@ jobs:
|
|||
run: |
|
||||
apt update
|
||||
apt install -y maven
|
||||
- name: Run maven verify
|
||||
- name: Run maven verify test
|
||||
run: |
|
||||
mvn -f attribute-endpoints-provider --batch-mode --no-transfer-progress verify
|
||||
mvn -f attribute-endpoints-provider verify test
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
# Attribute Endpoints Provider - Export User Attributes
|
||||
|
||||
This is a Keycloak Provider that exports user profile attribute values.
|
||||
The selection of attributes and authorization is managed through an endpoint configuration in the Keycloak admin website.
|
||||
The selection of attributes and authorization is manage through an endpoint configuration.
|
||||
|
||||
## Usage
|
||||
|
||||
|
|
@ -43,7 +43,7 @@ Once all dependencies are met, simply call `make` to build the provider, which s
|
|||
|
||||
There's also `make clean` available for removing the output directory.
|
||||
|
||||
To add the provider to your Keycloak install, copy `attribute-endpoints-provider/target/attribute-endpoints-provider-1.0-SNAPSHOT.jar` to the Keycloak Provider directory (`/opt/keycloak/providers/`).
|
||||
To add the provider to your Keycloak install, copy `attribute-endpoints-provider/target/attribute-endpoints-provider-1.0-SNAPSHOT.jar` to the Keycloak Provider directory (`/opt/keycloak/providers/).
|
||||
|
||||
## Testing Setup
|
||||
|
||||
|
|
|
|||
|
|
@ -128,7 +128,6 @@ public class AdminUiPage implements UiPageProvider, UiPageProviderFactory<Compon
|
|||
.add()
|
||||
|
||||
.property()
|
||||
// keep old name for backwards compatibility
|
||||
.name("attribute-group")
|
||||
.label("Attribute Name or Group")
|
||||
.helpText("The attribute or attribute group to export.")
|
||||
|
|
|
|||
|
|
@ -1,35 +1,36 @@
|
|||
package de.ccc.hamburg.keycloak.attribute_endpoints;
|
||||
|
||||
import com.google.auto.service.AutoService;
|
||||
import org.keycloak.Config;
|
||||
import org.keycloak.models.KeycloakSession;
|
||||
import org.keycloak.models.KeycloakSessionFactory;
|
||||
import org.keycloak.services.resource.RealmResourceProvider;
|
||||
import org.keycloak.services.resource.RealmResourceProviderFactory;
|
||||
|
||||
import com.google.auto.service.AutoService;
|
||||
|
||||
@AutoService(RealmResourceProviderFactory.class)
|
||||
public class AttributeEndpointsResourceProviderFactory implements RealmResourceProviderFactory {
|
||||
static final String PROVIDER_ID = "attribute-endpoints-provider";
|
||||
|
||||
@Override
|
||||
public RealmResourceProvider create(KeycloakSession keycloakSession) {
|
||||
return new AttributeEndpointsResourceProvider(keycloakSession);
|
||||
}
|
||||
public RealmResourceProvider create(KeycloakSession keycloakSession) {
|
||||
return new AttributeEndpointsResourceProvider(keycloakSession);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void init(Config.Scope config) {
|
||||
}
|
||||
@Override
|
||||
public void init(Config.Scope config) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void postInit(KeycloakSessionFactory keycloakSessionFactory) {
|
||||
}
|
||||
@Override
|
||||
public void postInit(KeycloakSessionFactory keycloakSessionFactory) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void close() {
|
||||
}
|
||||
@Override
|
||||
public void close() {
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getId() {
|
||||
return PROVIDER_ID;
|
||||
}
|
||||
@Override
|
||||
public String getId() {
|
||||
return PROVIDER_ID;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,7 +24,9 @@ import java.util.Map;
|
|||
import java.util.function.Supplier;
|
||||
import java.util.stream.Stream;
|
||||
|
||||
import static org.junit.Assert.*;
|
||||
import static org.junit.Assert.assertEquals;
|
||||
import static org.junit.Assert.assertThrows;
|
||||
import static org.junit.Assert.assertTrue;
|
||||
import static org.mockito.ArgumentMatchers.*;
|
||||
import static org.mockito.Mockito.mock;
|
||||
import static org.mockito.Mockito.when;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue