Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/visual-studio-2012/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Oauth 2.0 IdentityServer4应用程序体系结构_Oauth 2.0_Openid Connect_Identityserver4 - Fatal编程技术网

Oauth 2.0 IdentityServer4应用程序体系结构

Oauth 2.0 IdentityServer4应用程序体系结构,oauth-2.0,openid-connect,identityserver4,Oauth 2.0,Openid Connect,Identityserver4,我目前有能力主持一个,而且只有一个网站(在一个域名下的意思)。我将有一个SPA前端、Web Api资源,然后是用于安全的IdentityServer 4(使用AspNetCore Identity framework进行用户管理) 作为单一托管站点架构,这种方法感觉有些“错误”。我相信AspNet Identity会在经过身份验证后创建一个身份验证cookie,然后IdentityServer会为我的SPA提供JWT令牌以调用我的API 然而,经过进一步思考,这似乎被误导了。似乎有点不对劲的是,

我目前有能力主持一个,而且只有一个网站(在一个域名下的意思)。我将有一个SPA前端、Web Api资源,然后是用于安全的IdentityServer 4(使用AspNetCore Identity framework进行用户管理)

作为单一托管站点架构,这种方法感觉有些“错误”。我相信AspNet Identity会在经过身份验证后创建一个身份验证cookie,然后IdentityServer会为我的SPA提供JWT令牌以调用我的API

然而,经过进一步思考,这似乎被误导了。似乎有点不对劲的是,我相信我的API调用也会在头中自动附加auth cookie和JWT令牌,因为API调用将从生成auth cookie的同一域进行请求。所以我似乎不必要地同时使用了两种形式的身份验证。。。想法

换句话说,当所有内容都在一个域下运行时,是否不需要将IdentityServer4添加到支持AspNetCore身份的应用程序?IdentityServer4中管道的一个好处是,如果应用程序与其资源(Web Api)分开部署,那么除了要修改的配置之外,您什么都没有