1CAPIPLUGIN(8)               System Manager's Manual              CAPIPLUGIN(8)
2
3
4

NAME

6       capiplugin - Plugin for pppd (Point-to-Point Protocol daemon)
7
8

SYNOPSIS

10       pppd [options] plugin capiplugin.so [options for capiplugin]
11       before pppd 2.4.1:
12       pppd    [options]   plugin   /usr/lib/pppd/<pppd-version>/capiplugin.so
13       [options for capiplugin]
14
15

DESCRIPTION

17       The capiplugin provides a method to use PPP over ISDN  with  ISDN  con‐
18       trollers  that  provide a CAPI2.0 interface.  The plugin is responsible
19       for the call setup with CAPI2.0.  You can dial out, wait  for  incoming
20       calls  and set up communication over leased lines. It implements a fea‐
21       ture to reject an incoming call and callback. This feature can also  be
22       used  when  dialing  out.  In this case, the party called has to reject
23       the call and call back soon.  When using dial-on-demand it is  possible
24       let  both parties setup the connection, that means while the pppd is in
25       dial-on-demand mode not only an outgoing packet but  also  an  incoming
26       call  can  trigger  the  connection  setup. This can also combined with
27       callback to assign the cost to one side only (COSO).
28
29

PPPD VERSIONS

31       The plugin interface of the pppd is binary incompatible between differ‐
32       ent  version  of the pppd. So you need a different capiplugin for every
33       version of the pppd. The different plugins will  be  in  the  directory
34       /usr/lib/ppp/<pppd-version>.  Since 2.4.1 pppd checks if the version of
35       the plugin matches and also search the plugins  in  these  directories.
36       With  pppd versions before 2.4.1 you need to specify the absolute path‐
37       name of the plugin.
38
39

HOW IT WORKS

41       The capiplugin registers a new_phase_notifier and its  own  options  to
42       the  pppd  when  loaded.  When the pppd goes into phase SERIALCONN, the
43       capiplugin set up a connection and sets  the  global  variable  devnam.
44       The capiplugin will register a timer function that is called every sec‐
45       ond to handle the CAPI messages while pppd is running.  To notify  pppd
46       when  CAPI  messages  arrive,  the CAPI file descriptor is added to the
47       list of file descriptors which the pppd monitors for input.   Once  the
48       connection is set up the pppd will start PPP negotiation on device dev‐
49       nam. When the pppd enters  the  DEAD  phase,  the  connection  will  be
50       dropped  (if  it is still active) When operating in dial-on-demand mode
51       with wakeup on incoming calls, in phase DORMANT the plugin  will  setup
52       CAPI2.0 to accept incoming calls.  To wakeup pppd when an incoming call
53       arrives, the plugin will generate an UDP packet to the discard port (9)
54       of  the  gateway,  so  don't filter this packet or wakeup by incoming a
55       call will not work.
56
57

MODES OF OPERATION

