Function check_secrets_file

Source
fn check_secrets_file(path: &Path) -> Result<(), Error>
Expand description

Checks the accessibility of a secrets file.

Checks whether file at path

  • exists,
  • is a file,
  • has accessible metadata,
  • and has the file mode SECRET_FILE_MODE.

ยงErrors

Returns an error, if the file at path

  • does not exist,
  • is not a file,
  • does not have accessible metadata,
  • or has a file mode other than SECRET_FILE_MODE.