[Freeswitch-users] E-mail as user id and bridging

Iñaki Baz Castillo ibc at aliax.net
Sun Nov 16 09:57:46 PST 2008


El Domingo, 16 de Noviembre de 2008, Jan Kubr escribió:
> Basically I want the user to use his e-mail to login with her SIP
> phone. This works fine when the user id is james at yahoo.com (in a
> domain that is the IP of the FS box), but then it is not possible to
> bridge a call that user.

An username part if a SIP or MAILTO URI can't contain @ symbol, it's illegal 
as it's, in fact, the separator of the userpart and domain part.

What you can do is escaping "@" in hexadecimal before creating the SIP URI (I 
don't know the code for "@", but "a" == "%61"), so:

  sip:alice at domain.com == sip:%lice at domain.com
  
So supposing an user has an email:
  carol at gmail.com
and supposing that the hexadecimal conversion of "@" is "%88" then you can 
create a SIP URI like:
  sip:carol%88gmail.com at your_fs_domain


-- 
Iñaki Baz Castillo




More information about the FreeSWITCH-users mailing list