59       normal dial out
60              Simply make a connection, for example to your Internet provider.
61              Required options: number.
62              Recommended options: msn.
63              Other possible options: controller, dialmax, dialtimeout, proto‐
64              col and redialdelay.
65
66
67       dial out with callback
68              Call  a given number, the called party rejects the call and then
69              calls back.
70              Required options: number and coso remote.
71              Recommended options: cli and msn or inmsn.
72              Other possible options: cbwait, controller, connectdelay,  dial‐
73              timeout, protocol
74
75
76       dial out on demand
77              Initiate  the  connection only on demand, i.e. when data traffic
78              is present and drop the connection after a fix  amount  of  idle
79              time.
80              Required options: number.
81              Required pppd options: demand, connect, idle.
82              Recommended options: msn.
83              Other possible options: controller, dialmax, dialtimeout, proto‐
84              col and redialdelay.
85
86
87       dial out on demand on an incoming phone call
88              Initiate the connection only on demand, i.e. when  data  traffic
89              is  present  or  an incoming phone call is detected and drop the
90              connection after a fix amount of idle time. This  is  useful  if
91              you  are  not at home and you want your computer to make an con‐
92              nection to the Internet.
93              Required options: number and cli.
94              Required options: number, voicecallwakeup and inmsn and/or cli.
95              Required pppd options: demand, connect, idle.
96              Recommended options: msn.  Other possible  options:  controller,
97              dialmax, dialtimeout, protocol, redialdelay and inmsn.
98
99
100       wait for dial in
101              Wait for calls and accept incoming calls.
102              Recommended options: cli and msn or inmsn.
103              Possible  options: connectdelay, controller, dialtimeout, proto‐
104              col
105
106
107       wait for dial in and call back.
108              Wait for calls, reject the call and then call back.
109              Required options: cbnumber.
110              Recommended options: cli and msn or inmsn.
111              Other possible options: cbdelay, connectdelay, controller, dial‐
112              timeout, protocol
113
114
115       dial on demand and also wait for dial in
116              Initiate  the  connection only on demand, i.e. when data traffic
117              is present or when the other side dial in and drop  the  connec‐
118              tion after a fix amount of idle time.
119              Required options: number and inmsn and/or cli.
120              Recommended options: cli and msn or inmsn.
121              Optional options: coso caller.
122              Other possible options: cbdelay, connectdelay, controller, dial‐
123              timeout, protocol
124
125
126       dial on demand and also wait for dial in with COSO.
127              Initiate the connection only on demand, i.e. when  data  traffic
128              is  present  or when the other side dial in and drop the connec‐
129              tion after a fix amount of idle time. If option  coso  local  is
130              set, pppd will reject an incoming call from the remote party and
131              will callback.  With the option  coso  remote  set,  the  remote
132              party should reject the incoming call and call back.
133              Required  options:  number, inmsn and/or cli, coso local or coso
134              remote.
135              Recommended options: cli and msn or inmsn.
136              Other possible options: cbdelay, connectdelay, controller, dial‐
137              timeout, protocol
138
139
140       leased line
141              set  up  a  leased line connection, with or without CAPI channel
142              bundling.
143              Required options: channels.  Other possible options:
144              connectdelay, controller, dialtimeout and protocol
145
146
147

OPTIONS

149       avmadsl
150              make an DSL connection with the Fritz!Card DSL controller.   The
151              parameters  for  the  DSL  connection  will  be loaded from file
152              /etc/drdsl/adsl.conf. This file can be edited or will be created
153              by the program drdsl.
154
155
156       cbdelay <seconds>
157              Number  of seconds to wait before callback, when acting as dial-
158              in server with callback. Default value is 2 seconds.
159
160
161       cbnumber <phone numbers>
162              List of phone numbers for callback, separated  by  commas,  when
163              acting as dial-in server with callback.
164
165
166       cbwait <seconds>
167              Time  to wait for callback before giving up. Default value is 60
168              seconds.
169
170
171       channels <channel specification>
172              List of b-channels or ranges to activate leased line mode, sepa‐
173              rated by commas.
174
175
176       cli <phone numbers>
177              List of numbers from which incoming calls will be accepted, sep‐
178              arated by commas.
179
180
181       clicb  The option is retained  for  compatibility  reasons  only.   Use
182              option coso local or coso remote instead.
183              Enable  callback  mode.   When option number is set, call number
184              and wait for callback.  When option number is not set, wait  for
185              incoming  call,  reject  the call and call back.  This option is
186              optional if the cbnumber option is set.
187
188
189       connectdelay <seconds>
190              Number of seconds to wait after a connection is set  up,  before
191              PPP negotiation starts. Default value is 0 seconds.  This option
192              is useful when connecting with protocol  modem.   Some  Internet
193              access  servers  will  hang  up if they receive data immediately
194              after the connection is established.
195
196
197       controller <controller specification>
198              For point-to-multipoint <controller specification> is  only  the
199              CAPI  2.0  controller number, default is 1.  For point-to-point,
200              specify <controller number>,<ddi>,<length of internal numbers>
201
202
203       controller[1-3] <controller specification>
204              Like option controller.  Used to  specify  more  than  one  con‐
205              troller
206
207
208       coso caller
209              No callback is done, the costs are assigned to the caller.
210
211
212       coso local
213              The  costs are assigned to the local party.  On an incoming call
214              pppd will reject the call and callback.
215
216
217       coso remote
218              The costs are assigned to the remote party.  On an outgoing call
219              the remote party will reject the call and callback.
220
221
222       dialmax <times>
223              Maximum  number  of  times  the  list  of phone numbers is tried
224              before giving up.  Default value is 4.
225
226
227       dialtimeout <seconds>
228              Time to wait for the connection to be established or fail before
229              giving up.  Default value is 60 seconds.
230
231
232       inmsn <msn>
233              List of phone numbers to monitor for calls, separated by commas.
234              If this option is not set, the value of option msn is used.
235
236
237       inmsn[1-3] <msn>
238              List of phone numbers to monitor for calls on controller  speci‐
239              fied  by  option  controller[1-3], separated by commas.  If this
240              option is not set, the value of option msn[1-3] is used.
241
242
243       msn <msn>
244              Phone number used to make outgoing calls. Also used for incoming
245              calls if option inmsn is not set.
246
247
248       msn[1-3] <msn>
249              Phone number used to make outgoing calls on controller specified
250              by option controller[1-3].  Also  used  for  incoming  calls  if
251              option inmsn[1-3] is not set.
252
253
254       number <phone numbers>
255              List  of phone numbers to call, separated by commas.  Every num‐
256              ber in the list is called until a connection can be established.
257              When  the end of the list is reached, the first number is called
258              again.  See option dialmax.
259
260
261       numberprefix <prefix>
262              phone number to dial to access an  outside  line.  For  example,
263              numberprefix 0.
264
265
266       numberprefix[1-3] <prefix>
267              phone  number  to  dial to access an outside line for controller
268              specified by option controller[1-3]. For example,  numberprefix1
269              0.
270
271
272       protocol  hdlc  |  x75  |  v42bis  |  modem | analogmodem | v110async |
273       v120async
274              ISDN protocol to use. With hdlc and adskpppoe, the  sync  option
275              must  be  added to the pppd.  With x75, v42bis, modem, v110async
276              and v120async the sync option MUST NOT be enabled. Default value
277              is   hdlc.   Not  all  controllers  support  v42bis,  modem  and
278              v120async.  Use capiinfo(8) to view  which  features  your  con‐
279              troller supports.
280
281
282       redialdelay <seconds>
283              Number  of seconds to wait between redialing. Default value is 5
284              seconds.
285
286
287       voicewakeup
288              With this option a incoming voicecall can  trigger  an  outgoing
289              connection setup.
290
291

