X509UsernameRetriever (Apache Tomcat 10.1.2 API Documentation)

Package org.apache.catalina.realm

## Interface X509UsernameRetriever

- All Known Implementing Classes:
    `X509SubjectDnRetriever`

      public interface X509UsernameRetriever

  Provides an interface for retrieving a user name from an X509Certificate.

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `String` | `getUsername​(X509Certificate cert)` | Gets a user name from an X509Certificate.

- - ### Method Detail

    - #### getUsername

          String getUsername​(X509Certificate cert)

      Gets a user name from an X509Certificate.
      Parameters:
        `cert` - The certificate containing the user name.
      Returns:
        An appropriate user name obtained from one or more fields in the certificate.