未经授权的用户无法访问使用Windows上的mklink附加的NFS驱动器

时间:2016-01-14 09:41:47

标签: windows permissions nfs mklink

我从cygwin呼叫cmd.exe /c mklink /d C:\LOCAL\PATH \\REMOTE\PATH作为管理员,可以按照预期从多个管理员的会话中访问该驱动器。但是,我的意思是也可以由没有特权的本地用户使用它。

我已将符号链接的所有者更改为用户chown USER /LOCAL/PATH但我仍然无法访问该驱动器:

USER@DESKTOP-P014S4E ~
$ stat /LOCAL/PATH
  File: ‘/LOCAL/PATH’ -> ‘//REMOTE/PATH’
  Size: 55          Blocks: 0          IO Block: 65536  symbolic link
Device: cccc11d4h/3435925972d Inode: 2814749767198837  Links: 1
Access: (0777/lrwxrwxrwx)  Uid: (197619/  USER)   Gid: (197121/    None)
Access: 2016-01-13 12:41:49.035500500 -0800
Modify: 2016-01-13 12:41:49.035500500 -0800
Change: 2016-01-14 09:08:54.416498800 -0800
 Birth: 2016-01-13 12:41:49.035500500 -0800

USER@DESKTOP-P014S4E ~
$ ls -l /LOCAL/PATH
lrwxrwxrwx 1 USER None 55 Jan 13 12:41 /LOCAL/PATH -> //REMOTE/PATH

USER@DESKTOP-P014S4E ~
$ stat /LOCAL/PATH/
  File: ‘/LOCAL/PATH/’
  Size: 0           Blocks: 0          IO Block: 65536  directory
Device: c3h/195d  Inode: 2351152405898294425  Links: 1
Access: (0755/drwxr-xr-x)  Uid: (197619/  USER)   Gid: (197121/    None)
Access: 2016-01-13 12:41:49.035500500 -0800
Modify: 2016-01-13 12:41:49.035500500 -0800
Change: 2016-01-14 09:08:54.416498800 -0800
 Birth: 2016-01-13 12:41:49.035500500 -0800

USER@DESKTOP-P014S4E ~
$ ls -l /LOCAL/PATH/
ls: cannot open directory /LOCAL/PATH/: Permission denied

USER@DESKTOP-P014S4E ~
$ cd /LOCAL/PATH
-bash: cd: /LOCAL/PATH: Permission denied

USER@DESKTOP-P014S4E ~
$ cd /LOCAL/PATH/
-bash: cd: /LOCAL/PATH/: Permission denied

请注意stat /LOCAL/PATH/报告管理员完全不同的内容:

Admin@DESKTOP-P014S4E ~
$ stat /LOCAL/PATH
  File: ‘/LOCAL/PATH’
  Size: 1024        Blocks: 8          IO Block: 65536  directory
Device: 38h/56d Inode: 2           Links: 25
Access: (0755/drwxr-xr-x)  Uid: (4278190080/Unix_User+0)   Gid: (4278190080/Unix_Group+0)
Access: 2016-01-14 01:12:12.000000000 -0800
Modify: 2015-11-19 02:34:42.000226000 -0800
Change: 2015-11-19 02:34:42.000226000 -0800
 Birth: -

Admin@DESKTOP-P014S4E ~
$ powershell -Command "Get-Acl C:\PATH"


    Directory: C:\


Path  Owner                  Access                                                                                    
----  -----                  ------                                                                                    
PATH DESKTOP-P014S4E\USER Everyone Allow  Read, Synchronize...

感谢您的任何指示。

0 个答案:

没有答案