[Spce-user] Avoid 302 response

Mario Contreras mario.contreras at innovasur.es
Tue Mar 12 05:48:46 EDT 2013


Thanks for your answer.

This is what I've done:

if(t_check_status("301|302"))
{
     xlog("L_ERROR", "Failed to fetch contact '$ct' from 301/302 - [% 
logreq -%]\n");
     acc_db_request("480", "acc");
     $var(announce_handle) = "callee_tmp_unavailable";
     $var(announce_set) = $avp(s:callee_sound_set);
     $(avp(s:announce_code)[*]) = 403;
     $(avp(s:announce_reason)[*]) = "Forbidden";
     route(ROUTE_EARLY_REJECT);
}

I think it will work. You think I can improve it?

Anyway, my spce treats the calls like they were incoming. Is that 
normal? Here I show an entry from cdr table:

*************************** 1. row ***************************
                                 id: 285697
                        update_time: 2013-03-10 05:09:27
                     source_user_id: 0
                 source_provider_id: 3
      source_external_subscriber_id:
        source_external_contract_id:
                  source_account_id: 0
                        source_user: myuser
                      source_domain: example.com
                         source_cli: CCCCCCCCCC
                        source_clir: 1
                destination_user_id: 0
            destination_provider_id: 3
destination_external_subscriber_id:
   destination_external_contract_id:
             destination_account_id: 0
                   destination_user: XXXXXXXXXX
                 destination_domain: 1.1.1.1
            destination_user_dialed: XXXXXXXXXX
                destination_user_in: XXXXXXXXXX
              destination_domain_in: example.com
                     peer_auth_user:
                    peer_auth_realm:
                          call_type: cfb
                        call_status: ok
                          call_code: 200
                          init_time: 1362888551.234
                         start_time: 1362888554.040
                           duration: 4.690
                            call_id: 
kif13x12kf0axb0kf1mc41ck102e3dkm at SoftX3000
                       carrier_cost: 0.00
                      reseller_cost: 0.00
                      customer_cost: 0.00
                  carrier_free_time: 0
                 reseller_free_time: 0
                 customer_free_time: 0
             carrier_billing_fee_id: NULL
            reseller_billing_fee_id: NULL
            customer_billing_fee_id: NULL
            carrier_billing_zone_id: NULL
           reseller_billing_zone_id: NULL
           customer_billing_zone_id: NULL
                frag_carrier_onpeak: NULL
               frag_reseller_onpeak: NULL
               frag_customer_onpeak: NULL
                      is_fragmented: NULL
                           rated_at: 2013-03-10 05:09:27
                      rating_status: ok
***************************************************************

Thank you!

El 11/03/2013 20:24, Andreas Granig escribió:
> Hi,
>
> Search for "302" in your
> /etc/ngcp-config/templates/etc/kamailio/proxy/proxy.cfg and comment
> parts you don't want to be handled as is (preferably copy it to
> proxy.cfg.customtt.tt2 first and do your changes there to not get them
> overwritten with the next update).
>
> Andreas
>
> On 03/11/2013 07:45 PM, Mario Contreras wrote:
>> Sorry, I didn't want to send... I hope you can help me. I've been
>> looking for in kamailio proxy files, but I haven't find anything
>> helpful(I imagine it's there but I don't know where...).
>> Thanks for all!
>>
>> El 11/03/2013 19:39, Mario Contreras escribió:
>>> Hi all,
>>>
>>> One of my subscribers has suffered an attack, and some calls have been
>>> accepted by sipwise because the subscriber sent an 302 message.
>>>
>>> These are the messages:
>>> SIP PEERING            SPCE
>>>
>>>
>>> SPCE           SUBSCRIBER    SIP PEERING
>>>
>>>
>>> Those are the two conversations, one between my sip peering and
>>> spce(it's an incoming call), and the other from spce to subscriber,
>>> but it redirects the call to another number with a 302.
>>
>>
>> _______________________________________________
>> Spce-user mailing list
>> Spce-user at lists.sipwise.com
>> http://lists.sipwise.com/listinfo/spce-user
>>





More information about the Spce-user mailing list