I am trying to create a program, which can update a firewall rule and it should work. The issue is the expression.
It currently comes out like this
“(http.host eq "domain.name" and not ip.src in {13.13.13.13 12.12.12.12 11.11.11.11})”
though with other ip addresses and an actual domain name.
The expression is incorrect, due to cloudflare not accepting the \ symbols, inside the string. At least thats my theory. as the title says, i can update the description of the firewall, without issues.
I cant figure out how i can write it differently. According to cloudflare, it should be like this:
(http.host eq “domain.name” and not ip.src in {13.13.13.13 12.12.12.12 11.11.11.11})
Any suggestions?
this is my github, to the class that handles Cloudflare stuff.
https://github.com/MagnusHLund/Cloudflare_API_Firewall/blob/master/Cloudflare_API_Firewall/Controller/CloudflareController.cs
The method that actually updates the firewall is called UpdateFirewallRule.
I Hope you guys can help me out, thanks