<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#ffffff">
On 03/09/2011 02:09 PM, Bryant Zimmerman wrote:
<blockquote cite="mid:be0bde$ef7ca62$6e863c7e$@com" type="cite"><span
style="font-family: Arial,Helvetica,sans-serif; font-size: 10pt;"><span
style="font-family: tahoma,arial,sans-serif; font-size: 10pt;">
<hr size="2" width="100%" align="center"><b>From</b>: "Jonas Kellens"
<a class="moz-txt-link-rfc2396E" href="mailto:jonas.kellens@telenet.be"><jonas.kellens@telenet.be></a><br>
<b>Sent</b>: Wednesday, March 09, 2011 4:18 AM<br>
<b>To</b>: "Asterisk Users Mailing List - Non-Commercial Discussion"
<a class="moz-txt-link-rfc2396E" href="mailto:asterisk-users@lists.digium.com"><asterisk-users@lists.digium.com></a><br>
<b>Subject</b>: [asterisk-users] SIPAddHeader not working</span><br>
<br>
<!--CTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//E--><span
style="font-family: helvetica,arial,sans-serif;">Hello list,<br>
<br>
I notice that the dialplan method SIPAddHeader is not working :<br>
<br>
in dialplan :<br>
<br>
<i>exten => s,n,SIPAddHeader(Privacy: id)</i><br>
<br>
<br>
in SIP invite no trace of this header :<br>
<br>
<br>
Using Asterisk 1.6.2.16.1<br>
<br>
<br>
How do I correctly add the Privacy header ?!<br>
<br>
<br>
Kind regards,<br>
Jonas.<br>
</span><br>
Jonas<br>
<br>
Here is the way we add the rfc-3325 privacey header so our vendors pick
it up correctly. This is what we use in 1.6.x and 1.8.x<br>
When I check on my versions the privacy header appears to be there.<br>
<br>
<span lang="EN">
<p>exten => rfc-3325-CPN,1,NoOp(Set Call Privacy)<br>
exten => rfc-3325-CPN,n,NoOp(From ${SIP_HEADER(From)})<br>
exten => rfc-3325-CPN,n,NoOp(To ${SIP_HEADER(To)})<br>
exten =>
rfc-3325-CPN,n,Set(l_sipheaderfromip=${CUT(SIP_HEADER(From),@,2)})<br>
exten => rfc-3325-CPN,n,GotoIf($["${l_sipheaderfromip}" != ""]?hasat)<br>
exten =>
rfc-3325-CPN,n,Set(l_sipheaderfromip=${CUT(CUT(SIP_HEADER(From),>,1),:,2)})<br>
exten => rfc-3325-CPN,n,Goto(gotip)<br>
exten =>
rfc-3325-CPN,n(hasat),Set(FROM_IP=${CUT(CUT(CUT(SIP_HEADER(From),@,2),>,1),:,1)})<br>
exten => rfc-3325-CPN,n(gotip),NoOp(Gateway IP is ${FROM_IP})<br>
exten =>
rfc-3325-CPN,n,SIPAddHeader(P-Preferred-Identity:"${CALLERID(name)}"
<a class="moz-txt-link-rfc2396E" href="sip:+1${CALLERID(num)}@${FROM_IP}\;user=phone"><sip:+1${CALLERID(num)}@${FROM_IP}\;user=phone></a>) <br>
exten => rfc-3325-CPN,n,SIPAddHeader(Privacy: id) <br>
exten => rfc-3325-CPN,n,Set(CALLERPRES()=prohib_not_screened)<br>
exten => rfc-3325-CPN,n,Set(CALLERID(num)=Anonymous) <br>
exten => rfc-3325-CPN,n,Set(CALLERID(name)=Anonymous) <br>
exten => rfc-3325-CPN,n,Return() </p>
</span></span></blockquote>
<font face="Helvetica, Arial, sans-serif"><br>
I see no great difference. What does "<i>Set(CALLERPRES()=prohib_not_screened)</i>"
do ?<br>
<br>
How does your INVITE look like ? Does the header "<i>Privacy: id</i>"
appears ? Because it does not in my INVITE. <br>
<br>
<br>
Kind regards,<br>
Jonas.<br>
<br>
</font><br>
</body>
</html>