Windows IT Pro is the authoritative and independent resource for windows nt, windows 2000, windows 2003, windows xp. Features a collection of resources and magazines for windows IT professionals.
  
  
  Advanced Search 



Controlling Ownership in Windows


RSS
View this exclusive article with VIP access -- click here to join | See More Active Directory (AD) Articles Here | Reprints
Or sign up for our VIP Monthly Pass!

Q: What is the exact meaning of ownership in the Windows OS? How can I control the ownership of Windows resources on my Windows XP and Windows Server 2003 systems?

A: At the center of the Windows authorization model sits the notion of Discretionary Access Control (DAC). DAC builds on object owners and object ownership and owes its name to the fact that it allows the owner of a Windows object-- such as a file, folder, registry key, or Active Directory (AD) object--to set permissions on that object at his/her proper discretion. This means that it is the object owner who ultimately controls which users can access the object. In Windows, the user who creates an object automatically becomes the owner of anything he or she creates.

Windows ownership is a very powerful concept. The owner owes his powers to the fact that Windows implicitly grants an object owner the read permissions and change permissions on the object. This means that the owner is always allowed to access the object, regardless of what the Access Control List (ACL) of the object says. Even if the ACL of an object includes an explicit deny Access Control Entry (ACE) for the owner’s user account, the owner can still access the object: He or she can get to the object’s ACL and override or simply remove the deny ACE. It is important to stress that the OS grants the above permissions implicitly: They do not show up in the ACL of the object. If you do detect explicit ACEs for the object owner in the ACL of an object, these are not related to the implicit owner permissions for an object, but to another mechanism, called ownership inheritance, which is used to set explicit ownership-related permissions on the parent object level (e.g., a folder or AD organizational unit--OU). Even though ownership is a powerful thing, the Windows ownership model is a bit crippled: This is because Windows doesn't implement a pure DAC model. Besides object owners, Windows also allows other accounts to control the permissions on Windows objects--the almighty Windows administrator accounts. These include the members of the local Administrators group, and the domain-level Domain Admins and Enterprise Admins groups, and also the Local System account. Windows typically assigns ownership to the user account of the object creator. If you create a new Word document for example, your user account will become the owner of the document. The owner of an object is represented by the owner’s user account SID in the object’s security descriptor. An object’s security descriptor is the Windows construct that holds an object’s access control and auditing settings, which also include the object’s ACL. You can find out the object owner in the Windows GUI from the Owner tab in the Advanced Security settings of an object, as Figure 1 shows. One notable exception to the rule of granting ownership to the user account of the object creator is when the creator is a member of the Administrators or Domain Admins group. In that case, the group account rather than the user account will get the ownership of the object. Assigning ownership to a group rather than to the individual that created the object is not a good thing from an accountability and traceability point-of-view. An administrator could leverage it to hide his/her object creation tracks. That is why in XP and Windows 2003, Microsoft includes a configurable option to control the above behavior. The setting is included in the Group Policy Object (GPO) Security Options and is called “System objects: default owner for objects created by members of Administrators group.” The allowed settings for this option are “Administrators group” or “Object creator”. This GPO setting affects the nodefaultadminowner (REG_DWORD) registry value located in the HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Lsa registry key. The supported values are 0 for Administrators group, or 1 for Object creator. When you change this setting a Windows restart is required to effectively apply the setting.

The default setting on XP is to grant ownership to the object creator. The default on Windows 2003 is to grant it to the Administrators group. In Windows 2000, Windows 2003, and XP the Administrators group is also the default owner of Windows files and folders. These include all files and folders that are created as part of the Windows installation process. A Windows account can take ownership of an object if it has the Take ownership permission on the object or if it has the “Take ownership of files or other objects” user right. A user is also explicitly granted take ownership permission if he or she is granted Full Control permission on an object. The take ownership user right is by default only given to members of the Administrators group. They can use it to take ownership of an object in the absence of explicit administrator object access permissions. The take ownership user right is typically used to bypass permissions when someone has intentionally or accidentally removed an administrator’s access permissions. It also ensures that files can be recovered by an administrator in the event that a user leaves the company. This explains why this is a highly sensitive user right that you should not give to ordinary users or services. Note that the actual change of ownership (it doesn’t matter if you leverage the take ownership permission, or the take ownership user right) is instigated by the new owner of the object. So typically, the actual owner of the object first gives another user the take ownership permission on an object, which then allows this user to seize ownership of the object. To give another user the take ownership permission, you must use the advanced view of the object’s ACL editor.

You can use the same interface to seize ownership of an object. For example, to transfer ownership of a folder named New Folder to your Alice user account, select the Edit button on the ACL editor’s advanced view Owner tab, select your Alice account using the Other Users and Groups button, select Alice’s account as the new owner, and click Apply. This process is illustrated in Figure 2 . If you're an administrator and you want to assign the ownership directly to some other account users you must - besides the take ownership permission or user right - also have the restore files and directories user right. This right is by default given to the Administrators, Backup Operators and Server Operator groups. Administrators can use this ability if they don’t trust their users to actually seize ownership of an object. This direct assignment of ownership is possible in XP and Windows 2003, but not in Windows 2000 (with the exception of an administrator assigning ownership to the Administrators group). If you have sufficient permissions, you can also change an object’s ownership from the command line using the icacls and takeown tools. Icacls can be used to transfer ownership to any account (provided this account and the account you use to transfer ownership have sufficient privileges). Takeown can be used only to seize ownership of your personal account or the Administrators group (If you are a member of this group). The icacls and takeown syntax are illustrated in Figure 3 for transferring and seizing ownership on a file named test.txt.

