Networking Forums  

Go Back   Networking Forums > Networking Newsgroups > Linux Networking

callback dialup, client linux - server NT

Reply
 
Thread Tools Display Modes
  #1  
Old 12-10-2003, 09:13 PM
Default callback dialup, client linux - server NT



I started to configure my linux box to connect to a remote NT
machine via PPP and callback procedure. I call a certain number
and I'm called back by the NT host. I found a nice HOWTO but I
stumbled doing the first steps.

I wrote a small script:

#!/bin/sh
phone="callback 555111"
/usr/sbin/pppd 38400 connect '/usr/sbin/chat -v -f $HOME/win_nt.chat' \
lock $phone -detach
/usr/sbin/pppd 38400 connect '/usr/sbin/chat -v -f $HOME/win_nt_cb.chat' \
lock -detach


My win_nt.chat looks like:

TIMEOUT 60
ABORT "NO CARRIER"
ABORT BUSY
ABORT "NO DIALTONE"
ABORT ERROR
"" +++ATZ
OK ATE1Q0&C1&S0DT<a telephone number>
CONNECT ""

The first problem I encounter is the following:
The chat program send a ATZ command but get no OK from my modem.
Here is the output from /var/log/messages:

Dec 10 21:49:13 redrat pppd[1107]: pppd 2.4.0 started by thomas, uid 500
Dec 10 21:49:13 redrat chat[1108]: timeout set to 120 seconds
Dec 10 21:49:13 redrat chat[1108]: abort on (NO CARRIER)
Dec 10 21:49:13 redrat chat[1108]: abort on (BUSY)
Dec 10 21:49:13 redrat chat[1108]: abort on (NO DIALTONE)
Dec 10 21:49:13 redrat chat[1108]: abort on (ERROR)
Dec 10 21:49:13 redrat chat[1108]: send (+++ATZ^M)
Dec 10 21:49:13 redrat chat[1108]: expect (OK)
Dec 10 21:51:13 redrat chat[1108]: alarm
Dec 10 21:51:13 redrat chat[1108]: Failed
Dec 10 21:51:13 redrat pppd[1107]: Connect script failed
Dec 10 21:51:13 redrat pppd[1107]: Exit.

The modem lamps do not indicate any activities and therefore I think the
"ATZ" command does not reach the modem.

Why fails the chat command ?
I have a 2.4.20 kernel.
Any help is appreciated !

--
NO ePatents: http://swpat.ffii.org/index.de.html



Knackeback
Reply With Quote
  #2  
Old 12-10-2003, 10:04 PM
Clifford Kite
Guest
 
Posts: n/a
Default Re: callback dialup, client linux - server NT

Knackeback <(E-Mail Removed)> wrote:
> I started to configure my linux box to connect to a remote NT
> machine via PPP and callback procedure. I call a certain number
> and I'm called back by the NT host. I found a nice HOWTO but I
> stumbled doing the first steps.


> I wrote a small script:


> #!/bin/sh
> phone="callback 555111"
> /usr/sbin/pppd 38400 connect '/usr/sbin/chat -v -f $HOME/win_nt.chat' \
> lock $phone -detach
> /usr/sbin/pppd 38400 connect '/usr/sbin/chat -v -f $HOME/win_nt_cb.chat' \
> lock -detach


Try adding " /dev/ttySx" just after "/usr/sbin/pppd" in both scripts,
where ttySx is the device file associated with the serial device for
the modem.

The second chat script should probably be similar to

ABORT BUSY
ABORT "NO ANSWER"
"" AT&FE0Q0&D3
OK \c
RING ATA
CONNECT \c

but the AT string may vary.

> My win_nt.chat looks like:


> TIMEOUT 60
> ABORT "NO CARRIER"
> ABORT BUSY
> ABORT "NO DIALTONE"
> ABORT ERROR
> "" +++ATZ
> OK ATE1Q0&C1&S0DT<a telephone number>
> CONNECT ""


> The first problem I encounter is the following:
> The chat program send a ATZ command but get no OK from my modem.


The ATZ went into a black hole due to the missing ttySx and chat timed
out waiting for the OK.

--
Clifford Kite Email: "echo xvgr_yvahk-(E-Mail Removed)|rot13"
PPP-Q&A links, downloads: http://ckite.no-ip.net/
/* Speak softly and carry a sucker rod (See man syslogd, footnote to
recommendation 4 under SECURITY THREATS). */
Reply With Quote
  #3  
Old 12-11-2003, 01:32 PM
Knackeback
Guest
 
Posts: n/a
Default Re: callback dialup, client linux - server NT

