HomeSort by relevance Sort by last modified time
    Searched refs:bitLength (Results 1 - 25 of 185) sorted by null

1 2 3 4 5 6 7 8

  /external/bouncycastle/bcprov/src/main/java/org/bouncycastle/math/field/
FiniteFields.java 34 int bitLength = characteristic.bitLength();
35 if (characteristic.signum() <= 0 || bitLength < 2)
40 if (bitLength < 3)
  /external/bouncycastle/bcprov/src/main/java/org/bouncycastle/util/
BigIntegers.java 93 if (min.bitLength() > max.bitLength() / 2)
100 BigInteger x = createRandomBigInteger(max.bitLength(), random);
108 return createRandomBigInteger(max.subtract(min).bitLength() - 1, random).add(min);
129 return (n.bitLength() + 7) / 8;
133 * Return a positive BigInteger in the range of 0 to 2**bitLength - 1.
135 * @param bitLength maximum bit length for the generated BigInteger.
139 public static BigInteger createRandomBigInteger(int bitLength, SecureRandom random)
141 return new BigInteger(1, createRandom(bitLength, random));
147 * @param bitLength bit length for the generated BigInteger
    [all...]
Fingerprint.java 34 * Constructor with length - use SHAKE-256 (bitLength bits). This is the recommended one as it is also
39 public Fingerprint(byte[] source, int bitLength)
41 this.fingerprint = calculateFingerprint(source, bitLength);
125 * @param bitLength bit length of finger print to be produced.
128 public static byte[] calculateFingerprint(byte[] input, int bitLength)
130 if (bitLength % 8 != 0)
132 throw new IllegalArgumentException("bitLength must be a multiple of 8");
141 byte[] rv = new byte[bitLength / 8];
145 // digest.doFinal(rv, 0, bitLength / 8);
148 if ((bitLength / 8) >= 32)
    [all...]
  /external/bouncycastle/repackaged/bcprov/src/main/java/com/android/org/bouncycastle/math/field/
FiniteFields.java 38 int bitLength = characteristic.bitLength();
39 if (characteristic.signum() <= 0 || bitLength < 2)
44 if (bitLength < 3)
  /external/bouncycastle/repackaged/bcprov/src/main/java/com/android/org/bouncycastle/util/
BigIntegers.java 95 if (min.bitLength() > max.bitLength() / 2)
102 BigInteger x = createRandomBigInteger(max.bitLength(), random);
110 return createRandomBigInteger(max.subtract(min).bitLength() - 1, random).add(min);
131 return (n.bitLength() + 7) / 8;
135 * Return a positive BigInteger in the range of 0 to 2**bitLength - 1.
137 * @param bitLength maximum bit length for the generated BigInteger.
141 public static BigInteger createRandomBigInteger(int bitLength, SecureRandom random)
143 return new BigInteger(1, createRandom(bitLength, random));
149 * @param bitLength bit length for the generated BigInteger
    [all...]
Fingerprint.java 36 * Constructor with length - use SHAKE-256 (bitLength bits). This is the recommended one as it is also
41 public Fingerprint(byte[] source, int bitLength)
43 this.fingerprint = calculateFingerprint(source, bitLength);
127 * @param bitLength bit length of finger print to be produced.
130 public static byte[] calculateFingerprint(byte[] input, int bitLength)
132 if (bitLength % 8 != 0)
134 throw new IllegalArgumentException("bitLength must be a multiple of 8");
143 byte[] rv = new byte[bitLength / 8];
147 // digest.doFinal(rv, 0, bitLength / 8);
150 if ((bitLength / 8) >= 32)
    [all...]
  /art/test/175-alloc-big-bignums/src/
