Home
last modified time | relevance | path

Searched refs:pos (Results 1 – 25 of 28) sorted by relevance

12

/security/tomoyo/
Drealpath.c96 char *pos = ERR_PTR(-ENOMEM); in tomoyo_get_absolute_path() local
100 pos = d_absolute_path(path, buffer, buflen - 1); in tomoyo_get_absolute_path()
101 if (!IS_ERR(pos) && *pos == '/' && pos[1]) { in tomoyo_get_absolute_path()
110 return pos; in tomoyo_get_absolute_path()
127 char *pos = ERR_PTR(-ENOMEM); in tomoyo_get_dentry_path() local
130 pos = dentry_path_raw(dentry, buffer, buflen - 1); in tomoyo_get_dentry_path()
131 if (!IS_ERR(pos) && *pos == '/' && pos[1]) { in tomoyo_get_dentry_path()
140 return pos; in tomoyo_get_dentry_path()
156 char *pos = tomoyo_get_dentry_path(dentry, buffer, buflen); in tomoyo_get_local_path() local
158 if (IS_ERR(pos)) in tomoyo_get_local_path()
[all …]
Daudit.c30 unsigned long pos = bprm->p; in tomoyo_print_bprm() local
31 int offset = pos % PAGE_SIZE; in tomoyo_print_bprm()
46 if (!tomoyo_dump_page(bprm, pos, dump)) in tomoyo_print_bprm()
48 pos += PAGE_SIZE - offset; in tomoyo_print_bprm()
157 int pos; in tomoyo_print_header() local
165 pos = snprintf(buffer, tomoyo_buffer_len - 1, in tomoyo_print_header()
196 pos += snprintf(buffer + pos, in tomoyo_print_header()
197 tomoyo_buffer_len - 1 - pos, in tomoyo_print_header()
206 pos += snprintf(buffer + pos, tomoyo_buffer_len - 1 - pos, in tomoyo_print_header()
216 pos += snprintf(buffer + pos, in tomoyo_print_header()
[all …]
Dcondition.c113 unsigned long pos = bprm->p; in tomoyo_scan_bprm() local
114 int offset = pos % PAGE_SIZE; in tomoyo_scan_bprm()
130 if (!tomoyo_dump_page(bprm, pos, dump)) { in tomoyo_scan_bprm()
134 pos += PAGE_SIZE - offset; in tomoyo_scan_bprm()
457 char * const pos = param->data; in tomoyo_get_transit_preference() local
460 if (*pos == '<') { in tomoyo_get_transit_preference()
465 char *cp = strchr(pos, ' '); in tomoyo_get_transit_preference()
469 flag = tomoyo_correct_path(pos) || !strcmp(pos, "keep") || in tomoyo_get_transit_preference()
470 !strcmp(pos, "initialize") || !strcmp(pos, "reset") || in tomoyo_get_transit_preference()
471 !strcmp(pos, "child") || !strcmp(pos, "parent"); in tomoyo_get_transit_preference()
[all …]
Dutil.c135 char *pos = param->data; in tomoyo_read_token() local
136 char *del = strchr(pos, ' '); in tomoyo_read_token()
141 del = pos + strlen(pos); in tomoyo_read_token()
143 return pos; in tomoyo_read_token()
157 char *pos = start; in tomoyo_get_domainname() local
159 while (*pos) { in tomoyo_get_domainname()
160 if (*pos++ != ' ' || *pos++ == '/') in tomoyo_get_domainname()
162 pos -= 2; in tomoyo_get_domainname()
163 *pos++ = '\0'; in tomoyo_get_domainname()
166 param->data = pos; in tomoyo_get_domainname()
Dsecurityfs_if.c105 loff_t pos = *ppos; in tomoyo_read_self() local
107 if (pos >= len || !count) in tomoyo_read_self()
109 len -= pos; in tomoyo_read_self()
112 if (copy_to_user(buf, domain + pos, len)) in tomoyo_read_self()
Ddomain.c623 unsigned long pos = bprm->p; in tomoyo_environ() local
624 int offset = pos % PAGE_SIZE; in tomoyo_environ()
639 if (!tomoyo_dump_page(bprm, pos, &env_page)) in tomoyo_environ()
641 pos += PAGE_SIZE - offset; in tomoyo_environ()
898 bool tomoyo_dump_page(struct linux_binprm *bprm, unsigned long pos, in tomoyo_dump_page() argument
917 if (get_user_pages_remote(current, bprm->mm, pos, 1, in tomoyo_dump_page()
921 page = bprm->page[pos / PAGE_SIZE]; in tomoyo_dump_page()
924 const unsigned int offset = pos % PAGE_SIZE; in tomoyo_dump_page()
Dcommon.h938 bool tomoyo_dump_page(struct linux_binprm *bprm, unsigned long pos,
1329 #define list_for_each_cookie(pos, head) \ argument
1330 if (!pos) \
1331 pos = srcu_dereference((head)->next, &tomoyo_ss); \
1332 for ( ; pos != (head); pos = srcu_dereference(pos->next, &tomoyo_ss))
Dcommon.c199 const int pos = strlen(buffer); in tomoyo_addprintf() local
202 vsnprintf(buffer + pos, len - pos - 1, fmt, args); in tomoyo_addprintf()
282 size_t pos = head->r.avail; in tomoyo_io_printf() local
283 int size = head->readbuf_size - pos; in tomoyo_io_printf()
288 len = vsnprintf(head->read_buf + pos, size, fmt, args) + 1; in tomoyo_io_printf()
290 if (pos + len >= head->readbuf_size) { in tomoyo_io_printf()
295 tomoyo_set_string(head, head->read_buf + pos); in tomoyo_io_printf()
2205 unsigned int pos = 0; in tomoyo_read_query() local
2217 if (pos++ != head->r.query_index) in tomoyo_read_query()
2230 pos = 0; in tomoyo_read_query()
[all …]
/security/apparmor/
Dpolicy_unpack.c72 void *pos; /* pointer to current position in the buffer */ member
89 if (aad(sa)->iface.pos) in audit_cb()
90 audit_log_format(ab, " offset=%ld", aad(sa)->iface.pos); in audit_cb()
111 aad(&sa)->iface.pos = e->pos - e->start; in audit_iface()
200 return (size <= e->end - e->pos); in inbounds()
222 void *pos = e->pos; in unpack_u16_chunk() local
226 size = le16_to_cpu(get_unaligned((__le16 *) e->pos)); in unpack_u16_chunk()
227 e->pos += sizeof(__le16); in unpack_u16_chunk()
230 *chunk = e->pos; in unpack_u16_chunk()
231 e->pos += size; in unpack_u16_chunk()
[all …]
Dmatch.c373 unsigned int pos = base_idx(b) + (C); \
374 if ((check)[pos] != (state)) { \
380 (state) = (next)[pos]; \
519 unsigned int state = start, pos; in aa_dfa_match_until() local
530 pos = base_idx(base[state]) + equiv[(u8) *str++]; in aa_dfa_match_until()
531 if (check[pos] == state) in aa_dfa_match_until()
532 state = next[pos]; in aa_dfa_match_until()
541 pos = base_idx(base[state]) + (u8) *str++; in aa_dfa_match_until()
542 if (check[pos] == state) in aa_dfa_match_until()
543 state = next[pos]; in aa_dfa_match_until()
[all …]
Dapparmorfs.c389 loff_t *pos) in aa_simple_write_to_buffer() argument
395 if (*pos != 0) in aa_simple_write_to_buffer()
414 loff_t *pos, struct aa_ns *ns) in policy_update() argument
429 data = aa_simple_write_to_buffer(buf, size, size, pos); in policy_update()
442 loff_t *pos) in profile_load() argument
445 int error = policy_update(AA_MAY_LOAD_POLICY, buf, size, pos, ns); in profile_load()
459 size_t size, loff_t *pos) in profile_replace() argument
463 buf, size, pos, ns); in profile_replace()
476 size_t size, loff_t *pos) in profile_remove() argument
495 data = aa_simple_write_to_buffer(buf, size + 1, size, pos); in profile_remove()
[all …]
Dlabel.c226 int i, pos, dups = 0; in unique() local
231 pos = 0; in unique()
233 int res = profile_cmp(vec[pos], vec[i]); in unique()
242 pos++; in unique()
244 vec[pos] = vec[i]; in unique()
279 int pos, j; in aa_vec_unique() local
281 for (pos = i - 1 - dups; pos >= 0; pos--) { in aa_vec_unique()
282 int res = profile_cmp(vec[pos], tmp); in aa_vec_unique()
293 pos++; in aa_vec_unique()
295 for (j = i - dups; j > pos; j--) in aa_vec_unique()
[all …]
Dmount.c323 int pos, error; in match_mnt_path_str() local
344 pos = do_match_mnt(profile->policy.dfa, in match_mnt_path_str()
347 if (pos) { in match_mnt_path_str()
348 info = mnt_info_table[pos]; in match_mnt_path_str()
/security/smack/
Dsmackfs.c531 static void *smk_seq_start(struct seq_file *s, loff_t *pos, in smk_seq_start() argument
535 int i = *pos; in smk_seq_start()
548 static void *smk_seq_next(struct seq_file *s, void *v, loff_t *pos, in smk_seq_next() argument
553 ++*pos; in smk_seq_next()
607 static void *load2_seq_start(struct seq_file *s, loff_t *pos) in load2_seq_start() argument
609 return smk_seq_start(s, pos, &smack_known_list); in load2_seq_start()
612 static void *load2_seq_next(struct seq_file *s, void *v, loff_t *pos) in load2_seq_next() argument
614 return smk_seq_next(s, v, pos, &smack_known_list); in load2_seq_next()
753 static void *cipso_seq_start(struct seq_file *s, loff_t *pos) in cipso_seq_start() argument
755 return smk_seq_start(s, pos, &smack_known_list); in cipso_seq_start()
[all …]
/security/selinux/ss/
Dsidtab.c337 u32 *pos, u32 count, u32 level, in sidtab_convert_tree() argument
351 while (i < SIDTAB_INNER_ENTRIES && *pos < count) { in sidtab_convert_tree()
354 pos, count, level - 1, in sidtab_convert_tree()
368 while (i < SIDTAB_LEAF_ENTRIES && *pos < count) { in sidtab_convert_tree()
374 (*pos)++; in sidtab_convert_tree()
386 u32 count, level, pos; in sidtab_convert() local
421 pos = 0; in sidtab_convert()
423 &s->roots[level], &pos, count, level, params); in sidtab_convert()
/security/keys/
Dproc.c115 key_serial_t pos = *_pos; in proc_keys_start() local
122 key = find_ge_key(p, pos); in proc_keys_start()
276 loff_t pos = *_pos; in proc_key_users_start() local
281 while (pos > 0 && _p) { in proc_key_users_start()
282 pos--; in proc_key_users_start()
Dbig_key.c224 loff_t pos = 0; in big_key_preparse() local
253 written = kernel_write(file, buf->virt, enclen, &pos); in big_key_preparse()
369 loff_t pos = 0; in big_key_read() local
382 ret = kernel_read(file, buf->virt, enclen, &pos); in big_key_read()
/security/selinux/
Davc.c617 struct avc_node *pos, *node = NULL; in avc_insert() local
641 hlist_for_each_entry(pos, head, list) { in avc_insert()
642 if (pos->ae.ssid == ssid && in avc_insert()
643 pos->ae.tsid == tsid && in avc_insert()
644 pos->ae.tclass == tclass) { in avc_insert()
645 avc_node_replace(avc, node, pos); in avc_insert()
851 struct avc_node *pos, *node, *orig = NULL; in avc_update_node() local
885 hlist_for_each_entry(pos, head, list) { in avc_update_node()
886 if (ssid == pos->ae.ssid && in avc_update_node()
887 tsid == pos->ae.tsid && in avc_update_node()
[all …]
/security/apparmor/include/
Dlabel.h334 const char *pos; in aa_label_strn_split() local
337 state = aa_dfa_matchn_until(stacksplitdfa, DFA_START, str, n, &pos); in aa_label_strn_split()
341 return pos - 3; in aa_label_strn_split()
346 const char *pos; in aa_label_str_split() local
349 state = aa_dfa_match_until(stacksplitdfa, DFA_START, str, &pos); in aa_label_str_split()
353 return pos - 3; in aa_label_str_split()
Dmatch.h140 unsigned int pos; member
148 .pos = 0, \
Daudit.h144 long pos; member
/security/integrity/ima/
Dima_fs.c78 static void *ima_measurements_start(struct seq_file *m, loff_t *pos) in ima_measurements_start() argument
80 loff_t l = *pos; in ima_measurements_start()
95 static void *ima_measurements_next(struct seq_file *m, void *v, loff_t *pos) in ima_measurements_next() argument
105 (*pos)++; in ima_measurements_next()
Dima.h241 void *ima_policy_start(struct seq_file *m, loff_t *pos);
242 void *ima_policy_next(struct seq_file *m, void *v, loff_t *pos);
/security/
Ddevice_cgroup.c536 struct cgroup_subsys_state *pos; in propagate_exception() local
541 css_for_each_descendant_pre(pos, &devcg_root->css) { in propagate_exception()
542 struct dev_cgroup *devcg = css_to_devcgroup(pos); in propagate_exception()
550 if (pos == &devcg_root->css || !is_devcg_online(devcg)) in propagate_exception()
/security/integrity/evm/
Devm_main.c563 struct list_head *pos, *q; in init_evm() local
580 list_for_each_safe(pos, q, &evm_config_xattrnames) in init_evm()
581 list_del(pos); in init_evm()

12