Karaf as identity provider
The Apache Karaf comes with a simple authentication service that is also used to access the Karaf console.
|
When the BPC is initially started (or at every start if not available), a Backend Connection is automatically created for the Karaf as IdP.
This has the module name |
|
Access to the Karaf console is always via the Karaf Identity Provider (IdP), regardless of the configuration of the BPC. Only the |
Configuration
A new Backend Connection of type identity_provider is created.
The following values must be set there:
| Setting (Key) | Group | Value | Description |
|---|---|---|---|
Module_Name |
module |
idp-karaf |
Assign a descriptive and unique name |
IdentityProvider |
config |
karaf |
Set the Karaf as identity provider |
Data source (JAAS file)
The authentication and administration of users for access to the Karaf console is carried out via Java Authentication and AdministrationConsole is carried out via Java Authentication and Authorization Service (JAAS) files. These files, in particular users.properties and keys.properties, make it possible to define users and determine their access authorizations. Authentication can be configured using both password hashes and public/private key procedures.
Using users.properties for Karaf access
The users are controlled via the KARAF_HOME/etc/users.properties file.
The passwords are stored in the file as hashes in the format {CRYPT}Passwort-Hash{CRYPT}.
The plain text password cannot be reconstructed from the password hash.
To change the password, {CRYPT}Passwort-Hash{CRYPT} must be completely replaced by a plain text password.
Care must be taken to ensure that the {CRYPT} elements are also removed (see also the following examples).
The new password is effective immediately after saving the file and is then automatically replaced by a hash.
users.properties File with password hashesbpcadmin = {CRYPT}XYZ{CRYPT},bpcadmin
virtimo = {CRYPT}XYZ{CRYPT},_g_:admingroup,bpcNoFrontend
_g_\:admingroup = group,admin,manager,viewer,systembundles,ssh
users.properties File with plain text passwordsbpcadmin = einSehrSicheresPasswort123,bpcadmin
virtimo = einAnderesSehrSicheresPasswort123,_g_:admingroup,bpcNoFrontend
_g_\:admingroup = group,admin,manager,viewer,systembundles,ssh
|
If the syntax of the file is not adhered to, authentication is not possible and leads to an |
Use of keys.properties for Karaf access
In addition to users.properties, keys.properties can also be used to authenticate users with SSH keys. This defines which users have access via SSH keys, which provides additional security.
See Karaf SSH access.