The SID for any user account, group account or logon session is unique in itself. the security identifier associated with these aforesaid users or groups ensures that the individual gaining access has the appropriate permissions to use the folder or file. The operating system (Microsoft Windows, Macintosh or Linux) ensures that each entry in the access control list uses an access control entry or ACE for maximum security.
Because ACLs and SIDs are associated, the access mask (rights) are controlled by the access control entry. Each ACE uses flags to indicate the appropriate rights (read, execute or write - in the most simplex form).
If a folder is shared out to several users, and later a user is deleted (an employee quits or is terminated) the SID associated with that employee cannot be used again. If you recreated the employee (the employee returns to work), the folder must be reshared out (or permissions reset on the file or folder in order for the employee to regain access or use of the file or folder.