You also have to make sure that the Content-Length: header will be adopted
when changing the size of the SDP.
regards
klaus
On Tue, February 14, 2006 21:08, S G said:
Hi,
Can psuedo variables and avpops be enhanced to include the headers in
the SDP
message body?
v=0.
o=2139869454 25762964 25762964 IN IP4 192.168.1.133.
s=SDP Session For C&S MoIP.
c=IN IP4 64.xx.xxx.xxx
t=0 0.
m=audio 40000 RTP/AVP 4 0 97.
a=rtpmap:4 G723/8000.
a=ptime:30.
a=rtpmap:0 PCMU/8000.
a=ptime:20.
a=rtpmap:97 telephone-event/8000.
m=video 40002 RTP/AVP 34.
a=rtpmap:34 H263/90000.
Example, what if i wanted to take the local IP of a SIP phone in the
'o='
line and subst it in the 'c=' line for 2 stun enabled clients
residing behind the same NAT? Currently I can sort of do this by
grabbing the local IP off the call-id header in REGISTER and storing it
in the database then regex'ing the IP out of the header with avp_subst.
Though this still does not seem to work even with the output from ngrep
looking proper. What is cuasing this? I dont see why i should have to
store this value in the DB. Subst doenst work multiline so i cant do
this in one textops subst call either.
## In REGISTER
## Save to DB the private IP parsed out of call-id header
avp_write("$hdr[call-id]","i:222");
avp_subst("i:222",
"/.*(a)(.*)$/\1/")\1/");
avp_db_store("$from","i:222");
#In INVITE
#restore pre-stun IP
if( !nat_uac_test("8") ) {
avp_db_load("$from","i:222");
subst( '/^c=(.*)IP4 (.*)/c=\1IP4 $avp(i:222)\r/' );
};
Thanks,
Sumeet
_________________________________________________________________ FREE
pop-up
blocking with the new MSN Toolbar get it now!