In the situation below, a call made from PSTN to openser.
PSTN -----> openser ---------> UA1
How can I remove the caller such that UA1 can't show the caller number in her display?
I've done it this way:
if (search("^Remote-Party-ID:.*sip:.*?.*?;privacy=full.*?")) { xlog("L_NOTICE", "*** full privacy requested\n"); remove_hf("Remote-Party-ID"); append_hf("Remote-Party-ID:\ sip:anonymous@127.0.0.1;party=calling;screen=yes;privacy=full\n"); uac_replace_from("anonymous", "sip:anonymous@127.0.0.1");
avp_printf("contacthelp", "$hdr(contact)"); # xlog("L_NOTICE", "*** contact: $avp(contacthelp)\n"); avp_subst("contacthelp", "/sip:(.*)@(.*)/sip:\2/"); # xlog("L_NOTICE", "*** contact substituted: $avp(contacthelp)\n"); remove_hf("Contact"); avp_pushto("$Contact", "s:contacthelp"); }
More interesting than disabling the callees phone from displaying the number is to remove it completely from the SIP messages, since the black-hat callee could run tcpdump in front of his phone.
What do other ones think about my approach? In my setup it works fine, as it seems.
Wolfgang
unplug wrote:
In the situation below, a call made from PSTN to openser.
PSTN -----> openser ---------> UA1
How can I remove the caller such that UA1 can't show the caller number in her display?
Users mailing list Users@openser.org http://openser.org/cgi-bin/mailman/listinfo/users
Hi Wolfgang,
I would say adding the RPID hdr along with changing the FROM hdr is a little bit redundant - as most of the SIP phones do not interpret the RPID hdr, you may use RPID without FROM changing if the call goes to a GW and FROM changing (without adding RPID) if goes to a SIP UA.
regards, bogdan
Wolfgang Hottgenroth wrote:
I've done it this way:
if (search("^Remote-Party-ID:.*sip:.*?.*?;privacy=full.*?")) { xlog("L_NOTICE", "*** full privacy requested\n"); remove_hf("Remote-Party-ID"); append_hf("Remote-Party-ID:\ sip:anonymous@127.0.0.1;party=calling;screen=yes;privacy=full\n"); uac_replace_from("anonymous", "sip:anonymous@127.0.0.1");
avp_printf("contacthelp", "$hdr(contact)"); # xlog("L_NOTICE", "*** contact: $avp(contacthelp)\n"); avp_subst("contacthelp", "/sip:(.*)@(.*)/sip:\2/"); # xlog("L_NOTICE", "*** contact substituted: $avp(contacthelp)\n"); remove_hf("Contact"); avp_pushto("$Contact", "s:contacthelp"); }
What do other ones think about my approach? In my setup it works fine, as it seems.
Bogdan-Andrei Iancu wrote:
Hi Wolfgang,
I would say adding the RPID hdr along with changing the FROM hdr is a little bit redundant - as most of the SIP phones do not interpret the RPID hdr, you may use RPID without FROM changing if the call goes to a GW and FROM changing (without adding RPID) if goes to a SIP UA.
Yes. If the call goes to a trusted gateway, there should be no need to rewrite the message as the gateway should handle privacy=full correctly.
IF the request is sent to terminal, there is IMO no need for an RPID header.
regards klaus
regards, bogdan
Wolfgang Hottgenroth wrote:
I've done it this way:
if (search("^Remote-Party-ID:.*sip:.*?.*?;privacy=full.*?")) { xlog("L_NOTICE", "*** full privacy requested\n"); remove_hf("Remote-Party-ID"); append_hf("Remote-Party-ID:\ sip:anonymous@127.0.0.1;party=calling;screen=yes;privacy=full\n"); uac_replace_from("anonymous", "sip:anonymous@127.0.0.1");
avp_printf("contacthelp", "$hdr(contact)"); # xlog("L_NOTICE", "*** contact: $avp(contacthelp)\n"); avp_subst("contacthelp", "/sip:(.*)@(.*)/sip:\2/"); # xlog("L_NOTICE", "*** contact substituted: $avp(contacthelp)\n"); remove_hf("Contact"); avp_pushto("$Contact", "s:contacthelp"); }
What do other ones think about my approach? In my setup it works fine, as it seems.
Users mailing list Users@openser.org http://openser.org/cgi-bin/mailman/listinfo/users
Hi,
you may try first just to remove the display name (use subst() or uac_replace_from()). As this might be not enough (some clients extract display info from FROM uri), you might consider using uac_replace_from() to change display and URI. See the UAC module.
regards, bogdan
unplug wrote:
In the situation below, a call made from PSTN to openser.
PSTN -----> openser ---------> UA1
How can I remove the caller such that UA1 can't show the caller number in her display?
Users mailing list Users@openser.org http://openser.org/cgi-bin/mailman/listinfo/users
I've done it this way:
if (search("^Remote-Party-ID:.*sip:.*?.*?;privacy=full.*?")) { xlog("L_NOTICE", "*** full privacy requested\n"); remove_hf("Remote-Party-ID"); append_hf("Remote-Party-ID:\ sip:anonymous@127.0.0.1;party=calling;screen=yes;privacy=full\n"); uac_replace_from("anonymous", "sip:anonymous@127.0.0.1");
avp_printf("contacthelp", "$hdr(contact)"); # xlog("L_NOTICE", "*** contact: $avp(contacthelp)\n"); avp_subst("contacthelp", "/sip:(.*)@(.*)/sip:\2/"); # xlog("L_NOTICE", "*** contact substituted: $avp(contacthelp)\n"); remove_hf("Contact"); avp_pushto("$Contact", "s:contacthelp"); }
More interesting than disabling the callees phone from displaying the number is to remove it completely from the SIP messages, since the black-hat callee could run tcpdump in front of his phone.
What do other ones think about my approach? In my setup it works fine, as it seems.
Wolfgang
unplug wrote:
In the situation below, a call made from PSTN to openser.
PSTN -----> openser ---------> UA1
How can I remove the caller such that UA1 can't show the caller number in her display?
Users mailing list Users@openser.org http://openser.org/cgi-bin/mailman/listinfo/users
How about the setting in version 1.0.0? As found that remove_hf function is only available in devel version.
unplug
For the remove_hf
On 2/21/06, Wolfgang Hottgenroth woho@hottis.de wrote:
I've done it this way:
if (search("^Remote-Party-ID:.*sip:.*?.*?;privacy=full.*?")) { xlog("L_NOTICE", "*** full privacy requested\n"); remove_hf("Remote-Party-ID"); append_hf("Remote-Party-ID:\ sip:anonymous@127.0.0.1;party=calling;screen=yes;privacy=full\n"); uac_replace_from("anonymous", "sip:anonymous@127.0.0.1");
avp_printf("contacthelp", "$hdr(contact)"); # xlog("L_NOTICE", "*** contact: $avp(contacthelp)\n"); avp_subst("contacthelp", "/sip:(.*)@(.*)/sip:\2/"); # xlog("L_NOTICE", "*** contact substituted: $avp(contacthelp)\n"); remove_hf("Contact"); avp_pushto("$Contact", "s:contacthelp"); }
More interesting than disabling the callees phone from displaying the number is to remove it completely from the SIP messages, since the black-hat callee could run tcpdump in front of his phone.
What do other ones think about my approach? In my setup it works fine, as it seems.
Wolfgang
unplug wrote:
In the situation below, a call made from PSTN to openser.
PSTN -----> openser ---------> UA1
How can I remove the caller such that UA1 can't show the caller number in her display?
Users mailing list Users@openser.org http://openser.org/cgi-bin/mailman/listinfo/users
No, it works in all versions of (open)ser. It was only forgotten to document it.
regards klaus
unplug wrote:
How about the setting in version 1.0.0? As found that remove_hf function is only available in devel version.
unplug
For the remove_hf
On 2/21/06, Wolfgang Hottgenroth woho@hottis.de wrote:
I've done it this way:
if (search("^Remote-Party-ID:.*sip:.*?.*?;privacy=full.*?")) { xlog("L_NOTICE", "*** full privacy requested\n"); remove_hf("Remote-Party-ID"); append_hf("Remote-Party-ID:\ sip:anonymous@127.0.0.1;party=calling;screen=yes;privacy=full\n"); uac_replace_from("anonymous", "sip:anonymous@127.0.0.1");
avp_printf("contacthelp", "$hdr(contact)"); # xlog("L_NOTICE", "*** contact: $avp(contacthelp)\n"); avp_subst("contacthelp", "/sip:(.*)@(.*)/sip:\2/"); # xlog("L_NOTICE", "*** contact substituted: $avp(contacthelp)\n"); remove_hf("Contact"); avp_pushto("$Contact", "s:contacthelp"); }
More interesting than disabling the callees phone from displaying the number is to remove it completely from the SIP messages, since the black-hat callee could run tcpdump in front of his phone.
What do other ones think about my approach? In my setup it works fine, as it seems.
Wolfgang
unplug wrote:
In the situation below, a call made from PSTN to openser.
PSTN -----> openser ---------> UA1
How can I remove the caller such that UA1 can't show the caller number in her display?
Users mailing list Users@openser.org http://openser.org/cgi-bin/mailman/listinfo/users
Users mailing list Users@openser.org http://openser.org/cgi-bin/mailman/listinfo/users
Thanks! I have tested it. That function works fine.
However, the setting doesn't work for me. I noticed that there is a problem after executing the function uac_replace_from("anonymous", "sip:anonymous@127.0.0.1"); This function with parameter will totally replace the From header and it will cause one way ringing.
On 2/21/06, Klaus Darilion klaus.mailinglists@pernau.at wrote:
No, it works in all versions of (open)ser. It was only forgotten to document it.
regards klaus
unplug wrote:
How about the setting in version 1.0.0? As found that remove_hf function is only available in devel version.
unplug
For the remove_hf
On 2/21/06, Wolfgang Hottgenroth woho@hottis.de wrote:
I've done it this way:
if (search("^Remote-Party-ID:.*sip:.*?.*?;privacy=full.*?")) { xlog("L_NOTICE", "*** full privacy requested\n"); remove_hf("Remote-Party-ID"); append_hf("Remote-Party-ID:\ sip:anonymous@127.0.0.1;party=calling;screen=yes;privacy=full\n"); uac_replace_from("anonymous", "sip:anonymous@127.0.0.1");
avp_printf("contacthelp", "$hdr(contact)"); # xlog("L_NOTICE", "*** contact: $avp(contacthelp)\n"); avp_subst("contacthelp", "/sip:(.*)@(.*)/sip:\2/"); # xlog("L_NOTICE", "*** contact substituted: $avp(contacthelp)\n"); remove_hf("Contact"); avp_pushto("$Contact", "s:contacthelp"); }
More interesting than disabling the callees phone from displaying the number is to remove it completely from the SIP messages, since the black-hat callee could run tcpdump in front of his phone.
What do other ones think about my approach? In my setup it works fine, as it seems.
Hi,
if want to replace only the display, set the second param to empty string. Also do not forget to set the from_restore_mode to "auto" - see the doc: http://openser.org/docs/modules/1.0.x/uac.html#AEN75
regards, bogdan
unplug wrote:
Thanks! I have tested it. That function works fine.
However, the setting doesn't work for me. I noticed that there is a problem after executing the function uac_replace_from("anonymous", "sip:anonymous@127.0.0.1"); This function with parameter will totally replace the From header and it will cause one way ringing.
On 2/21/06, Klaus Darilion klaus.mailinglists@pernau.at wrote:
No, it works in all versions of (open)ser. It was only forgotten to document it.
regards klaus
unplug wrote:
How about the setting in version 1.0.0? As found that remove_hf function is only available in devel version.
unplug
For the remove_hf
On 2/21/06, Wolfgang Hottgenroth woho@hottis.de wrote:
I've done it this way:
if (search("^Remote-Party-ID:.*sip:.*?.*?;privacy=full.*?")) { xlog("L_NOTICE", "*** full privacy requested\n"); remove_hf("Remote-Party-ID"); append_hf("Remote-Party-ID:\ sip:anonymous@127.0.0.1;party=calling;screen=yes;privacy=full\n"); uac_replace_from("anonymous", "sip:anonymous@127.0.0.1");
avp_printf("contacthelp", "$hdr(contact)"); # xlog("L_NOTICE", "*** contact: $avp(contacthelp)\n"); avp_subst("contacthelp", "/sip:(.*)@(.*)/sip:\2/"); # xlog("L_NOTICE", "*** contact substituted: $avp(contacthelp)\n"); remove_hf("Contact"); avp_pushto("$Contact", "s:contacthelp"); }
More interesting than disabling the callees phone from displaying the number is to remove it completely from the SIP messages, since the black-hat callee could run tcpdump in front of his phone.
What do other ones think about my approach? In my setup it works fine, as it seems.
Users mailing list Users@openser.org http://openser.org/cgi-bin/mailman/listinfo/users
Hi,
Thanks for the hint. I have tried it and it has no effect when a call come from the other network. Instead, I need to remove the From and reconstruct the From header as below. remove_hf("From"); avp_pushto("$From", "s:fromheader");
Rgds, unplug
On 2/21/06, Bogdan-Andrei Iancu bogdan@voice-system.ro wrote:
Hi,
if want to replace only the display, set the second param to empty string. Also do not forget to set the from_restore_mode to "auto" - see the doc: http://openser.org/docs/modules/1.0.x/uac.html#AEN75
regards, bogdan
unplug wrote:
Thanks! I have tested it. That function works fine.
However, the setting doesn't work for me. I noticed that there is a problem after executing the function uac_replace_from("anonymous", "sip:anonymous@127.0.0.1"); This function with parameter will totally replace the From header and it will cause one way ringing.
On 2/21/06, Klaus Darilion klaus.mailinglists@pernau.at wrote:
No, it works in all versions of (open)ser. It was only forgotten to document it.
regards klaus
unplug wrote:
How about the setting in version 1.0.0? As found that remove_hf function is only available in devel version.
unplug
For the remove_hf
On 2/21/06, Wolfgang Hottgenroth woho@hottis.de wrote:
I've done it this way:
if (search("^Remote-Party-ID:.*sip:.*?.*?;privacy=full.*?")) { xlog("L_NOTICE", "*** full privacy requested\n"); remove_hf("Remote-Party-ID"); append_hf("Remote-Party-ID:\ sip:anonymous@127.0.0.1;party=calling;screen=yes;privacy=full\n"); uac_replace_from("anonymous", "sip:anonymous@127.0.0.1");
avp_printf("contacthelp", "$hdr(contact)"); # xlog("L_NOTICE", "*** contact: $avp(contacthelp)\n"); avp_subst("contacthelp", "/sip:(.*)@(.*)/sip:\2/"); # xlog("L_NOTICE", "*** contact substituted: $avp(contacthelp)\n"); remove_hf("Contact"); avp_pushto("$Contact", "s:contacthelp"); }
More interesting than disabling the callees phone from displaying the number is to remove it completely from the SIP messages, since the black-hat callee could run tcpdump in front of his phone.
What do other ones think about my approach? In my setup it works fine, as it seems.
Users mailing list Users@openser.org http://openser.org/cgi-bin/mailman/listinfo/users
Hi,
here is a sample:
# replace only display and do not touch uri uac_replace_from("batman","");
regards, bogdan
unplug wrote:
Hi,
Thanks for the hint. I have tried it and it has no effect when a call come from the other network. Instead, I need to remove the From and reconstruct the From header as below. remove_hf("From"); avp_pushto("$From", "s:fromheader");
Rgds, unplug
On 2/21/06, Bogdan-Andrei Iancu bogdan@voice-system.ro wrote:
Hi,
if want to replace only the display, set the second param to empty string. Also do not forget to set the from_restore_mode to "auto" - see the doc: http://openser.org/docs/modules/1.0.x/uac.html#AEN75
regards, bogdan
unplug wrote:
Thanks! I have tested it. That function works fine.
However, the setting doesn't work for me. I noticed that there is a problem after executing the function uac_replace_from("anonymous", "sip:anonymous@127.0.0.1"); This function with parameter will totally replace the From header and it will cause one way ringing.
On 2/21/06, Klaus Darilion klaus.mailinglists@pernau.at wrote:
No, it works in all versions of (open)ser. It was only forgotten to document it.
regards klaus
unplug wrote:
How about the setting in version 1.0.0? As found that remove_hf function is only available in devel version.
unplug
For the remove_hf
On 2/21/06, Wolfgang Hottgenroth woho@hottis.de wrote:
I've done it this way:
if (search("^Remote-Party-ID:.*sip:.*?.*?;privacy=full.*?")) { xlog("L_NOTICE", "*** full privacy requested\n"); remove_hf("Remote-Party-ID"); append_hf("Remote-Party-ID:\ sip:anonymous@127.0.0.1;party=calling;screen=yes;privacy=full\n"); uac_replace_from("anonymous", "sip:anonymous@127.0.0.1");
avp_printf("contacthelp", "$hdr(contact)"); # xlog("L_NOTICE", "*** contact: $avp(contacthelp)\n"); avp_subst("contacthelp", "/sip:(.*)@(.*)/sip:\2/"); # xlog("L_NOTICE", "*** contact substituted: $avp(contacthelp)\n"); remove_hf("Contact"); avp_pushto("$Contact", "s:contacthelp"); }
More interesting than disabling the callees phone from displaying the number is to remove it completely from the SIP messages, since the black-hat callee could run tcpdump in front of his phone.
What do other ones think about my approach? In my setup it works fine, as it seems.
Users mailing list Users@openser.org http://openser.org/cgi-bin/mailman/listinfo/users
Hi,
I updated the docs to include the description of the function.
Thanks for report, bogdan
Klaus Darilion wrote:
No, it works in all versions of (open)ser. It was only forgotten to document it.
regards klaus
unplug wrote:
How about the setting in version 1.0.0? As found that remove_hf function is only available in devel version.
unplug
For the remove_hf