Thanks. But I don't understand the use of aliases table.
I have defined some subscriber users, with username (like BOB) and password (BOBPWD). So, if I wanted to access the system, I would send a REGISTER message with correct username and password (authorization required). Then my proxy address will be "sip:BOB@IP_PROXY" and my Contact will be "sip:BOB@MY _IP_ADRRESS". These information are saved into USER LOCATION table (save("location") function). Now, through DB_aliases module and dbaliases table, I can define some aliases for BOB (like "sip:1234@IP_PROXY", etc...), so if an INVITE for bob has "sip:1234@IP_PROXY" as R-URI, with db_aliases_lookup() function I can rewrite R-URI with Bob's URI ("bob@IP_PROXY") and then call the lookup("location") function. But I don't understand how I can use the ALIASES table. Are there any example explaining its use ? Sorry.
Regards, daniel
Iñaki Baz Castillo wrote:
El Thursday 15 November 2007 14:31:52 Daniel escribi�:
Hi all, what is the different between Aliases table and DB aliases table? What is their use ?
"aliases" table is same as "location" table but it should be used to look for alias with the function lookup("aliases").
Of course, aliases are simpler than the complex location or aliases tables that manage more info about users, so in order to implement alias system in a simpler way the module ALIAS_DB exists and its table dbaliases.
Note that dbaliases table is much simpler (it's just valid for aliases), Look at the module doc: http://www.openser.org/docs/modules/1.3.x/alias_db.html
El Thursday 15 November 2007 15:17:36 Daniel escribió:
Thanks. But I don't understand the use of aliases table.
I have defined some subscriber users, with username (like BOB) and password (BOBPWD). So, if I wanted to access the system, I would send a REGISTER message with correct username and password (authorization required). Then my proxy address will be "sip:BOB@IP_PROXY" and my Contact will be "sip:BOB@MY _IP_ADRRESS". These information are saved into USER LOCATION table (save("location") function). Now, through DB_aliases module and dbaliases table, I can define some aliases for BOB (like "sip:1234@IP_PROXY", etc...), so if an INVITE for bob has "sip:1234@IP_PROXY" as R-URI, with db_aliases_lookup() function I can rewrite R-URI with Bob's URI ("bob@IP_PROXY") and then call the lookup("location") function. But I don't understand how I can use the ALIASES table. Are there any example explaining its use ?
If you use DB_ALIASES module you don't need ALIASES table at all. ALIASES table is other way of implement aliases, just it.
For example:
* alias with DB_ALIASES module:
table dbaliases: alias_username: 1234 alias_domain: IP_PROXY username: bob domain: IP_PROXY
db_aliases_lookup() will rewrite URI when it's 1234@IP_PROXY and it'll become bob@IP_PROXY
Later lookup("location") will look for the contact of that AOR.
* alias with ALIASES table:
table aliases: username: 1234 domain: IP_PROXY contact: sip:bob@IP_PROXY
lookup("aliases") will rewrite URI when it's 1234@IP_PROXY and it'll become bob@IP_PROXY
Later lookup("location") will look for the contact of that AOR.
ok now?