use of io.hops.hopsworks.api.filter.JWTNotRequired in project hopsworks by logicalclocks.
the class BannerService method findBanner.
@GET
@Produces(MediaType.APPLICATION_JSON)
@JWTNotRequired
public Response findBanner(@Context SecurityContext sc) {
Maintenance maintenance = maintenanceController.getMaintenance();
maintenance.setOtp(settings.getTwoFactorAuth());
return noCacheResponse.getNoCacheResponseBuilder(Response.Status.OK).entity(maintenance).build();
}
use of io.hops.hopsworks.api.filter.JWTNotRequired in project hopsworks by logicalclocks.
the class AuthService method recoverPassword.
@POST
@Path("/recover/password")
@Produces(MediaType.APPLICATION_JSON)
@JWTNotRequired
public Response recoverPassword(@FormParam("email") String email, @Context HttpServletRequest req) throws UserException, MessagingException {
RESTApiJsonResponse json = new RESTApiJsonResponse();
String reqUrl = FormatUtils.getUserURL(req);
userController.sendPasswordRecoveryEmail(email, reqUrl);
json.setSuccessMessage(ResponseMessages.PASSWORD_RESET);
return Response.ok(json).build();
}
Aggregations