5 String protocol_to_string(firewall_protocol_t &protocol)
18 firewall_protocol_t string_to_protocol(String &protocol)
20 if (protocol.equals(
"TCP"))
22 else if (protocol.equals(
"UDP"))
28 String target_to_string(firewall_target_t &target)
39 firewall_target_t string_to_target(String &target)
41 if (target.equals(
"DROP"))
49 Serial.printf(
"Something went wrong. Running endless loop until fixed...");
54 bool is_in_range(
const uint16_t number,
const uint16_t lower,
const uint16_t upper)
56 return lower <= number && number <= upper;