jdx/mise · error
firewall rule ' ' uses protocol , which UFW does not…
Error message
firewall rule '{}' uses protocol {}, which UFW does not support; select backend = "nftables" or "firewalld" What it means
UFW cannot express rules for the SCTP or DCCP protocols, so validation rejects rules carrying those protocols when the backend is Ufw. The error names the offending protocol and suggests nftables or firewalld, both of which support them.
Solutions
- Switch the backend to FirewallBackend::Nftables or FirewallBackend::Firewalld for this rule set.
- Change the rule's protocol to TCP or UDP if the service can use them.
- Remove the rule if the protocol is not actually needed on this host.
- Pre-screen the rule set per backend and route unsupported protocols to a capable backend.
Example fix
// before
apply(&FirewallRequest { backend: FirewallBackend::Ufw, rules: vec![FirewallRule { protocol: Some(FirewallProtocol::Sctp), .. }], .. }, false, true)?
// after
apply(&FirewallRequest { backend: FirewallBackend::Nftables, rules: vec![FirewallRule { protocol: Some(FirewallProtocol::Sctp), .. }], .. }, false, true)? Defensive patterns
Strategy: validation
Validate before calling
fn ufw_supported_protocol(rule: &FirewallRule) -> bool {
!matches!(rule.protocol, Some(FirewallProtocol::Sctp | FirewallProtocol::Dccp))
} Try / catch
match apply(&request, false, true) {
Err(e) if e.to_string().contains("UFW does not support") => {
eprintln!("route SCTP/DCCP rules to nftables or firewalld");
}
other => other?,
} Prevention
- Screen protocols per backend before building requests
- Default non-TCP/UDP protocols to nftables/firewalld backends
- Audit rule sets when migrating to ufw
- Keep protocol enums constrained to what the target backend accepts
When it happens
Trigger: Creating a FirewallRule with protocol = Some(FirewallProtocol::Sctp) or Some(FirewallProtocol::Dccp) while backend = FirewallBackend::Ufw, then calling validate_backend_request/apply.
Common situations: VoIP/telephony or signaling workloads that use SCTP configured behind a ufw-only host; protocol left at a non-TCP/UDP value from a shared rule template; migrating a rule set from nftables to ufw without auditing protocols.
Related errors
- bootstrap firewall management is only supported on Linux
- cache agent did not return the rustc identity
- cache agent did not store the rustc identity
- cache agent returned an incomplete blob lookup response
- cache agent returned an unexpected blob lookup response
AI-assisted analysis of jdx/mise@533346cc37 (2026-09-17).
Data as JSON: /api/errors/dfa51e621ca356ab.
Report an issue: GitHub.
Appendix: source
Thrown at src/system/firewall.rs:1070
bail!(
"firewall rule '{}' uses per-source connection limiting, which firewalld policies cannot express safely; select backend = \"nftables\" or \"ufw\"",
rule.name
);
}
}
if backend == FirewallBackend::Firewalld && rule.interface.is_some() {
bail!(
"firewall rule '{}' uses interface matching, which firewalld policies cannot express safely; select backend = \"nftables\" or \"ufw\"",
rule.name
);
}
if backend == FirewallBackend::Ufw
&& matches!(
rule.protocol,
Some(FirewallProtocol::Sctp | FirewallProtocol::Dccp)
)
{
bail!(
"firewall rule '{}' uses protocol {}, which UFW does not support; select backend = \"nftables\" or \"firewalld\"",
rule.name,
rule.protocol.expect("matched protocol").as_str()
);
}
}
Ok(())
}
fn validate_effective_backend_request(
request: &FirewallRequest,
effective: &FirewallRequest,
backend: FirewallBackend,
) -> Result<()> {
if effective.state == FirewallState::Enabled {
validate_backend_request(effective, backend)?;
request.validate_safety_with_rules(
&effective.rules,View on GitHub (pinned to 533346cc37)