Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 13 Mar 2009 21:12:07 -0400
From:      Steve Bertrand <steve@ibctech.ca>
To:        "freebsd-questions@freebsd.org Questions -" <freebsd-questions@freebsd.org>
Subject:   Re: Execute and lock a user into a program upon login
Message-ID:  <49BB0467.6090606@ibctech.ca>
In-Reply-To: <49BB0161.3070800@ibctech.ca>
References:  <49BB0161.3070800@ibctech.ca>

next in thread | previous in thread | raw e-mail | index | archive | help
Steve Bertrand wrote:
> Hi everyone,
> 
> Although the application of my question focuses on network operation, I
> believe that the objective fits this list.
> 
> Mostly irrelevant, I have been working on securing my network perimeter.
> I have a FreeBSD box that acts as a host-based BGP peer to all edge
> connected routers.
> 
> I use this host-based Quagga FBSD router to distribute routes that are
> to be blackholed by the edge devices.
> 
> What I want is to set up an environment so that when a specific user
> logs in to the box via SSH, a command is run, and they immediately get
> dropped into the environment that the command produces.
> 
> When they exit this 'command', the login session is dropped.
> 
> Essentially, I want to 'lock' a user into a program upon SSH login, and
> drop them from the SSH session when the program terminates.
> 
> In essence:
> 
> - user 'router' connects via SSH
> - user is dropped into the application 'vtysh'
> - user performs operations
> - user exits from program
> - shell drops (ie. user does not have to exit the csh shell to drop the
> SSH connection)

I probably should have explicitly stated that I'd like help as to how I
would go about doing what I want to do, instead of simply stating my
goals ;)

Steve



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?49BB0467.6090606>