tomoyo_permstr(9)
π tomoyo_permstr β a kernel API manual, but make it make sense
okay so bestie, welcome to tomoyo_permstr, straight out of section 9 of the Kernel API Manual (yes, the kernel API manual, we're fancy now π). It's a tiny little function with one very specific job and honestly? She ate. Let's get into it β¨
πΈ NAME πΈ
tomoyo_permstr β the girl who finds permission keywords. That's it. That's the whole job description π
π¦ SYNOPSIS π¦
bool tomoyo_permstr(const char *string, const char *keyword);
look at her. two const char * args, returns a bool. clean. minimal. main character energy fr fr π
π ARGUMENTS π
stringβ the string representation for permissions, and it's gotta be infoo/bar/buzformat. like, that exact shape. bestie do not free-style the format, I'm begging πkeywordβ the keyword you're trying to find fromstring. as in, you go looking insidestringfor this. iykyk π
β¨ DESCRIPTION β¨
So here's the vibe check: she returns true if keyword was found in string, and false otherwise. simple. elegant. no cap π―
Now for the one slightly unhinged assumption, and I need you to hear me on this one: the function assumes that
strncmp(w1, w2, strlen(w1)) != 0
whenever w1 != w2. like, it just takes that as a given. that's the whole foundation she's built on, okay? so if you roll up with two different words where one is a prefix of the other and they compare equal over strlen(w1) bytesβ¦ yeah that's not her problem, that's your problem π don't say I didn't warn you π«Ά
π SEE ALSO π
okay this is the part where she tags literally everyone in the group chat π all of these live in the kernel file ./security/tomoyo/util.c:
tomoyo_convert_time(9)tomoyo_read_token(9)tomoyo_get_domainname(9)tomoyo_parse_ulong(9)tomoyo_print_ulong(9)tomoyo_parse_name_union(9)tomoyo_parse_number_union(9)tomoyo_byte_range(9)tomoyo_alphabet_char(9)tomoyo_make_byte(9)tomoyo_valid(9)tomoyo_invalid(9)tomoyo_str_starts(9)tomoyo_normalize_line(9)tomoyo_correct_word2(9)tomoyo_correct_word(9)tomoyo_correct_path2(9)tomoyo_correct_path(9)tomoyo_correct_domain(9)tomoyo_domain_def(9)tomoyo_find_domain(9)tomoyo_const_part_length(9)tomoyo_fill_path_info(9)tomoyo_file_matches_pattern2(9)tomoyo_file_matches_pattern(9)tomoyo_path_matches_pattern2(9)tomoyo_path_matches_pattern(9)tomoyo_get_exe(9)tomoyo_get_mode(9)tomoyo_init_request_info(9)tomoyo_domain_quota_is_ok(9)
like I said. everyone. the whole squad π§ββοΈ
and that's the tea, bestie π this lil page came from ./security/tomoyo and it's dated October 2026, and yes it's still filed under tomoyo_permstr(9) β slay, periodt π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms