import java.io.IOException; import java.util.Enumeration; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import com.thingworx.security.authentication.AuthenticatorException; import com.thingworx.security.authentication.CustomAuthenticator; import com.thingworx.security.authentication.ThingworxUserNamePasswordCredentials; public class CheckPointEntry extends CustomAuthenticator { /** * */ private static final long serialVersionUID = 1L; public CheckPointEntry() { } @Override public void authenticate(HttpServletRequest request, HttpServletResponse response) throws AuthenticatorException { this.setCredentials("Anonymous User"); // response.sendRedirect("http://10.9.40.132:8888/Thingworx/Runtime/index.html#mashup=AnonymousUserMashUP"); } @Override public void issueAuthenticationChallenge(HttpServletRequest arg0, HttpServletResponse arg1) throws AuthenticatorException { } @Override public boolean matchesAuthRequest(HttpServletRequest request) throws AuthenticatorException { if (request.getRequestURL().toString() .equalsIgnoreCase("http://10.9.40.132:8888/Thingworx/Mashups/AnonymousUserMashUP")) { return true; } return false; } }