iSnare.com - Free Content Articles Directory
Authors Contents [Advanced Search][Add OpenSearch][Job Search]
Distribute your articles to thousands of article sites for only $2 and below! Read more...

Index  Computers and Technology
 

XCACLS, SUNINACL, And Other Permissions Security Recovery Tools

 
[ Contact the Author] [ Send to a Friend] [ Article Publisher] [Make PDF] [ Print] [ Bookmark & Share]
 
Read our Terms of Service before reprinting this article. The submitter specified above has claimed the rights to this article.
Darren Miller

You Have 50GB Of Data To Move Along With Permissions Security

This article is about several tools that can save a Windows administrators you know what in the event of a large scale permissions security problem.

Here is a fictional scenario we can use to illustrate the use of the XCACLS tool. We need to move or copy 50GB worth of data that is comprised of several thousand directories containing hundreds of thousands of small files from one storage system to another. These systems happen to part of a Windows 2000 Domain and permissions are quite granular in definition. We start the replication of that data using a favorite replication or synchronization tool and walk away for the evening. When we return the next day, everything has copied and all looks well. That is until you try to access the data.

The Data Is Copied, But I Cannot Access It: Permissions Security Problem

What you did not know, until just now, is that the root directory of the drive that you copied the data to had the wrong permissions assigned to it. In addition, inheritance was configured such that any data that is placed on the drive is over written with the permissions of the root directory. In this case, it was an old account that no longer existed. Believe it or not, that can happen, and system administrators will know what I am talking about. Now you are left with trying to figure out what to do. Do I format the new drive, change the permissions and inheritance on the root directory so they are correct and start all over again? Do I make the changes on the root drive so they have the correct permissions and wait hours upon hours for the permissions to propagate? No, there is another, very fast way of resolving this issue with XCACLS or another tool called SUBINACL.

XCALCS Quickly Resets Permissions On Directories And Files

Becasue I have limited space in this article, I am going to use XCACLS as the tool to correct this problem. However, in complex permissions structures, you will most likely want to use SUBINACL to fix the issue. I will talk about SUBINACL briefly at the end of the article.

XCACLS as a very fast tool that can set, remove, add, and change permissions on files and directories. For intance, the following command replaces all existing access rights and accounts with that of "dmiller" on the file "file.txt" with read-only access: "xcalcs file.txt /Y /T /G domain\dmiller:r". Although that is pretty easy and helpful, what about changing all my directories and files, which I have thousands of, to allow the domain\dmiller account to have full access? To do this in a very fast fashion you could execute the following from the root directory of the drive: "for /d %g IN (*.*) DO xcacls "%g" /Y /T /G domain\dmiller:f". This will go through every directory, subdirectory, and file and replace the current permissions with dmiller having full access to the object. You'll notice I put "" around the %g in the example. This is not required, but if you have directories that have names with spaces in them you will need to have the "".

What Other Ways Can I Use XCACLS To Change Security Permissions

To give you a few additional handy examples of how you can use this tool take a look at the follow command prompt methods for replacing, updating and removing accounts and permissions from large numbers of directories and files.

The following command replaces all existing access rights an accounts with that of dmiller with read only access rights: for /d %g IN (*.*) DO xcacls "%g" /Y /T /G domain\dmiller:r

The following command does not replace existing account permissions, instead, it adds the account, in the example the local admin account, with read only permissions: for /d %g IN (*.*) DO xcacls "%g" /Y /E /T /G administrator:r

The following command removes the account "administrator" permissions from all directories, files, and subdirectories: for /d %g IN (*.*) DO xcacls "%g" /Y /E /T /R administrator

This command should update all the directories and their contents to allow Domain Admins full access: for /d %g IN (*.*) DO xcacls "%g" /Y /T /G "Domain Admins:f"

I did a test on my XP Pro workstation and was able to change the permissions on approximately 10000 directories and files in less 1 minute. On one of my servers I was able to achieve a 500% increase in speed. It is blazingly fast.

SUBINACL Is More Complex But Man Can It Really Save The Day

I cannot go into specifics about this tool in this article but I will tell you what it can do. And again, it does it very very fast. Using the same scenario as above, let's say that you had to fix the permissions on thousands of home directories. With SUBINACL, you can actually go to the original directories and files, use the tool to create what is called a "play file", a text file that contains the right account and permissions from the source files, then use that same file to tell SUBINACL to fix the permissions on the target storage system, the one with the screwed up permissions. It's quite the life saver if you ever find yourself in the type of predicament.

Also check out "CACLS". This command is inherent to Windows XP Professional.

Conclusion

These tools are contained in the Windows 2000 and 2003 server resource tool kit, however several of them also exist native to the Windows XP environment. Check them out if you don't already know about them. Even if you have no use for them right now it may save you hours of hard work and stress in the event of a future permissions problem.

Important NoticeDISCLAIMER: All information, content, and data in this article are sole opinions and/or findings of the individual user or organization that registered and submitted this article at Isnare.com without any fee. The article is strictly for educational or entertainment purposes only and should not be used in any way, implemented or applied without consultation from a professional. We at Isnare.com do not, in anyway, contribute or include our own findings, facts and opinions in any articles presented in this site. Publishing this article does not constitute Isnare.com's support or sponsorship for this article. Isnare.com is an article publishing service. Please read our Terms of Service for more information.

