Home
last modified time | relevance | path

Searched refs:md (Results 1 – 15 of 15) sorted by relevance

/libcore/luni/src/test/java/org/apache/harmony/security/tests/java/security/
DMessageDigest1Test.java40 MyMessageDigest1 md = new MyMessageDigest1("ABC"); in test_reset() local
41 md.reset(); in test_reset()
42 assertTrue(md.runEngineReset); in test_reset()
49 MyMessageDigest1 md = new MyMessageDigest1("ABC"); in test_updateLB() local
50 md.update((byte) 1); in test_updateLB()
51 assertTrue(md.runEngineUpdate1); in test_updateLB()
58 MyMessageDigest1 md = new MyMessageDigest1("ABC"); in test_updateLB$LILI() local
60 md.update(bytes, 1, 2); in test_updateLB$LILI()
61 assertTrue(md.runEngineUpdate2); in test_updateLB$LILI()
66 md.update(null, 0, 1); in test_updateLB$LILI()
[all …]
DMessageDigestSpiTest.java71 MyMessageDigest md = new MyMessageDigest() { in test_engineDigestLB$LILI() local
85 md.engineDigest(null, 1, DIGEST_LENGTH); in test_engineDigestLB$LILI()
91 md.engineDigest(b, 1, DIGEST_LENGTH - 1); in test_engineDigestLB$LILI()
98 md.engineDigest(b, b.length + 1, b.length); in test_engineDigestLB$LILI()
105 md.engineDigest(b, -1, b.length); in test_engineDigestLB$LILI()
113 assertEquals("incorrect result", DIGEST_LENGTH, md in test_engineDigestLB$LILI()
117 md = new MyMessageDigest(); in test_engineDigestLB$LILI()
119 md.engineDigest(b, 0, 1); in test_engineDigestLB$LILI()
130 MyMessageDigest md = new MyMessageDigest(); in test_engineGetDigestLength() local
131 assertEquals(0, md.engineGetDigestLength()); in test_engineGetDigestLength()
[all …]
DDigestInputStreamTest.java83 MessageDigest md = MessageDigest.getInstance(algorithmName[i]); in testDigestInputStream01() local
85 InputStream dis = new DigestInputStream(is, md); in testDigestInputStream01()
116 MessageDigest md = MessageDigest.getInstance(algorithmName[ii]); in testRead01() local
118 DigestInputStream dis = new DigestInputStream(is, md); in testRead01()
149 MessageDigest md = MessageDigest.getInstance(algorithmName[ii]); in testRead02() local
151 DigestInputStream dis = new DigestInputStream(is, md); in testRead02()
184 MessageDigest md = MessageDigest.getInstance(algorithmName[ii]); in testRead03() local
186 DigestInputStream dis = new DigestInputStream(is, md); in testRead03()
216 MessageDigest md = MessageDigest.getInstance(algorithmName[ii]); in testRead04() local
217 DigestInputStream dis = new DigestInputStream(null, md); in testRead04()
[all …]
DDigestOutputStreamTest.java79 MessageDigest md = new MyMessageDigest1(); in test_CtorLjava_io_OutputStreamLjava_security_MessageDigest() local
82 MyDigestOutputStream dos = new MyDigestOutputStream(out, md); in test_CtorLjava_io_OutputStreamLjava_security_MessageDigest()
84 assertSame(md, dos.myMessageDigest()); in test_CtorLjava_io_OutputStreamLjava_security_MessageDigest()
91 dos = new MyDigestOutputStream(null, md); in test_CtorLjava_io_OutputStreamLjava_security_MessageDigest()
147 MessageDigest md = MessageDigest.getInstance(algorithmName[k]); in testWriteint01() local
149 DigestOutputStream dos = new DigestOutputStream(bos, md); in testWriteint01()
179 MessageDigest md = MessageDigest.getInstance(algorithmName[k]); in testWriteint02() local
181 DigestOutputStream dos = new DigestOutputStream(bos, md); in testWriteint02()
213 MessageDigest md = MessageDigest.getInstance(algorithmName[k]); in testWriteint03() local
214 DigestOutputStream dos = new DigestOutputStream(null, md); in testWriteint03()
[all …]
DMessageDigest2Test.java68 MessageDigestStub md = new MessageDigestStub(algorithm); in test_constructor() local
69 assertEquals(algorithm, md.getAlgorithm()); in test_constructor()
70 assertEquals(0, md.getDigestLength()); in test_constructor()
71 assertNull(md.getProvider()); in test_constructor()
289 MessageDigest md = MessageDigest.getInstance(algorithm, e.getKey().getName()); in test_getAlgorithm() local
290 assertEquals(algorithm, md.getAlgorithm()); in test_getAlgorithm()
301 MessageDigest md = MessageDigest.getInstance(algorithm, e.getKey().getName()); in test_getDigestLength() local
302 assertTrue("length not ok", md.getDigestLength() > 0); in test_getDigestLength()
313 MessageDigest md = MessageDigest.getInstance(algorithm); in test_getInstanceLjava_lang_String() local
314 assertNotNull(md); in test_getInstanceLjava_lang_String()
[all …]
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/javax/security/auth/
DDestroyableTest.java37 myDestroyable md = new myDestroyable(); in test_destroy() local
39 assertFalse(md.isDestroyed()); in test_destroy()
40 md.destroy(); in test_destroy()
41 assertTrue(md.isDestroyed()); in test_destroy()
/libcore/luni/src/test/java/libcore/java/security/
DMessageDigestTest.java210 private void test_MessageDigest(MessageDigest md) throws Exception { in test_MessageDigest() argument
211 String algorithm = md.getAlgorithm(); in test_MessageDigest()
217 actual = md.digest(); in test_MessageDigest()
221 md.update(mb); in test_MessageDigest()
223 actual = md.digest(); in test_MessageDigest()
228 assertEquals(algorithm, expected.length, md.getDigestLength()); in test_MessageDigest()
253 final MessageDigest md = MessageDigest.getInstance("SHA-256"); in testMessageDigest_MultipleThreads_Misuse() local
265 md.update(message); in testMessageDigest_MultipleThreads_Misuse()
266 md.digest(); in testMessageDigest_MultipleThreads_Misuse()
/libcore/luni/src/main/java/org/apache/harmony/security/utils/
DJarUtils.java207 MessageDigest md = null; in verifySignature() local
209 md = MessageDigest.getInstance(daOid); in verifySignature()
211 if (md == null && daName != null) { in verifySignature()
212 md = MessageDigest.getInstance(daName); in verifySignature()
214 if (md == null) { in verifySignature()
218 byte[] computedDigest = md.digest(sfBytes); in verifySignature()
/libcore/luni/src/main/java/java/util/jar/
DJarVerifier.java378 MessageDigest md; in verify() local
380 md = MessageDigest.getInstance(algorithm); in verify()
385 md.update(data, start, end - 1 - start); in verify()
387 md.update(data, start, end - start); in verify()
389 byte[] b = md.digest(); in verify()
/libcore/luni/src/main/java/java/util/
DUUID.java148 MessageDigest md = MessageDigest.getInstance("MD5"); in nameUUIDFromBytes() local
149 return makeUuid(md.digest(name), 3); in nameUUIDFromBytes()
/libcore/luni/src/main/java/java/security/
DMessageDigest.java348 MessageDigest md = (MessageDigest) clone(); in getDigestLength() local
349 return md.digest().length; in getDigestLength()
/libcore/luni/src/test/java/libcore/java/sql/
DOldConnectionTest.java242 DatabaseMetaData md = conn.getMetaData(); in testGetMetaData() local
243 Connection con = md.getConnection(); in testGetMetaData()
/libcore/support/src/test/java/tests/resources/x509/
Ddefault.cnf113 default_md = sha1 # which md to use.
/libcore/luni/src/main/java/java/util/concurrent/
DForkJoinPool.java854 int md = mode; in runTask() local
857 if (md != 0) in runTask()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/
DFormatterTest.java705 MockDestination md = new MockDestination(); in test_ioException() local
706 f = new Formatter(md); in test_ioException()