[Devel] [ openser-Patches-1477030 ] Support for setting src-ip via
AVP for mediaproxy
SourceForge.net
noreply at sourceforge.net
Thu Apr 27 10:54:55 CEST 2006
Patches item #1477030, was opened at 2006-04-26 17:40
Message generated for change (Comment added) made by agranig
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=1477030&group_id=139143
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: ver devel
>Status: Closed
>Resolution: Invalid
Priority: 5
Submitted By: Andreas Granig (agranig)
Assigned to: Nobody/Anonymous (nobody)
Summary: Support for setting src-ip via AVP for mediaproxy
Initial Comment:
In a load-balanced setup, an UAC's source IP may have
to be extracted for example from an additional header
field instead of getting it from the transport layer.
This patch allows to override the source IP, which is
passed to the mediaproxy dispatcher by the mediaproxy
module, via an AVP defined by the module parameter
"src_ip_avp". If this parameter is not set or the
defined AVP is not set, the source IP from the
transport layer is used.
Here's an example of its usage.
On the load-balancer:
route[0] {
...
if( /* request is from UAC */) {
append_hf("P-Src-Ip: $si\r\n");
}
...
}
reply_route[1] {
...
if( /* response is from UAC */) {
append_hf("P-Src-Ip: $si\r\n");
}
...
}
And on the backend-proxy controlling the mediaproxy:
...
modparam("mediaproxy", "src_ip_avp", "i:100")
...
route[0] {
...
route(1);
use_media_proxy();
...
}
route[1] {
avp_delete("$avp(i:100)");
if(is_present_hf("P-Src-Ip")) {
avp_write("$hdr(P-Src-Ip)", "$avp(i:100)");
remove_hf("P-Src-Ip");
}
}
reply_route[1] {
...
route(1);
use_media_proxy();
...
}
----------------------------------------------------------------------
>Comment By: Andreas Granig (agranig)
Date: 2006-04-27 10:54
Message:
Logged In: YES
user_id=825350
Closed because not necessary.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=1477030&group_id=139143
More information about the Devel
mailing list