A Windows user account can be renamed. You almost certainly never want to do it, and changing your Yale Netids is almost impossible because of all the systems that use it, but Windows does allow it. What doesn’t change is a unique binary identifier created when the account was defined: the Security ID or SID. When you login, Windows identifies you through your SID. Access to files and directories are through the SID. Each group you are a member of also has its own SID.
There are three sources for SIDs:
Microsoft generates some built in “factory installed” SIDs for standard Windows components, and many of these built in accounts also have a dummy User name.
As an administrator, you create Local User accounts on your own machine. The SID for a Local User is unique and exists only on the one computer, even if you create an account with the same User name on another computer.
Microsoft’s Active Directory creates SIDs that can be shared across machines. All computers that are members of the same AD, including all the Managed Workstations at Yale, share the SIDs in the yu.yale.edu domain also known by the nickname YALE. This is where your Netid and its password are saved.
Factory Installed SIDs
The Microsoft TrustedInstaller identity is built into Windows and has permission to update the most sensitive files in the operating system. It installs the monthly maintenance and optional components of Windows. You do not have and do not want to have direct access to it.
SYSTEM is an anonymous identity for most of the programs that run as background Services. There are some special versions of SYSTEM for SQL Server and Hyper-V. SYSTEM identities can access any file on a local hard disk but this SID is meaningless to other computers, so programs that run under this SID have no access to anything on another computer. There are two practical consequences of this:
SQL Server can only backup and restore databases to files on a local disk. When you run SSMS you can build a backup or restore request for a *.bak file on a network disk you have access to, but when that request is sent to the SQL Server it cannot access the network share so the backup fails.
When you run Hyper-V Manager you can configure a VM to mount an ISO DVD image from a network disk you have access to, but when you try to start the VM it will fail because Hyper-V itself cannot access the network disk.
Local User SIDs created on your Computer
Yale Security Policy expects users to login with their Yale Netid to Yale Managed Workstations and other computers that are Yale owned and on the Yale network. This section describes the security procedures for personally owned computers on a home network.
A Local User is an account you create when you are acting as an administrator of your Windows 10 or 11 computer. You assign a name and a password to the account and then add it to local groups. A local user can login to the machine, own files, and can be given various permissions.
The SID for a Local User account is unique on one machine and is meaningless on other machines. You can see this by creating a file on an NTFS formated thumb drive and then moving the drive to another computer. The other computer has no idea who owns or created the file. Local SID are meaningless across a network.
When you login to a computer, it runs everything in your session under your SID.
If you create two Local Users on two personally owned computers and give each the same username and password, then the two accounts have different SIDs on each machine. Again you will see this if you create a file on a thumb drive and move it to the other computer. Although the same Userid exists on both machines, it is the SID and not the Userid that is stored with the file, and that SID is meaningless on any machine other than the one that created the file.
However, in this case things are different across the network. When someone running under a Local User account tries to connect to another computer on the home network, Windows uses an authentication mechanism called NTLM. The two computers, without transmitting the password, agree that the server computer has a userid with the same name as the user currently logged into the client machine, and the password associated with this userid is the same on both machines. The server end of the connection is then assigned the SID of the matching Userid on that machine.
This “two local users with the same name and password must be the same person” approach was called “Workgroup” computing when Microsoft created it 30 years ago. Microsoft doesn’t talk much about it today because they would much rather sell you disk space in the Azure cloud and put OneDrive on all your computers, so you transfer a file between two of your home computers by sending the file 1000 miles away and then having Microsoft send it back again, but to the other machine.
Fully Qualified Usernames
Typing out a long meaningless unique number is hard, and remembering it is impossible.
So there is a notation that we use to describe the specific account without using SID. You qualify the Userid by a prefix indicating the machine or AD in which the SID is defined.
Assume there are two computers named SNARK and BOOJUM and each has an account named “bellman” with the same password on both machines. The notation “SNARK\bellman” means the account (and SID) for bellman on SNARK and “BOOJUM\bellman” means the account on BOOJUM.
If bellman logged into SNARK contacts BOOJUM through the network, then BOOJUM verifies that it has a local user also named “bellman” and that the password for “bellman” is the same on both BOOJUM and SNARK. So it assigns the SID of BOOJUM\bellman to the request coming from the network and allows the remote SNARK\bellman to access files as BOOJUM\bellman.
Active Directory Domain User SIDs
University and corporate systems assign centrally defined Domain User accounts through Active Directory. AD provides a set of central servers where administrators can create User accounts with a userid (the Netid), password, and a Domain generated SID. Administrators also join computers to the AD. Once a computer joins a Domain, it can login Domain Users, run programs under the Domain SID, and assign file and directory ownership and permissions to that SID. Everything that can be done with a Local User SID can also be done with a Domain SID, but Domain SIDs are the same on all computers that are a member of the Domain.
Yale Security Policy requires you to use your Yale AD account to login to Managed Workstations and other Yale owned computers performing Yale business. This allows the University to enforce minimal security standards.
Active Directory provides a set of accounts and SIDs that are shared between machines. When a computer joins the AD, it continues to have local user account but in addition can allow AD SIDs to login, create, and access files. The AD has its own nickname, and the nickname of the Yale AD is “YALE”. So to extend this example, assume that “bellman” is also the Netid (Userid in the Yale AD) of the person who owns the computers SNARK and BOOJUM, and he joins both machines to the Yale AD.
The account in the Yale AD for Userid “bellman” is identified as “YALE\bellman” and is a SID that is different from both SNARK\bellman and BOOJUM\bellman. However, once the two computers are joined to the AD, they can have logins, user profile directories, and file permissions for “YALE\bellman” as well as their own local “bellman” user.
The user can login to SNARK as either the domain account YALE\bellman or the local account SNARK\bellman. These are, however, two completely different users with different SIDs and there is no way to connect them. Even if YALE\bellman has the same password as SNARK\bellman, when the user is logged in as YALE\bellman he has no access to SNARK\bellman files, unless he logs on as SNARK\bellman first and grants permission to his Yale Domain user account to also access his local files. Even then, they are two separate users who have just granted each other permission to use each other’s files.
However, files created and permissions granted to YALE\bellman on either SNARK or BOOJUM are assigned to the same YALE Domain SID and they do work across machines. If YALE\bellman creates files or grant permissions to a file on an NTFS thumb drive attached to SNARK, then moves the drive to BOOJUM, then BOOJUM knows these files and permissions belong to YALE\bellman and will grant permission to access those files when YALE\bellman logs in or accesses the files over the network.
Your Own Domain Controller
Creating your own private AD is something that ordinary people don’t do. However, there is one additional special case and I would not provide a complete description of accounts without mentioning it.
You start with a computer running Windows Server. We will call this computer FIT. Windows Server is almost the same as Windows 10, except it lacks a lot of things that are convenient for individual users (like webcam support for meetings) and so you would not want to run it as your primary system. Initially you are required to create local admin user accounts, so bellman creates his with the usual password. It is assigned a local SID that is FIT\bellman.
Now configure this Server to have its own AD. The AD has its own name “HUNTING”. When the AD is created, the local administrators of the Server now become administrators of the AD. The problem is that these local users already have a local machine SID, and they have directories and files and permissions already assigned to that SID. So the creation of the new AD copies the SID of the local user accounts into the AD and makes the same SID also an AD account SID.
Once this happens, the local account FIT\bellman and the AD account HUNTING\bellman have the same SID and therefore are essentially the same account. It doesn’t matter whether you login as one or the other, and it doesn’t matter if over the network you access HUNTING\bellman files using AD authentication (Kerberos) or you access the files using NTLM authentication to the FIT\bellman account. In this one special case (a Server that was turned into a Domain Controller by creating a new AD on it) the local account and AD account have the same SID and are interchangeable.
Impersonate
Windows has two different ways to log someone on, either locally or as the Server end of a network request.
If a password is presented, then it can be saved and used in NTLM (for a local account) or it can be presented to the AD to obtain a Kerberos login credential (for an AD account). Either way this login now has the ability to access both local (on this machine) and network (remote servers) resources as this user.
However, there are an increasing number of ways to login without the local computer seeing a password: ssh with a public key, biometrics, user certificate, Microsoft cloud account, etc. If someone can prove that he is SNARK\bellman or YALE\bellman without actually providing the password, then the local computer operating system can create a session under the SID of that account, but without the ability to use NTLM or Kerberos to access services or data on other computers. This is called “impersonation”.
Even if a session on the computer is created through impersonation and the system has not automatically stored a network credential, the user can still send a password or key to the remote session and allow it to access network services through commands or interfaces that provide userid and password as parameters.
So while Linux users normally prefer to ssh to another computer using public key authentication, you can alternately use a version of the ssh command that passes a userid and password. Public key means impersonation and you will not have access to network resources on the remote system. Userid/password means a complete login and you will have access to all the resources you would have with a traditional Windows login.
Also note that if you ssh to a computer as “bellman” and the Home directory of the “bellman” user on that machine has its own .ssh subdirectory with the bellman secret key, it can use that key as a credential to do a subsequent passthrough ssh to another machine.