/libcore/ojluni/src/main/java/javax/net/ssl/ |
D | SNIServerName.java | 53 private final byte[] encoded; field in SNIServerName 74 protected SNIServerName(int type, byte[] encoded) { in SNIServerName() argument 84 if (encoded == null) { in SNIServerName() 88 this.encoded = encoded.clone(); in SNIServerName() 107 return encoded.clone(); in getEncoded() 129 Arrays.equals(this.encoded, that.encoded); in equals() 144 result = 31 * result + Arrays.hashCode(encoded); in hashCode() 184 return "type=host_name (0), value=" + toHexString(encoded); in toString() 186 return "type=(" + type + "), value=" + toHexString(encoded); in toString()
|
D | SNIHostName.java | 162 public SNIHostName(byte[] encoded) { in SNIHostName() argument 164 super(StandardConstants.SNI_HOST_NAME, encoded); in SNIHostName() 176 decoder.decode(ByteBuffer.wrap(encoded)).toString()); in SNIHostName()
|
/libcore/ojluni/src/main/java/javax/crypto/ |
D | EncryptedPrivateKeyInfo.java | 67 private byte[] encoded = null; field in EncryptedPrivateKeyInfo 77 public EncryptedPrivateKeyInfo(byte[] encoded) in EncryptedPrivateKeyInfo() argument 79 if (encoded == null) { in EncryptedPrivateKeyInfo() 83 this.encoded = encoded.clone(); in EncryptedPrivateKeyInfo() 84 DerValue val = new DerValue(this.encoded); in EncryptedPrivateKeyInfo() 150 this.encoded = null; in EncryptedPrivateKeyInfo() 191 this.encoded = null; in EncryptedPrivateKeyInfo() 248 byte[] encoded = null; in getKeySpec() 250 encoded = cipher.doFinal(encryptedData); in getKeySpec() 251 checkPKCS8Encoding(encoded); in getKeySpec() [all …]
|
/libcore/luni/src/main/java/libcore/util/ |
D | HexEncoding.java | 112 public static byte[] decode(String encoded) throws IllegalArgumentException { in decode() argument 113 return decode(encoded.toCharArray()); in decode() 124 public static byte[] decode(String encoded, boolean allowSingleChar) in decode() argument 126 return decode(encoded.toCharArray(), allowSingleChar); in decode() 136 public static byte[] decode(char[] encoded) throws IllegalArgumentException { in decode() argument 137 return decode(encoded, false); in decode() 148 public static byte[] decode(char[] encoded, boolean allowSingleChar) in decode() argument 150 int encodedLength = encoded.length; in decode() 160 result[resultOffset++] = (byte) toDigit(encoded, i); in decode() 170 result[resultOffset++] = (byte) ((toDigit(encoded, i) << 4) | toDigit(encoded, i + 1)); in decode()
|
/libcore/support/src/test/java/org/apache/harmony/security/tests/support/ |
D | KeyStoreTestSupport.java | 66 private byte[] encoded; field in KeyStoreTestSupport.SKey 68 public SKey(String type, byte[] encoded) { in SKey() argument 70 this.encoded = encoded; in SKey() 78 return encoded; in getEncoded() 94 private byte[] encoded; field in KeyStoreTestSupport.MyPrivateKey 96 public MyPrivateKey(String algorithm, String format, byte[] encoded) { in MyPrivateKey() argument 99 this.encoded = encoded; in MyPrivateKey() 111 return encoded; in getEncoded()
|
D | PublicKeyStub.java | 40 byte [] encoded = null; field in PublicKeyStub 45 public PublicKeyStub(String algorithm, String format, byte[] encoded) { in PublicKeyStub() argument 48 this.encoded = encoded; in PublicKeyStub() 71 return encoded; in getEncoded()
|
D | PrivateKeyStub.java | 37 byte [] encoded = null; field in PrivateKeyStub 47 public PrivateKeyStub(String algorithm, String format, byte[] encoded) { in PrivateKeyStub() argument 50 this.encoded = encoded; in PrivateKeyStub() 74 return encoded; in getEncoded()
|
D | MyKeyPairGenerator1.java | 99 private byte[] encoded; field in MyKeyPairGenerator1.PubKey 104 this.encoded = new byte[10]; in PubKey() 116 return encoded; in getEncoded() 125 private byte[] encoded; field in MyKeyPairGenerator1.PrivKey 130 this.encoded = new byte[10]; in PrivKey() 142 return encoded; in getEncoded()
|
D | TestCertUtils.java | 151 private static final byte[] encoded = new byte[] { 1, 2, 3, 4, 5, 6, 7, field in TestCertUtils.TestCertPath 192 return encoded.clone(); in getEncoded() 200 return encoded.clone(); in getEncoded() 280 private static final byte[] encoded = new byte[] { 1, 2, 3, 4, 5, 6, 7, field in TestCertUtils.TestPublicKey 290 return encoded.clone(); in getEncoded() 306 private static final byte[] encoded = new byte[] { 1, 2, 3, 4, 5, 6, 7, field in TestCertUtils.TestCertificate 346 return encoded.clone(); in getEncoded()
|
/libcore/ojluni/src/main/java/java/security/ |
D | KeyRep.java | 110 private byte[] encoded; field in KeyRep 132 String format, byte[] encoded) { in KeyRep() argument 135 format == null || encoded == null) { in KeyRep() 142 this.encoded = encoded.clone(); in KeyRep() 172 return new SecretKeySpec(encoded, algorithm); in readResolve() 175 return f.generatePublic(new X509EncodedKeySpec(encoded)); in readResolve() 178 return f.generatePrivate(new PKCS8EncodedKeySpec(encoded)); in readResolve()
|
D | PKCS12Attribute.java | 47 private byte[] encoded; field in PKCS12Attribute 96 this.encoded = encode(type, values); in PKCS12Attribute() 124 public PKCS12Attribute(byte[] encoded) { in PKCS12Attribute() argument 125 if (encoded == null) { in PKCS12Attribute() 128 this.encoded = encoded.clone(); in PKCS12Attribute() 131 parse(encoded); in PKCS12Attribute() 181 return encoded.clone(); in getEncoded() 201 return Arrays.equals(encoded, ((PKCS12Attribute) obj).getEncoded()); in equals() 213 Arrays.hashCode(encoded); in hashCode() 252 private void parse(byte[] encoded) throws IOException { in parse() argument [all …]
|
/libcore/ojluni/src/main/java/sun/security/provider/certpath/ |
D | X509CertificatePair.java | 80 private byte[] encoded; field in X509CertificatePair 118 private X509CertificatePair(byte[] encoded) throws CertificateException { in X509CertificatePair() argument 120 parse(new DerValue(encoded)); in X509CertificatePair() 121 this.encoded = encoded; in X509CertificatePair() 140 (byte[] encoded) throws CertificateException { in generateCertificatePair() argument 141 Object key = new Cache.EqualByteArray(encoded); in generateCertificatePair() 146 pair = new X509CertificatePair(encoded); in generateCertificatePair() 147 key = new Cache.EqualByteArray(pair.encoded); in generateCertificatePair() 194 if (encoded == null) { in getEncoded() 197 encoded = tmp.toByteArray(); in getEncoded() [all …]
|
/libcore/luni/src/test/java/org/apache/harmony/security/tests/java/security/ |
D | KeyFactoryTest.java | 193 assertTrue(Arrays.equals(key.encoded, publicKey.getEncoded())); in testGeneratePublic() 435 return new TestPrivateKey(((TestPrivateKeySpec)keySpec).encoded); in engineGeneratePrivate() 445 return new TestPublicKey(((TestPublicKeySpec)keySpec).encoded); in engineGeneratePublic() 508 private final byte[] encoded; field in KeyFactoryTest.TestPrivateKeySpec 511 this.encoded = key.getEncoded(); in TestPrivateKeySpec() 517 private final byte[] encoded; field in KeyFactoryTest.TestPublicKeySpec 520 this.encoded = key.getEncoded(); in TestPublicKeySpec() 526 private final byte[] encoded; field in KeyFactoryTest.TestPrivateKey 529 encoded = new byte[] {3, 4, 5}; in TestPrivateKey() 532 public TestPrivateKey(byte[] encoded) { in TestPrivateKey() argument [all …]
|
/libcore/luni/src/test/java/libcore/java/net/ |
D | UrlEncodingTest.java | 258 private void assertEncoded(String encoded, String original) throws Exception { in assertEncoded() argument 259 assertEquals(encoded, URLEncoder.encode(original, "UTF-8")); in assertEncoded() 260 assertEquals(encoded, URLEncoder.encode(original)); in assertEncoded() 261 assertEquals(encoded, new URI("http", "foo", "/", original).getRawFragment()); in assertEncoded() 264 private void assertRoundTrip(String original, String encoded) throws Exception { in assertRoundTrip() argument 265 assertEquals(encoded, URLEncoder.encode(original, "UTF-8")); in assertRoundTrip() 266 assertEquals(original, URLDecoder.decode(encoded, "UTF-8")); in assertRoundTrip()
|
/libcore/luni/src/test/java/tests/security/spec/ |
D | EncodedKeySpec2Test.java | 49 byte[] encoded = keys.getPublic().getEncoded(); in test_getEncoded() 50 Key key = fact.generatePublic(new X509EncodedKeySpec(encoded)); in test_getEncoded() 56 encoded = keys.getPrivate().getEncoded(); in test_getEncoded() 57 key = fact.generatePrivate(new PKCS8EncodedKeySpec(encoded)); in test_getEncoded()
|
/libcore/luni/src/test/java/org/apache/harmony/crypto/tests/javax/crypto/func/ |
D | CipherThread.java | 50 public void checkEncodedData(byte[] original, byte[] encoded) in checkEncodedData() argument 53 if (original[i] != encoded[i]) { in checkEncodedData() 60 public void checkPaddedEncodedData(byte[] original, byte[] encoded, int offset) in checkPaddedEncodedData() argument 63 if (encoded[i] != 0) { in checkPaddedEncodedData() 68 if (original[i] != encoded[i + offset]) { in checkPaddedEncodedData()
|
/libcore/luni/src/test/java/libcore/java/security/spec/ |
D | AlgorithmParametersPSSTest.java | 106 byte[] encoded, PSSParameterSpec expected) throws Exception { in assertInitWithDerEncoded() argument 108 params.init(encoded); in assertInitWithDerEncoded() 112 params.init(encoded, "ASN.1"); in assertInitWithDerEncoded() 136 byte[] encoded = params.getEncoded("ASN.1"); in assertGetEncoded() 137 assertTrue(Arrays.equals(expectedEncoded, encoded)); in assertGetEncoded() 139 assertTrue(Arrays.equals(encoded, params.getEncoded())); in assertGetEncoded()
|
/libcore/ojluni/annotations/hiddenapi/sun/security/provider/certpath/ |
D | X509CertificatePair.java | 42 private X509CertificatePair(byte[] encoded) throws java.security.cert.CertificateException { in X509CertificatePair() argument 52 generateCertificatePair(byte[] encoded) throws java.security.cert.CertificateException { in generateCertificatePair() argument 108 private byte[] encoded; field in X509CertificatePair
|
/libcore/ojluni/src/main/java/sun/security/x509/ |
D | X509Key.java | 316 byte[] encoded = encodedKey; in getEncodedInternal() 317 if (encoded == null) { in getEncodedInternal() 321 encoded = out.toByteArray(); in getEncodedInternal() 326 encodedKey = encoded; in getEncodedInternal() 328 return encoded; in getEncodedInternal()
|
/libcore/ojluni/src/main/java/java/security/cert/ |
D | PolicyQualifierInfo.java | 100 public PolicyQualifierInfo(byte[] encoded) throws IOException { in PolicyQualifierInfo() argument 101 mEncoded = encoded.clone(); in PolicyQualifierInfo()
|
D | PKIXRevocationChecker.java | 272 byte[] encoded = entry.getValue(); in clone() 273 entry.setValue(encoded.clone()); in clone()
|
/libcore/luni/src/test/java/libcore/java/util/ |
D | LibcoreIoDerivedBase64Test.java | 68 String encoded = encode(inputBytes); in assertEncodeDecode() local 69 assertEquals(expectedEncoded, encoded); in assertEncodeDecode() 73 int[] actualDecodedBytes = decodeToInts(encoded); in assertEncodeDecode() 264 private static byte[] decode(byte[] encoded) { in decode() argument 267 return decoder.decode(encoded); in decode()
|
D | Base64Test.java | 845 private static void checkRoundTrip_allBytes(Encoder encoder, Decoder decoder, String encoded) { in checkRoundTrip_allBytes() argument 850 assertRoundTrip(encoder, decoder, encoded, bytes); in checkRoundTrip_allBytes() 910 byte[] encoded = encoder.encode(plain); in checkRoundTrip_wrapInputStream() 917 ByteArrayInputStream bais = new ByteArrayInputStream(encoded); in checkRoundTrip_wrapInputStream() 926 bais = new ByteArrayInputStream(encoded); in checkRoundTrip_wrapInputStream() 935 bais = new ByteArrayInputStream(encoded); in checkRoundTrip_wrapInputStream() 1053 private static String decodeToAscii(Decoder decoder, String encoded) throws Exception { in decodeToAscii() argument 1054 byte[] plain = decoder.decode(encoded); in decodeToAscii() 1066 String encoded = encoder.encodeToString(plain.getBytes(US_ASCII)); in encodeFromAscii() local 1067 String decoded = decodeToAscii(decoder, encoded); in encodeFromAscii() [all …]
|
/libcore/ojluni/src/test/java/security/cert/ |
D | AKISerialNumberTest.java | 141 private static X509Certificate getCertFromMimeEncoding(String encoded) in getCertFromMimeEncoding() argument 144 byte[] bytes = b64Decoder.decode(encoded); in getCertFromMimeEncoding()
|
/libcore/luni/src/test/java/libcore/java/security/cert/ |
D | SubjectAlternativeNameTest.java | 67 byte[] encoded = certificate.getEncoded(); in bouncycastleToJava() 69 return (X509Certificate) factory.generateCertificate(new ByteArrayInputStream(encoded)); in bouncycastleToJava()
|