Next Previous Table of Contents
The following section was provided by Martin Häfner.
This chapter descibes the configuration of kppp for callback. The following servers are supported:
This section introduces in Unix (Linux) callback proceeding and how kppp can be configured to connect to a Unix callback server, especially to a scripting based Linux callback server.
If you have any questions or problems please feel free to contact the author of this section.
To increase the security of your local network or to reduce the expenses
of your external co-workers, setting up a callback server could be your first
choice. Think about someone calling the number of your dial-in server and
cracking a password? Why do you maintain a firewall for your internet
connection then? Callback software generally asks you for your name and
looks up the number to call back from a database. Therefore, the
number should be stored on the server. After authentication the server will
hang up the line and call you back immediately on the number chosen.
The client picks up the phone line and continues the dial-in as if
nothing happened. The server will ask for username and password,
then the connection is established and the pppd could be started. Now,
how can I tell the client to pick up the phone? Do I need a
program like mgetty? Well, the answer is "NO"! You do not need a special
client program. Generally spoken, all clients can be used for callback
connections. You can even use an ordinary terminal program like minicom
to connect to a callback server. The only thing you have to do is to tell
your modem to AutoAnswer
the phone when a RING
is
detected by the modem. This is done by using a certain modem command:
AT&S0=1
This means that the modem will pick up the phone after one RING
.
Remember, this is done without any client software interaction.
Like a lot of other client programs
kppp checks if the connection is closed by the server and stops the current
session if a NO CARRIER
is detected. And this it the next
problem:
NO CARRIER
is detected when the callback server hangs up the line after he
knows on which number to call the client back. Some servers use a special
login program therefore. How can you solve that problem?
Tell your modem to show carrier up all the time
(which makes no problems if the client hangs up the line) by using the
modem command:
AT&C0
If you want to test this you can first use an ordinary terminal program like minicom and call your callback server.
Setting up kppp to connect to a Linux callback server is quite straight forward.
Dial String: AT&C0S0=1DT
All the other configuration issues will remain as-is.
kppp has some problems with modem init and reset. See the
troubleshooting section if you are confronted with trouble.
Authentication: Script-based
Of course, you can first choose "Terminal based" and test your connection.
Have a look on what the server asks you so you can write your login script
afterwards.
Expect ogin: # remember, we do ordinary terminal login
ID "" # kppp sends the id you have configured in the main dialog
Expect for xyz: # a list of avaiable numbers is shown. The user must select one
Send xyz-home # the user wants to be called back at home
Expect ogin: # the callback process is running, a new connect, a new login
ID
Expect assword:
Password # now your password authentication
Expect > # wait for the command prompt (this may vary)
Send start_ppp # start_ppp starts the pppd
Just ignore the comments beginning with "#".
After waiting for the login request he sends his user ID and waits for
the list of available connections for his user ID. Then he tells the server on
which number he wants to be called back. kppp can open a dialog for that (very
nice feature) if your domicile changes rapidely (e.g. you are a
representative and you are travelling from hotel to hotel). Now the server
expects the
login and Password authentication. In the meanwhile the server hangs up
the line and calls the user back. kppp expects the commandline prompt and
starts a small script which fires up the pppd on the server. The script may
look like the following:
#!/bin/sh
stty -echo
exec /usr/sbin/pppd -detach silent modem
Of course, setting up a PPP-server is not within the scope of this document.
For detailed information see the pppd man pages. An example callback server
is described
here.All the other configuration issues (e.g. pppd config or IP settings) work as usual. Remember, no special software is needed to pick up the line.
Notice: kppp callback and other programs like mgetty or any other faxgetty can be run on the same serial port. There are no problems with the dial-in as kppp creates a Lock-file which will indicate the getty program that another program (kppp) is using the line at the moment. See problems with mgetty in the general troubleshooting below.
There are some known problems with kppp in callback mode:
Linux callback server software bundles are available throughout the internet. Of course, the all known mgetty is a very powerful program which is also able to handle callback connections. There is a description for how to set up mgetty for that purpose here. The site is maintained by Colin Mc Kinnon, so please don't ask me if you have any problems. But there is also a ready-to-use package for a Linux callback server available here. The package is maintained by Frank B. Brokken. As the package is not very easy to set up (although the setup is straight forward), I have written a short introduction for it. Also have a look in it if you need further general introduction to callback.
Windows NT uses a completly different approach than the one described here (as usual). NT requires an extension to the PPP protocol itself called CBCP (Call Back Control Protocol). pppd
has support for this protocol, but you have to recompile pppd
.
If anybody has experience how to do this with kppp, please drop me a line.
Next Previous Table of Contents