Darren Miller is an Information Security Consultant with over seventeen years experience. He has written many technology & security articles, some of which have been published in nationally circulated magazines & periodicals. If you would like to contact Darren you can e-mail him at Darren.Miller@defendingthenet http://www.defendingthenet.com/NewsLetters/XCACLS-SUBINACL-AndOtherPermissionSecurityRecoveryTools.htm
Article Tags: access [See Dictionary], directories [See Dictionary], permissions [See Dictionary]
Got a question about this article? Ask the community!
Article published on February 14, 2006 at Isnare.com
 
Rate this article:

Step Away From The Computer Before You Have A Mental Meltdown
Submitted by: Darren Miller

Do I Read A Technical Manual Tonight, or The Lord Of The Rings Just out of courtesy, I think I should tell you that the following article is about as far from my typical writings as I can get...

Finding Your MAC Address On Wired And Wireless Network Cards
Submitted by: Darren Miller

The Answer To The Media Access Control Question Over the past few weeks I have received quite a few e-mails about Ethernet cards, both wired and wireless, and more specifically, about Media Access Control (MAC) addresses...

What Are Survivable Computer Systems
Submitted by: Darren Miller

Definition Of A Survivable Computer System A computer system, which may be made up of multiple individual systems and components, designed to provide mission critical services must be able to perform in a consistent and timely manner under various operating conditions...

Why Easy To Use Software Is Putting You At Risk
Submitted by: Darren Miller

Can Easy To Use Software Also Be Secure Anyone who has been working with computers for a long time will have noticed that mainstream operating systems and applications have become easier to use over the years (supposedly)...

Worm_Grew.A Threat, Hype, Or Dud?
Submitted by: Darren Miller

The Worm_GrewA Virus Got Allot Of Attention The 3rd has come and gone...

10 Things To Do For A Healthy & Secure PC
Submitted by: Darren Miller

A Top 10 List That Can Save Your Computer Many who read this article may find these recommendations to be old news...

Video On How To Hack A PC
Submitted by: Darren Miller

Hacking Video - Education Or Marketing Tool I sat in my office for about thirty minutes trying to decide if I was going to write this article...

It’s a Mod Chip World!
Submitted by: Michiel Van Kets

No Nintendo Wii game console seems complete without a mod chip installation and with today’s latest mod chip innovations it’s easier than ever to buy and install your own Wii modification chip...

Be Careful When Buying Cheap Adobe Software
Submitted by: Adrianna Noton

When individuals are looking to buy software they always love finding cheap Adobe software However are these really great prices too good to be true...

What is the Difference Between Standard and High Yield Toner Cartridges?
Submitted by: Adriana N

There have been improvements in the manufacturing of printer toner cartridges Toner found in a cartridge is dry powder blended with a polymer that sticks on to the paper as printing takes place...

IPod Battery Guide For Your IPod Nano
Submitted by: Brian H Logan

iPod battery life is an issue to most iPod users The iPod battery weakens over a period of time and it is not easily replaced...

Factors in Selecting a VAR
Submitted by: Lawrence Reaves

Selecting a Value Added reseller (VAR) is crucial and requires pain-staking assessment of their capabilities and track record, including those who are already delivering services into a client, even when the relationship has subsisted for many years...

IDC Market Forecast Predicts Static it Spend to 2013
Submitted by: Lawrence Reaves

An IDC Market Analysis and Forecast for 2009-2013 has been released and the results demonstrate a modest increase in IT spend by SMB’s worldwide – gross IT spend is predicted to rise by a mere 5...

VAR Issues – “Cheap” Usually Means Scalability, Service, And Reliability Are Sacrificed
Submitted by: Shell Harris

Value Added Resellers (VAR’s) come in all flavors, shapes and sizes – they provide a vital service to IT departments who are suffering from severe budgetary constraints, staff and skill shortages and issues in implementing and managing increasingly complex solutions...

Why You Should Buy a Notebook
Submitted by: Roberto Sedycias

The notebook computer is quickly replacing the desktop as most computer owner's favorite machine Not only is it portable for travel, it is also portable for use in the home...

The Clear Advantages Of A Sony Ericsson Satio
Submitted by: Gordon Millisons

Sony Ericsson Satio is a smart phone available at phone shops today with huge support for multimedia, touch screen feature and a lot more...

Did Windows 7 Boom or Bust?
Submitted by: John Dow

It's been a few weeks now since the launch of the Windows 7 release by Microsoft The launch in general was much lower key than past version launches, probably for a couple of reasons...

GBC H312 Laminator Review
Submitted by: Jeff McRitchie

The H312 replaces the H310 in the GBC HeatSeal line of pouch laminators Like its predecessor, this machine is targeted toward small business or home offices that do light to moderate amounts of laminating and need the flexibility to process larger documents...

GBC HeatSeal H435 Laminator Review
Submitted by: Jeff McRitchie

A new addition to GBC's Jam Free line of laminators, the HeatSeal H435 is presented as a laminating solution for small to medium sized organizations that need the flexibility of being able to laminate documents of many sizes, and of thicknesses up to 7mil...

GBC HeatSeal H520 Laminator Review
Submitted by: Jeff McRitchie

Aimed at the medium to large office market, the GBC HeatSeal H520 is designed as a solution for organizations that need to laminate documents of many different sizes...

GBC HeatSeal H535 Turbo Laminator Review
Submitted by: Jeff McRitchie

It is no secret that in today's business world, it's vital to produce top-notch work quickly That is hard to do that when you're waiting around for your laminator to work...

GBC ProClick P50 Binding Punch Review
Submitted by: Jeff McRitchie

As one of the premier manufacturers of binding machines, GBC produces machines both large and small for a wide range of uses...

Isnare.com Footer Divider

© 2004-2009. Isnare Free Articles - An Isnare Online Technologies Free Articles Project. All Rights Reserved.   Privacy Policy