Hi Egor, This sounds like it could be a bug. What version of Kea are you running?
/Peter From: "egor grijuc" <[email protected]> To: "[email protected]" <[email protected]> Sent: Monday, 7 October, 2024 15:49:41 Subject: [Kea-users] Cannot add client class via api Hello. API call curl -X POST -H "Content-Type: application/json" -d '{ "command": "remote-class6-set","arguments": {"client-classes": [{"name": "48575443E62BA1AA","test": "substring(relay6[1].option[37].hex,-16,all) == 0x34383537353434334536324241314141","option-data": [{"name": "dns-servers","code": 23,"space": "dhcp6","csv-format": true,"data": "2a00:1858:0:1::53,2a00:1858:0:2::53"}]}],"remote": {"type": "mysql"},"server-tags": [ "all" ]}, "service": [ "dhcp6" ] }' [ http://127.0.0.1:8000/ | http://127.0.0.1:8000/ ] Result [ { "result": 1, "text": "expression: [substring(relay6[1].option[37].hex,-16,all) == 0x34383537353434334536324241314141] error: <string>:1.18: Nest level invalid for DHCPv4 packets at (:0:0)" } ] Earlier similar client class was in text config "client-classes": [ { "name": "Client_SNCFG", "test": "substring(relay6[1].option[37].hex,-16,all) == 0x34383537353434334237423843374137", "option-data": [ { "name": "dns-servers", "code": 23, "space": "dhcp6", "csv-format": true, "data": "2a00:1858:0:1::53,2a00:1858:0:2::53" } ] } ]… And it worked What is wrong? And why kea saying …” for DHCPv4…” In my api call service is dhcp6 Orange Restricted ____________________________________________________________________________________________________________ Ce message et ses pieces jointes peuvent contenir des informations confidentielles ou privilegiees et ne doivent donc pas etre diffuses, exploites ou copies sans autorisation. Si vous avez recu ce message par erreur, veuillez le signaler a l'expediteur et le detruire ainsi que les pieces jointes. Les messages electroniques etant susceptibles d'alteration, Orange decline toute responsabilite si ce message a ete altere, deforme ou falsifie. Merci. This message and its attachments may contain confidential or privileged information that may be protected by law; they should not be distributed, used or copied without authorisation. If you have received this email in error, please notify the sender and delete this message and its attachments. As emails may be altered, Orange is not liable for messages that have been modified, changed or falsified. Thank you. -- ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information. To unsubscribe visit https://lists.isc.org/mailman/listinfo/kea-users. Kea-users mailing list [email protected] https://lists.isc.org/mailman/listinfo/kea-users
-- ISC funds the development of this software with paid support subscriptions. Contact us at https://www.isc.org/contact/ for more information. To unsubscribe visit https://lists.isc.org/mailman/listinfo/kea-users. Kea-users mailing list [email protected] https://lists.isc.org/mailman/listinfo/kea-users
