Welcome to the TechSpot OpenBoards. Please read the FAQ if you have any questions. Login to participate.

Go Back   TechSpot OpenBoards > OS & Software > The Alternative OS

Cygwin access denied

Reply
Bookmark / Share this page
Thread Tools
  #1  
Old 03-31-2008
jobeard's Avatar
jobeard jobeard is offline
TechSpot Evangelist
 
Location: Southern Calif.
Member since: Apr 2005, 6,387 posts
Cygwin access denied

On XP/Pro, \cygwin\bin\sed.exe gets Access Denied; Why?

what am I missing?

Code:
Jeff@ltbeard /usr/bin
	$ sed.exe -h
	bash: /usr/bin/sed.exe: Permission denied

yet cygwin perms are correct
	$ ls -l sed.exe
	-rwxrwxr-x 1 nMaster Users 97280 Aug  2  2006 sed.exe

and XP ACLs look good (to me at least)
C:\cygwin\bin>cacls ..
C:\cygwin BUILTIN\Administrators:(OI)(CI)F
          NT AUTHORITY\SYSTEM:(OI)(CI)F
          <Account Domain not found>F
          CREATOR OWNER:(OI)(CI)(IO)F
          BUILTIN\Users:(OI)(CI)R
          BUILTIN\Users:(CI)(special access:)
                            FILE_APPEND_DATA

          BUILTIN\Users:(CI)(special access:)
                            FILE_WRITE_DATA

C:\cygwin\bin>cacls .
C:\cygwin\bin BUILTIN\Administrators:(OI)(CI)(NP)F
              BUILTIN\Users:(OI)(CI)R
              BUILTIN\Administrators:(OI)(CI)F
              NT AUTHORITY\SYSTEM:(OI)(CI)F
              LTBEARD\Jeff:F
              CREATOR OWNER:(OI)(CI)(IO)F
              BUILTIN\Users:(OI)(CI)R
              BUILTIN\Users:(CI)(special access:)
                                FILE_APPEND_DATA

              BUILTIN\Users:(CI)(special access:)
                                FILE_WRITE_DATA



C:\cygwin\bin>cacls sed.exe
C:\cygwin\bin\sed.exe LTBEARD\nMaster:(special access:)
                                      STANDARD_RIGHTS_ALL
                                      DELETE
                                      READ_CONTROL
                                      WRITE_DAC
                                      WRITE_OWNER
                                      SYNCHRONIZE
                                      STANDARD_RIGHTS_REQUIRED
                                      FILE_GENERIC_READ
                                      FILE_GENERIC_WRITE
                                      FILE_GENERIC_EXECUTE
                                      FILE_READ_DATA
                                      FILE_WRITE_DATA
                                      FILE_APPEND_DATA
                                      FILE_READ_EA
                                      FILE_WRITE_EA
                                      FILE_EXECUTE
                                      FILE_READ_ATTRIBUTES
                                      FILE_WRITE_ATTRIBUTES

                      BUILTIN\Users:R
                      Everyone:R
                      BUILTIN\Users:(special access:)
                                    WRITE_DAC
                                    SYNCHRONIZE
                                    FILE_WRITE_DATA
                                    FILE_WRITE_EA
                                    FILE_EXECUTE
                                    FILE_WRITE_ATTRIBUTES
So why the permission errors?

(and yes, I've reinstalled it twice; first just overlay the program,
second, delete the program first (to clear the ACL) and then reinstall -- same error )

Last edited by jobeard; 03-31-2008 at 03:45 PM.
Reply With Quote
  #2  
Old 04-01-2008
Nodsu's Avatar
Nodsu Nodsu is offline
TS Special Forces
 
Location: Estonia
Member since: Feb 2002, 9,430 posts
System specs
It could be any of the DLLs or data files that sed is trying to access. Maybe run the file monitor from sysinternals and see which file access is denied.
Reply With Quote
You can remove this banner by registering, join the TS Community for free.
  #3  
Old 04-01-2008
jobeard's Avatar
jobeard jobeard is offline
TechSpot Evangelist
 
Location: Southern Calif.
Member since: Apr 2005, 6,387 posts
Quote:
Originally Posted by Nodsu
It could be any of the DLLs or data files that sed is trying to access. Maybe run the file monitor from sysinternals and see which file access is denied.
even just SED -H is denied, so it's not a data file. I fetch the F.M. and try that
Reply With Quote
  #4  
Old 04-02-2008
Nodsu's Avatar
Nodsu Nodsu is offline
TS Special Forces
 
Location: Estonia
Member since: Feb 2002, 9,430 posts
System specs
Also, I forgot the cool Linux (also in Cygwin) utility called strace that shows you what system calls a program uses and the results of these.
Reply With Quote
  #5  
Old 04-02-2008
jobeard's Avatar
jobeard jobeard is offline
TechSpot Evangelist
 
