locked
getfolder permission denied RRS feed

  • Question

  • Under what condition should the builtin administrator get a permission denied.  When I try to do a getfolder function on the c:\windows\system32 folder it gets a permission denied error.  I thought that the builtin administrator had full access to everything. 

    I understand that when I run the script when logged in as a user with administrator rights that I will get permission denied on some folders.  But if I run the same script using the run as administrator it gets the permission denied on the system32 folder.  Which is the same problem when run after logging into the builtin admistrator.

     

    I understand that the builtin administrator is disabled normally.  I enabled it to try to figure out why I'm getting this error.

     

    Any help would be appreciated.

    P.S. I hope I'm in the right group.
    Sunday, February 24, 2008 12:25 AM

Answers

  • Hi rac8006,

     

    Yes, by default the built-in administrator have Read, Write and Delete permission for the system32 folder.

     

    Regarding why the getfolder function does not work, I suggest submitting this issue to MSDN forum. The support professionals there are better qualified to assist you.

     

    For your reference, I’ve included the link to MSDN Forum:
     
    MSDN Forum
    http://forums.microsoft.com/msdn/default.aspx?siteid=1

     

    Sincerely,

    Joson Zhou

    Microsoft Online Community Support

     

    Tuesday, February 26, 2008 9:43 AM
    Moderator

All replies

  • After further testing I've found that the permission denied is not doing the getfolder function but when I try to do the f.size.  Then f.name returns the folder name but the f.size gets the permission denied.

    Sunday, February 24, 2008 2:45 PM
  • Hi rac8006,

     

    Yes, by default the built-in administrator have Read, Write and Delete permission for the system32 folder.

     

    Regarding why the getfolder function does not work, I suggest submitting this issue to MSDN forum. The support professionals there are better qualified to assist you.

     

    For your reference, I’ve included the link to MSDN Forum:
     
    MSDN Forum
    http://forums.microsoft.com/msdn/default.aspx?siteid=1

     

    Sincerely,

    Joson Zhou

    Microsoft Online Community Support

     

    Tuesday, February 26, 2008 9:43 AM
    Moderator
  • I did post the question on the MSDN Forum.  No answers.  I have found out the the problem with the getfolder is that when the getfolder function is called it will traverse through the folder adding up the size of each folder.  When I run the getfolder either as a regular user of as the builtin administrator I got the permission denied problem.  With further testing I found that the getfolder function failed trying to access the c:\windows\system32\Logfiles\WMI\RTbackup.  When I tried to access this folder as the builtin administrator using windows explorer it asked if I wanted to access this folder.  I said yes once I was allowed to access this folder the getfolder function worked. I not longer got the permission denied error.  But it still fails for the regular user on the rtbackup folder.

    If you try to do a getfolder on the c:\users directory the getfolder fails on c:\users\Administrator\appdata\local\Application Data.  This folder is a junction.  Don't know why getfolder is having a problem with this junction but not other junctions.

     

    This is what I know so far.

    Tuesday, March 11, 2008 2:27 PM