Ask a questionAsk a question
 

AnswerHow do I un-protect a file?

  • Monday, November 02, 2009 8:29 PMjratzlaf Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    I would like to un-protect a specific file in a Program Files (x86) subfolder, which the system will not allow me to change without requiring administrative approval (UAC). Is this possible? The file is C:\Program Files (x86)\Mozilla Firefox\defaults\pref\Firefox.js, and I need the system login script to be able to check and modify this file regardless of who is logged in. Is this possible? (I come from an XP background where there was no obstacle to doing such a thing, and I never used Vista, which may behave like this as well.) TIA - JR

    ps I'm using Win7RC.

Answers

  • Tuesday, November 03, 2009 9:40 AMAndy SongMSFT, ModeratorUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

    Hello,

     

    According to your requirement, I suggest you disable UAC in Windows 7, which is similar to steps to disable UAC in Windows Vista, only with slight user interface change, and there is plenty of methods to turn off UAC too.

     

    Method 1: Disable or Turn Off UAC (User Account Control) in Control Panel

     

    1. To user Control Panel to disable UAC in Windows 7, login the system with the administrative account, go to Start Menu -> Control Panel -> User Accounts
    2. Click on Change User Account Control settings link.
    3. Slide the slider bar to the lowest value (towards Never Notify me when)

    For more information about those four values, please refer to the following webpage

    User Account Control (UAC) settings in Windows 7

    1. Click OK to make the change effective.
    2. Restart the computer to turn off User Access Control.

     

    Method 2: Disable UAC with Registry Editor

     

    1. Run Registry Editor (RegEdit).
    2. Navigate to the following registry key:

    HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Policies\System

    1. Locate the following REG_DWORD value:

    EnableLUA

    1. Set the value of EnableLUA to 0.
    2. Optional step to suppress UAC consent prompt dialog, locate the following REG_DWORD value:

    ConsentPromptBehaviorAdmin

    1. Set the value of ConsentPromptBehaviorAdmin to 0 (optional).
    2. Exit from Registry Editor and restart the computer to turn off UAC

     

    For more details about UAC, please refer to the following article.

    User Account Control Step-by-Step Guide

     

    Hope the above steps work out!


    Andy

All Replies

  • Tuesday, November 03, 2009 9:40 AMAndy SongMSFT, ModeratorUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

    Hello,

     

    According to your requirement, I suggest you disable UAC in Windows 7, which is similar to steps to disable UAC in Windows Vista, only with slight user interface change, and there is plenty of methods to turn off UAC too.

     

    Method 1: Disable or Turn Off UAC (User Account Control) in Control Panel

     

    1. To user Control Panel to disable UAC in Windows 7, login the system with the administrative account, go to Start Menu -> Control Panel -> User Accounts
    2. Click on Change User Account Control settings link.
    3. Slide the slider bar to the lowest value (towards Never Notify me when)

    For more information about those four values, please refer to the following webpage

    User Account Control (UAC) settings in Windows 7

    1. Click OK to make the change effective.
    2. Restart the computer to turn off User Access Control.

     

    Method 2: Disable UAC with Registry Editor

     

    1. Run Registry Editor (RegEdit).
    2. Navigate to the following registry key:

    HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Policies\System

    1. Locate the following REG_DWORD value:

    EnableLUA

    1. Set the value of EnableLUA to 0.
    2. Optional step to suppress UAC consent prompt dialog, locate the following REG_DWORD value:

    ConsentPromptBehaviorAdmin

    1. Set the value of ConsentPromptBehaviorAdmin to 0 (optional).
    2. Exit from Registry Editor and restart the computer to turn off UAC

     

    For more details about UAC, please refer to the following article.

    User Account Control Step-by-Step Guide

     

    Hope the above steps work out!


    Andy

  • Tuesday, November 03, 2009 2:18 PMjratzlaf Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Is there really no way to un-protect that one file? I don't really want to give up UAC on all the computers on campus for just that one tiny need... - JR
  • Tuesday, November 10, 2009 6:51 AMAndy SongMSFT, ModeratorUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    If you would like to run login script without getting the UAC promotion, you might add the login script to a Task Scheduler and run the Task automatically. Hope it helps!
  • Tuesday, November 10, 2009 8:42 PMrogergh Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    Hi, if you are able to you can just install Firefox to a location that is not protected by the system (NOT "Program Files (x86), "Program Files", "Windows" etc.) and as far as I know UAC should not prompt you for security reasons in that location, unless your script invokes something that triggers UAC-security besides the systempath.

    Ex: C:\Programs\Mozilla Firefox\etcetc