Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
titleTargettedTicket

public Interface TargettedTicket
    extends DerivedTicket {

   /**
    * Get the URL to which this ticket will authenticate.
    */
    public URL getTarget();

   /**
    * Get the chain of principals through which authentication has passed
    * in producing this targetted ticket, starting with the most recent principal
    * and leading back to the originally authenticating User.
    */
    public List getPrincipalChain();

}

Code Block
titleTargettedTicketImpl

public Class TargettedTicketImpl implements TargettedTicket {

    private final Date whenCreated = new Date();

    private final ExpirationPolicy expPolicy;

    private final TicketGrantingTicket parent;

    private final URL target;


    public SSOTicket(URL target, TicketGrantingTicket parent, ExpirationPolicy expPolicy) {
       this.target = target;
       this.parent = parent;
       this.expPolicy = expPolicy;
    }

    public boolean isValid() {
         return this.expPolicy.isValid()
             && this.parent.isValid();
    }

    public URL getTarget() {
        return this.target;
    }

}