Module iu.util.auth
Package edu.iu.auth

Interface IuPrincipalIdentity

All Superinterfaces:
Principal
All Known Subinterfaces:
IuApiCredentials, IuBasicAuthCredentials
All Known Implementing Classes:
PkiPrincipal

public interface IuPrincipalIdentity extends Principal
Designates an authenticated principal identity.
  • Method Summary

    Modifier and Type
    Method
    Description
    Gets the point in time the principal's credentials were verified by the authentication provider.
    Gets the point in time after which the principal's authenticated session is expired.
    Gets the point in time proof of principal identity was issued by an authentication provider.
    Gets a subject including this principal, related principals, and implied credentials.
    default boolean
    implies(Subject subject)
     
    static boolean
    Verifies that a principal identity was issued by a registered identity provider for an authentication realm.

    Methods inherited from interface java.security.Principal

    equals, getName, hashCode, toString
  • Method Details

    • verify

      static boolean verify(IuPrincipalIdentity id, String realm) throws IuAuthenticationException
      Verifies that a principal identity was issued by a registered identity provider for an authentication realm.
      Parameters:
      id - principal identity
      realm - authentication realm
      Returns:
      true if verification was successful and the authorization module is considered authoritative for the authentication realm; false if verification was successful but based solely on well-known information about the authentication provider.
      Throws:
      IuAuthenticationException - If credentials could not be verified
    • getIssuedAt

      Instant getIssuedAt()
      Gets the point in time proof of principal identity was issued by an authentication provider.
      Returns:
      Instant
    • getAuthTime

      Instant getAuthTime()
      Gets the point in time the principal's credentials were verified by the authentication provider.
      Returns:
      Instant
    • getExpires

      Instant getExpires()
      Gets the point in time after which the principal's authenticated session is expired.
      Returns:
      Instant
    • getSubject

      Subject getSubject()
      Gets a subject including this principal, related principals, and implied credentials.
      Returns:
      Subject
    • implies

      default boolean implies(Subject subject)
      Specified by:
      implies in interface Principal