Commit Graph

24 Commits

Author SHA1 Message Date
Poul-Henning Kamp
9c749ffb8b Here is a diff of /usr/src/usr.sbin/ppp against current. The diffs
add some logging functionality which I find very useful.
'set debug link' will record just link up/down and address assignments.
'set debug connect' will record the entire chat dialog
'set debug carrier' will record just chat lines including 'CARRIER'
(so that I can be sure I'm getting a 28.8 line).

There was a global change required to permit LogPrintf to take a bit
mask instead of a bit position value (to permit logging some events
on either of two flags, so that no change in 'set debug lcp' would
result from the code supporting 'link'.  Thus the diffs are rather
long for such a small change.  The man page is also touched.

Oh, and there was a slight syntax problem in route.c

Reviewed by:	phk
Submitted by:	Tony Kimball <alk@Think.COM>
1996-05-11 20:48:42 +00:00
Andrey A. Chernov
043e364b86 Fix UnrawModem:
restore initial (not second level) state
not call it for DEV_SYNC
issue input flush after restoring
1996-03-29 15:24:04 +00:00
Andrey A. Chernov
e3118d3f5b Directly clear parity area because cfmakeraw not do it 1996-03-28 13:38:59 +00:00
Andrey A. Chernov
3f0f267e5d After real problem is found (flush never occurse), re-enable
software flow control, but re-enable it properly,
idea taken from taylor 'cu'
1996-03-27 22:58:21 +00:00
Andrey A. Chernov
71f99a8d0e Fix typing bug cause flushing never occurse:
TIOCFLUSH -> TCIOFLUSH
1996-03-27 22:28:19 +00:00
Andrey A. Chernov
b3f735dcfd Use cfmakeraw() instead of all those termios settings 1996-03-27 21:40:55 +00:00
Andrey A. Chernov
8cf220d53b Cleanup both raw & termianl modes termios flags settings 1996-03-27 21:16:32 +00:00
Andrey A. Chernov
38e0acf3bc Disable ^S/^Q flow control!!! 1996-03-27 20:53:03 +00:00
Andrey A. Chernov
f2fc832c4b Better fix for terminal mode 1996-03-13 12:02:16 +00:00
Andrey A. Chernov
d91680ea37 1) Open /dev/null for std* after setsid() to be shure that modem is
*not* our controlling terminal (SIGHUP can coming in other case)

2) Add HUPCL for non-dedicated lines to be shure that modem
properly resetted.

3) Correct usage string.
1996-03-09 08:18:41 +00:00
Andrey A. Chernov
cb7fddc6fa Log phone as LOG_PHASE, it is valuable enough for multi-phone environment.
Add missing return when terminal mode can't be re-established due
to modem not opened.
1996-03-08 12:34:40 +00:00
Andrey A. Chernov
1dff3fc565 1) Add multi-phone dialing/redialing, several phones separated by ':'
2) Improve on-line help subsystem
3) Make 'term' mode works even carrier dropped (old code
close line forever here)
4) Make 'term' mode 8bit clean.
5) Improve manual page
6) #ifdef DEBUG diagnostic about missing optional files.
7) Don't put interactive dialing info to logfile
1996-03-08 09:03:09 +00:00
Doug Rabson
76bd0c0a9d Some patches to ppp which improve stability. I have been running a
ppp based on these patches for about 3 weeks with no downtime.

The original submitters comments:

Two features iijppp has over kernel ppp that I like are predictor1
compression and demand dialing.  Here are a few bug fixes.

I expanded the priority queueing scheme and discovered it was broken
due to the assignment at ip.c line 300.  All packets were being
queued at the same priority.

Fixing priority queueing broke predictor1 compression.  Packets
were compressed before being queued and predictor1 worked as long
as the packets were popped off the queue in the same order they
were pushed onto the queue.

There were a few byte order problems in IP header tests also.

There is a recursion problem in SendLqrReport().  LcpClose() is
called when "Too many echo packets are lost" which winds up in
SendLqrReport() again.  I believe the original intention was to
just stop the LQR timer with the call to StopLqr() but the side
effects hurt.

Submitted by:	John Capo <jc@irbs.com>
1996-01-30 11:08:50 +00:00
Poul-Henning Kamp
ed6a16c181 Final cleanup for now. -Wall is now silent. A couple of bogons found. 1996-01-11 17:48:59 +00:00
Poul-Henning Kamp
7b64106a9e A random bunch of cleanup changes. 1996-01-10 21:28:04 +00:00
Atsushi Murai
c3899f8d3c 1. Do not log the password itself to ppp.log ( Mr. Rich Murphey )
2. Add ability to execute shell commands and suspend back into
   invoking shell (Mr. J Wunsch)

