19 Jail(std::filesystem::path
const& jailRoot);
24 bool isWithinJail(std::filesystem::path
const& other)
const;
29 std::optional<std::filesystem::path>
39 std::optional<std::filesystem::path>
pathAsIsInJail(std::filesystem::path
const& other)
const;
47 std::filesystem::path
fakeJailAsRoot(std::filesystem::path
const& other)
const;
std::optional< std::filesystem::path > relativeToRoot(std::filesystem::path const &other, bool fakeJailAsRoot=false) const
Definition jail.cpp:27
std::filesystem::path jailRoot_
Definition jail.hpp:50
std::filesystem::path fakeJailAsRoot(std::filesystem::path const &other) const
Returns the jailed path as if it were coming from root like "/jail/asdf.txt".
Definition jail.cpp:52
std::optional< std::filesystem::path > pathAsIsInJail(std::filesystem::path const &other) const
First tests if the path is in the jail and then returns a full path of the resource including the jai...
Definition jail.cpp:44
bool isWithinJail(std::filesystem::path const &other) const
Definition jail.cpp:20
Definition authorization.hpp:10