Hi all,
I would like to share some experience with uac_replace_from(). Please anybody correct me if I made any mistake.
I have done tons of test with openser 1.2.3 and 1.3.1 and finally found the trend as follows:
In 1.2.3 the Header Field From in CANCEL will be the one received from UAC, no matter what you have done with INVITE, it will remember the From: prior to all the changes. Parameter from_restore_mode doesn't apply to this. So you have to write something like if(method=="CANCEL") uac_replace_from("sometext").
However, in 1.3.1. If you set modparam("uac", "from_restore_mode", "auto"). TM is smart enough to change From: in CANCEL for you to match the one in INVITE, even modified by Openser. But the problem in 1.3.1 is if you set from_restore_mode to none, no matter how you write uac_replace_from() to your CANCEL request, nothing will happen. Actually this means in Openser 1.3.1, no matter what you do with uac_replace_from() to CANCEL, nothing will happen, depends on the module param it will be either original message or modified message in INVITE. But you can hardly do anything to CANCEL manually.
Bogdan, this is the behavior you intend to?
Best Regards, Bai Shi