The User Name May Not Be the Same as the Computer Name but Computer Name can be same as the User Name

Windows does not allow you to create a user with a user name same as the machine name.


This is because having user name as same as machine name can cause confuse NetBIOS. he

User Name May Not Be the Same as the Computer Name…

This behavior occurs to prevent users from creating user names with the same user name as the computer’s name. This check is made to prevent problems with programs that use NetBIOS name registrations, which can mistakenly use the 03 NetBIOS entry (registered in this case by the user), rather than the 20 NetBIOS entry, which represents the workstation’s Server service. Such errors can prevent programs from working properly.

But unfortunately windows allow you to change windows machine to an existing user name.



Ran into a problem recently while trying to retrieve user’s SecurityIdentifer(SID) using their account name with NTAccount.Translate function because the machine name was same as the user name.

The problem does not occur if you qualify the user name with the domain name so for local users VirtualUser\VirtualUser will give you the VirtualUser sid on the local machine.

Applications should check for the same user and machine name in case NTAccount.Translate fails to resolve SID and try the fully qualified name.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s