[pbs-devel] applied: [PATCH proxmox-backup] upid: remove arbitrary 128 max length for UPID

Dietmar Maurer dietmar at proxmox.com
Fri Sep 24 11:10:44 CEST 2021


applied to proxmox crate (upid is now in proxmox crate)

On 9/23/21 3:47 PM, Dominik Csapak wrote:
> we can easily go beyond that when having long datastore/remote names
> also because we do 'systemd-encode' them, which means that every special
> char takes up 4 bytes (e.g. '-' => '\x2d')
>
> while we could just increase the lenght to say 256 or 512, i do not
> really see the benefit to limit this at all, since users cannot create
> tasks with arbitrary names, and all other fields are generated from
> other valid types (username, datastore, remote, etc.)
>
> Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
> ---
>   pbs-api-types/src/upid.rs | 1 -
>   1 file changed, 1 deletion(-)
>
> diff --git a/pbs-api-types/src/upid.rs b/pbs-api-types/src/upid.rs
> index ba23a646..3094be2d 100644
> --- a/pbs-api-types/src/upid.rs
> +++ b/pbs-api-types/src/upid.rs
> @@ -58,7 +58,6 @@ pub const PROXMOX_UPID_FORMAT: ApiStringFormat =
>   
>   pub const UPID_SCHEMA: Schema = StringSchema::new("Unique Process/Task Identifier")
>       .min_length("UPID:N:12345678:12345678:12345678:::".len())
> -    .max_length(128) // arbitrary
>       .format(&PROXMOX_UPID_FORMAT)
>       .schema();
>   





More information about the pbs-devel mailing list