在授权服务器上没有 Login/Register 视图的情况下将隐式流与 OpenIdDict 一起使用
Use the Implicit flow with OpenIdDict without having a Login/Register View on the Authorization Server
我想做的是:
与 dotnet Core Wep 通信的 SPA API。
我想使用社交登录。
我想使用(服务器端)授权代码流。
我倾向于使用 OpenIdDict 来处理 JWT 令牌身份验证。
我设置了 OpenIdDict 的示例项目,特别是 ImplicitFlow,我让它开始工作。
但此示例使用重定向到授权服务器进行实际登录过程。
是否可以让 SPA 服务这些页面?
好像以前有人做过,见:https://github.com/Kukks/openiddict-custom-grants-example
但我无法再构建该概念证明。
我想知道的是,Kukks 的概念验证是否仍然是实现这一目标的方法,以及我想要这样做是否是在做正确的事情。或者我在这里打开了一堆蠕虫,我应该只从授权服务器加载一个页面而停止抱怨吗?
Would it be possible to have these pages served by the SPA ass well?
没有。对于交互式流程(如代码或隐式),授权服务器应该负责身份验证部分,这是保证授权服务器和客户端应用程序之间隔离的唯一方法,不能 "see" 用户凭据.试图解决这个问题几乎会破坏这些流程的全部目的。
What I want to know is, whether Kukks proof of concept is still the way to go for implementing this and whether I'm doing the right thing by wanting it this way.
如果您拥有客户端应用程序,并且如果将您的用户重定向到您的授权服务器(例如使用隐式流程)对您来说是不可接受的,那么是的,您可以考虑使用断言流程。
在这种情况下,JS 应用程序将负责处理社交登录部分(这意味着它将直接向外部社交提供者注册。在经典的隐式流程中,它将是授权服务器)。
Or am I opening a can of worms here and should I should I just load a page from the Authorization Server an stop complaining?
如果您决定实施此流程,则在实施外部 code/token 验证例程时必须格外小心,以避免我们所说的 "confused deputy attacks".
不幸的是,您所指的演示存在漏洞,如该票证中所述:https://github.com/openiddict/openiddict-samples/issues/13#issuecomment-250903091。
我想做的是:
与 dotnet Core Wep 通信的 SPA API。 我想使用社交登录。
我想使用(服务器端)授权代码流。
我倾向于使用 OpenIdDict 来处理 JWT 令牌身份验证。
我设置了 OpenIdDict 的示例项目,特别是 ImplicitFlow,我让它开始工作。 但此示例使用重定向到授权服务器进行实际登录过程。
是否可以让 SPA 服务这些页面?
好像以前有人做过,见:https://github.com/Kukks/openiddict-custom-grants-example
但我无法再构建该概念证明。
我想知道的是,Kukks 的概念验证是否仍然是实现这一目标的方法,以及我想要这样做是否是在做正确的事情。或者我在这里打开了一堆蠕虫,我应该只从授权服务器加载一个页面而停止抱怨吗?
Would it be possible to have these pages served by the SPA ass well?
没有。对于交互式流程(如代码或隐式),授权服务器应该负责身份验证部分,这是保证授权服务器和客户端应用程序之间隔离的唯一方法,不能 "see" 用户凭据.试图解决这个问题几乎会破坏这些流程的全部目的。
What I want to know is, whether Kukks proof of concept is still the way to go for implementing this and whether I'm doing the right thing by wanting it this way.
如果您拥有客户端应用程序,并且如果将您的用户重定向到您的授权服务器(例如使用隐式流程)对您来说是不可接受的,那么是的,您可以考虑使用断言流程。
在这种情况下,JS 应用程序将负责处理社交登录部分(这意味着它将直接向外部社交提供者注册。在经典的隐式流程中,它将是授权服务器)。
Or am I opening a can of worms here and should I should I just load a page from the Authorization Server an stop complaining?
如果您决定实施此流程,则在实施外部 code/token 验证例程时必须格外小心,以避免我们所说的 "confused deputy attacks".
不幸的是,您所指的演示存在漏洞,如该票证中所述:https://github.com/openiddict/openiddict-samples/issues/13#issuecomment-250903091。