Home
last modified time | relevance | path

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

/tools/apksig/src/main/java/com/android/apksig/internal/apk/
DAndroidBinXmlParser.java672 private static String getLengthPrefixedUtf16EncodedString(ByteBuffer encoded) in getLengthPrefixedUtf16EncodedString() argument
677 int lengthChars = getUnsignedInt16(encoded); in getLengthPrefixedUtf16EncodedString()
679 lengthChars = ((lengthChars & 0x7fff) << 16) | getUnsignedInt16(encoded); in getLengthPrefixedUtf16EncodedString()
688 if (encoded.hasArray()) { in getLengthPrefixedUtf16EncodedString()
689 arr = encoded.array(); in getLengthPrefixedUtf16EncodedString()
690 arrOffset = encoded.arrayOffset() + encoded.position(); in getLengthPrefixedUtf16EncodedString()
691 encoded.position(encoded.position() + lengthBytes); in getLengthPrefixedUtf16EncodedString()
695 encoded.get(arr); in getLengthPrefixedUtf16EncodedString()
710 private static String getLengthPrefixedUtf8EncodedString(ByteBuffer encoded) in getLengthPrefixedUtf8EncodedString() argument
717 int lengthBytes = getUnsignedInt8(encoded); in getLengthPrefixedUtf8EncodedString()
[all …]
DApkSigningBlockUtils.java600 ByteBuffer encoded = createVerityDigestBuffer(true); in computeApkVerityDigest() local
606 encoded.put(rootHash); in computeApkVerityDigest()
607 encoded.putLong(beforeCentralDir.size() + centralDir.size() + eocd.size()); in computeApkVerityDigest()
608 outputContentDigests.put(VERITY_CHUNKED_SHA256, encoded.array()); in computeApkVerityDigest()
622 ByteBuffer encoded = ByteBuffer.allocate(backBufferSize); in createVerityDigestBuffer() local
623 encoded.order(ByteOrder.LITTLE_ENDIAN); in createVerityDigestBuffer()
624 return encoded; in createVerityDigestBuffer()
643 ByteBuffer encoded = createVerityDigestBuffer(false); in computeChunkVerityTreeAndDigest() local
649 encoded.put(rootHash); in computeChunkVerityTreeAndDigest()
650 return new VerityTreeAndDigest(VERITY_CHUNKED_SHA256, encoded.array(), tree.array()); in computeChunkVerityTreeAndDigest()
/tools/apksig/src/test/java/com/android/apksig/internal/util/
DHexEncoding.java61 public static byte[] decode(String encoded) { in decode() argument
63 int resultLengthBytes = (encoded.length() + 1) / 2; in decode()
67 if ((encoded.length() % 2) != 0) { in decode()
70 (byte) getHexadecimalDigitValue(encoded.charAt(encodedCharOffset)); in decode()
73 for (int len = encoded.length(); encodedCharOffset < len; encodedCharOffset += 2) { in decode()
75 ((getHexadecimalDigitValue(encoded.charAt(encodedCharOffset)) << 4) in decode()
76 | getHexadecimalDigitValue(encoded.charAt(encodedCharOffset + 1))); in decode()
DResources.java102 byte[] encoded = toByteArray(cls, resourceName); in toPrivateKey()
121 return keyFactory.generatePrivate(new PKCS8EncodedKeySpec(encoded)); in toPrivateKey()
/tools/apksig/src/test/java/com/android/apksig/internal/asn1/ber/
DBerDataValueTest.java79 ByteBuffer encoded = TEST_VALUE1.getEncoded(); in testGetEncodedReturnsSlice() local
80 assertByteBufferEquals(HexEncoding.decode("aa"), encoded); in testGetEncodedReturnsSlice()
81 encoded.position(encoded.limit()); in testGetEncodedReturnsSlice()
95 ByteBuffer encoded = TEST_VALUE1.getEncodedContents(); in testGetEncodedContentsReturnsSlice() local
96 assertByteBufferEquals(HexEncoding.decode("bb"), encoded); in testGetEncodedContentsReturnsSlice()
97 encoded.position(encoded.limit()); in testGetEncodedContentsReturnsSlice()
/tools/apksig/src/main/java/com/android/apksig/internal/asn1/
DAsn1BerParser.java60 public static <T> T parse(ByteBuffer encoded, Class<T> containerClass) in parse() argument
64 containerDataValue = new ByteBufferBerDataValueReader(encoded).readDataValue(); in parse()
96 public static <T> List<T> parseImplicitSetOf(ByteBuffer encoded, Class<T> elementClass) in parseImplicitSetOf() argument
100 containerDataValue = new ByteBufferBerDataValueReader(encoded).readDataValue(); in parseImplicitSetOf()
480 private static long decodeBase128UnsignedLong(ByteBuffer encoded) throws Asn1DecodingException { in decodeBase128UnsignedLong() argument
481 if (!encoded.hasRemaining()) { in decodeBase128UnsignedLong()
485 while (encoded.hasRemaining()) { in decodeBase128UnsignedLong()
489 int b = encoded.get() & 0xff; in decodeBase128UnsignedLong()
501 private static BigInteger integerToBigInteger(ByteBuffer encoded) { in integerToBigInteger() argument
502 if (!encoded.hasRemaining()) { in integerToBigInteger()
[all …]
DAsn1DerEncoder.java414 byte[] encoded = JavaToDerConverter.toDer(fieldValue, mDataType, mElementDataType); in toDer()
417 return encoded; in toDer()
419 return createTag(mDerTagClass, true, mDerTagNumber, encoded); in toDer()
421 int originalTagNumber = BerEncoding.getTagNumber(encoded[0]); in toDer()
429 encoded[0] = BerEncoding.setTagNumber(encoded[0], mDerTagNumber); in toDer()
430 encoded[0] = BerEncoding.setTagClass(encoded[0], mDerTagClass); in toDer()
431 return encoded; in toDer()
DAsn1OpaqueObject.java27 public Asn1OpaqueObject(ByteBuffer encoded) { in Asn1OpaqueObject() argument
28 mEncoded = encoded.slice(); in Asn1OpaqueObject()
31 public Asn1OpaqueObject(byte[] encoded) { in Asn1OpaqueObject() argument
32 mEncoded = ByteBuffer.wrap(encoded); in Asn1OpaqueObject()
/tools/apkzlib/src/test/java/com/android/tools/build/apkzlib/zip/
DEncodeUtilsTest.java43 byte[] encoded = EncodeUtils.encode(text, flags); in asciiEncodeAndDecode()
44 assertArrayEquals(new byte[] { 0x66, 0x6f, 0x6f }, encoded); in asciiEncodeAndDecode()
45 assertEquals(text, EncodeUtils.decode(encoded, flags)); in asciiEncodeAndDecode()
53 byte[] encoded = EncodeUtils.encode(kazakhCapital, flags); in utf8EncodeAndDecode()
56 (byte) 0xd0, (byte) 0xb0 }, encoded); in utf8EncodeAndDecode()
57 assertEquals(kazakhCapital, EncodeUtils.decode(encoded, flags)); in utf8EncodeAndDecode()
/tools/apksig/src/main/java/com/android/apksig/internal/asn1/ber/
DInputStreamBerDataValueReader.java88 byte[] encoded = in.getReadBytes(); in readDataValue()
90 ByteBuffer.wrap(encoded, contentsOffsetInDataValue, contentsLength); in readDataValue()
92 ByteBuffer.wrap(encoded), in readDataValue()
224 ByteBuffer encoded = dataValue.getEncoded(); in skipConstructedIndefiniteLengthContents() local
225 if ((encoded.remaining() == 2) && (encoded.get(0) == 0) && (encoded.get(1) == 0)) { in skipConstructedIndefiniteLengthContents()
DByteBufferBerDataValueReader.java75 ByteBuffer encoded = mBuf.slice(); in readDataValue() local
80 encoded.position(contentsOffsetInTag); in readDataValue()
81 encoded.limit(contentsOffsetInTag + contentsLength); in readDataValue()
82 ByteBuffer encodedContents = encoded.slice(); in readDataValue()
83 encoded.clear(); in readDataValue()
86 encoded, in readDataValue()
DBerDataValue.java32 ByteBuffer encoded, in BerDataValue() argument
37 mEncoded = encoded; in BerDataValue()
/tools/test/connectivity/acts/framework/acts/libs/proto/
Dproto_utils.py46 encoded = parse_proto_to_ascii(proto).encode()
47 return hashlib.md5(encoded).hexdigest()
/tools/apksig/src/apksigner/java/com/android/apksigner/
DPasswordRetriever.java281 byte[] encoded = new byte[pwdBytes.remaining()]; in encodePassword()
282 pwdBytes.get(encoded); in encodePassword()
283 return encoded; in encodePassword()
Dhelp_lineage.txt110 form encoded using the JVM default charset, and, on Java 8
111 and older, the form encoded using the console's charset.
Dhelp_rotate.txt116 form encoded using the JVM default charset, and, on Java 8
117 and older, the form encoded using the console's charset.
Dhelp_sign.txt203 form encoded using the JVM default charset, and, on Java 8
204 and older, the form encoded using the console's charset.
/tools/external/fat32lib/src/main/java/de/waldheinz/fs/fat/
DFatLfnDirectory.java286 FatDirectoryEntry[] encoded = currentEntry.compactForm(); in updateLFN() local
287 dest.addAll(Arrays.asList(encoded)); in updateLFN()
/tools/test/connectivity/acts/framework/acts/controllers/buds_lib/dev_utils/proto/
Dplugin.proto54 // An encoded CodeGeneratorRequest is written to the plugin's stdin.
78 // The plugin writes an encoded CodeGeneratorResponse to stdout.
/tools/metalava/src/test/java/com/android/tools/metalava/
DExtractAnnotationsTest.kt632 fun `Test generics in XML attributes are encoded`() { in Test generics in XML attributes are encoded()
/tools/test/connectivity/acts/framework/acts/controllers/buds_lib/dev_utils/proto/google/protobuf/
Ddescriptor.proto116 // Not ZigZag encoded. Negative numbers take 10 bytes. Use TYPE_SINT64 if
120 // Not ZigZag encoded. Negative numbers take 10 bytes. Use TYPE_SINT32 if
438 // writing the tag and type for each element, the entire array is encoded as
446 // inner message's contents will not be parsed but instead stored in encoded
/tools/apkzlib/src/test/resources/testData/packaging/text-files/
Drfc2460.txt97 Changes in the way IP header options are encoded allows for
289 In IPv6, optional internet-layer information is encoded in separate
459 number of type-length-value (TLV) encoded "options", of the following
480 The Option Type identifiers are internally encoded such that their
609 TLV-encoded options, as described in section
1268 or more TLV-encoded options, as described in
1286 encoded either as a separate header or as an option in the
1300 o If any other action is desired, the information must be encoded