重定向到服务器端的安全 URL (HTTPS)
我的目标是拥有一个 HTTPS 安全登录服务(GWT-RPC),其余的都是非 HTTPS。我想要一个非 HTTPS 身份验证服务来检查用户是否登录并成功通过身份验证的会话。如果失败,服务应将客户端重定向到 HTTPS 安全登录。我的想法是在每个服务中进行身份验证(登录服务和身份验证服务本身除外)。
所有服务均受 XSRF 保护(登录服务除外)。
1)对每项服务进行身份验证有意义吗? 2)有没有办法在服务器端的服务中做到这一点(到目前为止我只找到了在客户端上做到这一点的方法)?
My goal is to have a HTTPS secured login service (GWT-RPC) and the rest is non-HTTPS. I want to have a non-HTTPS authentication service that checks the session if the user is logged in and successfully authenticated. If this fails, the service shall redired the client to the HTTPS secured login. My idea is to do authentication in every service (except the login service and the authentication service itself).
All services are XSRF protected (except the login service).
1) Does it make sense to have every service authenticated?
2) Is there a way to do that in the service on the server-side (until now I have only found ways to do that on the client)?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我认为这是有道理的。重要的是不要留下任何安全漏洞。
在
RemoteServiceServlet
中,您可以执行以下操作将请求重定向到 HTTPS:getThreadLocalResponse().sendRedirect("https://yourUrl");
In my opinion it makes sense. It's important to not leave any security holes open.
Within your
RemoteServiceServlet
, you can do the following to redirect your request to HTTPS:getThreadLocalResponse().sendRedirect("https://yourUrl");