[Serusers] Mediaproxy works only for the caller

Felipe Louback louback at gmail.com
Wed Sep 28 15:20:41 CEST 2005


Hey all,

I am using ser-0.9.4 and  mediaproxy-1.4.2 but it seems that
mediaproxy only works for the caller.

During a call, if I use sessions.py, i see:
Caller                Via               Called     Status    Duration 
Codec    Type   Traffic
----------------------------------------------------------------------------------------------
150.164.x.x:8000 - 127.0.0.1:35000 - ?.?.?.?:?  inactive     0'26" 
Unknown  Audio  0/0/0

Total traffic:  0bps/0bps/0bps (in1/in2/out)
Session count:  1
Proxy version:  1.4.2

The status is inactive and after 60 seconds it ends.

The called part receives audio but the caller receives nothing.

It seems that the called part is not passing through media proxy.

Here it is my ser.cfg:

route{
    if (!mf_process_maxfwd_header("10")) {
        if (method!="ACK") {
            sl_send_reply("483", "Too many hops");
        };
        break;
    };

    if (msg:len >= max_len) {
        if (method!="ACK") {
            sl_send_reply("513", "Message too big");
        };
        break;
    };

    record_route();

    if (loose_route()) {
        if (method=="INVITE" || method=="ACK") {
            use_media_proxy();
        };
        t_relay();
        break;
    };

    if (method=="REGISTER") {
            # Mark as NAT'ed
            if (client_nat_test("3")) {
                setflag(2);
                force_rport();
                fix_contact();
            };
            if (!www_authorize("mydomain", "subscriber")) {
                www_challenge("mydomain", "0");
                break;
            }
            if (!save("location")) {
                sl_reply_error();
            };
        break;
    };

    if (method == "BYE" || method == "CANCEL") {
        end_media_session();
    };

    # Force subsequent messages to pass trough this proxy
    if (method == "INVITE") {
        record_route();
    };

    if (client_nat_test("3") && !search("^Record-Route:")) {
        # Mark as NAT'ed
        force_rport();
        fix_contact();
    };

    if (method=="INVITE" || method=="ACK") {
        use_media_proxy();
    };

        if (!lookup("location")) {
            sl_send_reply("404", "User not found");
            break;
        };

    if (!t_relay()) {
        if (method=="INVITE" || method=="ACK") {
            end_media_session();
        };
        sl_reply_error();
    };
}

How do I do for the called part to pass through mediaproxy?

I've searched about this, but I found nothing.
Initially I was using ser0.8.14 and I thought it was a problem with it
and I am now using 0.9.0. It seems that the problem wasnt with ser
version 0.8.14.

Could anyone give me some advice or tell me where I can find more
information about it?

Thanx,

Felipe

--
Master Student - Electrical Engineering Department
Computer Engineering and Telecommunications Research Group
Universidade Federal de Minas Gerais - Brazil

"For God so loved the world that he gave his one and only Son, that
whoever believes in him shall not perish but have eternal life."
John 3:16




More information about the sr-users mailing list