RadiusClient rc = new RadiusClient("xx.xx.xx.xx","0000");
AccountingRequest acc = new AccountingRequest("michael",AccountingRequest.ACCT_STATUS_TYPE_START);
acc.addAttribute("Framed-IP-Address", "1.1.1.1");
acc.addAttribute("Class","Key CL: PT=C");
rc.account(acc);
rc.close();
i try to send an accounting request to my accounting server by create a jsp page as above.
However, only
acc.addAttribute("Framed-IP-Address", "1.1.1.1")can be accpeted, there is error occured while sending attribute type no.25 "Class" by using
acc.addAttribute("Class","Key CL: PT=C")where is going wrong ?!
Finally i found the answer, attribute "Class" , need to be added by method :
acc.addAttribute(new StringAttribute(25,"Key CL: PT=C"));