Ejemplo n.º 1
0
  @Override
  public RequestSecurityTokenResponseType renew(String tenantName, Request req) {
    assert tenantName != null;
    assert req != null;

    STS sts = stsFactory.getSTS(tenantName);
    try {
      return sts.renew(req);
    } catch (InvalidSignatureException e) {
      throw new InvalidCredentialsException(e.getMessage(), e);
    }
  }
Ejemplo n.º 2
0
  @Override
  public RequestSecurityTokenResponseCollectionType challenge(
      String tenantName,
      RequestSecurityTokenResponseType requestSecurityTokenResponse,
      SecurityHeaderType headerInfo) {
    assert tenantName != null;
    assert requestSecurityTokenResponse != null;
    assert headerInfo != null;

    STS sts = stsFactory.getSTS(tenantName);
    try {
      return sts.challenge(requestSecurityTokenResponse, headerInfo);
    } catch (InvalidSignatureException e) {
      throw new InvalidCredentialsException(e.getMessage(), e);
    }
  }