Nessesarius / mintty

Automatically exported from code.google.com/p/mintty
GNU General Public License v3.0
0 stars 0 forks source link

mintty 0.9.4+ triggers UAC check on Win7 #245

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?

With versions 0.9.4 and 0.9.5, mintty triggers User Access Control (UAC) in 
Windows 7. Versions 0.9.3 and earlier do not do this. I attempted to determine 
the underlying cause by watching mintty start under SysInternals Process 
Monitor (http://technet.microsoft.com/en-us/sysinternals/bb896645), but I 
didn't see anything obvious, nor any obvious differences from past versions 
(checked with 0.7.1, 0.8.1, and 0.9.3).

I can also reproduce the behavior by runing an older version of mintty (<= 
0.9.3), and then attempting to invoke a newer version (>= 0.9.4) from bash. I 
get:

$ mintty -
-bash: /usr/bin/mintty: Permission denied

$ strace mintty -
strace: error creating process mintty, (error 740)

I couldn't find anything helpful in Event Viewer.

What is the expected output? What do you see instead?

Mintty still works after the UAC check, but certain things don't work, which I 
attributed to the privilege change:

1. network shares mounted as drive letters don't appear in /cygdrive
2. dragging a file to mintty no longer pastes in the file's path

What versions of mintty, Cygwin/MSYS, and Windows are you using?

mintty 0.9.5, as packaged by cygwin (mintty-0.9.5-1.tar.bz2)
cygwin1.dll version 1.7.7
Windows 7 Ultimate 64-bit

Original issue reported on code.google.com by jsnee...@gmail.com on 17 Jan 2011 at 9:34

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
I also encountered this problem when using "ping", see it below:

wsh@wsh-win7 ~
$ which ping
/usr/bin/ping

wsh@wsh-win7 ~
$ ping www.google.com
ping: socket: Operation not permitted

wsh@wsh-win7 ~
$ /cygdrive/c/Windows/system32/ping.exe www.google.com

正在 Ping www-g-com-chn.l.google.com [66.249.89.104] 具有 32 
字节的数据:
来自 66.249.89.104 的回复: 字节=32 时间=605ms TTL=51
来自 66.249.89.104 的回复: 字节=32 时间=464ms TTL=51
来自 66.249.89.104 的回复: 字节=32 时间=753ms TTL=51
来自 66.249.89.104 的回复: 字节=32 时间=486ms TTL=51

66.249.89.104 的 Ping 统计信息:
    数据包: 已发送 = 4,已接收 = 4,丢失 = 0 (0% 丢失),
往返行程的估计时间(以毫秒为单位):
    最短 = 464ms,最长 = 753ms,平均 = 577ms

Original comment by sharkke.w@gmail.com on 20 Jan 2011 at 7:48

GoogleCodeExporter commented 8 years ago
Problem fixed. For some reason, the mintty.exe binary on my PC was configured 
to always run as an administrator. I don't know how (or when) it happened, but 
after clearing the checkbox (see attached), UAC is no longer triggered, and I 
no longer have the problems I noted. Please accept my apologies for the wild 
goose chase.

Regarding sharkke.w's comment about ping, I believe this is normal. The Cygwin 
ping uses raw sockets, which require administrative privileges under Vista and 
Windows 7. The Windows ping apparently uses a different mechanism, so it works 
fine without admin privs. To use /usr/bin/ping inside Cygwin, you will need to 
invoke mintty (or bash) as an administrator.

Original comment by jsnee...@gmail.com on 20 Jan 2011 at 4:31

Attachments:

GoogleCodeExporter commented 8 years ago
well, thanks for your reply, it's OK and after all it it not a big problem.

Original comment by sharkke.w@gmail.com on 21 Jan 2011 at 2:39

GoogleCodeExporter commented 8 years ago
@jsnee: Glad you got that sorted, because I have no idea what change could have 
caused that.

@sharkke.w: Cygwin ping requiring administrator privileges is unfortunate, but 
it's not a mintty issue. The Cygwin mailing list is the best place to ask about 
that, but you might just get the same answer as jsnee's.

Original comment by andy.koppe on 23 Jan 2011 at 7:33

GoogleCodeExporter commented 8 years ago
@andy.koppe: I got it, thank you.

Original comment by sharkke.w@gmail.com on 23 Jan 2011 at 11:36