Isn't that an anti-piracy measure? Though I would have thought they'd somehow tie the external install to a profile or even online.
How does MS implement it
For purposes of this discussion, this refers to Digital Download games and not Physical Media install games...
For MS the external drive can be moved to any console as it performs a license check. AFAIK the files are not magically encrypted or paired. The purchaser's license extends to their account and to the "home console", so everyone else can play the game on the purchaser's home console.
Caveats: There might be some inherent license information contained in the downloaded files but it should not prevent others from making use of the same download/installs.
I think the following is allowed and functions fine: User A purchases the game on Console A, downloads/installs it to external hard drive A, takes the hard drive to Console B for and as long as User A is signed in everyone else can play the game on Console B using User A's license. If User A signs out, then other users on Console B can only play the game if they too have bought the game at some point.
For example:
User AlNom buys Xbox One S to be Console A.
User BRiT buys Xbox One to be Console B.
User BRiT buys Gears of War 4 and installs it on Hard Drive B on Console B.
User AlNom buys Gears of War 4 via Microsoft Store and installs it on PC.
User BRiT sends Hard Drive B to AlNom.
User AlNom plugs in Hard Drive B to Console A and can play Gears of War 4 without any additional installs.