Dear Teigre:
    How can I slove this problem?
    Thanks.
 
Sincerely
Caxton
 
 

Message: 6
Date: Tue, 11 Jul 2006 08:47:40 +0200
From: "Greger V. Teigre" < greger@teigre.com>
Subject: Re: [Serusers] Radius Accounting
To: Caxton <kaifu.chan@gmail.com>
Cc: serusers@lists.iptel.org , serusers-request@lists.iptel.org
Message-ID: <44B3498C.7020003@teigre.com>
Content-Type: text/plain; charset="iso-8859-1"

The BYE is loose routed, thus it will go to route(1).
g-)

Caxton wrote:
> Hi all:
>
>     I have installed radius server, and I also configure the "ser.cfg"
> for the radius accounting.  However, there is a problem confues me.
>
>     While the sip session have set up, the radiusclient send a
> Request-Account packet to radius server immediately, than radius server
>     can save the start-up time of the session into database.  But
> after the session terminated, radiusclient do nothing(it should send a
>     Accounting-Stop packet to radius server)!!  Therefore, I can
> not have a complete time record.
>
>     I try to look up the solution in seruser mailing list, but I can
> not find what I want.  Please help me, thanks.
>
>     Sincerely
>
>     Caxton
>
> -----ser.cfg-----
>
> [cut]
>
> # -- acc params --
> modparam("acc", "radius_config",
> "/usr/local/etc/radiusclient-ng/radiusclient.conf")
> modparam("acc", "log_level", 2)
> modparam("acc", "radius_flag", 1)
> modparam("acc", "report_ack", 0)
> # -------------------------  request routing logic -------------------
>
> # main routing logic
> route{
>
>         # initial sanity checks -- messages with
>         # max_forwards==0, or excessively long requests
>         if (!mf_process_maxfwd_header("10")) {
>                 sl_send_reply("483","Too Many Hops");
>                 break;
>         };
>         if (msg:len >=  2048 ) {
>                 sl_send_reply("513", "Message too big");
>                 break;
>         };
>         # we record-route all messages -- to make sure that
>         # subsequent messages will go through our proxy; that's
>         # particularly good if upstream and downstream entities
>         # use different transport protocol
>         if (!method=="REGISTER") record_route();
>
>         # subsequent messages withing a dialog should take the
>         # path determined by record-routing
>         if (loose_route()) {
>                 # mark routing logic in request
>                 append_hf("P-hint: rr-enforced\r\n");
>                 route(1);
>                 break;
>         };
>
>         if (!uri==myself) {
>                 # mark routing logic in request
>                 append_hf("P-hint: outbound\r\n");
>                 route(1);
>                 break;
>         };
>
>         # if the request is for other domain use UsrLoc
>         # (in case, it does not work, use the following command
>         # with proper names and addresses in it)
>         if (uri==myself) {
>
>                 if (method=="REGISTER") {
>                        log(1, "REGISTER: Authenticating user\n");
> # Uncomment this if you want to use digest authentication
>                         if (!www_authorize("pc80.s206.tj.mcu.edu.tw
> < http://pc80.s206.tj.mcu.edu.tw/>", "subscriber")) {
>                                 log(1, "REGISTER: Chanllenging user\n");
>                                 www_challenge("
> pc80.s206.tj.mcu.edu.tw <http://pc80.s206.tj.mcu.edu.tw/>", "0");
>                                 break;
>                         };
>                         save("location");
>                         break;
>                 };
>                 if(method=="INVITE") {
>                         log(1, "INVITE\n");
>                         setflag(1);
>                 }
>                 if(method=="MESSAGE") {
>                         log(1, "MESSAGE\n");
>                         setflag(1);
>                 }
>                 if(method=="BYE"||method== "CANCEL") {
>                         log(1, "BYE or CANCEL\n");
>                         setflag(1);
>                 }
>
> [cut]
> ------------------------------------------------------------------------
>
> _______________________________________________
> Serusers mailing list
> Serusers@lists.iptel.org
> http://lists.iptel.org/mailman/listinfo/serusers