From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 60E161382FE for ; Tue, 12 Jul 2016 20:40:09 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 0010421C0E7; Tue, 12 Jul 2016 20:39:58 +0000 (UTC) Received: from smtprelay02.ispgateway.de (smtprelay02.ispgateway.de [80.67.18.14]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id C3A2E21C080 for ; Tue, 12 Jul 2016 20:39:57 +0000 (UTC) Received: from [95.33.36.253] (helo=localhost) by smtprelay02.ispgateway.de with esmtpsa (TLSv1.2:AES128-GCM-SHA256:128) (Exim 4.84) (envelope-from ) id 1bN4TD-0000sw-Va for gentoo-user@lists.gentoo.org; Tue, 12 Jul 2016 22:39:56 +0200 Date: Tue, 12 Jul 2016 22:39:59 +0200 From: jens w To: gentoo-user@lists.gentoo.org Subject: Re: [gentoo-user] executing a command as a nologin user Message-ID: <20160712223959.00003246@lxsbbs.eu> In-Reply-To: <20160712161742.72f233b0@hal9000.localdomain> References: <20160712034702.00000f6c@lxsbbs.eu> <20160712161742.72f233b0@hal9000.localdomain> Organization: LxSBBS X-Mailer: Claws Mail 3.13.2 (GTK+ 2.24.28; i686-w64-mingw32) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Df-Sender: andAbHhzYmJzLmV1 X-Archives-Salt: 512dca71-7c15-4ec0-be0e-a1863a61ba55 X-Archives-Hash: 7086ab1b61e250dcb6a35ec7534ed96f Am Tue, 12 Jul 2016 16:17:42 +0200 schrieb wabe : > jens w wrote: > > > .procmailrc > > :0 c > > * !^X-Loop: name@example.com > > | formail -X "From:" | $HOME/bin/script.sh > > > > procmail.log > > procmail: Executing " formail -X "From:" | $HOME/bin/script.sh > > > > for incoming mail, a script is executed. logfile has the same entry > > as it is in other users. but the script do nothing. > > > > How executing a command as a nologin user? > > Is script.sh readable and executable for the procmail user? > > Does script.sh contain a definition for a command interpreter > (something like #!/bin/sh)? yes and yes. it works for default user. it does not work for nologin user. as workaround I forward the mail to a helper-user, and process it there