Restrict HTTP file artifact inputs
This commit is contained in:
@@ -70,6 +70,12 @@ Input reference types currently supported by runtime artifact loading:
|
||||
- `file`
|
||||
- `inline`
|
||||
|
||||
HTTP `file` references require `server.artifact_root` or `serve --artifact-root`.
|
||||
Relative file URIs resolve inside that root. Absolute file URIs are accepted
|
||||
only when they remain inside the root. Requests that escape the root, including
|
||||
`..` traversal and absolute paths outside the root, return
|
||||
`400 artifact_not_allowed`. `inline` references do not require an artifact root.
|
||||
|
||||
Model override notes:
|
||||
|
||||
- Numeric model override fields distinguish omitted values from explicit zero values. For example, omitting `temperature` preserves the selected profile/default value, while `"temperature": 0` explicitly sets the effective temperature to zero.
|
||||
@@ -194,6 +200,7 @@ Current error mapping (non-exhaustive):
|
||||
- `400 profile_required`: no explicit `profile_id` and prompt has no `default_profile`
|
||||
- `400 prompt_load_failed`: prompt definition invalid/unloadable
|
||||
- `400 profile_load_failed`: profile invalid/unloadable
|
||||
- `400 artifact_not_allowed`: file input artifact is outside the configured artifact root or file refs are not enabled
|
||||
- `400 artifact_read_failed`: input artifact loading failed
|
||||
- `400 prompt_render_failed`: template render failed
|
||||
- `400 api_key_env_missing`: named API-key environment variable is missing
|
||||
|
||||
Reference in New Issue
Block a user