[英]Angular 6 auth using cookies
Any idea on how to implement cookie auth in Angular 6? 关于如何在Angular 6中实现cookie auth的任何想法? I have tried using AuthGuard but I'm not able to check if the user is authenticated or not because the cookie is HttpOnly so I can't access its content.
我尝试使用AuthGuard,但由于cookie为HttpOnly,所以无法检查用户是否已通过身份验证,因此我无法访问其内容。 I need this to protect some routes.
我需要这个来保护一些路线。
Thanks!!! 谢谢!!!
使用JWT时,您应该保存令牌,必须保留cookie中的密钥。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.