Goal (short description)

Goal is to set ENUM (RFC3761,Wikipedia) records to provide E.164 telephone number to URI translation.

Applicability

It is applicable for institution or even person using E.164 telephone number and willing to provide such translation.

Prerequisites (OS, dependencies on other software)

  • DNS server with NAPTR support (i.e. current BIND9).
  • Enum domain which is constructed as reversed telephone number +123456 -> 6.5.4.3.2.1.suffix.

Suffixes

e164.arpa - Public User Enum tree
If you want to use Public User Enum you need to be eligible user of number(s) and register your number or prefix by registrator in country where the number belongs. Your eligibility is validated by special process that depends on your registrator (validation SMS, TSP Invoice, ...).
Current status of golden tree (e164.arpa) delegations could be fount at enumdata.org

nrenum.net - Private NREN tree
nrenum.net is an effort of National Research and Education Networks (NREN) and provides nrenum.net provides countries, where the Golden ENUM Tree (e164.arpa) is not (yet) available, with the possibility to publish ENUM data. The nrenum.net tree is queried by the participating partners in case no ENUM data is found in the Golden Tree.
See nrenum.net for more infromation.

sample.edu - Institutional private tree
You can have you own private tree within you domain. It is usable for internal routing i.e. in case that you have several locations or so and you need to share different translation different from golden tree or nrenum. You don't need any validation here.
There are also lots of managed private tree like enum.org enum.info and so on.

Configuration (OS agnostic)

Number prefix is 123456 (with 3 digit branch) and suffix is e164.arpa.

  • Create zone 6.5.4.3.2.1.e164.arpa
  • Prepare records
    Following records use wildcards, which can fasten the setup but can be sometimes problematic. Be carefull especially when using more records (for dfferent numbers or prefixes)
    ;                                       order pref flags service    regexp                            replacement
    *.6.5.4.3.2.1.e164.arpa.   IN  	NAPTR  	100   10   "u"  "E2U+sip"  "!^(.*)$!sip:\\1@sample.edu!"           .
    *.6.5.4.3.2.1.e164.arpa.   IN 	NAPTR 	100   10   "u" 	"E2U+h323" "!^\\+12(3456.*)$!h323:\\1@sample.edu!" .
    
    These recorda provides translation for numbers starting with +123456 (+123456789 but also +1234567899999).
    First one is for SIP service. Translation of +123456789 leads to URI sip:123456789@sample.edu.
    Second one is for H.323 service. Translation of +123456789 leads to URI h323:3456789@sample.edu.
    You can also set up records for full numbers
    $ORIGIN 6.5.4.3.2.1.e164.arpa.
    ;     TTL              order pref flags service    regexp                            replacement
    9.8.7 3600  IN  NAPTR  	100   10   "u"  "E2U+sip"  "!^(.*)$!sip:userA@sample.edu!"     .
    9.8.7 3600  IN 	NAPTR 	100   10   "u" 	"E2U+h323" "!^(.*)$!h323:user789@sample.edu!"  .
    1.1.1       IN  NAPTR  	100   10   "u"  "E2U+sip"  "!^(.*)$!sip:info@sample.edu!"      .
    1.1.1       IN 	NAPTR 	100   10   "u" 	"E2U+h323" "!^(.*)$!h323:info111@sample.edu!"  .
    
    Different TTL (one hour) is set in the first two records. If there is no value specified, zone settings (SOA) or default is used (it is usually one or two days).
    If you are testing ENUM records consider setting up TTL to low numbers (minutes).
  • reload/restart the DNS server

Be careful when constructing regular expression as they can be a bit complicated. Test retrieval and functionality of your records carefully. Regexp is applied at the client side.

OS specific help

Validation, confirmation tests

Basic existence test

host -t naprt 1.1.1.6.5.4.3.2.1.e164.arpa.
or
dig -t naptr +short @nameserver 1.1.1.6.5.4.3.2.1.e164.arpa.

I found nice small script for those who don't like to transform the numbers to domain names manually

#!/bin/sh
host -t naptr $(echo $1 | rev | sed -e 's/[0-9]/&./g')e164.arpa

These commands just retrive dns record from server. To test regexp you can use php scripts at nona.net where e164.arpa, e164.org, e164.info and enum.org are queried. At CESNET site you can find script that looks up e164.apra, nrenum.net and e164.org.

  • No labels