Main.java 30 if (huge.bitLength() != 4_000_001) {
31 System.out.println("Wrong answer length: " + huge.bitLength());
  /external/bouncycastle/bcprov/src/main/java/org/bouncycastle/crypto/params/
DSAKeyGenerationParameters.java 16 super(random, params.getP().bitLength() - 1);
ECKeyGenerationParameters.java 16 super(random, domainParams.getN().bitLength());
DHKeyGenerationParameters.java 28 return params.getL() != 0 ? params.getL() : params.getP().bitLength();
  /external/apache-commons-compress/src/main/java/org/apache/commons/compress/archivers/zip/
BinaryTree.java 128 final int bitLength = (b & 0x0F) + 1;
131 originalBitLengths[pos++] = bitLength;
134 maxLength = Math.max(maxLength, bitLength);
181 final int bitLength = originalBitLengths[k];
182 if (bitLength > 0) {
183 tree.addLeaf(0, Integer.reverse(codes[k] << 16), bitLength, k);
  /external/bouncycastle/repackaged/bcprov/src/main/java/com/android/org/bouncycastle/crypto/params/
DSAKeyGenerationParameters.java 20 super(random, params.getP().bitLength() - 1);
ECKeyGenerationParameters.java 20 super(random, domainParams.getN().bitLength());
DHKeyGenerationParameters.java 32 return params.getL() != 0 ? params.getL() : params.getP().bitLength();
  /external/bouncycastle/bcprov/src/main/java/org/bouncycastle/crypto/digests/
GeneralDigest.java 115 long bitLength = (byteCount << 3);
127 processLength(bitLength);
157 protected abstract void processLength(long bitLength);
  /external/bouncycastle/repackaged/bcprov/src/main/java/com/android/org/bouncycastle/crypto/digests/
GeneralDigest.java 117 long bitLength = (byteCount << 3);
129 processLength(bitLength);
159 protected abstract void processLength(long bitLength);
  /external/conscrypt/common/src/main/java/org/conscrypt/
ChainStrengthAnalyzer.java 78 int modulusLength = ((RSAPublicKey) pubkey).getModulus().bitLength();
91 int pLength = ((DSAPublicKey) pubkey).getParams().getP().bitLength();
92 int qLength = ((DSAPublicKey) pubkey).getParams().getQ().bitLength();
  /external/conscrypt/repackaged/common/src/main/java/com/android/org/conscrypt/
ChainStrengthAnalyzer.java 80 int modulusLength = ((RSAPublicKey) pubkey).getModulus().bitLength();
93 int pLength = ((DSAPublicKey) pubkey).getParams().getP().bitLength();
94 int qLength = ((DSAPublicKey) pubkey).getParams().getQ().bitLength();
  /external/bouncycastle/bcprov/src/main/java/org/bouncycastle/math/ec/
WNafUtil.java 17 if ((k.bitLength() >>> 16) != 0)
19 throw new IllegalArgumentException("'k' must have bitlength < 2^16");
28 int bits = _3k.bitLength();
69 if ((k.bitLength() >>> 16) != 0)
71 throw new IllegalArgumentException("'k' must have bitlength < 2^16");
78 int[] wnaf = new int[k.bitLength() / width + 1];
88 while (pos <= k.bitLength())
126 int digits = Math.max(g.bitLength(), h.bitLength()) + 1;
133 while ((d0 | d1) != 0 || k0.bitLength() > offset || k1.bitLength() > offset
    [all...]
  /external/bouncycastle/repackaged/bcprov/src/main/java/com/android/org/bouncycastle/math/ec/
WNafUtil.java 21 if ((k.bitLength() >>> 16) != 0)
23 throw new IllegalArgumentException("'k' must have bitlength < 2^16");
32 int bits = _3k.bitLength();
73 if ((k.bitLength() >>> 16) != 0)
75 throw new IllegalArgumentException("'k' must have bitlength < 2^16");
82 int[] wnaf = new int[k.bitLength() / width + 1];
92 while (pos <= k.bitLength())
130 int digits = Math.max(g.bitLength(), h.bitLength()) + 1;
137 while ((d0 | d1) != 0 || k0.bitLength() > offset || k1.bitLength() > offset
    [all...]
  /external/python/pyasn1/pyasn1/compat/
integer.py 39 bits = bitLength(value)
84 def bitLength(number):
109 def bitLength(number):
  /external/bouncycastle/bcprov/src/main/java/org/bouncycastle/crypto/signers/
RandomDSAKCalculator.java 34 int qBitLength = q.bitLength();
  /external/bouncycastle/repackaged/bcprov/src/main/java/com/android/org/bouncycastle/crypto/signers/
RandomDSAKCalculator.java 38 int qBitLength = q.bitLength();
  /external/wycheproof/java/com/google/security/wycheproof/testcases/
RsaKeyTest.java     [all...]
  /external/bouncycastle/bcprov/src/main/java/org/bouncycastle/crypto/generators/
RSAKeyPairGenerator.java 74 if (diff.bitLength() < mindiffbits || diff.compareTo(minDiff) <= 0)
84 if (n.bitLength() != strength)
155 * @param bitlength the bit-length of the returned prime
159 protected BigInteger chooseRandomPrime(int bitlength, BigInteger e, BigInteger sqrdBound)
161 for (int i = 0; i != 5 * bitlength; i++)
163 BigInteger p = BigIntegers.createRandomPrime(bitlength, 1, param.getRandom());
193 int iterations = getNumberOfIterations(x.bitLength(), param.getCertainty());

Completed in 481 milliseconds

1 2 3 4 5 6 7 8