Home
last modified time | relevance | path

Searched refs:bit_string (Results 1 – 22 of 22) sorted by relevance

/external/cronet/net/der/
Dparse_values_unittest.cc314 absl::optional<BitString> bit_string = ParseBitString(Input(kData)); in TEST() local
315 ASSERT_TRUE(bit_string.has_value()); in TEST()
317 EXPECT_EQ(0u, bit_string->unused_bits()); in TEST()
318 EXPECT_EQ(0u, bit_string->bytes().Length()); in TEST()
320 EXPECT_FALSE(bit_string->AssertsBit(0)); in TEST()
321 EXPECT_FALSE(bit_string->AssertsBit(1)); in TEST()
322 EXPECT_FALSE(bit_string->AssertsBit(3)); in TEST()
329 absl::optional<BitString> bit_string = ParseBitString(Input(kData)); in TEST() local
330 EXPECT_FALSE(bit_string.has_value()); in TEST()
338 absl::optional<BitString> bit_string = ParseBitString(Input(kData)); in TEST() local
[all …]
Dparser_unittest.cc345 absl::optional<BitString> bit_string = parser.ReadBitString(); in TEST() local
346 ASSERT_TRUE(bit_string.has_value()); in TEST()
349 EXPECT_EQ(1u, bit_string->unused_bits()); in TEST()
350 ASSERT_EQ(2u, bit_string->bytes().Length()); in TEST()
351 EXPECT_EQ(0xAA, bit_string->bytes().UnsafeData()[0]); in TEST()
352 EXPECT_EQ(0xBE, bit_string->bytes().UnsafeData()[1]); in TEST()
361 absl::optional<BitString> bit_string = parser.ReadBitString(); in TEST() local
362 EXPECT_FALSE(bit_string.has_value()); in TEST()
/external/libsrtp2/crypto/math/
Ddatatypes.c82 char bit_string[MAX_PRINT_STRING_LEN]; variable
104 bit_string[i] = srtp_nibble_to_hex_char(*str >> 4); in srtp_octet_string_hex_string()
105 bit_string[i + 1] = srtp_nibble_to_hex_char(*str++ & 0xF); in srtp_octet_string_hex_string()
107 bit_string[i] = 0; /* null terminate string */ in srtp_octet_string_hex_string()
108 return bit_string; in srtp_octet_string_hex_string()
116 bit_string[j++] = srtp_nibble_to_hex_char(x->v8[i] >> 4); in v128_hex_string()
117 bit_string[j++] = srtp_nibble_to_hex_char(x->v8[i] & 0xF); in v128_hex_string()
120 bit_string[j] = 0; /* null terminate string */ in v128_hex_string()
121 return bit_string; in v128_hex_string()
132 bit_string[i] = '1'; in v128_bit_string()
[all …]
/external/libsrtp2/test/
Dutil.c52 char bit_string[MAX_PRINT_STRING_LEN + 1]; variable
160 bit_string[i] = nibble_to_hex_char(*str >> 4); in octet_string_hex_string()
161 bit_string[i + 1] = nibble_to_hex_char(*str++ & 0xF); in octet_string_hex_string()
163 bit_string[i] = 0; /* null terminate string */ in octet_string_hex_string()
164 return bit_string; in octet_string_hex_string()
/external/rust/crates/der/src/asn1/
Dbit_string.rs117 bit_string: self, in bits()
190 fn try_from(bit_string: BitStringRef<'a>) -> Result<&'a [u8]> { in try_from()
191 bit_string in try_from()
324 fn from(bit_string: &'a BitString) -> BitStringRef<'a> { in from()
326 BitStringRef::new(bit_string.unused_bits, &bit_string.inner).expect("invalid BIT STRING") in from()
343 bit_string: BitStringRef<'a>, field
354 if self.position >= self.bit_string.bit_len() { in next()
358 let byte = self.bit_string.raw_bytes().get(self.position / 8)?; in next()
367 self.bit_string.bit_len() in len()
Dany.rs80 pub fn bit_string(self) -> Result<BitStringRef<'a>> { in bit_string() method
/external/rust/crates/der_derive/src/
Dchoice.rs206 let bit_string = &ir.variants[0]; in implicit_example() localVariable
207 assert_eq!(bit_string.ident, "BitString"); in implicit_example()
208 assert_eq!(bit_string.attrs.asn1_type, Some(Asn1Type::BitString)); in implicit_example()
210 bit_string.attrs.context_specific, in implicit_example()
213 assert_eq!(bit_string.attrs.tag_mode, TagMode::Implicit); in implicit_example()
215 bit_string.tag, in implicit_example()
Dsequence.rs292 bit_string: BitString<'a>, in implicit_example()
307 let bit_string = &ir.fields[0]; in implicit_example() localVariable
308 assert_eq!(bit_string.ident, "bit_string"); in implicit_example()
309 assert_eq!(bit_string.attrs.asn1_type, Some(Asn1Type::BitString)); in implicit_example()
311 bit_string.attrs.context_specific, in implicit_example()
314 assert_eq!(bit_string.attrs.tag_mode, TagMode::Implicit); in implicit_example()
/external/rust/crates/der/src/
Dasn1.rs5 mod bit_string; module
30 bit_string::{BitStringIter, BitStringRef},
50 pub use self::{any::Any, bit_string::BitString, octet_string::OctetString, set_of::SetOfVec};
/external/rappor/tests/
Drappor_sim.py130 irr1_str = rappor.bit_string(irr1, params1.num_bloombits)
131 irr2_str = rappor.bit_string(irr2, params2.num_bloombits)
172 bloom_str = rappor.bit_string(bloom, params.num_bloombits)
173 prr_str = rappor.bit_string(prr, params.num_bloombits)
174 irr_str = rappor.bit_string(irr, params.num_bloombits)
/external/python/cryptography/src/cryptography/hazmat/backends/openssl/
Ddecode_asn1.py404 def _decode_key_usage(backend, bit_string): argument
405 bit_string = backend._ffi.cast("ASN1_BIT_STRING *", bit_string)
406 bit_string = backend._ffi.gc(bit_string, backend._lib.ASN1_BIT_STRING_free)
408 digital_signature = get_bit(bit_string, 0) == 1
409 content_commitment = get_bit(bit_string, 1) == 1
410 key_encipherment = get_bit(bit_string, 2) == 1
411 data_encipherment = get_bit(bit_string, 3) == 1
412 key_agreement = get_bit(bit_string, 4) == 1
413 key_cert_sign = get_bit(bit_string, 5) == 1
414 crl_sign = get_bit(bit_string, 6) == 1
[all …]
/external/cronet/third_party/boringssl/src/ssl/
Dssl_cert.cc590 CBS bit_string; in ssl_cert_check_key_usage() local
591 if (!CBS_get_asn1(&contents, &bit_string, CBS_ASN1_BITSTRING) || in ssl_cert_check_key_usage()
599 if (!CBS_is_valid_asn1_bitstring(&bit_string)) { in ssl_cert_check_key_usage()
604 if (!CBS_asn1_bitstring_has_bit(&bit_string, bit)) { in ssl_cert_check_key_usage()
/external/rust/crates/quiche/deps/boringssl/src/ssl/
Dssl_cert.cc592 CBS bit_string; in ssl_cert_check_key_usage() local
593 if (!CBS_get_asn1(&contents, &bit_string, CBS_ASN1_BITSTRING) || in ssl_cert_check_key_usage()
601 if (!CBS_is_valid_asn1_bitstring(&bit_string)) { in ssl_cert_check_key_usage()
606 if (!CBS_asn1_bitstring_has_bit(&bit_string, bit)) { in ssl_cert_check_key_usage()
/external/boringssl/src/ssl/
Dssl_cert.cc590 CBS bit_string; in ssl_cert_check_key_usage() local
591 if (!CBS_get_asn1(&contents, &bit_string, CBS_ASN1_BITSTRING) || in ssl_cert_check_key_usage()
599 if (!CBS_is_valid_asn1_bitstring(&bit_string)) { in ssl_cert_check_key_usage()
604 if (!CBS_asn1_bitstring_has_bit(&bit_string, bit)) { in ssl_cert_check_key_usage()
/external/rust/crates/der/tests/
Dderive.rs104 pub fn bit_string(&self) -> Option<BitStringRef<'a>> { in bit_string() method
126 cs_bit_string.bit_string().unwrap().as_bytes().unwrap(), in decode()
/external/scapy/scapy/
Dasn1fields.py564 bit_string, remain = ASN1F_BIT_STRING.m2i(self, pkt, s)
565 if len(bit_string.val) % 8 != 0:
567 p,s = self.extract_packet(self.cls, bit_string.val_readable)
/external/rappor/client/python/
Drappor.py220 def bit_string(irr, num_bloombits): function
/external/rust/crates/quiche/deps/boringssl/src/crypto/x509/
Dasn1_gen.c787 (str, ',', 1, bitstr_cb, atmp->value.bit_string)) { in asn1_str2type()
/external/rust/crates/quiche/deps/boringssl/src/include/openssl/
Dasn1.h699 ASN1_BIT_STRING *bit_string; member
/external/cronet/third_party/boringssl/src/include/openssl/
Dasn1.h1497 ASN1_BIT_STRING *bit_string; member
/external/boringssl/src/include/openssl/
Dasn1.h1497 ASN1_BIT_STRING *bit_string; member
/external/python/asn1crypto/tests/
Dtest_core.py508 def bit_string(self, native, der_bytes): member in CoreTests