Clifford Kite <(E-Mail Removed)> writes:

> Knackeback <(E-Mail Removed)> wrote:
> > I started to configure my linux box to connect to a remote NT
> > machine via PPP and callback procedure. I call a certain number
> > and I'm called back by the NT host. I found a nice HOWTO but I
> > stumbled doing the first steps.

>
> > I wrote a small script:

>
> > #!/bin/sh
> > phone="callback 555111"
> > /usr/sbin/pppd 38400 connect '/usr/sbin/chat -v -f $HOME/win_nt.chat' \
> > lock $phone -detach
> > /usr/sbin/pppd 38400 connect '/usr/sbin/chat -v -f $HOME/win_nt_cb.chat' \
> > lock -detach

>
> Try adding " /dev/ttySx" just after "/usr/sbin/pppd" in both scripts,
> where ttySx is the device file associated with the serial device for
> the modem.
>


Yes, thanks for your hint ! Now the right device is used and
the modem dials the number. However until now
I could not establish a successful connection.
I think something with the PAP-authentification does not work. The logs from
/var/log/messages are:

Using interface ppp0
Connect: ppp0 <--> /dev/ttyS1
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x50cb604b> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x50cb604b> <pcomp> <accomp>]
rcvd [LCP ConfAck id=0x1 <asyncmap 0x0> <magic 0x50cb604b> <pcomp> <accomp>]
rcvd [LCP ConfReq id=0x43 <asyncmap 0xa0000> <auth pap> <magic 0xa181275d> <pcomp> <accomp>]
sent [LCP ConfRej id=0x43 <auth pap>]
rcvd [LCP ConfReq id=0x44 <asyncmap 0xa0000> <auth pap> <magic 0xa181275d> <pcomp> <accomp>]
sent [LCP ConfRej id=0x44 <auth pap>]
rcvd [LCP ConfReq id=0x45 <asyncmap 0xa0000> <auth pap> <magic 0xa181275d> <pcomp> <accomp>]
sent [LCP ConfRej id=0x45 <auth pap>]
rcvd [LCP ConfReq id=0x46 <asyncmap 0xa0000> <auth pap> <magic 0xa181275d> <pcomp> <accomp>]
sent [LCP ConfRej id=0x46 <auth pap>]
rcvd [LCP ConfReq id=0x47 <asyncmap 0xa0000> <auth pap> <magic 0xa181275d> <pcomp> <accomp>]
sent [LCP ConfRej id=0x47 <auth pap>]
rcvd [LCP TermReq id=0x48]
sent [LCP TermAck id=0x48]
rcvd [LCP ConfReq id=0x49 <asyncmap 0xa0000> <auth pap> <magic 0xa181275d> <pcomp> <accomp>]
sent [LCP ConfRej id=0x49 <auth pap>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x50cb604b> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x50cb604b> <pcomp> <accomp>]
sent [LCP ConfReq id=0x1 <asyncmap 0x0> <magic 0x50cb604b> <pcomp> <accomp>]
..
..
..
Modem hangup
Connection terminated.
Perms of /dev/ttyS1 are ok, no 'mesg n' neccesary.
Connect script failed

From the log I see that sometime the server sent a "termination request"
and my host sent a "termination acknowledgment"
But I don't understand the lines above. Why does the PAP chatting fail ?

My /etc/ppp/pap-secrets looks like:
"my user name" "IP-address of the NT server" "my password"

Still in trouble and happy about every help, Thomas



--
NO ePatents: http://swpat.ffii.org/index.de.html
Reply With Quote
  #4  
Old 12-11-2003, 03:26 PM
Clifford Kite
Guest
 
Posts: n/a
Default Re: callback dialup, client linux - server NT

Knackeback <(E-Mail Removed)> wrote:

> I think something with the PAP-authentification does not work. The
> logs from /var/log/messages are:


You need to add the pppd option " user <your username> " so pppd will
know you want to authenticate via a secrets file. It's clear that you
haven't done much homework before setting out on this project.

Here's a good link for setting up a Linux PPP connection in general:

http://www.theory.physics.ubc.ca/ppp-linux.html

Please read it to see if it provides a solution to your next problem
before posting.

--
Clifford Kite Email: "echo xvgr_yvahk-(E-Mail Removed)|rot13"
PPP-Q&A links, downloads: http://ckite.no-ip.net/
/* Speak softly and carry a sucker rod (See man syslogd, footnote to
recommendation 4 under SECURITY THREATS). */
Reply With Quote
Reply

Tags
callback, client, dialup, linux, server

Thread Tools
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 On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT. The time now is 03:46 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.