[RADIATOR] Some information lost during Diameter to Radius conversion

Arthur kasjas at hot.ee
Fri Mar 28 04:50:07 CDT 2014


Heikki, thanks for the tip.

I've written the following.

Config file part:
<ServerDIAMETER>
         OriginHost mm2.ims.xxxx.xx
         OriginRealm ims.xxxx.xx
         Port 3870
         SupportedVendorIds      DictVendors
         PostDiaToRadiusConversionHook file:"%D/dia_to_radius_hook.pl"
</ServerDIAMETER>

dia_to_radius_hook.pl:
sub
{
     my $d=${$_[0]};
     my $p=${$_[1]};

     my $subscription = $p->get_attr('Subscription-Id-Data');
     $subscription =~ s/^sip://g;
     $p->add_attr('User-Name', $subscription);
     &main::log($main::LOG_DEBUG,"*****AKO: User-Name: $subscription");
}

But in the log file I have an empty 'User-Name'. Where I have did mistake?


br,
Arthur



27.03.2014 21:04, Heikki Vatiainen kirjutas:
> On 03/27/2014 04:57 PM, Arthur wrote:
>> In my incoming Diameter Accounting message I have the following part:
> ...
>>       3GPP-Service-Information: VM.,
>>          Subscription-Id: .M.,
>>             Subscription-Id-Type: .M., END_USER_SIP_URI
>>             Subscription-Id-Data: .M., sip:300000000 at xxxx.xx
>> How to add "Subscription-Id-Data" (and possible "Subscription-Id-Type"
>> too) to the Radius conversion? Currently it just dropped and I loose
>> this information for the further analysis.
> Hello Arthur,
>
> please see goodies/diameter-server.cfg and
> PostDiaToRadiusConversionHook. This Hook is not documented in the
> current reference manual yet, but exists to help to do any custom work
> after the default conversion runs. The purpose of the hook is to help
> with cases such as yours.
>
> There's also a respective hook from going to Radius back to Diameter.
>
> Thanks,
> Heikki
>



More information about the radiator mailing list