Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: High
  • Security: Public
  • Views: 120
  • Last Modified:

Access Denied when opening .txt file

Hi Experts,

When I try to open a text file, I get Access Denied.

When I tried to give full permissions, I get

An error occurred while applying security information to:

C:/inetpub/wwwroot\domain.com\downloads\myfile.txt

Access is denied.

I have also verified that I am that I am the owner of the  file.  I am also logged in as an admin.

I'm using Win 7 Pro x64

Any help will be appreciated
0
APD Toronto
Asked:
APD Toronto
  • 6
  • 5
  • 2
  • +2
2 Solutions
 
Yves AccadNetwork Security EngineerCommented:
From your description it sounds like it may be a UAC issue. As a test can you edit the file if you access it using the UNC?

example:   \\Yourservername\C$\inetpub/wwwroot\domain.com\downloads\myfile.txt
0
 
APD TorontoAuthor Commented:
OK, This is even stranger. When I use the UNC, I don't even see all my files
Files.JPG
0
 
Yves AccadNetwork Security EngineerCommented:
Can you try hitting F5 on the UNC accessed foler? Any change?
0
Worried about phishing attacks?

90% of attacks start with a phish. It’s critical that IT admins and MSSPs have the right security in place to protect their end users from these phishing attacks. Check out our latest feature brief for tips and tricks to keep your employees off a hackers line!

 
APD TorontoAuthor Commented:
No change
0
 
Yves AccadNetwork Security EngineerCommented:
Just to make absolutely sure we're hitting the same folder can you use this UNC instead of what is in the screenshot?

\\Optiplex\C$\inetpub\wwwroot\CRM_COR\attachments\client-1\prog-11
0
 
APD TorontoAuthor Commented:
OK, no idea how, but that listed the files equally.

Still Access deenied.
0
 
Yves AccadNetwork Security EngineerCommented:
One more test please. Right-click notepad > Run as administrator. Then go to the file in question and try to open it, modify and save it. Does it work?
0
 
APD TorontoAuthor Commented:
Opening the file through Notepad as an admin, then modifying it works.

Using File Explorer does not.

How come?
0
 
Yves AccadNetwork Security EngineerCommented:
OK so that verifies that we're dealing with a UAC issue. You don't have access to c:\inetpub although the Administrators group has access to the folder and you are part of the Administrators group because UAC takes precedence.

You can try disabling UAC or set permission using an elevated command prompt ( right-click command prompt and run as administrator)
icacls %systemdrive%\inetpub /grant  %userdomain%\%username%:(OI)(CI)(F) /grant %userdomain%\%username%:F

This will assign your user full control on inetpub.
0
 
APD TorontoAuthor Commented:
When I set this PC 10 years back, I chose "Nataliia & aleks" as the main Admin, then I changed it to APoposki, and now I get...

Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation.  All rights reserved.

C:\Windows\system32>icacls %systemdrive%\inetpub /grant  %userdomain%\%username%:(OI)(CI)(F) /grant %userdomain%\%username%:F
Invalid parameter "OPTIPLEX\Nataliia"
'aleks:' is not recognized as an internal or external command,
operable program or batch file.
The filename, directory name, or volume label syntax is incorrect.

C:\Windows\system32>icacls %systemdrive%\inetpub /grant  %userdomain%\apoposki:(OI)(CI)(F) /grant %userdomain%\%username%:F
Invalid parameter "OPTIPLEX\Nataliia"
The filename, directory name, or volume label syntax is incorrect.

C:\Windows\system32>icacls %systemdrive%\inetpub /grant  %userdomain%\"apoposki":(OI)(CI)(F) /grant %userdomain%\%username%:F
Invalid parameter "OPTIPLEX"apoposki:(OI)(CI)(F) /grant OPTIPLEX\Nataliia "
The filename, directory name, or volume label syntax is incorrect.

C:\Windows\system32>icacls %systemdrive%\inetpub /grant  %userdomain%\"Nataliia & aleks":(OI)(CI)(F) /grant %userdomain%\%username%:F
Invalid parameter "OPTIPLEX"Nataliia"
The filename, directory name, or volume label syntax is incorrect.

C:\Windows\system32>

Open in new window

0
 
Shaun VermaakTechnical Specialist/DeveloperCommented:
Do you get Accress Denied when you save the file or when you open it?
0
 
EirmanChief Operations ManagerCommented:
Try Unlocker.
It's the most popular file unlocking software out there.

This tip applies to ALL software that you may ever install ...

Take your time installing, so you don't install unwanted toolbars etc.
Don't blindly click YES/OK/Standard Installation - Read before you click!
0
 
Andrew LeniartSenior EditorCommented:
@Eirman,

You're on the wrong track. Unlocker will do nothing to solve an access denied message. The file is not "Locked" - This is clearly a permissions issue and Yves has already proven that.
0
 
EirmanChief Operations ManagerCommented:
You're on the wrong track.
Maybe so - Still there is no harm in trying Unlocker (It lists any locking 'handles).

(Perhaps re-booting to safe mode would be worth trying).
0
 
APD TorontoAuthor Commented:
Changing Permissions in Safe Mode did it,
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Improve Your Query Performance Tuning

In this FREE six-day email course, you'll learn from Janis Griffin, Database Performance Evangelist. She'll teach 12 steps that you can use to optimize your queries as much as possible and see measurable results in your work. Get started today!

  • 6
  • 5
  • 2
  • +2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now