Skip to main content

resolve

Function resolve 

Source
pub fn resolve(base: &str, path: &str) -> Result<String>
Expand description

Resolve a request path against an alias base, refusing anything that escapes.

Deliberately string-only. Asking the remote to REALPATH every request would add a round trip per request and break invariant 1. The cost is real and worth stating plainly: a symlink inside the base that points outside it is not caught here. That check needs the listing cache and arrives with it.