Skip to main content

prepare_dir

Function prepare_dir 

Source
pub fn prepare_dir(dir: &Path, gid: Option<u32>) -> Result<()>
Expand description

Create dir (if needed) 0750 so group members can reach the ticket cache inside; with Some(gid), hand the directory to that group. This must only ever manage a dedicated directory like /run/machine-krb, so it refuses: relative paths, paths containing .., a symlink where the directory should be, and (post-canonicalization) well-known shared directories.