/third_party/python/Lib/unittest/ |
D | util.py | 18 def _shorten(s, prefixlen, suffixlen): argument 19 skip = len(s) - prefixlen - suffixlen 21 s = '%s[%d chars]%s' % (s[:prefixlen], skip, s[len(s) - suffixlen:]) 31 prefixlen = len(prefix) 34 (maxlen - prefixlen + _MIN_BEGIN_LEN + _PLACEHOLDER_LEN) 37 (maxlen - prefixlen) < _MAX_LENGTH 39 return tuple(prefix + s[prefixlen:] for s in args) 42 return tuple(prefix + _shorten(s[prefixlen:], _MIN_DIFF_LEN, _MIN_END_LEN)
|
/third_party/python/Lib/ |
D | ipaddress.py | 435 def _ip_int_from_prefix(cls, prefixlen): argument 445 return cls._ALL_ONES ^ (cls._ALL_ONES >> prefixlen) 462 prefixlen = cls._max_prefixlen - trailing_zeroes 464 all_ones = (1 << prefixlen) - 1 470 return prefixlen 495 prefixlen = int(prefixlen_str) 498 if not (0 <= prefixlen <= cls._max_prefixlen): 500 return prefixlen 686 return '%s/%d' % (self.network_address, self.prefixlen) 796 def prefixlen(self): member in _BaseNetwork [all …]
|
/third_party/wpa_supplicant/wpa_supplicant-2.9_standard/src/ap/ |
D | dhcp_snoop.c | 40 int res, msgtype = 0, prefixlen = 32; in handle_dhcp() local 79 prefixlen--; in handle_dhcp() 115 prefixlen); in handle_dhcp() 129 prefixlen, sta->addr); in handle_dhcp()
|
D | ap_drv_ops.h | 314 int prefixlen, const u8 *addr) in hostapd_drv_br_add_ip_neigh() argument 320 prefixlen, addr); in hostapd_drv_br_add_ip_neigh()
|
/third_party/wpa_supplicant/wpa_supplicant-2.9/src/ap/ |
D | dhcp_snoop.c | 40 int res, msgtype = 0, prefixlen = 32; in handle_dhcp() local 79 prefixlen--; in handle_dhcp() 113 prefixlen); in handle_dhcp() 127 prefixlen, sta->addr); in handle_dhcp()
|
D | ap_drv_ops.h | 309 int prefixlen, const u8 *addr) in hostapd_drv_br_add_ip_neigh() argument 315 prefixlen, addr); in hostapd_drv_br_add_ip_neigh()
|
/third_party/node/deps/openssl/openssl/crypto/x509/ |
D | v3_addr.c | 397 const int prefixlen, const int afilen) in make_addressPrefix() argument 399 int bytelen = (prefixlen + 7) / 8, bitlen = prefixlen % 8; in make_addressPrefix() 402 if (prefixlen < 0 || prefixlen > (afilen * 8)) in make_addressPrefix() 437 int i, prefixlen; in make_addressRange() local 442 if ((prefixlen = range_should_be_prefix(min, max, length)) >= 0) in make_addressRange() 443 return make_addressPrefix(result, min, prefixlen, length); in make_addressRange() 601 unsigned char *a, const int prefixlen) in X509v3_addr_add_prefix() argument 607 || !make_addressPrefix(&aor, a, prefixlen, length_from_afi(afi))) in X509v3_addr_add_prefix() 941 int prefixlen, i1, i2, delim, length; in v2i_IPAddrBlocks() local 1024 prefixlen = (int)strtoul(s + i2, &t, 10); in v2i_IPAddrBlocks() [all …]
|
/third_party/openssl/crypto/x509/ |
D | v3_addr.c | 397 const int prefixlen, const int afilen) in make_addressPrefix() argument 399 int bytelen = (prefixlen + 7) / 8, bitlen = prefixlen % 8; in make_addressPrefix() 402 if (prefixlen < 0 || prefixlen > (afilen * 8)) in make_addressPrefix() 437 int i, prefixlen; in make_addressRange() local 442 if ((prefixlen = range_should_be_prefix(min, max, length)) >= 0) in make_addressRange() 443 return make_addressPrefix(result, min, prefixlen, length); in make_addressRange() 601 unsigned char *a, const int prefixlen) in X509v3_addr_add_prefix() argument 607 || !make_addressPrefix(&aor, a, prefixlen, length_from_afi(afi))) in X509v3_addr_add_prefix() 941 int prefixlen, i1, i2, delim, length; in v2i_IPAddrBlocks() local 1020 prefixlen = (int)strtoul(s + i2, &t, 10); in v2i_IPAddrBlocks() [all …]
|
/third_party/musl/src/network/ |
D | getifaddrs.c | 82 static void gen_netmask(struct sockaddr **r, int af, union sockany *sa, int prefixlen) in gen_netmask() argument 87 if (prefixlen > 8*sizeof(addr)) prefixlen = 8*sizeof(addr); in gen_netmask() 88 i = prefixlen / 8; in gen_netmask() 90 if (i < sizeof(addr)) addr[i++] = 0xff << (8 - (prefixlen % 8)); in gen_netmask()
|
D | lookup_name.c | 480 int prefixlen = 0; in lookup_name_ext() local 493 prefixlen = prefixmatch(&sa6.sin6_addr, in lookup_name_ext() 501 key |= prefixlen << DAS_PREFIX_SHIFT; in lookup_name_ext()
|
/third_party/musl/porting/liteos_a/user/src/network/ |
D | getifaddrs.c | 91 static void gen_netmask(struct sockaddr **r, int af, union sockany *sa, int prefixlen) in gen_netmask() argument 96 if (prefixlen > 8*sizeof(addr)) prefixlen = 8*sizeof(addr); in gen_netmask() 97 i = prefixlen / 8; in gen_netmask() 99 if (i < sizeof(addr)) addr[i++] = 0xff << (8 - (prefixlen % 8)); in gen_netmask()
|
/third_party/musl/src/network/liteos_a/ |
D | getifaddrs.c | 91 static void gen_netmask(struct sockaddr **r, int af, union sockany *sa, int prefixlen) in gen_netmask() argument 96 if (prefixlen > 8 * sizeof(addr)) prefixlen = 8 * sizeof(addr); in gen_netmask() 97 i = prefixlen / 8; in gen_netmask() 99 if (i < sizeof(addr)) addr[i++] = 0xff << (8 - (prefixlen % 8)); in gen_netmask()
|
/third_party/openssl/ssl/ |
D | ssl_conf.c | 82 size_t prefixlen; member 812 if (strlen(*pcmd) <= cctx->prefixlen) in ssl_conf_cmd_skip_prefix() 815 strncmp(*pcmd, cctx->prefix, cctx->prefixlen)) in ssl_conf_cmd_skip_prefix() 818 OPENSSL_strncasecmp(*pcmd, cctx->prefix, cctx->prefixlen)) in ssl_conf_cmd_skip_prefix() 820 *pcmd += cctx->prefixlen; in ssl_conf_cmd_skip_prefix() 1039 cctx->prefixlen = strlen(tmp); in SSL_CONF_CTX_set1_prefix() 1041 cctx->prefixlen = 0; in SSL_CONF_CTX_set1_prefix()
|
/third_party/ltp/testcases/network/stress/ns-tools/ |
D | ns-common.c | 373 int ifidx, prefixlen, scope; in get_a_lla_byifindex() local 389 &ifidx, &prefixlen, &scope); in get_a_lla_byifindex() 400 if (prefixlen != 64) in get_a_lla_byifindex()
|
/third_party/node/deps/openssl/openssl/ssl/ |
D | ssl_conf.c | 82 size_t prefixlen; member 812 if (strlen(*pcmd) <= cctx->prefixlen) in ssl_conf_cmd_skip_prefix() 815 strncmp(*pcmd, cctx->prefix, cctx->prefixlen)) in ssl_conf_cmd_skip_prefix() 818 OPENSSL_strncasecmp(*pcmd, cctx->prefix, cctx->prefixlen)) in ssl_conf_cmd_skip_prefix() 820 *pcmd += cctx->prefixlen; in ssl_conf_cmd_skip_prefix() 1047 cctx->prefixlen = strlen(tmp); in SSL_CONF_CTX_set1_prefix() 1049 cctx->prefixlen = 0; in SSL_CONF_CTX_set1_prefix()
|
/third_party/icu/ohos_icu4j/src/main/java/ohos/global/icu/impl/ |
D | UCharacterName.java | 732 int prefixlen = m_prefix_.length(); in getChar() local 733 if (name.length() < prefixlen || in getChar() 734 !m_prefix_.equals(name.substring(0, prefixlen))) { in getChar() 743 int result = Integer.parseInt(name.substring(prefixlen), in getChar() 782 prefixlen)) { in getChar()
|
/third_party/icu/icu4j/main/classes/core/src/com/ibm/icu/impl/ |
D | UCharacterName.java | 731 int prefixlen = m_prefix_.length(); in getChar() local 732 if (name.length() < prefixlen || in getChar() 733 !m_prefix_.equals(name.substring(0, prefixlen))) { in getChar() 742 int result = Integer.parseInt(name.substring(prefixlen), in getChar() 781 prefixlen)) { in getChar()
|
/third_party/node/deps/nghttp2/lib/ |
D | nghttp2_hd.c | 1038 size_t prefixlen; in emit_indname_block() local 1041 prefixlen = 6; in emit_indname_block() 1043 prefixlen = 4; in emit_indname_block() 1049 blocklen = count_encoded_length(idx + 1, prefixlen); in emit_indname_block() 1059 encode_length(bufp, idx + 1, prefixlen); in emit_indname_block() 1958 size_t prefixlen; in nghttp2_hd_inflate_hd_nv() local 1961 prefixlen = 7; in nghttp2_hd_inflate_hd_nv() 1963 prefixlen = 6; in nghttp2_hd_inflate_hd_nv() 1965 prefixlen = 4; in nghttp2_hd_inflate_hd_nv() 1969 rv = hd_inflate_read_len(inflater, &rfin, in, last, prefixlen, in nghttp2_hd_inflate_hd_nv()
|
/third_party/nghttp2/lib/ |
D | nghttp2_hd.c | 1038 size_t prefixlen; in emit_indname_block() local 1041 prefixlen = 6; in emit_indname_block() 1043 prefixlen = 4; in emit_indname_block() 1049 blocklen = count_encoded_length(idx + 1, prefixlen); in emit_indname_block() 1059 encode_length(bufp, idx + 1, prefixlen); in emit_indname_block() 1958 size_t prefixlen; in nghttp2_hd_inflate_hd_nv() local 1961 prefixlen = 7; in nghttp2_hd_inflate_hd_nv() 1963 prefixlen = 6; in nghttp2_hd_inflate_hd_nv() 1965 prefixlen = 4; in nghttp2_hd_inflate_hd_nv() 1969 rv = hd_inflate_read_len(inflater, &rfin, in, last, prefixlen, in nghttp2_hd_inflate_hd_nv()
|
/third_party/node/deps/openssl/openssl/providers/implementations/kdfs/ |
D | hkdf.c | 587 const unsigned char *prefix, size_t prefixlen, in prov_tls13_hkdf_expand() argument 605 || !WPACKET_memcpy(&pkt, prefix, prefixlen) in prov_tls13_hkdf_expand() 626 size_t prefixlen, in prov_tls13_hkdf_generate_secret() argument 665 prefix, prefixlen, label, labellen, in prov_tls13_hkdf_generate_secret()
|
/third_party/openssl/providers/implementations/kdfs/ |
D | hkdf.c | 587 const unsigned char *prefix, size_t prefixlen, in prov_tls13_hkdf_expand() argument 605 || !WPACKET_memcpy(&pkt, prefix, prefixlen) in prov_tls13_hkdf_expand() 626 size_t prefixlen, in prov_tls13_hkdf_generate_secret() argument 665 prefix, prefixlen, label, labellen, in prov_tls13_hkdf_generate_secret()
|
/third_party/toybox/toys/pending/ |
D | route.c | 410 int prefixlen, metric, use, refcount, flag, items = 0; in display_routes6() local 419 &prefixlen, ipv6_src_addr+8, &metric, &use, &refcount, &flag, in display_routes6() 431 sprintf(toybuf, "%s/%d", buf2, prefixlen); in display_routes6()
|
/third_party/libinput/src/ |
D | util-strings.h | 393 size_t prefixlen = strlen(prefix); in strstartswith() local 395 return prefixlen > 0 ? strneq(str, prefix, strlen(prefix)) : false; in strstartswith()
|
/third_party/python/Lib/test/ |
D | test_ipaddress.py | 1320 self.assertEqual(self.ipv6_network.prefixlen, 64) 1323 self.assertEqual(self.ipv6_scoped_network.prefixlen, 64) 1340 self.assertEqual(net.prefixlen, 24) 1357 self.assertEqual(self.ipv4_interface.network.prefixlen, 24) 1358 self.assertEqual(self.ipv6_interface.network.prefixlen, 64) 1359 self.assertEqual(self.ipv6_scoped_interface.network.prefixlen, 64) 1362 self.assertEqual(self.ipv4_network.supernet().prefixlen, 23) 1369 self.assertEqual(self.ipv6_network.supernet().prefixlen, 63) 1374 self.assertEqual(self.ipv6_scoped_network.supernet().prefixlen, 63) 1379 self.assertEqual(self.ipv4_network.supernet(3).prefixlen, 21) [all …]
|
/third_party/musl/porting/linux/user/src/network/ |
D | lookup_name.c | 479 int prefixlen = 0; in lookup_name_ext() local 492 prefixlen = prefixmatch(&sa6.sin6_addr, in lookup_name_ext() 500 key |= prefixlen << DAS_PREFIX_SHIFT; in lookup_name_ext()
|