1$Id: README.logwtmp,v 1.1 2004/04/28 11:36:07 quozl Exp $ 2pptpd 1.2.0 logwtmp feature, by James Cameron, 28th April 2004. 3 4The --logwtmp feature uses the standard wtmp feature to track users 5who have connections to the server. It works as follows. 6 7When a connection occurs, pptpd launches pppd with two additional 8options. The first option directs pppd to load the pptpd-logwtmp.so 9plugin. The second option is the IP address of the client. 10 11 "plugin /usr/lib/pptpd/pptpd-logwtmp.so" 12 "pptpd-original-ip 10.0.0.1" 13 14The plugin defines the pptpd-original-ip option so that pppd will 15accept it. 16 17If the plugin fails to load, pppd will fail in the usual manner. Such 18a failure will usually be related to a missing file in /usr/lib/pptpd. 19 20The plugin asks pppd to notify it when IP comes up or goes down. 21 22When IP comes up, the plugin's ip_up() function executes, calling 23logwtmp() to mark the user as logged in. Once this has happened, 24commands like "who" will show the user. The tty will be set to the 25PPP interface name. 26 27When IP goes down, the plugin's ip_down() function executes, removing 28the entry from wtmp. Note that a "kill -9" on the pppd will result in 29a user appearing to remain logged in. Don't use "kill -9", use an 30ordinary kill. 31 32If pppd debug mode is enabled, the plugin announces it's version when 33loaded, and reports the parameters it is handing over to the logwtmp 34call. See the plugins/pptpd-logwtmp.c source. 35 36-- 37