简体   繁体   English

使用DotNetOpenAuth设置具有子域标识符的OpenID提供程序

[英]Setting up OpenID Provider with SubDomains Identifiers using DotNetOpenAuth

I am currently trying to implement an OpenID Provider on my own domain name. 我目前正在尝试在自己的域名上实现OpenID提供程序。 Thus, I would like the OpenID Identifier of a user to be user.example.com instead of the default example.com/user.aspx/user .. 因此,我希望用户的OpenID标识符是user.example.com而不是默认的example.com/user.aspx/user ..

Is it possible for DotNetOpenAuthto do that? DotNetOpenAuth可以做到吗? If so, roughly what changes do i need to make? 如果是这样,大致需要做出哪些改变?

Yes, it's absolutely possible. 是的,这绝对是可能的。

  1. Configure your DNS and web site(s) and IIS to actually respond to user.example.com . 配置您的DNS和网站以及IIS以实际响应user.example.com
  2. Place a default.aspx file such that it responds to requests for that domain, and make that URL an OpenID Claimed Identifier by placing the tags in it that you find in the user.aspx sample. 放置一个default.aspx文件,使其响应该域的请求,并通过在user.aspx示例中找到标记,将该URL设置为OpenID Claimed Identifier。 Be sure in those tags that point to your OP Endpoint that it uses the absolute URL (which may be http://www.example.com/provider.ashx ) 请确保那些指向OP端点的标记使用绝对URL(可能是http://www.example.com/provider.ashx
  3. Modify your provider.ashx (or server.aspx , or MVC action, whatever you're using for your OP Endpoint) to be willing to send assertions for user.example.com 修改您的provider.ashx (或者server.aspx或MVC操作,无论您使用什么用于OP端点)都愿意为user.example.com发送断言

And you're done. 而且你已经完成了。 I haven't gone into great detail on these steps because it's the same steps you take when you customize the URL of your claimed identifiers in any way -- special host name or not. 我没有详细介绍这些步骤,因为这与您以任何方式自定义声明的标识符的URL时所采取的步骤相同 - 特殊主机名。 The only really special step is #1: Configuring IIS. 唯一真正特别的步骤是#1:配置IIS。 To accept any random host name requires special DNS configuration, but since it's just your own user name you can just hard-code your username into DNS. 要接受任何随机主机名,需要特殊的DNS配置,但由于它只是您自己的用户名,因此您只需将用户名硬编码到DNS中即可。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 在客户httphandler程序集中使用DotNetOpenAuth作为OpenID提供程序 - Using DotNetOpenAuth as OpenID Provider in a customer httphandler assembly DotNetOpenAuth OpenID提供程序不接受请求 - DotNetOpenAuth OpenID provider not accepting requests DotNetOpenAuth:如何实现一个简单的OpenId提供程序? - DotNetOpenAuth: How to implement a simple OpenId provider? 如何在我的系统上为OpenID提供程序使用DotNetOpenAuth? - How to Use DotNetOpenAuth on my system for OpenID provider? 使用 DotNetOpenAuth 从 OpenID Provider 获取 email 地址 - Get email address from OpenID Provider with DotNetOpenAuth 使用OpenID(通过DotNetOpenAuth)以及用户角色和其他成员资格提供程序功能 - Using OpenID (via DotNetOpenAuth) along with user roles and other Membership Provider features DotNetOpenAuth OpenID提供程序“序列包含多个元素” - DotNetOpenAuth OpenID Provider “Sequence contains more than one element” 设置SpecFlow以传递标识符 - Setting up SpecFlow to pass in identifiers 如何使用DotNetOpenAuth对任何邮件提供商进行身份验证? - How to authenticate to any mail provider using DotNetOpenAuth? 几乎所有OpenId依赖方都拒绝来自我的dotNetOpenAuth支持提供商的断言 - Nearly all OpenId relying parties reject assertions from my dotNetOpenAuth backed provider
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM