Home | History | Annotate | Download | only in ext4_utils

Lines Matching full:directory

79         PLOG(ERROR) << "Unable to read directory: " << dirname;
87 PLOG(ERROR) << "Unable to read directory: " << dirname;
104 static bool e4crypt_policy_set(const char *directory, const char *policy,
110 int fd = open(directory, O_DIRECTORY | O_NOFOLLOW | O_CLOEXEC);
112 PLOG(ERROR) << "Failed to open directory " << directory;
123 PLOG(ERROR) << "Failed to set encryption policy for " << directory;
131 LOG(INFO) << "Policy for " << directory << " set to " << policy_hex;
135 static bool e4crypt_policy_get(const char *directory, char *policy,
142 int fd = open(directory, O_DIRECTORY | O_NOFOLLOW | O_CLOEXEC);
144 PLOG(ERROR) << "Failed to open directory " << directory;
151 PLOG(ERROR) << "Failed to get encryption policy for " << directory;
161 LOG(ERROR) << "Failed to find matching encryption policy for " << directory;
169 static bool e4crypt_policy_check(const char *directory, const char *policy,
176 if (!e4crypt_policy_get(directory, existing_policy, EXT4_KEY_DESCRIPTOR_SIZE,
185 LOG(ERROR) << "Found policy " << existing_policy_hex << " at " << directory
189 LOG(INFO) << "Found policy " << existing_policy_hex << " at " << directory
194 int e4crypt_policy_ensure(const char *directory, const char *policy,
207 if (!is_dir_empty(directory, &is_empty)) return -1;
209 if (!e4crypt_policy_set(directory, policy, policy_length,
212 if (!e4crypt_policy_check(directory, policy, policy_length,