michael@13: ISN (ITAD Subscriber Number) lookup integration contribution code michael@13: michael@13: Contribution michael@13: michael@13: This contribution introduces ISN formatting logic into the OpenSIPS michael@13: ENUM module, allowing it to perform NAPTR based ISN lookups on the michael@13: user part of the Request-URI in addition to the existing ENUM lookups. michael@13: michael@13: Rationale michael@13: michael@13: This extends the utility of the existing E.164 formatting logic which michael@13: previously caused valid ISN lookups to fail (although the OpenSIPS michael@13: documentation did suggest that lookups to freenum.org would succeed.) michael@13: michael@13: Compliance michael@13: michael@13: The author believes that the introduced logic complies with the michael@13: relevant ITAD standards as defined by RFC 3872 and RFC 2871, however michael@13: it seems that at this time ISN is rather loosely defined according to michael@13: nonstandard documentation provided by freenum.org. michael@13: michael@13: Location michael@13: michael@13: http://scm.europalab.com/contrib/opensips/ michael@13: http://scm.europalab.com/contrib/file/tip/opensips/ michael@13: michael@13: Instructions michael@13: michael@13: To integrate this contributed logic into the source code tree of michael@13: a OpenSIPS distribution, download the unified diff and use the michael@13: patch(1) command: michael@13: michael@13: $ cd /tmp && mkdir enum-patch && cd enum-patch michael@13: $ wget http://scm.europalab.com/contrib/raw-file/tip/opensips/enum-isn.diff michael@13: $ tar zxf /tmp/opensips--tls.tar.gz michael@13: $ cd opensips--tls michael@13: $ patch -p0 <../enum-isn.diff michael@13: michael@14: Testing michael@14: michael@14: A basic test of this contribution michael@14: Once compiled and installed, a basic test of this contributed software michael@14: involves calling the new exported function in the routing script of the michael@14: OpenSIPS configuration file: michael@14: michael@14: # dial '1234*256' from a UAC first michael@14: isn_query(); michael@14: t_relay(); michael@14: michael@14: According to the freenum.org cookbook, the ISN '1234*256' is being michael@14: provided for testing. After dialing the caller hears monkeys screaming. michael@14: michael@13: Disclaimer michael@13: michael@13: This software contribution is based on source code from OpenSIPS SVN michael@13: revision 6511. The author makes no guarantees as to this contribution. michael@13: A user who downloads and executes it does so at his own risk. michael@13: michael@13: Michael Schloh von Bennewitz michael@13: http://michael.schloh.com/ michael@13: Monday, 18. January 2010