Location: Southern Calif.
Member since: Apr 2005, 6,387 posts
cool -- I forgot that too. However ...
$ strace -d -o ./strace.log /usr/bin/sed.exe
strace: error creating process C:\cygwin/bin\sed.exe, (error 5)
while tracing LS works perfectly!

The puzzle continues ...
Reply With Quote
  #6  
Old 04-03-2008
jobeard's Avatar
jobeard jobeard is offline
TechSpot Evangelist
 
Location: Southern Calif.
Member since: Apr 2005, 6,387 posts
filemon results
Code:
09:50	bash.exe:1856	FASTIO_QUERY_OPEN	C:\cygwin\bin\sed.exe	SUCCESS	Attributes: A	
09:50	bash.exe:1856	IRP_MJ_CREATE 	C:\cygwin\bin\sed.exe	SUCCESS	Options: Open  Access: 00020080	
09:50	bash.exe:1856	IRP_MJ_QUERY_INFORMATION	C:\cygwin\bin\sed.exe	SUCCESS	FileNameInformation	
09:50	bash.exe:1856	IRP_MJ_QUERY_VOLUME_INFORMATION	C:\cygwin\bin\sed.exe	SUCCESS	FileFsVolumeInformation	
09:50	bash.exe:1856	IRP_MJ_QUERY_INFORMATION	C:\cygwin\bin\sed.exe	SUCCESS	FileAllInformation	
09:50	bash.exe:1856	IRP_MJ_QUERY_SECURITY	C:\cygwin\bin\sed.exe	BUFFER OVERFLOW		
while other IRP_MJ_QUERY.. complete ok
Code:
09:50	bash.exe:1856	IRP_MJ_CREATE 	C:\cygwin\bin\sed.exe	SUCCESS	Options: Open  Access: 001000A1	
09:50	bash.exe:1856	IRP_MJ_QUERY_INFORMATION	C:\cygwin\bin\sed.exe	SUCCESS	FileNameInformation	
09:50	bash.exe:1856	FASTIO_QUERY_BASIC_INFO	C:\cygwin\bin\sed.exe	SUCCESS	Attributes: A	
09:50	bash.exe:1856	FASTIO_QUERY_STANDARD_INFO	C:\cygwin\bin\sed.exe	SUCCESS	Length: 97280	
09:50	bash.exe:1856	IRP_MJ_QUERY_INFORMATION	C:\cygwin\bin\sed.exe	SUCCESS	FileNameInformation	
09:50	bash.exe:1856	FASTIO_QUERY_OPEN	C:\cygwin\bin\sed.exe	SUCCESS	Attributes: A	
09:50	bash.exe:1856	FASTIO_QUERY_STANDARD_INFO	C:\cygwin\bin\sed.exe	SUCCESS	Length: 97280	
09:50	bash.exe:1856	FASTIO_QUERY_STANDARD_INFO	C:\cygwin\bin\sed.exe	SUCCESS	Length: 97280	
09:50	bash.exe:1856	IRP_MJ_QUERY_INFORMATION	C:\cygwin\bin\sed.exe	SUCCESS	FileNameInformation	
09:50	bash.exe:1856	IRP_MJ_CREATE 	C:\cygwin\bin\sed.exe	SUCCESS	Options: Open  Access: Read	
09:50	bash.exe:1856	FASTIO_QUERY_STANDARD_INFO	C:\cygwin\bin\sed.exe	SUCCESS	Length: 97280	
09:50	bash.exe:1856	IRP_MJ_READ 	C:\cygwin\bin\sed.exe	SUCCESS	Offset: 0 Length: 8192	
09:50	System:4	IRP_MJ_CLOSE 	C:\cygwin\bin\sed.exe	SUCCESS
is a puzzlement! (from the King & I)
Reply With Quote
  #7  
Old 04-07-2008
jobeard's Avatar
jobeard jobeard is offline
TechSpot Evangelist
 
Location: Southern Calif.
Member since: Apr 2005, 6,387 posts
I give up

I found a static linked version of sed in an archive name UnxUtils.zip

I extracted ONLY sed.exe, stored it into /usr/local/bin and verified that it would run.
rm -i /usr/bin/sed.exe then cleaned up the issue.

I had previously attempted to reinstall sed frm the cygwin setup service, but to no avail, so I was forced into this approach.

It drives me nuts to not understand what caused this, but sometimes you just have to move on
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Access Denied, when i access the my computer icon and its properties redkintanar Windows OS 2 12-07-2007 07:21 AM
access denied Peerob Windows OS 14 04-10-2007 06:25 AM
Access Denied ra_zuh Windows OS 1 03-06-2006 04:24 PM
Messed up computer and cannot access internet, page says cache access denied m5fromns Windows OS 1 01-07-2006 07:34 AM
access denied -help wchopper Windows OS 1 11-08-2004 12:24 AM


All times are GMT -4. The time now is 04:38 PM.