MessagesTranslation

MessagesTranslation

Overview

The Identity Provider software and its various pugins contain by default US English messages.properties file(s) that contain the strings to render messages in the various views included in the software. In addition, the built-in attribute registry rules define names and descriptions of many standardized Attributes.

Many deployers may want to present this information in the local language(s) or customize/localize some strings. To translate or adapt the IdP messages and thus support multiple languages, the IdP supports translations of the corresponding message files. The servlet container will then automatically select a matching message file based on the client's Accept-Languages header as provided by the web browser. The attribute metadata is, by contrast, directly embedded in the various default rule files we include.

Managing Translations

With the move to Codeberg, we can now support pull requests in a “typical” way for those wishing to contribute or correct translations. While this is not a complete summary, it illustrates where most of the messages are and where you can generally find them in most plugins. You can always check out the code or search Codeberg for messages.properties within a project and you will locate the proper directory.

Within each module, the relevant path lives under src/main/resources/

Software

Module Path

Message Location

Attribute Metadata Location

Software

Module Path

Message Location

Attribute Metadata Location

Identity Provider

idp-conf-impl

/net/shibboleth/idp/messages/

/net/shibboleth/idp/module/conf/attributes/

DuoOIDC Plugin

idp-duo-impl

/net/shibboleth/idp/plugin/authn/duo/

 

TOTP Plugin

totp-impl

/net/shibboleth/idp/plugin/authn/totp/

 

WebAuthn Plugin

webauthn-impl

/net/shibboleth/idp/plugin/authn/webauthn/

 

OIDC OP

idp-oidc-extension-impl

 

/net/shibboleth/idp/plugin/oidc/op/conf/attributes/

OIDC RP

idp-oidc-rp-impl

 

/net/shibboleth/idp/plugin/authn/oidc/rp/conf/attributes

Notably, while message translations can generally be added to existing installs automatically during upgrades, as they’re internal, changes to attribute metadata require deployer action, as updated versions of those files are created alongside the “existing” files.

Also note that the final two are actually duplicate copies of a file that will be moving to a single plugin later.

Messages

For example, to create a German translation of the IdP's messages, copy the default (US English) messages file, to a file named messages_de.properties and translate/adapt the strings in the new properties file. For example, one would translate the string idp.title.suffix = Error to idp.title.suffix = Fehler

The IdP will select a language file based on the locale of the browser without additional configuration. Note that Spring (and by extension the IdP) does not support a precedence of languages to fall back to, so the support for full i18n is constrained by that limitation. Also, note that if the browser does not specify a locale to use, the OS default will generally dictate what is selected, so this may or may not be the right answer.

Attributes

The names and descriptions for each default attribute transcoding rule are laid out as property sets in XML syntax in the various default rule files. These can be extended/changed as required, though obviously this means avoiding stepping on others' translations.

Contributing to the Translation Effort

If you want to contribute translations for other languages, please:

  1. Contact us via contact@shibboleth.net (as a courtesy).

  2. Provide any PRs using Codeberg.

  3. Join the i18n list to be aware of impending release schedules or connect to other translators.

Thank you for your interest and help!