从 HttpContext.Current.User.Identity.Name 中删除域?

Remove domain from HttpContext.Current.User.Identity.Name?

我们有一个第三方应用程序 (YetAnotherForum),我们使用 Windows 身份验证。问题是每个人的用户名都以 DOMAIN\ 为前缀。是否有 web.config 设置会停止 ASP.NET 包括域名?

谢谢,

我发现您可以从 yaf_User table 的名称列中删除域,这将更改论坛上显示的名称。只要您不触摸 yaf_prov_Membership table,它仍将绑定回 Active Directory 用户。