From owner-freebsd-questions@FreeBSD.ORG Thu Aug 27 19:34:25 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 09129106568D for ; Thu, 27 Aug 2009 19:34:25 +0000 (UTC) (envelope-from jwdevel@gmail.com) Received: from mail-yw0-f175.google.com (mail-yw0-f175.google.com [209.85.211.175]) by mx1.freebsd.org (Postfix) with ESMTP id B7D7A8FC1C for ; Thu, 27 Aug 2009 19:34:24 +0000 (UTC) Received: by ywh5 with SMTP id 5so1821132ywh.13 for ; Thu, 27 Aug 2009 12:34:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:cc:content-type; bh=e8WIQer2Bkj8IN9e4viYRlAbcNp9ahv+iQTS3lDNEi0=; b=XKjDt3JZ8osjg2mqNB5CVnMggjPAZe5CALtx9A9uaD6+gTEst8STepTAzpozUtKYRs ZmmJqDJPbtWH50Km28Gx/X3rgpa3CH+2pwWQdd0CcIgADlBbnEDq3Kn3ylJwWW2oblK3 vYBbo+WOEshEVQ3fvRxmCZ25l/36XkgkcLM8c= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=E/BpjvbI09W2aGUbS05/wHLyUuGdJLYdS+JfuPacaKmPUQ20nDnE+Hshvm/AmiMY2A IJ9j0qrPXApKi61m4wa2bWXlh0uVjwPSc32k35g+SCSmHIET6BfIjmTaauFzTUtGeh0n UVymPHPVjrUDTdvyLpsP+UN4V7fnRaTqz4860= MIME-Version: 1.0 Received: by 10.91.28.19 with SMTP id f19mr180385agj.54.1251401663939; Thu, 27 Aug 2009 12:34:23 -0700 (PDT) In-Reply-To: <6DFAF6A1805D48FABE793388572490D5@rivendell> References: <6DFAF6A1805D48FABE793388572490D5@rivendell> Date: Thu, 27 Aug 2009 12:34:23 -0700 Message-ID: From: John W To: Reko Turja Content-Type: text/plain; charset=ISO-8859-1 Cc: freebsd-questions@freebsd.org Subject: Re: Can anyone reproduce this Samba problem? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 27 Aug 2009 19:34:25 -0000 On Thu, Aug 27, 2009 at 2:30 AM, Reko Turja wrote: >> Interestingly, if I turn off 'inherit permissions', then 'inherit >> owner' DOES take effect correctly. However, that means the sticky bit >> does not get inherited, which will not work for me. I need both to be >> inherited, and for some reason they are behaving mutually-exclusive >> (with 'inherit permissions' taking precedence). > > If I understood your problem correctly, you don't actually want to set > sticky bit on the root directory, but suid - so the chmod would be like > > chmod 4xxx mydir > > In FreeBSD suid-bitted directory will make all the subdirs to inherit the > owner. > > Sticky bit causes bit different behaviour - see sticky (8) and chmod(1) I want both the owner AND the sticky bit to be inherited. That is my dilemma. The sticky bit is necessary in my case because I do not want anyone but the owner to modify a file once created. And further, I am setting the owner to 'nobody' so this means *no* user can modify a file once created, not even files they themselves created. That is exactly the point of this share I'm trying to create. This directory will be open to many users, via a public share, with no passwords. I want everyone to be able to create new files/dirs in this share, but I do not want anyone to be able to rename/delete/modify/overwrite/etc. *any* files once created. I am trying to avoid using SUIDDIR (see my email), though I realize that is an option. If I cannot make Samba's 'inherit owner' option work on FreeBSD, that may be my only choice. Regardless of that, I would like to determine if this is a Samba bug or not, and which versions are affected, if so. However, even if I were to use SUIDDIR, I would still need the sticky bit to prevent modifications to files. Unless I am missing something, of course (: -John