Hello;
i am testing to radius modules. i have found this tutorial
http://www.kamailio.org/docs/openser-radius-1.0.x.html . it is old but
i changed some variables. i configured radiusclient-ng and free radius.
But kamailio cann't start because of
0(17813) ERROR: misc_radius [misc_radius.c:208]: mod_init():
misc_radius: can't get code for the SIP-AVP attribute
0(17813) ERROR: <core> [sr_module.c:968]: init_mod(): Error while
initializing module misc_radius
(/usr/local/lib64/kamailio/modules/misc_radius.so)
i already defined SIP-AVP in dictionary.kamailio.
And when i set radius_config in misc_radius , it try to find in default
path (/usr/local/etc/radiusclient-ng). So i linked to path
/usr/local/etc/radiusclient-ng to solve this problem.
---- kamailio V 4.2.4 ----
------------------dictionary.kamailio------------
#### Attributes ###
ATTRIBUTE Sip-Method 101 integer # Schulzrinne, acc
ATTRIBUTE Sip-Response-Code 102 integer # Schulzrinne, acc
ATTRIBUTE Sip-Cseq 103 string # Schulzrinne, acc
ATTRIBUTE Sip-To-Tag 104 string # Schulzrinne, acc
ATTRIBUTE Sip-From-Tag 105 string # Schulzrinne, acc
ATTRIBUTE Sip-Translated-Request-URI 107 string # Proprietary, acc
ATTRIBUTE Sip-Src-IP 108 string # Proprietary, acc
ATTRIBUTE Sip-Src-Port 109 string # Proprietary, acc
ATTRIBUTE Digest-Response 206 string # Sterman,
auth_radius
ATTRIBUTE Sip-Uri-User 208 string # Proprietary,
auth_radius
ATTRIBUTE Sip-Group 211 string # Proprietary,
group_radius
ATTRIBUTE Sip-Rpid 213 string # Proprietary,
auth_radius
ATTRIBUTE SIP-AVP 225 string # Proprietary,
avp_radius
ATTRIBUTE Digest-Realm 1063 string # Sterman,
auth_radius
ATTRIBUTE Digest-Nonce 1064 string # Sterman,
auth_radius
ATTRIBUTE Digest-Method 1065 string # Sterman,
auth_radius
ATTRIBUTE Digest-URI 1066 string # Sterman,
auth_radius
ATTRIBUTE Digest-QOP 1067 string # Sterman,
auth_radius
ATTRIBUTE Digest-Algorithm 1068 string # Sterman,
auth_radius
ATTRIBUTE Digest-Body-Digest 1069 string # Sterman,
auth_radius
ATTRIBUTE Digest-CNonce 1070 string # Sterman,
auth_radius
ATTRIBUTE Digest-Nonce-Count 1071 string # Sterman,
auth_radius
ATTRIBUTE Digest-User-Name 1072 string # Sterman,
auth_radius
### Acct-Status-Type Values ###
#VALUE Acct-Status-Type Start 1 # RFC2866, acc
#VALUE Acct-Status-Type Stop 2 # RFC2866, acc
#VALUE Acct-Status-Type Failed 15 # RFC2866, acc
### Service-Type Values ###
#VALUE Service-Type Call-Check 10 # RFC2865, uri_radius
VALUE Service-Type Group-Check 12 # Proprietary, group_radius
##VALUE Service-Type Sip-Session 15 # Schulzrinne, acc,
auth_radius
VALUE Service-Type SIP-Caller-AVPs 30 # Proprietary, avp_radius
VALUE Service-Type SIP-Callee-AVPs 31 # Proprietary, avp_radius
### Sip-Method Values ###
VALUE Sip-Method Undefined 0
VALUE Sip-Method Invite 1
VALUE Sip-Method Cancel 2
VALUE Sip-Method Ack 4
VALUE Sip-Method Bye 8
VALUE Sip-Method Info 16
VALUE Sip-Method Options 32
VALUE Sip-Method Update 64
VALUE Sip-Method Register 128
VALUE Sip-Method Message 256
VALUE Sip-Method Subscribe 512
VALUE Sip-Method Notify 1024
VALUE Sip-Method Prack 2048
VALUE Sip-Method Refer 4096
VALUE Sip-Method Other 8192
---------------------------Kamailio.cfg--------------------------------------------------------
#modparam("acc", "log_flag", FLT_ACC)
modparam("acc_radius", "radius_extra",
"Sip-Src-IP=$si;Sip-Src-Port=$sp")
modparam("acc_radius",
"radius_config","/etc/radiusclient-ng/radiusclient.conf")
modparam("acc_radius", "radius_flag", FLT_ACC)
modparam("acc_radius", "radius_missed_flag", FLT_ACCMISSED)
modparam("acc_radius", "service_type", 15)
modparam("misc_radius", "radius_config",
"/etc/radiusclient-ng/radiusclient.conf")
modparam("misc_radius", "group_service_type", 12)
modparam("misc_radius", "uri_service_type", 10)
modparam("misc_radius", "caller_extra",
"Calling-Station-Id=$fu")
modparam("misc_radius", "callee_extra",
"SIP-URI-User=$rU;SIP-URI-Host=$rd")
modparam("misc_radius", "group_extra",
"My-Special=$avp(i:100)")
modparam("misc_radius", "uri_extra",
"Called-Station-Id=$tu")
------------------------------------------------------------------------------------------------
Thanks