EXAMPLE FOR NORMAL DIAL OUT

293       Probably  the  most  common use of pppd is to dial out to an ISP.  This
294       can be specified with a command like
295
296              pppd call isp
297
298       where the /etc/ppp/peers/isp file is set up by the system administrator
299       to resemble the following:
300
301              sync
302              noauth
303              defaultroute
304              name USERNAME
305              plugin capiplugin.so ®msn MSN
306              number PHONENUMBER
307              protocol hdlc
308              ipcp-accept-local
309              ipcp-accept-remote
310              /dev/null
311
312       and  where the files /etc/ppp/pap-secrets and /etc/ppp/chap-secrets are
313       set up by the system administrator to resemble the following:
314
315              USERNAME * PASSWORD *
316
317
318

EXAMPLE OF DIAL OUT WITH CALLBACK

320       Dial out with callback can be specified with a command like
321
322              pppd call isp-callback
323
324       where the /etc/ppp/peers/isp-callback file is  set  up  by  the  system
325       administrator to resemble the following:
326
327              sync
328              noauth
329              defaultroute
330              name USERNAME
331              plugin capiplugin.so
332              msn MSN
333              number PHONENUMBER
334              coso remote
335              cli PHONENUMBER
336              protocol hdlc
337              ipcp-accept-local
338              ipcp-accept-remote
339              /dev/null
340
341       and  where the files /etc/ppp/pap-secrets and /etc/ppp/chap-secrets are
342       set up by the system administrator to resemble the following:
343       USERNAME * PASSWORD *
344
345

EXAMPLE DIAL OUT ON DEMAND

347       To dial out on demand and drop the link after 120 seconds idle time  on
348       the link add this line to the /etc/inittab file:
349
350              isp:23:respawn:/usr/sbin/pppd  call  isp  demand connect "" idle
351              120
352
353       where the /etc/ppp/peers/isp file is set up by the system administrator
354       to resemble the following:
355
356              sync
357              noauth
358              defaultroute
359              name USERNAME
360              plugin capiplugin.so ®msn MSN
361              number PHONENUMBER
362              protocol hdlc
363              ipcp-accept-local
364              ipcp-accept-remote
365              /dev/null
366
367       and  where the files /etc/ppp/pap-secrets and /etc/ppp/chap-secrets are
368       set up by the system administrator to resemble the following:
369
370              USERNAME * PASSWORD *
371
372

