Hi,
with an usuall SER setup a typical user account looks like this:
Primary sip address: sip:joe@myvoip.net Aliases:
Berlin incoming number: sip:493042423@myvoip.net Los Angeles "" : sip:1310232323@myvoip.net
If "joe" now calls out via a PSTN-GW the caller-id which is transmitted to the PSNT-GW would be "joe". Now "Joe" is clearly alphanumeric and no PSTN-GW (or the PSTN-Switch to which the PSTN-GW is connected) will accept "Joe" as caller-id.
All i can currently do is setting a default callerid on the PSTN-GW in case the incoming caller-id isnt valid.
What i would like to do though is to lookup if a user has an alias for a certain region and rewrite the the from line in the sip-packet going to the PSTN-GW.
Example: "Joe" uses the Berlin/german PSTN-GW or dials a german PSTN number. Now i would look into the alias table and search for either an alias starting with "49" or "4930" and if one is found set the from field to the according alias. In this case "493042423@myvoip.net".
This would ensure that, if possible, a matching caller-id would be set for every user.
Problems:
- "From" line rewriting is not RFC compliant. - I dont see any possebility to do this with the stock SER software
Questions:
- Which module would be a good starting point for adding this functionality? All which would be needed would be one command for looking up the alias list of a user from memory using regular expressions. - How do others cope with this problem?
The easy but not very elegant solution is to just use a valid e.164 number (ex. the LA number) as primary sip address. But that still doesnt fix the problem that "Joes" Los Angeles number would be set as caller-id even if he got a valid "berlin" number too and calls via a german PSTN termination.
best regards,
Arnd
At 08:26 PM 2/27/2004, Arnd Vehling wrote:
Hi,
with an usuall SER setup a typical user account looks like this:
Primary sip address: sip:joe@myvoip.net Aliases:
Berlin incoming number: sip:493042423@myvoip.net Los Angeles "" : sip:1310232323@myvoip.net
If "joe" now calls out via a PSTN-GW the caller-id which is transmitted to the PSNT-GW would be "joe". Now "Joe" is clearly alphanumeric and no PSTN-GW (or the PSTN-Switch to which the PSTN-GW is connected) will accept "Joe" as caller-id.
All i can currently do is setting a default callerid on the PSTN-GW in case the incoming caller-id isnt valid.
What i would like to do though is to lookup if a user has an alias for a certain region and rewrite the the from line in the sip-packet going to the PSTN-GW.
Example: "Joe" uses the Berlin/german PSTN-GW or dials a german PSTN number. Now i would look into the alias table and search for either an alias starting with "49" or "4930" and if one is found set the from field to the according alias. In this case "493042423@myvoip.net".
This would ensure that, if possible, a matching caller-id would be set for every user.
Problems:
- "From" line rewriting is not RFC compliant.
That's really not recomendable -- it is a ticket for interop troubles.
- I dont see any possebility to do this with the stock SER software
Use of Remote-Party-ID should solve your problem if I understood it right. (append_rpid_hf in auth module).
-jiri
Hello,
Jiri Kuthan wrote:
Use of Remote-Party-ID should solve your problem if I understood it right. (append_rpid_hf in auth module).
Ive read the module doc and browsed through the rfc but i couldnt relate this command to what i wanted to do.
What i want to do is to set the users valid e.164 number as caller-id in case the user has one, otherwise i would setup a default e.164 number.
I can set a default e.164 number using the pstn gw but i dont see how i can search the users "alias entries", select the most appropriate e.164 from it and set it in the sip packet going to the pstn gw so it will be used as the pstn caller-id for the outgoing call.
Usually a pstn gw will take the "username" from a sip address (sip:username@domain) and set it as caller-id for an outgoing call. Reading the rfc i couldnt find any other parameter for setting it.
The easy solution is to just give a user a an e.164 id as primary SER login. I.e. "sip:493012345@myvoip.net" but in case he has several valid e.164 (as aliases) i would like to set the most appropriate number for each pstn gw when he calls out there.
Example: If you has an german e.164 number and he uses a german PSTN gw i would use the german e.164 number and if he dialouts using an US pstn gw i would like to set the US number if he has any.
I am prepared to write the appropriate code for this but i want to make sure that i dont "re-invent the wheel" before i do this.
Did i made myself more clear this time?
-- Arnd
At 06:46 PM 2/28/2004, Arnd Vehling wrote:
Hello,
Jiri Kuthan wrote:
Use of Remote-Party-ID should solve your problem if I understood it right. (append_rpid_hf in auth module).
Ive read the module doc and browsed through the rfc but i couldnt relate this command to what i wanted to do.
What i want to do is to set the users valid e.164 number as caller-id in case the user has one, otherwise i would setup a default e.164 number.
That's what it does. It looks up number "owned" by the user by his digest identity and appends it to request.
I can set a default e.164 number using the pstn gw but i dont see how i can search the users "alias entries", select the most appropriate e.164 from it and set it in the sip packet going to the pstn gw so it will be used as the pstn caller-id for the outgoing call.
It does not use alias table -- it uses a separate table for that.
Usually a pstn gw will take the "username" from a sip address (sip:username@domain) and set it as caller-id for an outgoing call. Reading the rfc i couldnt find any other parameter for setting it.
The easy solution is to just give a user a an e.164 id as primary SER login. I.e. "sip:493012345@myvoip.net" but in case he has several valid e.164 (as aliases) i would like to set the most appropriate number for each pstn gw when he calls out there.
The module currently does not support more than one rpid per user.
Example: If you has an german e.164 number and he uses a german PSTN gw i would use the german e.164 number and if he dialouts using an US pstn gw i would like to set the US number if he has any.
I am prepared to write the appropriate code for this but i want to make sure that i dont "re-invent the wheel" before i do this.
If you write it a way, which will depend on destination _somehow_ you will not be re-inventing wheel. I think this would be indeed useful -- for example some people can have a US number from addaline.com and a Spanish number from VozTele and desire to display the correct one based on where they are calling to, so that they can be called back inexpensively.
Perhaps appending a RegExp to the rpid table and selecting one of multiple rpid entries only if request-uri matches the RegExp would solve the problem.
-jiri
This is the oppesit of what Im doing...
but would you be needing a thing that rewrote the realname feeld? if so.. Im thinking of writing one, that can get a name out of the database, and say that "493042423" is Peter Pan.
- Atle * Arnd Vehling av@nethead.de [040227 20:37]:
Hi,
with an usuall SER setup a typical user account looks like this:
Primary sip address: sip:joe@myvoip.net Aliases:
Berlin incoming number: sip:493042423@myvoip.net Los Angeles "" : sip:1310232323@myvoip.net
If "joe" now calls out via a PSTN-GW the caller-id which is transmitted to the PSNT-GW would be "joe". Now "Joe" is clearly alphanumeric and no PSTN-GW (or the PSTN-Switch to which the PSTN-GW is connected) will accept "Joe" as caller-id.
All i can currently do is setting a default callerid on the PSTN-GW in case the incoming caller-id isnt valid.
What i would like to do though is to lookup if a user has an alias for a certain region and rewrite the the from line in the sip-packet going to the PSTN-GW.
Example: "Joe" uses the Berlin/german PSTN-GW or dials a german PSTN number. Now i would look into the alias table and search for either an alias starting with "49" or "4930" and if one is found set the from field to the according alias. In this case "493042423@myvoip.net".
This would ensure that, if possible, a matching caller-id would be set for every user.
Problems:
- "From" line rewriting is not RFC compliant.
- I dont see any possebility to do this with the stock SER software
Questions:
- Which module would be a good starting point for adding this functionality? All which would be needed would be one command for looking up the alias list of a user from memory using regular expressions.
- How do others cope with this problem?
The easy but not very elegant solution is to just use a valid e.164 number (ex. the LA number) as primary sip address. But that still doesnt fix the problem that "Joes" Los Angeles number would be set as caller-id even if he got a valid "berlin" number too and calls via a german PSTN termination.
best regards,
Arnd
Serusers mailing list serusers@lists.iptel.org http://lists.iptel.org/mailman/listinfo/serusers