代码之家  ›  专栏  ›  技术社区  ›  Bassie

我的凭据存储在哪里?

  •  0
  • Bassie  · 技术社区  · 6 年前

    看到一个奇怪的问题,我无法在我正在构建的web应用程序中注销我的帐户。

    我的身份验证设置如下所示

    程序cs公司

    public static IWebHost BuildWebHost(string[] args) =>
        WebHost.CreateDefaultBuilder(args)
        .UseStartup<Startup>()
        .UseHttpSys(options =>
        {
            options.Authentication.Schemes =
                AuthenticationSchemes.NTLM | AuthenticationSchemes.Negotiate;
            options.Authentication.AllowAnonymous = false;
        })   
        .Build();
    

    启动。cs(在ConfigureServices中)

    services.AddAuthentication(
        Microsoft.AspNetCore.Server.IISIntegration.IISDefaults.AuthenticationScheme);
    

    当我调试应用程序时,它总是以某种方式让我使用该帐户登录 Bassie123 ,但我想将其更改为 贝西

    启动设置。json

    {
      "iisSettings": {
        "windowsAuthentication": true,
        "anonymousAuthentication": false,
        "iisExpress": {
          "applicationUrl": "http://localhost:55680/",
          "sslPort": 0
        }
      },
      "profiles": {
        "IIS Express": {
          "commandName": "IISExpress",
          "launchBrowser": true,
          "environmentVariables": {
            "ASPNETCORE_ENVIRONMENT": "Development"
          }
        }
      }
    }
    

    我清除了所有cookie,尝试在私人浏览窗口中打开它,甚至将该应用程序重新发布到ISS,但我的凭据仍然是 Bassie123 正在某处存储。

    我知道我可以实现一个注销方法并调用它,但这个问题更多的是关于导致帐户持久存在的数据存储在哪里。

    1 回复  |  直到 4 年前
        1
  •  1
  •   Bassie    6 年前

    所以证明凭证存储在winows中 凭据管理器

    他们坐在下面 Windows凭据-> http://addressofwebapp:3000

    删除后 Bassie123 凭据,应用程序现在会自动将我作为 贝西