1833016 Members
2228 Online
110048 Solutions
New Discussion

User group login

 
sahizan
Occasional Contributor

User group login

Dear All,

May i know is possible to me create an account for user by group? that mean the users with same group will detect from their ip address.. so only verified user on that group can login using the group login id.

Thanx.
4 REPLIES 4
Michael Tully
Honored Contributor

Re: User group login

Hi,

I am fairly sure that this is not possible,
but have a look at this link which you
can restrict the number of users belonging
to certain groups. This might help you.

http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0xb16b972194d6d5118ff40090279cd0f9,00.html

-Michael
Anyone for a Mutiny ?
Deepak Extross
Honored Contributor

Re: User group login

Sahizan,
Selamat Berbuka Puasa!
I'm not too sure what exactly you're looking for, but if you want a particular user to login only from his/her machine and nowhere else, you can add this to the user's login script (.profile/.login):
thisip=`who -T | grep $(whoami) | tr -s " " | cut -d" " -f9`
allowedip="555.55.555.55"
if [ $thisip = $allowedip ]
then
: # OK, the user can continue
else
echo Sorry, you are only permitted to login from $allowedip
exit
fi
Darrell Allen
Honored Contributor

Re: User group login

Hi,

Do you want to limit login as a specific user to only sessions from a group of IP addresses?

You could put a edit in that user's .profile but the preferred place would be /etc/profile. And if it's a csh account, you'd put it in /etc/csh.login.

Darrell
"What, Me Worry?" - Alfred E. Neuman (Mad Magazine)
sahizan
Occasional Contributor

Re: User group login

Dear all..thanx for yr reply..i'm quite busy rite now with training..

i'll try to run yr advise :)