Re: logon script
On Wed, Jan 26, 2005 at 02:58:46PM +0000, Matt Johnson wrote:
> Hi all,
>
> I have a debian box authenticating from an NT server.
> Users don't "exist" until first time they try to logon
> to the debian box. They all logon from kdm staight
> into a gnome or kde session.
>
> I want to run a script...
> 2. Every time the user logs on.
this goes in ~/.profile (or ~/.bash_profile)
> 1. The first time a user logs on (as they spring into
> existance!)
You could do this perhaps with something in ~/.profile again, which
checks whether they have logged on before using some sort of database or
list or whatever... If you want to do it securely, perhaps you could
start users with a default shell pointing to some program that will do
the initial login stuff, and then change their shell to /bin/bash or
whatever. That program might need to be setuid root.
Sorry for long delay answering, I haven't been reading the list for a
while.
Reply to: