Language: Python
Label: safe
CWE: CWE-36 \u2014 Absolute Path Traversal
The product uses external input to construct a pathname that should be within a restricted directory, but it does not properly neutralize absolute path sequences such as "/abs/path" that can resolve to a location that is outside of that directory.

Code:
def test_create_registered_model_with_name_that_looks_like_path(store, tmp_path):
    name = str(tmp_path.joinpath("test"))
    with pytest.raises(
        MlflowException, match=r"Registered model name cannot contain path separator"
    ):
        store.get_registered_model(name)