X-Git-Url: https://git.saurik.com/apple/security.git/blobdiff_plain/07691282a056c4efea71e1e505527601e8cc166b..refs/heads/master:/OSX/libsecurity_codesigning/lib/csutilities.h diff --git a/OSX/libsecurity_codesigning/lib/csutilities.h b/OSX/libsecurity_codesigning/lib/csutilities.h index bd4408cd..6a69749f 100644 --- a/OSX/libsecurity_codesigning/lib/csutilities.h +++ b/OSX/libsecurity_codesigning/lib/csutilities.h @@ -225,7 +225,27 @@ private: Dispatch::Semaphore *mResourceSemaphore; }; +// Check if the path is on the root filesystem, protected by the OS. +bool isOnRootFilesystem(const char *path); +// Check if a path exists. +bool pathExists(const char *path); + +// Check if the path name represents an extended attribute file (on file systems which don't support +// them natively). +bool pathMatchesXattrFilenameSpec(const char *path); + +// Check if path is a regular file. +bool pathIsRegularFile(const char *path); + +// Check if a path has any extended attributes. +bool pathHasXattrs(const char *path); + +// Check if the path is on a file system that requires files to store extended attributes. +bool pathFileSystemUsesXattrFiles(const char *path); + +// Check if path is a valid extended attribute file. +bool pathIsValidXattrFile(const string fullPath, const char *scope = "csutilities"); } // end namespace CodeSigning } // end namespace Security