EXAMPLE DIAL OUT ON DEMAND AND ON AN INCOMING PHONE CALL

374       To dial out on demand or on an incoming phone call and  drop  the  link
375       after 120 seconds idle time on the link add this line to the /etc/init‐
376       tab file:
377
378              isp:23:respawn:/usr/sbin/pppd call isp demand  connect  ""  idle
379              120
380
381       where the /etc/ppp/peers/isp file is set up by the system administrator
382       to resemble the following:
383
384              sync
385              noauth
386              defaultroute
387              name USERNAME
388              plugin capiplugin.so
389              msn MSN
390              number PHONENUMBER
391              cli VOICEPHONENUMBER
392              voicecallwakeup
393              protocol hdlc
394              ipcp-accept-local
395              ipcp-accept-remote
396              /dev/null
397
398       and where the files /etc/ppp/pap-secrets and /etc/ppp/chap-secrets  are
399       set up by the system administrator to resemble the following:
400
401              USERNAME * PASSWORD *
402
403

EXAMPLE DIAL OUT ON DEMAND AND ALSO ACCEPT AN INCOMING DATA CALL

405       To  dial  out  on  demand or on an incoming data call and drop the link
406       after 120 seconds idle time on the link add this line to the /etc/init‐
407       tab file:
408
409              isp:23:respawn:/usr/sbin/pppd  call  isp  demand connect "" idle
410              120
411
412       where the /etc/ppp/peers/isp file is set up by the system administrator
413       to resemble the following:
414
415              sync
416              noauth
417              defaultroute
418              name USERNAME
419              plugin capiplugin.so
420              msn MSN
421              number PHONENUMBER
422              inmsn MSN
423              protocol hdlc
424              ipcp-accept-local
425              ipcp-accept-remote
426              /dev/null
427
428       and  where the files /etc/ppp/pap-secrets and /etc/ppp/chap-secrets are
429       set up by the system administrator to resemble the following:
430
431              USERNAME * PASSWORD *
432
433

EXAMPLE OF WAIT FOR DIAL IN WITHOUT CLI AUTHENTICATION

435       Wait for incoming calls, accept them according to options  msn,  inmsn,
436       and protocol.
437
438       Do  not provide option cli to the capiplugin.  Start a pppd for every b
439       channel.  Authorization is  checked  using  PAP  or  CHAP  and  the  IP
440       addresses   are  assigned  according  to  the  /etc/ppp/pap-secrets  or
441       /etc/ppp/chap-secrets file.  Assume that  the  server  has  IP  address
442       192.168.0.1,  the clients are to be assigned IP addresses starting from
443       192.168.0.2, and the hostname of the  server  is  "dialinserver".   Add
444       these two lines to the /etc/inittab file:
445
446              p0:23:respawn:/usr/sbin/pppd call incoming-noncli
447              p1:23:respawn:/usr/sbin/pppd call incoming-noncli
448
449       where the /etc/ppp/peers/incoming-noncli file is set up to resemble the
450       following:
451
452              sync
453              auth
454              plugin capiplugin.so
455              inmsn MSN
456              protocol hdlc 192.168.0.1:
457
458       with the files /etc/ppp/pap-secrets and /etc/ppp/chap-secrets set up to
459       resemble the following:
460
461              user1 dialinserver PASSWORD1 192.168.0.2
462              user2 dialinserver PASSWORD2 192.168.0.3
463
464

EXAMPLE OF WAIT FOR DIAL IN WITH CLI AUTHENTICATION

466       Wait  for  incoming calls, accept them according to options msn, inmsn,
467       cli and protocol.
468
469       Start a pppd for every client.  Assume that the server has  IP  address
470       192.168.0.1  and  the  clients are to be assigned IP addresses starting
471       from 192.168.0.2.  Add these three lines to the /etc/inittab file:
472
473              p0:23:respawn:/usr/sbin/pppd   call   incoming-cli   cli   04711
474              192.168.0.1:192.168.0.2
475              p1:23:respawn:/usr/sbin/pppd   call   incoming-cli   cli   04712
476              192.168.0.1:192.168.0.3
477              p2:23:respawn:/usr/sbin/pppd   call   incoming-cli   cli   04713
478              192.168.0.1:192.168.0.4
479
480
481       where  the  /etc/ppp/peers/incoming-cli  file is set up to resemble the
482       following:
483
484              sync
485              noauth
486              plugin capiplugin.so
487              inmsn MSN
488              protocol hdlc
489
490

