Xref: utzoo news.newusers.questions:2421 comp.lang.perl:1889 Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sdd.hp.com!ucsd!helios.ee.lbl.gov!pasteur!ucbvax!iwarp.intel.com!news From: merlyn@iwarp.intel.com (Randal Schwartz) Newsgroups: news.newusers.questions,comp.lang.perl Subject: Re: .signatures Message-ID: <1990Jul25.183555.23879@iwarp.intel.com> Date: 25 Jul 90 18:35:55 GMT References: <4016@rodan.acs.syr.edu> <12443@mentor.cc.purdue.edu> Sender: news@iwarp.intel.com Reply-To: merlyn@iwarp.intel.com (Randal Schwartz) Organization: Stonehenge; netaccess via Intel, Beaverton, Oregon, USA Lines: 31 X-Local-Date: 25 Jul 90 11:35:55 PDT In-Reply-To: akf@mentor.cc.purdue.edu (Jay Hinkelman) In article <12443@mentor.cc.purdue.edu>, akf@mentor (Jay Hinkelman) writes: | drwxr-xr-x [other stuff] ./ | | You can achieve this by typing "chmod gu+x ~/." This allows anyone | else, including the news program, to see the contents of your home | directory. That should be chmod go=r-w $HOME for all shells. (This is a pretty handy combination to remember, by the way.) Your's might have turned on the x bits without the r bits, and wouldn't have done anything for "other", which is probably what the newsposter-program was considered as. In Perl, of course, it'd be: #!/usr/bin/perl $h = $ENV{"HOME"}; $usermode = ((stat($h))[2]&0700) >> 6; $nonwritemode = $usermode &~ 2; chmod +(($usermode<<6)|($nonwritemode<<3)|($nonwritemode)), $h; which goes to show ya that not everything is easier in Perl. :-) Just another UNIX and Perl hacker, -- /=Randal L. Schwartz, Stonehenge Consulting Services (503)777-0095 ==========\ | on contract to Intel's iWarp project, Beaverton, Oregon, USA, Sol III | | merlyn@iwarp.intel.com ...!any-MX-mailer-like-uunet!iwarp.intel.com!merlyn | \=Cute Quote: "Welcome to Portland, Oregon, home of the California Raisins!"=/