Date: Thu, 21 Sep 2006 09:17:00 +0200 From: "Aitor San Juan" <asanjuan@bolsabilbao.es> To: "FreeBSD" <freebsd-questions@freebsd.org> Subject: Default file creation permissions Message-ID: <8944F1E6DB931D4681FF94706234BF71E95A@BB06.bolsabilbao.local> In-Reply-To: <45116D40.7020904@lidstrom.eu>
next in thread | previous in thread | raw e-mail | index | archive | help
Hi List, I have a shell script whose execution is scheduled by CRON. The command = scheduled is of the form: 50 23 * * 1-5 /apps/batch/cronjobs/bd_backup.sh > = /apps/batch/logs/bd_backup.log 2>&1 This shell script runs under the id of root. The file permissions of the = log file created are 644 (owner: root, group: wheel). I'd like that the = file permissions of the log created be 600 (or 640 maximum). How could I = accomplish this? This is probably related to "umask", but I don't dare = changing anything in case that change could affect some other security = configuration as a side effect. What would you recommend? Any hint or suggestion would be highly appreciated. Thanks in advance. Aitor. ************ LEGEZKO OHARRA / AVISO LEGAL / LEGAL ADVICE *************=20 Mezu honek isilpeko informazioa gorde dezake, edo jabea duena, edota = legez babestuta dagoena. Zuri zuzendua ez bada, bidali duenari esan eta = ezabatu, inori berbidali edo gorde gabe, legeak debekatzen duelako = mezuak erabiltzea baimenik gabe.=20 -------------------------------------------------------------------------= - Este mensaje puede contener informaci=F3n confidencial, en propiedad o = legalmente protegida. Si usted no es el destinatario, le rogamos lo = comunique al remitente y proceda a borrarlo, sin reenviarlo ni = conservarlo, ya que su uso no autorizado est=E1 prohibido legalmente. -------------------------------------------------------------------------= - This message may contain confidential, proprietary or legally privileged = information. If you are not the intended recipient of this message, = please notify it to the sender and delete without resending or backing = it, as it is legally prohibited. *************************************************************************= *
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?8944F1E6DB931D4681FF94706234BF71E95A>