Distributed Universal Number Discovery - Example

Example

In the Asterisk CLI one can do a lookup by hand to test if a DUNDi configuration works.

asterisk1*CLI> dundi lookup 301@priv bypass 1. 0 IAX2/priv:ByWFbOGKgGmZbM43BJHSZw@192.168.1.2/301 (EXISTS) from 00:0c:29:d2:d8:ec, expires in 3600 s DUNDi lookup completed in 113 ms

The above DUNDi lookup tells the PBX to ask the known peers if they know how to reach extension 301 in the "priv" network. The answer consists of 6 parts:

  • The used protocol to communicate is IAX2.
  • The context-name is "priv".
  • The secret key of the PBX, which can redirect you to extension 301 is ByWHSZw (this changes periodically)
  • The address of this PBX is 192.168.1.2 (or some domainname, should be reachable by the calling party)
  • The extension to call is 301 (this can be different from what you asked for, e.g. when calls from the outside are not allowed directly to an internal extension)
  • "EXISTS" tells us the PBX is advertising this number. It is possible the PBX advertises a lot more extensions than really are connected, so it is no guarantee the extension can be reached.

In order to prevent the network from overloading and at the same time keep the responses as quick as possible, the involved peers will cache the lookups they see. Because the used keys may become invalid after some period, each lookup has some expiry date. This defaults to one hour.

When no context is given with a lookup, DUNDi defaults to the E.164 context. This means you are looking for normal (international) phone-numbers, like 0031201234567 (some bogus number in Amsterdam, The Netherlands) In order to do so, you have to peer with at least one other peer in the E164 trust group. The peers in this group are bound to the Digium GPA (Digium General Peering Agreement) (PDF)

Read more about this topic:  Distributed Universal Number Discovery

Famous quotes containing the word example:

    Our intellect is not the most subtle, the most powerful, the most appropriate, instrument for revealing the truth. It is life that, little by little, example by example, permits us to see that what is most important to our heart, or to our mind, is learned not by reasoning but through other agencies. Then it is that the intellect, observing their superiority, abdicates its control to them upon reasoned grounds and agrees to become their collaborator and lackey.
    Marcel Proust (1871–1922)