"Open Forms extension to use Keycloak access tokens when requesting prefill data from external APIs."
Project description
- Version:
- 0.3.0
- Source:
https://github.com/open-formulieren/open-forms-ext-token-exchange
- Keywords:
Open Forms Extension, Keycloak token exchange
Open Forms extension to use Keycloak access tokens when requesting prefill data from external APIs.
1 Features
Signal receiver which extracts the Keycloak access token from the session and caches it.
Pre-request hook that adds a custom authentication class to the request kwargs.
Custom authentication class that performs the token exchange with Keycloak and adds the exchanged token to the Authorization header.
2 Installation
Requirements
Python 3.7 or above
setuptools 30.3.0 or above
Django 3.2
3 Usage
For an explanation of this how this extension works, look at the Open Forms developer documentation.
To see how to build and distribute an image with this extension, look at the Open Forms documentation about building and distributing extensions.
4 Configuration
In the Open Forms Admin, go to Miscellaneous > Token exchange plugin configurations. Click on Add Token exchange plugin configuration and fill in the details:
Select the service for which you want the token authorisation to be performed.
Add the Keycloak audience.
Save the configuration.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file open-forms-ext-token-exchange-0.3.0.tar.gz
.
File metadata
- Download URL: open-forms-ext-token-exchange-0.3.0.tar.gz
- Upload date:
- Size: 7.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3fb4aa2ad4d9e0d99c0ca809a75a2f737746b6289f01f1900867203537a37683 |
|
MD5 | f74214b75a268a7ddf1f9e1045e6b6bf |
|
BLAKE2b-256 | 95e8705a7b51bf2bbc2b52990cec0a10f19d95903c310d2712b529d2a1632207 |
File details
Details for the file open_forms_ext_token_exchange-0.3.0-py3-none-any.whl
.
File metadata
- Download URL: open_forms_ext_token_exchange-0.3.0-py3-none-any.whl
- Upload date:
- Size: 10.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.15
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4fc18f710fb4027acb442d6517250502862e0b76c7f62ab57e0a92a03df80e86 |
|
MD5 | 1d513724243f6b1c985a15cada32c479 |
|
BLAKE2b-256 | a0ff958d0f083ce5ed5266c4cd8d71106d441439a59e454fb50b5aaac75473dd |