简体   繁体   English

Visual Studio ASP.NET未知的用户名或错误的密码

[英]Visual Studio ASP.NET unknown user name or bad password

I am trying to debug an asp.net website on a remote IIS server. 我正在尝试在远程IIS服务器上调试asp.net网站。

When I debug the project, I get the error unknown user name or bad password . 调试项目时,出现错误的unknown user name or bad password错误。

After sniffing with wireshark, he is using a username that doesn't exist on my machine. 在嗅过wireshark之​​后,他使用的用户名在我的计算机上不存在。

Where can you select which user it uses to do the remote debugging? 在哪里可以选择使用哪个用户进行远程调试?

The remote debugging tool (msvsmon.exe) doesn't give you the option to select a user when you begin the debugging session in VS; 在VS中开始调试会话时,远程调试工具(msvsmon.exe)不能为您提供选择用户的选项。 it must already be configured to allow the account to debug when the session is started. 它必须已经配置为允许该帐户在启动会话时进行调试。

You can do this by opening msvsmon on the target system, selecting Tools -> Permissions, and adding the necessary user account(s). 您可以通过在目标系统上打开msvsmon,选择“工具”->“权限”,然后添加必要的用户帐户来执行此操作。

From the MSDN article regarding how to configure user accounts for remote debugging across domains (which I also found useful setting up debugging from a domain system to a workgroup system): MSDN文章中,有关如何配置用户帐户以进行跨域的远程调试(我也发现将调试从域系统设置为工作组系统很有用):

To connect to msvsmon, you must run Visual Studio under the same user account as msvsmon or under an administrator account. 若要连接到msvsmon,必须在与msvsmon相同的用户帐户下或在管理员帐户下运行Visual Studio。 (You can also configure msvsmon to accept connections from other users.) (您也可以将msvsmon配置为接受来自其他用户的连接。)

Visual Studio accepts connections from msvsmon if msvsmon is running as a user who can be authenticated on the Visual Studio computer. 如果msvsmon以可以在Visual Studio计算机上进行身份验证的用户身份运行,则Visual Studio接受msvsmon的连接。 (The user must have a local account on the Visual Studio computer.) (用户必须在Visual Studio计算机上具有本地帐户。)

If both systems are in the same domain, this makes it a little easier: 如果两个系统都在同一个域中,这将使操作变得容易一些:

  1. Add a user account to the domain for this purpose (or use an existing domain account) 为此,将用户帐户添加到域中(或使用现有的域帐户)
  2. Add the domain user account to both systems 将域用户帐户添加到两个系统
  3. Configure msvsmon.exe to allow this user account to debug 配置msvsmon.exe以允许该用户帐户进行调试
  4. Start your VS debugging session under this user account. 使用该用户帐户启动VS调试会话。

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

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM