Re: Killing ssshd seassions

This is a discussion on Re: Killing ssshd seassions within the OpenSSH Development forums, part of the Networking and Network Related category; On Sun, May 22, 2005 at 08:12:13PM +0000, stdout azi wrote: > The aplication i'm writting should, ...


Go Back   Usenet Forums > Networking and Network Related > OpenSSH Development

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 05-23-2005
Peter Stuge
 
Posts: n/a
Default Re: Killing ssshd seassions

On Sun, May 22, 2005 at 08:12:13PM +0000, stdout azi wrote:
> The aplication i'm writting should, at some point, kill the user
> from his terminal line. To achieve this I read the users utmp entry
> and kill the ut_pid in it.. It works fine if the user is not loged
> trought ssh. If the user has a sshd seassion, killing the ut_pid
> doesnt work though. I've done some workaround and got to this
> point:
>
> ps -aux
>
> root 26621 0.0 0.3 5940 1644 ? S 21:33 0:00 sshd: janez [priv] <-
> the pid in utmp
> janez 2356 0.0 0.3 5940 1720 ? S 21:34 0:00 sshd: janez@pts/5 <- the
> right one to kill


You could go through the process table and kill the process that has
it's PPID==ut_pid.


//Peter

_______________________________________________
openssh-unix-dev mailing list
openssh-unix-dev@mindrot.org
http://www.mindrot.org/mailman/listi...enssh-unix-dev
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 07:13 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0