End of Article



Reader Comments

You must log on before posting a comment.

If you don't have a username & password, please register now.




Top Viewed ArticlesView all articles
The Memory-Optimization Hoax

Don't believe the hype. At best, RAM optimizers have no effect. At worst, they seriously degrade performance. ...

Remote Control Software

Control remote machines from home or the office. ...

WinInfo Short Takes: Week of July 21, 2008

An often irreverent look at some of the week's other news, including an iPhone 3G defeat, 180 million copies of Windows Vista in the wild, Microsoft earnings some more Yahoo silliness, Wii vs. Xbox 360, EU vs. Intel, AMD ousts its CEO, and so much more ...


Active Directory (AD) Whitepapers An Introduction to Windows Server 2008 Server Manager

Get More from Active Directory—Easily Audit Changes, and Secure and Restore Objects

User Provisioning: Get the Most Bang for your IT Buck

Related Events Check out our list of Free Email Newsletters!

Security eBooks Spam Fighting and Email Security for the 21st Century

Keeping Your Business Safe from Attack: Monitoring and Managing Your Network Security

Windows 2003: Active Directory Administration Essentials

Related Active Directory (AD) Resources Become a VIP member of the Windows IT Pro community!
Get it all with the VIP CD and VIP access. A $500+ value for only $279!

Subscribe to Windows IT Pro!
Solve your toughest technical problems with our experts and access 10,000 + articles online. 30% off

Monthly Online Pass - Only $5.95!
Get instant access to 10,000+ articles from Windows IT Pro Magazine!

TechNet Virtual Labs
Evaluate and test Microsoft's newest products.


ADS BY GOOGLE SPONSORED LINKS FEATURED LINKS

Shortcut Guide to SQL Server Infrastructure Optimization
With right tools and techniques, you can have a top-performing SQL Server infrastructure without having to cram your data centers so that they're overflowing. Download this eBook to learn how.

WinConnections Conference Fall 2008
Don’t miss the premier event for Microsoft IT Professionals in Las Vegas, November 10-13. Register and book your room by August 25 and receive a FREE room night (based on a three night minimum stay).

Become a fan of Windows IT Pro on Facebook!
Join us on Facebook and be a fan of Windows IT Pro!

Continuous Data Protection and Recovery for Exchange
Read this white paper to learn about Continuous Data Protection (CDP), Exchange 2007's local continuous replication and cluster continuous replication features.

Rev Up Your IT Know-How with Our Recharged Magazine!
The improved Windows IT Pro provides trusted IT content with an enhanced new look and functionality! Get comprehensive coverage of industry topics, expert advice, and real-world solutions—PLUS access to over 10,000 articles online. Order today!

Tips to Managing Messaging
Discover three fundamental mail and messaging management services - security, availability and control services - and how you can implement them in a Microsoft-centric mail and messaging environment.

Get It All with Windows IT Pro VIP
Stock your IT toolbox with every solution ever printed in Windows IT Pro and SQL Server Magazine plus bonus Web-exclusive content on hot topics. Subscribe to receive the VIP CD and a subscription to your choice of Windows IT Pro or SQL Server Magazine!



Drag & Drop Data Mapping Tool
Try this award-winning data mapping, & transformation tool that supports multiple databases, flat files, Web services, EDI, Excel 2007, & more! Free trial for 30 days!

Overcome bloated Windows file systems
Crossroads FMA delivers powerful yet inexpensive data migration

Bandwidth Monitoring Tool from SolarWinds
Identify largest bandwidth users in seconds. Get the free download now.

Speed Deployment of Vista and Microsoft Office
Read this white paper to learn how you can maximize your Vista and Office investments while lowering costs and increasing efficiency.

Integrated Virtualization Done Right
Download this white paper on server virtualization to begin improving resource utilization and lowering operating costs.

Order Your Fundamentals CD Today!
Gain an introduction to Exchange, learn server security requirements, and understand how unified communications can play a role in your messaging strategies with this free Exchange CD.

KVM over IP Solutions
Learn about a KVM over IP solution that is specifically designed to meet the needs of the distributed IT environment.
Windows IT Pro Home Register FAQ for Windows WinInfo News
Europe Edition About Us Contact Us/Customer Service Media Kit Affiliates / Licensing  
SQL Server Magazine Office & SharePoint Pro Windows Dev Pro IT Job Hound
IT Library Technical Resources Directory Connected Home Windows Excavator SuperSite 
 
 Windows IT Pro is a Division of Penton Media Inc.
 Copyright © 2008 Penton Media, Inc., All rights reserved. Terms and Use | Privacy Statement | Reprints and Licensing