On 5/27/17, Rowland Penny via samba <samba at lists.samba.org> wrote:> I do not fully know, but it is probably because this is such a bad idea > that it has been made not to work, or even more likely, no one ever > thought about doing this (because it is a bad idea), so there is no > code in Samba to do this.But it seems that it took more work to prevent guest from performing chown than to allow it. As a Samba pseudo user guest is directly mapped to nobody on the server and as nobody is able to chown directly on the server there must be an additional code somewhere that intentionally forbid guest to chown. -- <wempwer at gmail.com>
On Sun, 28 May 2017 01:21:12 +0900 john smith via samba <samba at lists.samba.org> wrote:> But it seems that it took more work to prevent guest from performing > chown than to allow it. As a Samba pseudo user guest is directly > mapped to nobody on the server and as nobody is able to chown directly > on the server there must be an additional code somewhere that > intentionally forbid guest to chown.You are totally missing the point, you can only chown as 'nobody' because you changed the 'nobody' user, no one else can , because they haven't changed the user 'nobody'. Just because you can do something, doesn't mean it is a good idea. Rowland
On 5/28/17, Rowland Penny via samba <samba at lists.samba.org> wrote:> On Sun, 28 May 2017 01:21:12 +0900 > john smith via samba <samba at lists.samba.org> wrote: > >> But it seems that it took more work to prevent guest from performing >> chown than to allow it. As a Samba pseudo user guest is directly >> mapped to nobody on the server and as nobody is able to chown directly >> on the server there must be an additional code somewhere that >> intentionally forbid guest to chown. > > You are totally missing the point, you can only chown as 'nobody' > because you changed the 'nobody' user, no one else can , because they > haven't changed the user 'nobody'.You're unhelpful. I know that I can chown as nobody because I changed it because I changed it on my own as I already said multiple times. Now I want to know why I cannot chown a file in a mounted directory but can do that on the server as *the same* user. I had the second thought that it may not be related to Samba but to how cifs module works on Linux general because as strace shows lchown() is finally done but it fails. I'm just looking for hints. -- <wempwer at gmail.com>