Re: [Freeswitch-users] E-mail as user id and bridging
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@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@domain.com == sip:%lice@domain.com
OK I see now. I didn't realize I'm using a SIP URI here (since I'm only calling the user "locally") whose userinfo part can't contain the at-sign (as found here: http://tools.ietf.org/html/rfc3261#section-25.1). The escaping doesn't do quite what I wanted, but thanks a lot for the effort. I'll stick to what I'm doing now which is that I replace the at-sign with a dot and take that as a username. Sorry for the newbie question and thanks all for the answers. Jan
Its better to use a dash... a dot is valid in the username part of an email address... so what dot do you split on? Example brian.west@domain.com brian@west.domain.com Even worse brian.k.west@domain.com Lets go even worse... brian.k.west@sub.domain.com So which do you split on :) Not very clear is it? /b On Nov 16, 2008, at 4:13 PM, Jan Kubr wrote:
I'll stick to what I'm doing now which is that I replace the at-sign with a dot and take that as a username. Sorry for the newbie question and thanks all for the answers.
Jan
participants (2)
-
Brian West
-
Jan Kubr