EXAMPLE OF WAIT FOR DIAL IN WITH CLI AUTHENTICATION AND CALLBACK

492       Wait for incoming calls, accept them according to options  msn,  inmsn,
493       cli and protocol, reject incoming calls and call back.
494
495       Start  a  pppd for every client.  Assume that the server has IP address
496       192.168.0.1 and the clients are to be assigned  IP  addresses  starting
497       from 192.168.0.2.  Add these three lines to the /etc/inittab file.
498
499              p0:23:respawn:/usr/sbin/pppd  call incoming-cli cli 04711 cbnum‐
500              ber 4711 192.168.0.1:192.168.0.2
501              p1:23:respawn:/usr/sbin/pppd call incoming-cli cli 04712  cbnum‐
502              ber 4712 192.168.0.1:192.168.0.3
503              p2:23:respawn:/usr/sbin/pppd  call incoming-cli cli 04713 cbnum‐
504              ber 4713 192.168.0.1:192.168.0.4
505
506       where the /etc/ppp/peers/incoming-cli file is set up  to  resemble  the
507       following:
508
509              sync
510              noauth
511              plugin capiplugin.so
512              inmsn MSN
513              protocol hdlc
514
515

EXAMPLE OF A LEASED LINE CONNECTION WITH HDLC

517       Assume  that the server has IP address 192.168.0.1 and the peer has the
518       IP address 192.168.0.2.  Add this line to the /etc/inittab file:
519
520              p0:23:respawn:/usr/sbin/pppd call leased-hdlc controller 1 chan‐
521              nels 1 192.168.0.1:192.168.0.2
522
523       where  the  /etc/ppp/peers/leased-hdlc  file  is set up to resemble the
524       following:
525
526              sync
527              noauth
528              lcp-echo-interval 5
529              lcp-echo-failure 3
530              lcp-max-configure 50
531              lcp-max-terminate 2
532              noccp
533              noipx
534              persist
535              plugin capiplugin.so
536              protocol hdlc
537
538

EXAMPLE OF A LEASED LINE CONNECTION WITH V42BIS

540       Assume that the server has IP address 192.168.0.1 and the peer has  the
541       IP  address  192.168.0.2.   Add  this line to the /etc/inittab file for
542       server 1 (192.168.0.1):
543
544              p0:23:respawn:/usr/sbin/pppd  call  leased-v42bis  controller  1
545              channels 1 192.168.0.1:192.168.0.2
546
547       and this line to the /etc/inittab file for server 1 (192.168.0.2):
548
549              p0:23:respawn:/usr/sbin/pppd  call  leased-v42bis  controller  1
550              channels p1 192.168.0.2:192.168.0.1
551
552       where the /etc/ppp/peers/leased-v42bis file is set up to  resemble  the
553       following:
554
555              sync
556              noauth
557              lcp-echo-interval 5
558              lcp-echo-failure 3
559              lcp-max-configure 50
560              lcp-max-terminate 2
561              noccp
562              noipx
563              persist
564              plugin capiplugin.so
565              protocol v42bis
566
567

CAVEATS

569       Every  pppd awaiting incoming calls can receive an incoming call first.
570       So when two pppds are started to monitor the same  MSN,  one  with  CLI
571       Authentication and the other without, the following can happen:
572
573              The  Client  with the CLI specified to the first pppd calls, but
574              the pppd without the cli option  receives  the  call  first  and
575              accepts it.
576
577       To  combine CLI Authentication and PAP/CHAP Authentication, use one MSN
578       for CLI authenticated calls and another for the PAP/CHAP  authenticated
579       calls.
580
581

DIAGNOSTICS

583       Messages  are  sent  to the syslog daemon just as in normal pppd opera‐
584       tion; see the pppd manual page.
585
586

SEE ALSO

588       pppd(8), capiinfo(8), capiinit(8), capictrl(8)
589
590

AUTHORS

592       Carsten Paeth (calle@calle.in-berlin.de)
593       AVM GmbH Berlin (info@avm.de)
594
595
596
597                                                                 CAPIPLUGIN(8)
Impressum