DUNDi Enterprise Configuration IAX

This is all you should need to setup DUNDi between two boxes with IAX.
You can add more boxes to your network in a similar way.

See also: DUNDi Enterprise Configuration SIP

(Based on configurations in the configs directory from the Asterisk source code and documents published by Brian K. West aka bkw_)

On both boxes in your extensions.conf:

; the first three contexts are separated in order to group them by the appropriate dundi priority

; Private DUNDi network
[dundi-priv-canonical]
; Direct numbers (dundi priority 0)

[dundi-priv-customers]
; If you are an ITSP or Reseller, list your customers here.  (dundi priority 100)

[dundi-priv-via-pstn]
; If you are freely delivering calls to the PSTN, list them here (dundi priority 400)

; this context is used to group the 3 above and reference in iax.conf for the incoming calls referred by dundi
[dundi-priv-local]
include => dundi-priv-canonical
include => dundi-priv-customers
include => dundi-priv-via-pstn

; the rest of the contexts are used for calls placed locally to go out to our dundi peers
; entry point is macro-dundi-priv

[dundi-priv-switch]
; Just a wrapper for the switch
switch => DUNDi/priv

[dundi-priv-lookup]
include => dundi-priv-local
include => dundi-priv-switch

[macro-dundi-priv]
exten => s,1,Goto(${ARG1},1)
include => dundi-priv-lookup


iax.conf on both boxes:
[priv]
type=user
dbsecret=dundi/secret
context=dundi-priv-local


In this example, "dundi/secret" should be taken literally. It refers to the family/key in astdb that pbx_dundi.so stores a password that is changed every hour. It's also what pbx_dundi.so substitutes in place of ${SECRET} below when replying to queries.


dundi.conf on both boxes under [mappings]:
In many cases you will need to replace ${IPADDR} with your local IP address
priv => dundi-priv-canonical,0,IAX,priv:${SECRET}@${IPADDR}/${NUMBER},nopartial
priv => dundi-priv-customers,100,IAX,priv:${SECRET}@${IPADDR}/${NUMBER},nopartial
priv => dundi-priv-via-pstn,400,IAX,priv:${SECRET}@${IPADDR}/${NUMBER},nopartial



now on each box cd /var/lib/asterisk/keys

astgenkey -n [BOXNAMEHERE]


Press enter do not put a password on the keys unless you want to init keys every time you start asterisk.

Now exchange public keys between the boxes.



Box A dundi.conf:

[DE:AD:BE:EF:DE:AD]   <-- EID/MAC from BOX B
model = symmetric
host = boxb.domain.com
inkey = BOXB   <- BOX B's public key
outkey = BOXA  <- BOX A's private key
include = priv
permit = priv
qualify = yes
order = primary


Box B dundi.conf:


[BE:EF:DE:AD:BE:EF]  <-- EID/MAC from BOX A
model = symmetric
host = boxa.domain.com
inkey = BOXA   <- BOX A's public key
outkey = BOXB  <- BOX B's private key
include = priv

permit = priv
qualify = yes
order = primary


Now you can do this in the context which your devices dialout:

exten => _91NXXNXXXXXX,1,Macro(dundi-priv,${EXTEN:1})
exten => _91NXXNXXXXXX,2,Dial(Zap/g1/${EXTEN:1}) ; This is fall through example to a PSTN such a as PRI


And find numbers in your enterprise DUNDi network.

These same things apply to the e164 DUNDi network too.
This is all you should need to setup DUNDi between two boxes with IAX.
You can add more boxes to your network in a similar way.

See also: DUNDi Enterprise Configuration SIP

(Based on configurations in the configs directory from the Asterisk source code and documents published by Brian K. West aka bkw_)

On both boxes in your extensions.conf:

; the first three contexts are separated in order to group them by the appropriate dundi priority

; Private DUNDi network
[dundi-priv-canonical]
; Direct numbers (dundi priority 0)

[dundi-priv-customers]
; If you are an ITSP or Reseller, list your customers here.  (dundi priority 100)

[dundi-priv-via-pstn]
; If you are freely delivering calls to the PSTN, list them here (dundi priority 400)

; this context is used to group the 3 above and reference in iax.conf for the incoming calls referred by dundi
[dundi-priv-local]
include => dundi-priv-canonical
include => dundi-priv-customers
include => dundi-priv-via-pstn

; the rest of the contexts are used for calls placed locally to go out to our dundi peers
; entry point is macro-dundi-priv

[dundi-priv-switch]
; Just a wrapper for the switch
switch => DUNDi/priv

[dundi-priv-lookup]
include => dundi-priv-local
include => dundi-priv-switch

[macro-dundi-priv]
exten => s,1,Goto(${ARG1},1)
include => dundi-priv-lookup


iax.conf on both boxes:
[priv]
type=user
dbsecret=dundi/secret
context=dundi-priv-local


In this example, "dundi/secret" should be taken literally. It refers to the family/key in astdb that pbx_dundi.so stores a password that is changed every hour. It's also what pbx_dundi.so substitutes in place of ${SECRET} below when replying to queries.


dundi.conf on both boxes under [mappings]:
In many cases you will need to replace ${IPADDR} with your local IP address
priv => dundi-priv-canonical,0,IAX,priv:${SECRET}@${IPADDR}/${NUMBER},nopartial
priv => dundi-priv-customers,100,IAX,priv:${SECRET}@${IPADDR}/${NUMBER},nopartial
priv => dundi-priv-via-pstn,400,IAX,priv:${SECRET}@${IPADDR}/${NUMBER},nopartial



now on each box cd /var/lib/asterisk/keys

astgenkey -n [BOXNAMEHERE]


Press enter do not put a password on the keys unless you want to init keys every time you start asterisk.

Now exchange public keys between the boxes.



Box A dundi.conf:

[DE:AD:BE:EF:DE:AD]   <-- EID/MAC from BOX B
model = symmetric
host = boxb.domain.com
inkey = BOXB   <- BOX B's public key
outkey = BOXA  <- BOX A's private key
include = priv
permit = priv
qualify = yes
order = primary


Box B dundi.conf:


[BE:EF:DE:AD:BE:EF]  <-- EID/MAC from BOX A
model = symmetric
host = boxa.domain.com
inkey = BOXA   <- BOX A's public key
outkey = BOXB  <- BOX B's private key
include = priv

permit = priv
qualify = yes
order = primary


Now you can do this in the context which your devices dialout:

exten => _91NXXNXXXXXX,1,Macro(dundi-priv,${EXTEN:1})
exten => _91NXXNXXXXXX,2,Dial(Zap/g1/${EXTEN:1}) ; This is fall through example to a PSTN such a as PRI


And find numbers in your enterprise DUNDi network.

These same things apply to the e164 DUNDi network too.
Created by: gdalgliesh, Last modification: Sat 12 of May, 2012 (20:40 UTC) by admin
Please update this page with new information, just login and click on the "Edit" or "Discussion" tab. Get a free login here: Register Thanks! - Find us on Google+