Reviewed by:	amurai@spec.co.jp
Submitted by:	joerg_wunsch@uriah.heep.sax.de (Joerg Wunsch)
		Rich Murphey <rich@lamprey.utmb.edu>
1995-09-02 17:20:54 +00:00
Atsushi Murai
60e218e470 1. Clean up log message.
2. Optimize ModemQlen.
3. Sending ProtoReject for Unknow protocol (i.e. IPX)
4. Avoid select looping by reading tun under the high system load.
5. Adding Local version String for maintenance.
6. Just more speak rather silent ignore if you type invalid key words.
1995-07-08 17:46:56 +00:00
Doug Rabson
f553a3f620 Hang up the modem if the dial or login fails. This ensures that we
will not hold the line open if the other end has a broken modem or server.
This happens to me quite frequently with my ISP.
1995-06-30 19:53:04 +00:00
Rodney W. Grimes
709e8f9ae1 Remove trailing whitespace. 1995-05-30 03:57:47 +00:00
Atsushi Murai
38c50f39a0 Fixing follows and John's fruent explnation than my English....
The first problem I found was that descriptor 0 was being closed.
This happens because the modem variable is set to 0 to indicate
that it is not valid but there are not enough tests for the modem
variable being 0.  You can see where I have done this in the patch.
Code in OpenModem() dups the modem descriptor if it is < 3.  Once
this happened the modem was always open and an incomming call would
have getty and ppp reading the modem.

Descriptor 1 is closed when the quit command was executed from a
telnet connection.  The next modem open returns descriptor 1
and this gets duped leaving the modem always open again.

The modem was not being closed when the connection dropped or was
closed from the other end.  The UUCP lock was also not removed if
the modem could not be opened.

Reviewed by:	Atsushi Murai <amurai@spec.co.jp>
Submitted by:	John Capo <jc@irbs.com>
1995-04-16 13:38:39 +00:00
Atsushi Murai
84b8a6ebd1 1.Reducing cpu usage at off connection.
2.Implment Redail function as working correctly.
3.Clean up a code as I notice.
4.Now, RTT getting close to 50ms with ISDN/TA 38400bps !!

Reviewed by:	amurai@spec.co.jp
Submitted by:	amurai@spec.co.jp
1995-03-11 15:18:55 +00:00
Atsushi Murai
41db65649e Fixing minor bug and allow help(Not for all command) and quit
but not close line connection by "quit all" command if not
authorized.

Reviewed by:	amurai@spec.co.jp
Submitted by:	tony-o@iij.ad.jp amurai@spec.co.jp
1995-02-27 10:57:54 +00:00
Atsushi Murai
53c9f6c0c4 New user Process PPP based on iij-ppp0.94beta2.
o Supporting SYNC SIO device (But need a device driver)
     - add "set speed sync"
   o Fixing bug for Predictor-1 function.
   o Add new parameter that re-sent interval for set timeout commands.
   o Improving RTT (Round Trip Time) and reducing processor time.
     - Previous Timer service was using polling, and now using
       SIGALRM ;-)
     - A 0.94beta2 will not work correctly....

   -- Follows are additinal feature not including 0.94beta2
   o Support Proxy ARP
     - add "enable/disable proxy" commands
   o Marging common routine in CHAP/PAP.
   o Enhancing LCP/IPCP log information.
   o Support local Authfication connection on port 300x and tty.
     - You can set up pair of your "hostname -s" and
       password in ppp.secret. if either ppp.secret file nor
       your hostname line don't exist, It will notify a message
       and working as same as previous version.(Backword compatibility)
     - If you did set up them, It's allow connection but nothing to do
       except help and passwd command.
     - add "passwd yourpasswd" commands
   o Support afilter - keep Alive filter that a packet can send/receiving
     according to ifilter/ofilter but doesn't count it as preventing idle
     timer expires.
     - Same syntax of other filters.
   o Fixing bugs reported by current user for previous one. Thanks !!

Reviewed by: Atsushi Murai (amurai@spec.co.jp)
1995-02-26 12:18:08 +00:00
Atsushi Murai
af57ed9fdc 1995-01-31 06:29:58 +00:00