[Serusers] How can I redirect SIP invitation

Nicolas Ruiz nruiz at vivaction.com
Tue Nov 16 14:28:06 CET 2004


HI Jan,

In fact, I have on SER database :

Table GRP :
mysql> select * from grp;
+---------------+------------------+--------------+-------------------------
----+
| username  | domain            | grp       | last_modified         |
+---------------+------------------+--------------+-------------------------
-----+
| TEST        | vivaction.net | TEST      | 2004-10-13 13:36:48 |
| 170703232| vivaction.net | TEST      | 2004-11-16 12:34:26 |
| 170703233| vivaction.net | TEST      | 2004-11-16 12:34:26 |
| 170703234| vivaction.net | TEST      | 2004-11-16 12:34:26 |
| 170703235| vivaction.net | TEST      | 2004-11-16 12:34:26 |
| 170703236| vivaction.net | TEST      | 2004-11-16 12:34:26 |
| 170703237| vivaction.net | TEST      | 2004-11-16 12:34:26 |
| 170703238| vivaction.net | TEST      | 2004-11-16 12:34:26 |
+---------------+------------------+--------------+-------------------------
-----+

mysql> select * from subscriber;

Only One user. the user TEST

 TEST      | sip.vivaction.net | password     | nruiz at vivaction.com       |
2004-10-06 14:12:37

And when I execute  : serctl ul show >> the user TEST is registered.

How can i redirect an incoming call to this group ?

Thanks for your help

Best Regards
Nicolas RUIZ



-----Message d'origine-----
De : Jan Janak [mailto:jan at iptel.org]
Envoyé : mardi 16 novembre 2004 13:50
A : Nicolas Ruiz
Cc : serusers at lists.iptel.org
Objet : Re: [Serusers] How can I redirect SIP invitation


That's what lookup function is for. It will take the URI in the
Request-URI and lookup all contacts for that URI in the database. So if
user test is registered with your server and has many contacts
registered then just do lookup("location") and the function will return
all of them. Later, when you call t_relay, the server will fork the
request and forward a copy to each registered contact.

  Jan.

On 16-11 10:40, Nicolas Ruiz wrote:
> Hello,
>
> - I have a group : "TEST"
> - In this group, i have a lot of phone's numbers.
>
> Only my group "TEST" is REGISTERED on SER.
>
> How can i redirect INVITE requests who arrive on SER to this phone's
> numbers, to the IP@ of the group "TEST".
>
> I have configured that, for this moment :
>
>    if (is_user_in("To","TEST")){
>                         forward("62.38.29.6", 5060);
>                         break;
>                 };
>
> HOW CAN I FIND THE IP@ OF THE GROUP "TEST" REGISTERED ???
>
> Thanks a lot for your help.
>
> Best Regards
> Nicolas RUIZ
>

> _______________________________________________
> Serusers mailing list
> serusers at lists.iptel.org
> http://lists.iptel.org/mailman/listinfo/serusers





More information about the sr-users mailing list