Signed-off-by: Dietmar Maurer <[email protected]>
---
proxmox-firewall-api-types/Cargo.toml | 1 +
proxmox-firewall-api-types/src/rule.rs | 5 ++---
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/proxmox-firewall-api-types/Cargo.toml
b/proxmox-firewall-api-types/Cargo.toml
index 8b77b522..2e894606 100644
--- a/proxmox-firewall-api-types/Cargo.toml
+++ b/proxmox-firewall-api-types/Cargo.toml
@@ -23,3 +23,4 @@ proxmox-schema = { workspace = true, features = ["api-macro"]
}
proxmox-serde = { workspace = true, features = ["perl"] }
proxmox-fixed-string = { workspace = true, optional = true }
proxmox-network-types = { workspace = true, features = [ "api-types" ] }
+proxmox-config-digest = { workspace = true }
\ No newline at end of file
diff --git a/proxmox-firewall-api-types/src/rule.rs
b/proxmox-firewall-api-types/src/rule.rs
index a2298609..835ac96e 100644
--- a/proxmox-firewall-api-types/src/rule.rs
+++ b/proxmox-firewall-api-types/src/rule.rs
@@ -1,3 +1,4 @@
+use proxmox_config_digest::ConfigDigest;
use serde::{Deserialize, Serialize};
#[cfg(feature = "enum-fallback")]
@@ -29,9 +30,7 @@ const_regex! {
optional: true,
},
digest: {
- max_length: 64,
optional: true,
- type: String,
},
dport: {
optional: true,
@@ -98,7 +97,7 @@ pub struct FirewallRule {
/// Prevent changes if current configuration file has a different digest.
/// This can be used to prevent concurrent modifications.
#[serde(default, skip_serializing_if = "Option::is_none")]
- pub digest: Option<String>,
+ pub digest: Option<ConfigDigest>,
/// Restrict TCP/UDP destination port.
#[serde(default, skip_serializing_if = "Option::is_none")]
--
2.47.3