Class GlobalSecurityManagerRest

java.lang.Object
de.aristaflow.ilm.ws.rest.base.service.AbstractSubResource<GlobalSecurityManagerWebService>
de.aristaflow.ilm.ws.rest.base.security.GlobalSecurityManagerRest

@Produces("application/json") @Consumes("application/json") public class GlobalSecurityManagerRest extends AbstractSubResource<GlobalSecurityManagerWebService>
See Also:
  • Field Details

  • Constructor Details

    • GlobalSecurityManagerRest

      public GlobalSecurityManagerRest(GlobalSecurityManagerWebService service, de.aristaflow.adept2.base.communication.rest.RequestHandler reqHandler, de.aristaflow.adept2.base.communication.rest.ResponseHandler respHandler, de.aristaflow.adept2.base.communication.rest.ExceptionHandler excpHandler, de.aristaflow.adept2.base.communication.rest.ServiceResourceConfig srConf, Supplier<com.fasterxml.jackson.databind.ObjectMapper> objectMapper, UnaryOperator<Exception> headerDataExcpAdapter)
  • Method Details

    • preAuthenticate

      @PUT @Path("/pre-authentication") @Consumes("application/x-www-form-urlencoded") @NotEmpty public @NotEmpty List<@Valid QualifiedAgent> preAuthenticate(@NotBlank @FormParam("userName") @NotBlank String userName, @FormParam("password") String password)
      This method pre-authenticates with either the designated password or the OAuth2 authentication token retrieved from the request header.
    • preAuthenticateMethod

      @PUT @Path("/pre-generic-authentication") @NotEmpty public @NotEmpty List<@Valid QualifiedAgent> preAuthenticateMethod(@NotBlank @QueryParam("method") @NotBlank String method, @NotNull @NotNull AuthenticationData authData)
      See Also:
    • _preAuthenticateMethod

      protected AuthDataOrgPosSpec.QualifiedAgentList _preAuthenticateMethod(String method, AuthenticationData authData)
      Pre-authenticates with the designated ILM authentication data and wraps the result (qualified agents) in a QualifiedAgentList.
    • authenticateCookie

      @PUT @Path("/authentication-cookie") @Consumes("application/x-www-form-urlencoded") @NotNull @Valid public @NotNull @Valid ClientSessionDetails authenticateCookie(@NotBlank @FormParam("userName") @NotBlank String userName, @FormParam("orgPosId") Long orgPosId, @NotNull @FormParam("callerUri") @NotNull URI callerUri, @FormParam("password") String password)
      This method authenticates with either the designated password or the OAuth2 authentication token retrieved from the request header using either the one and only org position the agent has or the designated org position. If no org position is provided and the agent occupies several org positions, an AuthenticationException will be thrown.

      Note that the token in the returned ClientSessionDetails is Base64-URL-encoded (according to RFC 4648, table 2).

    • authenticateMethodCookie

      @PUT @Path("/generic-authentication-cookie") @NotNull @Valid public @NotNull @Valid ClientSessionDetails authenticateMethodCookie(@NotBlank @QueryParam("method") @NotBlank String method, @NotNull @QueryParam("callerUri") @NotNull URI callerUri, @NotNull @NotNull AuthenticationData authData)
      Note that the token in the returned ClientSessionDetails is Base64-URL-encoded (according to RFC 4648, table 2).
      See Also:
    • _authenticateMethodCookie

      protected ClientSessionDetails _authenticateMethodCookie(String method, URI callerUri, AuthenticationData authData)
      Authenticates with the designated ILM authentication data.
    • authenticateAll

      @PUT @Path("/authentication") @Consumes("application/x-www-form-urlencoded") @NotNull public @NotNull List<@Valid ClientSessionDetails> authenticateAll(@NotBlank @FormParam("userName") @NotBlank String userName, @FormParam("orgPosId") Long orgPosId, @NotNull @FormParam("callerUri") @NotNull URI callerUri, @FormParam("password") String password)
      This method authenticates with either the designated password or the OAuth2 authentication token retrieved from the request header using the designated org position or all org positions occupied by the agent if not provided.

      Note that the token in the returned ClientSessionDetails is Base64-URL-encoded (according to RFC 4648, table 2).

    • orgPosSpecified

      protected boolean orgPosSpecified(AuthDataOrgPosSpec ops)
      Gets whether the designated AuthDataOrgPosSpec specifies at least one org position. If not, we usually need to retrieve the one(s) for the provided authentication data.
      Parameters:
      ops - The authentication data possibly referring to one or several org positions. This may be null.
      Returns:
      Whether the designated authentication data specifies at least one org position.
    • authenticateAllMethod

      @PUT @Path("/generic-authentication") @NotNull public @NotNull List<@Valid ClientSessionDetails> authenticateAllMethod(@NotBlank @QueryParam("method") @NotBlank String method, @NotNull @QueryParam("callerUri") @NotNull URI callerUri, @NotNull @NotNull AuthenticationData authData)
      This method authenticates using the designated org position or all org positions occupied by the agent if not provided.

      Note that the token in the returned ClientSessionDetails is Base64-URL-encoded (according to RFC 4648, table 2).

      See Also:
    • _authenticateAllMethod

      protected List<ClientSessionDetails> _authenticateAllMethod(String method, URI callerUri, AuthenticationData authData)
      Authenticates with the designated ILM authentication data.
    • logoff

      @GET @Path("/logoff") public void logoff()
      See Also: