procmail
[Top] [All Lists]

Re: procmail not delivering to $HOME/mail

2002-06-21 06:22:45
Mario,

On Friday 21 June 2002 07:47, Mario Michael da Costa wrote:
[SNIP, SNIP]
note that the permissions seen on /usr/bin/procmail are after i did
the foll:
chown u+s /usr/bin/procmail
chmod 4755 /usr/bin/procmail

but this did not help, i even tried
chmod g+s /usr/bin/procmail

which didn't work as well. as you can guess, i am totally lost.
this setuid/setgid stuff is beyond me. any solution that will let
procmail deliver mail to my $HOME/mail will be greatly appreciated.


Let me start by explaining a bit about setuid/setgid. It's really 
quite simple once you get it, but isn't that with everything in life? 
:)

setuid means that the program will be run under the uid of the owner 
of the file, instead of the uid of the person who started it. The 
command "/bin/sh" is owned by root, but if user "mario" would start 
it, it would be run under his id. Now if root makes it setuid (with 
"chmod o+s /bin/sh" or "chmod 04755 /bin/sh", that's about the same), 
the shell is run as root, even if mario starts it. Which means that 
if mario runs the shell, he has root-privileges.

Now you probably want procmail to be setuid by root, although I don't 
think that's necessary. You should avoid setuid-programs as much as 
possible anyway. You would make it setuid by issuing (as root of 
course) "chmod 04755 procmail". To check this, use "ls -al procmail" 
and notice the "-rwsr-xr-x" instead of the normal "-rwxr-xr-x". But 
according to what you wrote, you accomplished this.

If I read your logfiles and notice the "rocmail: skipped" (i.e. 
without the "p"), I suspect that you edited your .procmailrc in a DOS 
environment. I haven't tried this myself, but I remember having read 
something about that in one of the FAQs I read. Procmail seems to 
have problems with the way DOS ends a line. To test this, you could 
edit the file in "joe" (not default installed in RH, but it's on the 
CD's) and look for colored M's at the end of the line. There's a way 
in vi too, but since I don't use that function, I forgot :)  Anyway, 
get those CR/LF's out of the file.

Well, I hope this is useful, because I can't think of other things 
that are wrong. But maybe some expert on this list can :)

Good luck!

Hans

_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>