Skip to content

Translation Phrases Editor

The CEP includes a user-friendly phrase editor for modifying translation phrases. This feature can be activated by adding a parameter to grant access to specific users or groups. Additionally, it is essential to configure a directory in the container configuration (docker-compose.yml) to ensure that the modifications are saved persistently. If you have previously customized translation phrases, the editor will display these phrases for further modification if they are stored in the custom-translation directory.

How To Switch Languages

To switch languages in the editor, you need to adjust the order of preferred languages in your browser settings. The interface will consistently display the language that is currently set as the preferred language for the CEP.

Advantages Of Using Placeholders

Many translation phrases utilize placeholders that are automatically substituted with custom names retrieved from the AA API and configured names of the used token hardware. We do not recommend replacing these placeholders with custom text. Instead, it is advisable to make dynamic replacements in the AA configuration for these placeholders. This approach will not only save you time and resources when customizing the translation and wording of the CEP but also ensure a consistent and unified language across your entire authentication environment.

Configuration

You can include an additional environment file in your existing configuration. In this example, we've introduced "translator.env" to the configuration. We've enabled access for the user "REPO_NAME\user1234" as well as all users in the group "CN=GroupName,CN=Users,DC=cep,DC=corp" to access the translation interface.

docker-compose.yml
version: "3.5"
services:
  cep:
    image: registry.example.com/aaf/MY-cep:latest
    container_name: cep
    volumes:
      - aaf_webd-config:/etc/nginx/certs:ro
      # This line mounts the "custom-translation" directory into the container.
      # If you have existing custom messages, translation files should be stored within this directory.
      - ${PWD}/custom-translation:/var/www/html/translations/custom:rw
    restart: unless-stopped
    ports:
      - "8443:443"
    env_file:      
      - base.env
      - translator.env
      - language.env
volumes:
 aaf_webd-config:
   external: true
language.env
CEP_ENABLED_LANGUAGES=["en", "de", "fr", "es"]
CEP_DEFAULT_LANGUAGE=en
translator.env
CEP_CUSTOMIZER_USERS=["REPO_NAME\\user1234"]
CEP_CUSTOMIZER_GROUPS=["CN=Grouname,CN=Users,DC=cep,DC=corp"]

Note

It you use the CEP_CUSTOMIZER_GROUPS parameter is necessary to enable the "Return groups on logon" option in the "Authenticators Management" event. Otherwise, AA will not provide group-related information for the CEP.

Make Changes To Your Custom Translation

Below, you can see the translated welcome message for the portal login. Modified messages will be displayed in green, with the original English translation shown below. By clicking the reset button, the message will be deleted from the custom translation, and the original translation will be restored.

Translated message

Clear Application Cache

To make your changes visible to users, you can either restart the container or clear the cache using the following command line.

  docker exec cep /usr/bin/cep-clearcache