Home
last modified time | relevance | path

Searched refs:name (Results 1 – 25 of 111) sorted by relevance

12345

/mbedtls-3.5.0/scripts/
Dconfig.py45 def __init__(self, active, name, value='', section=None): argument
47 self.name = name
71 def __contains__(self, name): argument
77 return name in self.settings and self.settings[name].active
81 return all(self.__contains__(name) for name in names)
85 return any(self.__contains__(name) for name in names)
87 def known(self, name): argument
89 return name in self.settings
91 def __getitem__(self, name): argument
96 return self.settings[name].value
[all …]
Dgenerate_query_config.pl90 my $name = $2;
93 next if $name =~ /$excluded_re/;
96 #if defined($name)
97 if( strcmp( "$name", config ) == 0 )
99 MACRO_EXPANSION_TO_STR( $name );
102 #endif /* $name */
107 #if defined($name)
108 OUTPUT_MACRO_NAME_VALUE($name);
109 #endif /* $name */
Dgenerate_psa_constants.py229 def _make_return_case(name): argument
230 return 'case %(name)s: return "%(name)s";' % {'name': name}
233 def _make_append_case(name): argument
237 return template % {'name': name, 'length': len(name)}
Dgenerate_ssl_debug_helpers.py233 name=self._name,
278 name = m.groupdict()['name']
279 return_val = name[len('MBEDTLS_TLS1_3_SIG_'):].lower()
281 ' case {}:\n return "{}";'.format(name, return_val))
337 name = m.groupdict()['name']
338 iana_name = name[len('MBEDTLS_SSL_IANA_TLS_GROUP_'):].lower()
339 translation_table.append(' case {}:\n return "{}";'.format(name, iana_name))
/mbedtls-3.5.0/scripts/mbedtls_dev/
Dmacro_collector.py123 def is_internal_name(self, name: str) -> bool:
126 if name.endswith('_BASE') or name.endswith('_NONE'):
128 if '_CATEGORY_' in name:
130 return name.endswith('_FLAG') or name.endswith('_MASK')
150 def _format_arguments(name: str, arguments: Iterable[str]) -> str:
156 return name + '(' + ', '.join(arguments) + ')'
163 def distribute_arguments(self, name: str) -> Iterator[str]:
172 if name not in self.argspecs:
173 yield name
175 argspec = self.argspecs[name]
[all …]
Dtest_data_generation.py181 def generate_target(self, name: str, *target_args) -> None:
187 test_cases = self.targets[name](*target_args)
188 self.write_test_data_file(name, test_cases)
217 for name in sorted(generator.targets):
218 print(generator.filename_for(name))
222 print(';'.join(generator.filename_for(name)
223 for name in sorted(generator.targets)), end='')
Dcrypto_knowledge.py82 def __init__(self, name: str, params: Optional[Iterable[str]] = None) -> None:
93 self.name = name.strip()
100 if '(' in self.name:
101 m = re.match(r'(\w+)\s*\((.*)\)\Z', self.name)
103 self.name = m.group(1)
111 assert re.match(r'PSA_KEY_TYPE_\w+\Z', self.name)
113 self.expression = self.name
118 m = re.match(r'PSA_KEY_TYPE_(\w+)', self.name)
123 self.private_type = re.sub(r'_PUBLIC_KEY\Z', r'_KEY_PAIR', self.name)
139 return self.name.endswith('_PUBLIC_KEY')
[all …]
/mbedtls-3.5.0/tests/scripts/
Dgenerate_test_code.py298 def gen_function_wrapper(name, local_vars, args_dispatch): argument
316 '''.format(name=name,
323 def gen_dispatch(name, dependencies): argument
344 '''.format(preprocessor_check=preprocessor_check, name=name)
348 '''.format(name=name)
362 headers = '#line %d "%s"\n' % (funcs_f.line_no + 1, funcs_f.name)
369 (funcs_f.name, end_regex))
416 str(error) + " - %s:%d" % (funcs_f.name, funcs_f.line_no))
421 " not found!" % (funcs_f.name,
496 def generate_function_code(name, code, local_vars, args_dispatch, argument
[all …]
Dcheck_names.py81 def __init__(self, filename, line, line_no, pos, name): argument
87 self.name = name
178 .format(self.match.filename, self.match.line_no, self.match.name)
187 self.match.name,
208 .format(self.match.filename, self.match.line_no, self.match.name)
216 .format(self.match.filename, self.match.line_no, self.match.name)
291 identifiers_justname = [x.name for x in identifiers]
295 if macro.name not in identifiers_justname:
442 for name in mbed_regex.finditer(line):
447 name.span(0),
[all …]
Dgen_gcm_decrypt.pl29 my $name = shift;
35 ($val) = ($line =~ /\[$name\s\=\s(\w+)\]/);
44 my $name = shift;
54 ($val) = ($line =~ /^$name = (\w+)/);
61 my $name = shift;
71 ($val) = ($line =~ /^$name = (\w+)/) if ($line =~ /=/);
Ddepends.py169 def __init__(self, name, config_settings, commands): argument
179 self.name = name
189 log_line(self.name + ' PASSED', color=colors.green)
191 log_line(self.name + ' FAILED', color=colors.red)
193 log_line('starting ' + self.name, color=colors.cyan)
443 self.jobs[job.name] = job
445 def get_jobs(self, name): argument
448 if name in self.domains:
449 return sorted(self.domains[name].jobs, key=lambda job: job.name)
451 return [self.jobs[name]]
[all …]
Dgenerate_pkcs7_tests.py38 def __init__(self, name, depends, func_call): argument
39 self.name = name
45 return "\n" + self.name + "\n" + self.depends + "\n" + self.func_call + "\n"
80 latest_test_num = float(tests[-1].name.split('#')[1])
83 def add(self, name, func_call): argument
85 self.new_tests.append(Test(self.test_name + ": " + name + " #" + \
Dgen_gcm_encrypt.pl29 my $name = shift;
35 ($val) = ($line =~ /\[$name\s\=\s(\w+)\]/);
44 my $name = shift;
54 ($val) = ($line =~ /^$name = (\w+)/);
Dgen_ctr_drbg.pl30 my $name = shift;
34 ($val) = ($line =~ /\[$name\s\=\s(\w+)\]/);
41 my $name = shift;
51 ($val) = ($line =~ /^$name = (\w+)/);
Dgenerate_psa_tests.py36 def psa_want_symbol(name: str) -> str:
38 if name.startswith('PSA_'):
39 return name[:4] + 'WANT_' + name[4:]
41 raise ValueError('Unable to determine the PSA_WANT_ symbol for ' + name)
78 return sorted(psa_want_symbol(name) for name in used)
179 if kt.name in self.ALWAYS_SUPPORTED:
184 psa_want_symbol(kt.name)]
189 if kt.name.endswith('_PUBLIC_KEY'):
273 import_dependencies = [psa_want_symbol(kt.name)]
277 if kt.name.endswith('_PUBLIC_KEY'):
[all …]
Dpsa_collect_statuses.py68 for value, name in zip(values, output.rstrip().split('\n')):
69 self.status_names[value] = name
79 for name in sorted(names):
80 sys.stdout.write('{} {}\n'.format(function, name))
/mbedtls-3.5.0/programs/psa/
Dpsa_constant_names.c126 const char *name = get_name(alg); in append_with_alg() local
127 if (name != NULL) { in append_with_alg()
129 name, strlen(name)); in append_with_alg()
141 const char *name = psa_strerror(status); in psa_snprint_status() local
142 if (name == NULL) { in psa_snprint_status()
145 size_t length = strlen(name); in psa_snprint_status()
147 memcpy(buffer, name, length + 1); in psa_snprint_status()
158 const char *name = psa_ecc_family_name(curve); in psa_snprint_ecc_curve() local
159 if (name == NULL) { in psa_snprint_ecc_curve()
162 size_t length = strlen(name); in psa_snprint_ecc_curve()
[all …]
/mbedtls-3.5.0/library/
Dx509_create.c34 const char *name; /* String representation of AttributeType, e.g. member
108 static const x509_attr_descriptor_t *x509_attr_descr_from_name(const char *name, size_t name_len) in x509_attr_descr_from_name() argument
112 for (cur = x509_attrs; cur->name != NULL; cur++) { in x509_attr_descr_from_name()
114 strncmp(cur->name, name, name_len) == 0) { in x509_attr_descr_from_name()
119 if (cur->name == NULL) { in x509_attr_descr_from_name()
126 int mbedtls_x509_string_to_names(mbedtls_asn1_named_data **head, const char *name) in mbedtls_x509_string_to_names() argument
129 const char *s = name, *c = s; in mbedtls_x509_string_to_names()
238 const unsigned char *name = cur_name->val.p; in x509_write_name() local
244 (const char *) name, in x509_write_name()
Dx509.c844 const mbedtls_x509_name *name; in mbedtls_x509_dn_gets() local
850 name = dn; in mbedtls_x509_dn_gets()
854 while (name != NULL) { in mbedtls_x509_dn_gets()
855 if (!name->oid.p) { in mbedtls_x509_dn_gets()
856 name = name->next; in mbedtls_x509_dn_gets()
860 if (name != dn) { in mbedtls_x509_dn_gets()
865 ret = mbedtls_oid_get_attr_short_name(&name->oid, &short_name); in mbedtls_x509_dn_gets()
874 for (i = 0, j = 0; i < name->val.len; i++, j++) { in mbedtls_x509_dn_gets()
879 c = name->val.p[i]; in mbedtls_x509_dn_gets()
897 merge = name->next_merged; in mbedtls_x509_dn_gets()
[all …]
Dssl_ticket.c85 if ((ret = ctx->f_rng(ctx->p_rng, key->name, sizeof(key->name))) != 0) { in ssl_ticket_gen_key()
156 const unsigned char *name, size_t nlength, in mbedtls_ssl_ticket_rotate() argument
203 memcpy(key->name, name, TICKET_KEY_NAME_BYTES); in mbedtls_ssl_ticket_rotate()
342 memcpy(key_name, key->name, TICKET_KEY_NAME_BYTES); in mbedtls_ssl_ticket_write()
401 const unsigned char name[4]) in ssl_ticket_select_key()
406 if (memcmp(name, ctx->keys[i].name, 4) == 0) { in ssl_ticket_select_key()
Ddebug.c255 char name[16]; in debug_print_pk() local
270 mbedtls_snprintf(name, sizeof(name), "%s%s", text, items[i].name); in debug_print_pk()
271 name[sizeof(name) - 1] = '\0'; in debug_print_pk()
274 mbedtls_debug_print_mpi(ssl, level, file, line, name, items[i].value); in debug_print_pk()
278 mbedtls_debug_print_ecp(ssl, level, file, line, name, items[i].value); in debug_print_pk()
Dentropy_poll.c137 int name[2]; in sysctl_arnd_wrapper() local
140 name[0] = CTL_KERN; in sysctl_arnd_wrapper()
141 name[1] = KERN_ARND; in sysctl_arnd_wrapper()
145 if (sysctl(name, 2, buf, &len, NULL, 0) == -1) { in sysctl_arnd_wrapper()
/mbedtls-3.5.0/tests/suites/
Dtest_suite_x509parse.data3 …n \: 3\nserial number \: 01\nissuer name \: C=NL, O=PolarSSL, CN=PolarSSL Test CA\ns…
7 …n \: 3\nserial number \: 01\nissuer name \: C=NL, O=PolarSSL, CN=PolarSSL Test CA\ns…
11 …n \: 3\nserial number \: 02\nissuer name \: C=NL, O=PolarSSL, CN=PolarSSL Test CA\ns…
15 …n \: 3\nserial number \: 02\nissuer name \: C=NL, O=PolarSSL, CN=PolarSSL Test CA\ns…
19 …n \: 3\nserial number \: 03\nissuer name \: C=NL, O=PolarSSL, CN=PolarSSL Test CA\ns…
23 …n \: 3\nserial number \: 03\nissuer name \: C=NL, O=PolarSSL, CN=PolarSSL Test CA\ns…
27 …n \: 3\nserial number \: 06\nissuer name \: C=NL, O=PolarSSL, CN=PolarSSL Test CA\ns…
31 …n \: 3\nserial number \: 07\nissuer name \: C=NL, O=PolarSSL, CN=PolarSSL Test CA\ns…
35 …n \: 3\nserial number \: 08\nissuer name \: C=NL, O=PolarSSL, CN=PolarSSL Test CA\ns…
39 …n \: 3\nserial number \: 09\nissuer name \: C=NL, O=PolarSSL, CN=PolarSSL Test CA\ns…
[all …]
/mbedtls-3.5.0/programs/test/
Dselftest.c226 const char *name; member
481 for (test = selftests; test->name != NULL; test++) { in main()
482 if (!strcmp(*argp, test->name)) { in main()
490 if (test->name == NULL) { in main()
497 for (test = selftests; test->name != NULL; test++) { in main()
501 if (!strcmp(*excluded, test->name)) { in main()
507 mbedtls_printf(" Skip: %s\n", test->name); in main()
/mbedtls-3.5.0/tests/data_files/
Dprint_c.pl34 my $name = shift @ARGV;
43 print "const char $name\[\] = $pp_name;\n";
45 print "const char $name\[\] =";

12345