Add --allow-read/--allow-write security options and deprecate --file-root
Author: fabricereixCreated May 23, 2024Updated Jul 17, 2026
Labelsenhancement
The current option --file-root is used for both:
- calculating an input/output path from a relative path
- enforcing file access
To make it easier to understand, this option could be removed. Relative files could be resolved only with the Hurl directory, and absolute files could use standard Hurl variables.
For example tests/test.hurl
file,data.bin; # Relative file resolved to tests/data.bin
file,../data/data.bin; # Relative file resolved to data/data.bin
file,/data/data.bin; # Absolute file
file,{{data_dir}}/data.bin; # Absolute fileEnforcing file access could be configured explicity with additional CLI options --allow-read/allow-write
similar to Deno (https://docs.deno.com/runtime/manual/basics/permissions)
The directory in which the hurl file is located and/or the current directory can be allowed by default.
Source: Orange-OpenSource/hurl