Searched defs:len (Results 1 - 25 of 41) sorted by relevance

12

/security/apparmor/include/
H A Dcrypto.h22 size_t len);
25 void *start, size_t len)
24 aa_calc_profile_hash(struct aa_profile *profile, u32 version, void *start, size_t len) argument
H A Dapparmor.h90 * @len: length of @sub to compare
94 static inline bool aa_strneq(const char *str, const char *sub, int len) argument
96 return !strncmp(str, sub, len) && !str[len];
H A Dmatch.h114 static inline size_t table_size(size_t len, size_t el_size) argument
116 return ALIGN(sizeof(struct table_header) + len * el_size, 8);
121 const char *str, int len);
/security/apparmor/
H A Dcrypto.c33 size_t len)
58 error = crypto_shash_update(&desc.shash, (u8 *) start, len);
32 aa_calc_profile_hash(struct aa_profile *profile, u32 version, void *start, size_t len) argument
H A Dmatch.c289 * @len: length of the string of bytes to match
296 * when @len input is consumed.
301 const char *str, int len)
317 for (; len; len--) {
326 for (; len; len--) {
300 aa_dfa_match_len(struct aa_dfa *dfa, unsigned int start, const char *str, int len) argument
H A Dprocattr.c39 int len = 0, mode_len = 0, ns_len = 0, name_len; local
61 len = mode_len + ns_len + name_len + 1; /* + 1 for \n */
62 s = str = kmalloc(len + 1, GFP_KERNEL); /* + 1 \0 */
78 /* NOTE: len does not include \0 of string, not saved as part of file */
79 return len;
H A Ddomain.c142 int len = 0; local
148 if (profile->xmatch && profile->xmatch_len > len) {
155 len = profile->xmatch_len;
H A Dapparmorfs.c59 int len = 0; local
63 len++;
66 return len;
419 int len, id_len; local
420 len = mangle_name(profile->base.name, NULL);
423 profile->dirname = kmalloc(len + id_len + 1, GFP_KERNEL);
428 sprintf(profile->dirname + len, ".%ld", profile->ns->uniq_id++);
/security/selinux/
H A Dnetlink.c46 static void selnl_add_payload(struct nlmsghdr *nlh, int len, int msgtype, void *data) argument
52 memset(msg, 0, len);
60 memset(msg, 0, len);
72 int len; local
77 len = selnl_msglen(msgtype);
79 skb = nlmsg_new(len, GFP_USER);
84 nlh = nlmsg_put(skb, 0, 0, msgtype, len, 0);
87 selnl_add_payload(nlh, len, msgtype, data);
/security/selinux/ss/
H A Dcontext.h30 u32 len; /* length of string in bytes */ member in struct:context
128 dst->len = src->len;
131 dst->len = 0;
146 c->len = 0;
152 if (c1->len && c2->len)
153 return (c1->len == c2->len && !strcmp(c1->str, c2->str));
154 if (c1->len || c
[all...]
H A Dconditional.c226 u32 len; local
244 len = le32_to_cpu(buf[2]);
247 key = kmalloc(len + 1, GFP_KERNEL);
250 rc = next_entry(key, fp, len);
253 key[len] = '\0';
356 u32 len; local
361 len = 0;
366 len = le32_to_cpu(buf[0]);
367 if (len == 0)
374 for (i = 0; i < len;
402 u32 len, i; local
457 u32 i, len; local
500 u32 len; local
530 u32 len; local
560 u32 len = 0; local
596 u32 len; local
[all...]
H A Dmls.c37 int i, l, len, head, prev; local
45 len = 1; /* for the beginning ":" */
48 len += strlen(sym_name(&policydb, SYM_LEVELS, index_sens - 1));
59 len += strlen(nm) + 1;
62 len += strlen(nm) + 1;
69 len += strlen(nm) + 1;
76 len++;
80 return len;
/security/
H A Dlsm_audit.c308 int len = 0; local
344 len = u->addr->len-sizeof(short);
350 audit_log_n_hex(ab, p, len);
/security/tomoyo/
H A Dmemory.c151 int len; local
156 len = strlen(name) + 1;
157 hash = full_name_hash((const unsigned char *) name, len - 1);
168 ptr = kzalloc(sizeof(*ptr) + len, GFP_NOFS);
171 memmove((char *) ptr->entry.name, name, len);
H A Drealpath.c24 int len = 0; local
35 len += 2;
37 len++;
39 len += 4;
41 len++;
43 cp = kzalloc(len + 10, GFP_NOFS);
H A Dsecurityfs_if.c109 loff_t len = strlen(domain); local
111 if (pos >= len || !count)
113 len -= pos;
114 if (count < len)
115 len = count;
116 if (copy_to_user(buf, domain + pos, len))
118 *ppos += len;
119 return len;
H A Daudit.c28 int len; local
36 len = snprintf(buffer, tomoyo_buffer_len - 1, "argv[]={ ");
37 cp = buffer + len;
232 * @len: Buffer size needed for @fmt and @args.
241 char *tomoyo_init_log(struct tomoyo_request_info *r, int len, const char *fmt, argument
255 len += strlen(domainname) + strlen(header) + 10;
263 len += strlen(realpath) + 80 + strlen(bprm_info);
267 len += 18 + strlen(symlink);
269 len = tomoyo_round2(len);
358 tomoyo_write_log2(struct tomoyo_request_info *r, int len, const char *fmt, va_list args) argument
414 int len; local
[all...]
H A Ddomain.c415 * @len: Length of @name.
423 (const char *name, const unsigned int len)
427 if (strncmp(name, ns->name, len) ||
428 (name[len] && name[len] != ' '))
450 unsigned int len = 0; local
452 len++;
453 ptr = tomoyo_find_namespace(domainname, len);
456 if (len >= TOMOYO_EXEC_TMPSIZE - 10 || !tomoyo_domain_def(domainname))
458 entry = kzalloc(sizeof(*entry) + len
422 tomoyo_find_namespace(const char *name, const unsigned int len) argument
489 const int len = strlen(namespace); local
[all...]
H A Dnetwork.c381 int len; local
389 len = strlen(buf);
390 snprintf(buf + len, sizeof(buf) - len, " %u",
551 int len = address->unix0.addr_len - sizeof(sa_family_t); local
553 if (len <= 0) {
555 len = 9;
557 len = strnlen(buf, len);
559 buf = tomoyo_encode2(buf, len);
[all...]
/security/integrity/ima/
H A Dima_api.c56 u32 len; local
64 len = (*entry)->template_data[i].len;
65 (*entry)->template_data_len += sizeof(len);
66 (*entry)->template_data_len += len;
H A Dima_fs.c34 ssize_t len; local
36 len = scnprintf(tmpbuf, TMPBUFLEN, "%li\n", atomic_long_read(val));
37 return simple_read_from_buffer(buf, count, ppos, tmpbuf, len);
56 return ima_show_htable_value(buf, count, ppos, &ima_htable.len);
222 if (e->template_data[i].len == 0)
H A Dima_template_lib.c64 field_data->len = buflen;
73 u8 *buf_ptr = field_data->data, buflen = field_data->len;
103 u32 len = (show == IMA_SHOW_BINARY_OLD_STRING_FMT) ? local
104 strlen(field_data->data) : field_data->len;
107 ima_putc(m, &len, sizeof(len));
109 if (!len)
112 ima_putc(m, field_data->data, len);
H A Dima.h58 u32 len; member in struct:ima_field_data
119 atomic_long_t len; /* number of stored measurements in the list */ member in struct:ima_h_table
/security/keys/
H A Dtrusted.h21 int len; member in struct:tpm_buf
25 #define INIT_BUF(tb) (tb->len = 0)
87 int len; local
90 len = LOAD32(buf, TPM_SIZE_OFFSET);
91 print_hex_dump(KERN_INFO, "", DUMP_PREFIX_NONE, 16, 1, buf, len, 0);
113 buf->data[buf->len++] = value;
118 *(uint16_t *) & buf->data[buf->len] = htons(value);
119 buf->len += sizeof value;
124 *(uint32_t *) & buf->data[buf->len] = htonl(value);
125 buf->len
128 storebytes(struct tpm_buf *buf, const unsigned char *in, const int len) argument
[all...]
/security/smack/
H A Dsmack_access.c426 * @len: the maximum size, or zero if it is NULL terminated.
430 char *smk_parse_smack(const char *string, int len) argument
435 if (len <= 0)
436 len = strlen(string) + 1;
446 for (i = 0; i < len; i++)
471 int len)
483 for (cat = 1, cp = catset, byte = 0; byte < len; cp++, byte++)
501 * @len: the maximum size, or zero if it is NULL terminated.
506 struct smack_known *smk_import_entry(const char *string, int len) argument
513 smack = smk_parse_smack(string, len);
470 smk_netlbl_mls(int level, char *catset, struct netlbl_lsm_secattr *sap, int len) argument
[all...]

Completed in 871 milliseconds

12