本文整理汇总了Java中org.bouncycastle.crypto.digests.SkeinDigest类的典型用法代码示例。如果您正苦于以下问题:Java SkeinDigest类的具体用法?Java SkeinDigest怎么用?Java SkeinDigest使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
SkeinDigest类属于org.bouncycastle.crypto.digests包,在下文中一共展示了SkeinDigest类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: initDigesters
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
private static void initDigesters() {
digesters.put("Blake2b", Blake2bDigest.class);
digesters.put("GOST3411", GOST3411Digest.class);
digesters.put("Keccak", KeccakDigest.class);
digesters.put("MD2", MD2Digest.class);
digesters.put("MD4", MD4Digest.class);
digesters.put("MD5", MD5Digest.class);
digesters.put("RIPEMD128", RIPEMD128Digest.class);
digesters.put("RIPEMD160", RIPEMD160Digest.class);
digesters.put("RIPEMD256", RIPEMD256Digest.class);
digesters.put("RIPEMD320", RIPEMD320Digest.class);
digesters.put("SHA1", SHA1Digest.class);
digesters.put("SHA224", SHA224Digest.class);
digesters.put("SHA256", SHA256Digest.class);
digesters.put("SHA384", SHA384Digest.class);
digesters.put("SHA3-512", SHA3Digest.class);
digesters.put("SHA3-256", SHA3Digest.class);
digesters.put("SHA3-224", SHA3Digest.class);
digesters.put("SHA3-384", SHA3Digest.class);
digesters.put("SHA512", SHA512Digest.class);
digesters.put("SHAKE-128", SHAKEDigest.class);
digesters.put("SHAKE-256", SHAKEDigest.class);
digesters.put("Skein256", SkeinDigest.class);
digesters.put("Skein512", SkeinDigest.class);
digesters.put("Skein1024", SkeinDigest.class);
digesters.put("SM3", SM3Digest.class);
digesters.put("Tiger", TigerDigest.class);
digesters.put("Whirlpool", WhirlpoolDigest.class);
}
开发者ID:shilongdai,项目名称:vsDiaryWriter,代码行数:30,代码来源:Digesters.java
示例2: clone
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public Object clone()
throws CloneNotSupportedException
{
BCMessageDigest d = (BCMessageDigest)super.clone();
d.digest = new SkeinDigest((SkeinDigest)digest);
return d;
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:9,代码来源:Skein.java
示例3: runTest
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
private void runTest(Case dc)
{
SkeinDigest digest = new SkeinDigest(dc.getBlockSize(), dc.getOutputSize());
byte[] message = dc.getMessage();
digest.update(message, 0, message.length);
byte[] output = new byte[digest.getDigestSize()];
digest.doFinal(output, 0);
if (!Arrays.areEqual(output, dc.getDigest()))
{
fail(digest.getAlgorithmName() + " message mismatch.\n Message " + new String(Hex.encode(dc.getMessage())),
new String(Hex.encode(dc.getDigest())), new String(Hex.encode(output)));
}
// Clone test
digest.update(message, 0, message.length / 2);
// clone the Digest
Digest d = new SkeinDigest(digest);
digest.update(message, message.length / 2, message.length - message.length / 2);
digest.doFinal(output, 0);
if (!areEqual(dc.getDigest(), output))
{
fail("failing clone vector test", new String(Hex.encode(dc.getDigest())), new String(Hex.encode(output)));
}
d.update(message, message.length / 2, message.length - message.length / 2);
d.doFinal(output, 0);
if (!areEqual(dc.getDigest(), output))
{
fail("failing second clone vector test", new String(Hex.encode(dc.getDigest())), new String(Hex.encode(output)));
}
//
// memo test
//
Memoable m = (Memoable)digest;
digest.update(message, 0, message.length / 2);
// copy the Digest
Memoable copy1 = m.copy();
Memoable copy2 = copy1.copy();
digest.update(message, message.length / 2, message.length - message.length / 2);
digest.doFinal(output, 0);
if (!areEqual(dc.getDigest(), output))
{
fail("failing memo vector test", new String(Hex.encode(dc.getDigest())), new String(Hex.encode(output)));
}
m.reset(copy1);
digest.update(message, message.length / 2, message.length - message.length / 2);
digest.doFinal(output, 0);
if (!areEqual(dc.getDigest(), output))
{
fail("failing memo reset vector test", new String(Hex.encode(dc.getDigest())), new String(Hex.encode(output)));
}
Digest md = (Digest)copy2;
md.update(message, message.length / 2, message.length - message.length / 2);
md.doFinal(output, 0);
if (!areEqual(dc.getDigest(), output))
{
fail("failing memo copy vector test", new String(Hex.encode(dc.getDigest())), new String(Hex.encode(output)));
}
}
开发者ID:ttt43ttt,项目名称:gwt-crypto,代码行数:78,代码来源:SkeinDigestTest.java
示例4: DigestSkein256
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public DigestSkein256(int outputSize)
{
super(new SkeinDigest(SkeinDigest.SKEIN_256, outputSize));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例5: DigestSkein512
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public DigestSkein512(int outputSize)
{
super(new SkeinDigest(SkeinDigest.SKEIN_512, outputSize));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例6: DigestSkein1024
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public DigestSkein1024(int outputSize)
{
super(new SkeinDigest(SkeinDigest.SKEIN_1024, outputSize));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例7: HashMac_256_128
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public HashMac_256_128()
{
super(new HMac(new SkeinDigest(SkeinDigest.SKEIN_256, 128)));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例8: HashMac_256_160
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public HashMac_256_160()
{
super(new HMac(new SkeinDigest(SkeinDigest.SKEIN_256, 160)));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例9: HashMac_256_224
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public HashMac_256_224()
{
super(new HMac(new SkeinDigest(SkeinDigest.SKEIN_256, 224)));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例10: HashMac_256_256
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public HashMac_256_256()
{
super(new HMac(new SkeinDigest(SkeinDigest.SKEIN_256, 256)));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例11: HashMac_512_128
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public HashMac_512_128()
{
super(new HMac(new SkeinDigest(SkeinDigest.SKEIN_512, 128)));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例12: HashMac_512_160
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public HashMac_512_160()
{
super(new HMac(new SkeinDigest(SkeinDigest.SKEIN_512, 160)));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例13: HashMac_512_224
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public HashMac_512_224()
{
super(new HMac(new SkeinDigest(SkeinDigest.SKEIN_512, 224)));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例14: HashMac_512_256
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public HashMac_512_256()
{
super(new HMac(new SkeinDigest(SkeinDigest.SKEIN_512, 256)));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例15: HashMac_512_384
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public HashMac_512_384()
{
super(new HMac(new SkeinDigest(SkeinDigest.SKEIN_512, 384)));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例16: HashMac_512_512
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public HashMac_512_512()
{
super(new HMac(new SkeinDigest(SkeinDigest.SKEIN_512, 512)));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例17: HashMac_1024_384
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public HashMac_1024_384()
{
super(new HMac(new SkeinDigest(SkeinDigest.SKEIN_1024, 384)));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例18: HashMac_1024_512
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public HashMac_1024_512()
{
super(new HMac(new SkeinDigest(SkeinDigest.SKEIN_1024, 512)));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例19: HashMac_1024_1024
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public HashMac_1024_1024()
{
super(new HMac(new SkeinDigest(SkeinDigest.SKEIN_1024, 1024)));
}
开发者ID:thedrummeraki,项目名称:Aki-SSL,代码行数:5,代码来源:Skein.java
示例20: register
import org.bouncycastle.crypto.digests.SkeinDigest; //导入依赖的package包/类
public static final void register(final Map<String, Hasher> hashers) {
hashers.put(BouncyCastleHasher.GOST,
new BouncyCastleHasher(new GOST3411Digest()));
hashers.put(BouncyCastleHasher.MD2,
new BouncyCastleHasher(new MD2Digest()));
hashers.put(BouncyCastleHasher.MD4,
new BouncyCastleHasher(new MD4Digest()));
hashers.put(BouncyCastleHasher.MD5,
new BouncyCastleHasher(new MD5Digest()));
hashers.put(BouncyCastleHasher.RIPEMD128,
new BouncyCastleHasher(new RIPEMD128Digest()));
hashers.put(BouncyCastleHasher.RIPEMD160,
new BouncyCastleHasher(new RIPEMD160Digest()));
hashers.put(BouncyCastleHasher.RIPEMD256,
new BouncyCastleHasher(new RIPEMD256Digest()));
hashers.put(BouncyCastleHasher.RIPEMD320,
new BouncyCastleHasher(new RIPEMD320Digest()));
hashers.put(BouncyCastleHasher.SHA1,
new BouncyCastleHasher(new SHA1Digest()));
hashers.put(BouncyCastleHasher.SHA224,
new BouncyCastleHasher(new SHA224Digest()));
hashers.put(BouncyCastleHasher.SHA256,
new BouncyCastleHasher(new SHA256Digest()));
hashers.put(BouncyCastleHasher.SHA3,
new BouncyCastleHasher(new SHA3Digest()));
hashers.put(BouncyCastleHasher.SHA384,
new BouncyCastleHasher(new SHA384Digest()));
hashers.put(BouncyCastleHasher.SHA512,
new BouncyCastleHasher(new SHA512Digest()));
hashers.put(BouncyCastleHasher.SHA512_T,
new BouncyCastleHasher(new SHA512tDigest(7 * 8)));
hashers.put(BouncyCastleHasher.SKEIN1024, new BouncyCastleHasher(
new SkeinDigest(SkeinDigest.SKEIN_1024, Long.BYTES * 8)));
hashers.put(BouncyCastleHasher.SKEIN256, new BouncyCastleHasher(
new SkeinDigest(SkeinDigest.SKEIN_256, Long.BYTES * 8)));
hashers.put(BouncyCastleHasher.SKEIN512, new BouncyCastleHasher(
new SkeinDigest(SkeinDigest.SKEIN_512, Long.BYTES * 8)));
hashers.put(BouncyCastleHasher.SM3,
new BouncyCastleHasher(new SM3Digest()));
hashers.put(BouncyCastleHasher.TIGER,
new BouncyCastleHasher(new TigerDigest()));
hashers.put(BouncyCastleHasher.WHIRLPOOL2,
new BouncyCastleHasher(new WhirlpoolDigest()));
}
开发者ID:benalexau,项目名称:hash-bench,代码行数:45,代码来源:BouncyCastleHasher.java
注:本文中的org.bouncycastle.crypto.digests.SkeinDigest类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论