Package javax.security.auth.message

## Interface ServerAuth

- All Known Subinterfaces:
    `ServerAuthContext`, `ServerAuthModule`

      public interface ServerAuth

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `void` | `cleanSubject​(MessageInfo messageInfo, javax.security.auth.Subject subject)` | Remove principals and/or credentials from the subject that were previously added by this authentication mechanism.
    `AuthStatus` | `secureResponse​(MessageInfo messageInfo, javax.security.auth.Subject serviceSubject)` | Secure (authenticate) the response.
    `AuthStatus` | `validateRequest​(MessageInfo messageInfo, javax.security.auth.Subject clientSubject, javax.security.auth.Subject serviceSubject)` | Validate the request.

- - ### Method Detail

    - #### validateRequest

          AuthStatus validateRequest​(MessageInfo messageInfo,
                                     javax.security.auth.Subject clientSubject,
                                     javax.security.auth.Subject serviceSubject)
                              throws AuthException

      Validate the request.
      Parameters:
        `messageInfo` - The associated request and response
        `clientSubject` - The subject that represents the source of the request
        `serviceSubject` - The subject that represents the recipient of the request
      Returns:
        An AuthStatus instance that represents the result of the validation
      Throws:
        `AuthException` - If the a failure occurred in a manner that prevented the failure from being communicated via messageInfo

    - #### secureResponse

          AuthStatus secureResponse​(MessageInfo messageInfo,
                                    javax.security.auth.Subject serviceSubject)
                             throws AuthException

      Secure (authenticate) the response.
      Parameters:
        `messageInfo` - The associated request and response
        `serviceSubject` - The subject that represents the source of the response
      Returns:
        An AuthStatus instance that represents the result of the authentication
      Throws:
        `AuthException` - If the a failure occurred in a manner that prevented the failure from being communicated via messageInfo

    - #### cleanSubject

          void cleanSubject​(MessageInfo messageInfo,
                            javax.security.auth.Subject subject)
                     throws AuthException

      Remove principals and/or credentials from the subject that were previously added by this authentication mechanism.
      Parameters:
        `messageInfo` - The associated request and response
        `subject` - The subject to clean
      Throws:
        `AuthException` - If the a failure occurred