From owner-freebsd-questions@FreeBSD.ORG Sun Mar 15 20:34:46 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 7339B106566B for ; Sun, 15 Mar 2009 20:34:46 +0000 (UTC) (envelope-from mister.olli@googlemail.com) Received: from mail-fx0-f158.google.com (mail-fx0-f158.google.com [209.85.220.158]) by mx1.freebsd.org (Postfix) with ESMTP id C5C9E8FC18 for ; Sun, 15 Mar 2009 20:34:45 +0000 (UTC) (envelope-from mister.olli@googlemail.com) Received: by fxm2 with SMTP id 2so3126428fxm.43 for ; Sun, 15 Mar 2009 13:34:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:received:received:subject:from:reply-to:to:cc :in-reply-to:references:content-type:date:message-id:mime-version :x-mailer:content-transfer-encoding; bh=8K91fSwNpyNFrYblDpogVuU3Uty9/3JcRZwBQ/46Zwk=; b=c/KMITbU3AbDFAIIQghjP+5uJf9UwmmCsEIMCeiOpshnAO2ksTyiCyL7PSUtBWUoNV Dose4KmIZUeVHyDOM+LGntyG0CzZ5BStkcCCtk/e1ohbICAqi5vMLt5Cf9iQvOWtAD0P COlLGLHGYWZ2TtpMwSsWHZ5oCoGfKGTPFhid8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=subject:from:reply-to:to:cc:in-reply-to:references:content-type :date:message-id:mime-version:x-mailer:content-transfer-encoding; b=JY+hoeEkvdvBONUxQQ6nM94qJvNE6xsXjZU5+Ocqsnz89wcaWy0k3MLc/Qpfd7ol31 IrZ3n/F2Jhj3YB4PM4C6XEUGcvIrkvfpLT7H7/1y6yaXZHyTa1tvcB7At9o3f+9fRMYM 0CCZzQ3NPi+Sl5m0kvYj3P4+232gOzRzJmmDA= Received: by 10.103.8.17 with SMTP id l17mr1797378mui.125.1237149284472; Sun, 15 Mar 2009 13:34:44 -0700 (PDT) Received: from ?10.30.1.199? (vpn-or.studi-planet.com [78.47.172.52]) by mx.google.com with ESMTPS id b9sm8841074mug.32.2009.03.15.13.34.36 (version=SSLv3 cipher=RC4-MD5); Sun, 15 Mar 2009 13:34:43 -0700 (PDT) From: Mister Olli To: Steve Bertrand In-Reply-To: <49BB0D5E.7080309@ibctech.ca> References: <49BB0161.3070800@ibctech.ca> <49BB0467.6090606@ibctech.ca> <20090314021827.1ada6548.freebsd@edvax.de> <20090314014535.GB94130@osiris.chen.org.nz> <49BB0D5E.7080309@ibctech.ca> Content-Type: text/plain Date: Sun, 15 Mar 2009 21:33:22 +0100 Message-Id: <1237149202.4448.8.camel@phoenix.blechhirn.net> Mime-Version: 1.0 X-Mailer: Evolution 2.22.3.1 Content-Transfer-Encoding: 7bit Cc: Polytropon , freebsd-questions@freebsd.org, Jonathan Chen Subject: Re: Execute and lock a user into a program upon login X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: mister.olli@googlemail.com List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Mar 2009 20:34:46 -0000 hi... have a look here: http://docs.hp.com/en/5991-7517/ch01s04.html I think the cleanest solution would be to create a match block for your user, and apply the forcecommand within that block... -- Olli On Fr, 2009-03-13 at 21:50 -0400, Steve Bertrand wrote: > Jonathan Chen wrote: > > On Sat, Mar 14, 2009 at 02:18:27AM +0100, Polytropon wrote: > > > > [..] > >> If the user's shell is csh (FreeBSD's standard dialog shell), you > >> could achieve the goal: > >> > >> ~/.login > >> vtysh > >> logout > >> > >> Only problem: I don't know how the shell will act when the user > >> terminates the vtysh application (^C)... > > > > Change the contents of ~/.login to: > > > > exec vtysh > > > > This overlays the shell with "vtysh". When it exits, the session will > > be closed. > > Thank you. > > This appears to be what I want. > > I was trying it with the previous setup, but I had to put the user in > the wheel group. I haven't yet figured where permissions were going astray. > > Your procedure will allow me to put the user in the wheel group for now, > knowing that logout will occur as soon as the program terminates. This > way, I can safely know it works, and make myself a note for Monday to > fix the permissions issues ;) > > Regards, > > Steve > > _______________________________________________ > freebsd-questions@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org