Hello, I searched for some time and checked docs and API viewer here:
API viewer - PUT - /api2/json/cluster/firewall/ipset/{name}/{cidr}
But I'm not able to change my CIDR range when already exists using HTTP PUT API call.
There is no issue create CIDR range (in already created IPSet management) like this:
I get {"data":null} response which is completely fine and CIDR range is created under IPSet named management:
But if I try to change it with PUT, I get duplicate parameter error.
According to documentation I should use cidr param. What can I do to be able to change already set cidr?
pve-manager/7.3-6/723bb6ec (running kernel: 5.15.85-1-pve)
Thanks,
J.
API viewer - PUT - /api2/json/cluster/firewall/ipset/{name}/{cidr}
But I'm not able to change my CIDR range when already exists using HTTP PUT API call.
There is no issue create CIDR range (in already created IPSet management) like this:
Bash:
curl -sS --noproxy "*" -k -b "PVEAuthCookie=${TIC}" -H "CSRFPreventionToken: ${TOK}" -X POST --data-urlencode cidr="192.168.251.0/24" https://${H}:8006/api2/json/cluster/firewall/ipset/management
I get {"data":null} response which is completely fine and CIDR range is created under IPSet named management:
But if I try to change it with PUT, I get duplicate parameter error.
Bash:
curl -sS --noproxy "*" -k -b "PVEAuthCookie=${TIC}" -H "CSRFPreventionToken: ${TOK}" -X PUT --data-urlencode cidr="192.168.251.100/32" https://${H}:8006/api2/json/cluster/firewall/ipset/management/192.168.251.0/24
JSON:
{"data":null,"errors":{"cidr":"duplicate parameter (already defined in URI) with conflicting values!"}}
According to documentation I should use cidr param. What can I do to be able to change already set cidr?
pve-manager/7.3-6/723bb6ec (running kernel: 5.15.85-1-pve)
Thanks,
J.