Package nl.warper.threefish

Examples of nl.warper.threefish.ThreefishSecretKey


    final int nb = blockCipher.getBlockSize() / Long.SIZE;
    hi = new long[nb]; // set H{0} to all zero's
  }
 
  public void update(long[] mi, long[] ti) {
    blockCipher.init(new ThreefishSecretKey(hi), ti);
    blockCipher.blockEncrypt(mi, hi);
    for ( int i = 0; i < hi.length; i++ ) {
      hi[i] ^= mi[i];
    }
  }
View Full Code Here


      tweak = new long[] { rnd.nextLong(), rnd.nextLong() };
    } catch (GeneralSecurityException e) {
      throw new RuntimeException(e);
    }

    ThreefishSecretKey sk = new ThreefishSecretKey(keyData);

    impl.init(sk, tweak);
    final byte[] plain = "Maarten".getBytes();
    final byte[] plainPadded = zeroPad(plain, impl.getBlockSize());
View Full Code Here

TOP

Related Classes of nl.warper.threefish.ThreefishSecretKey

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.