SecureRandom    k = new SecureRandom() { public void nextBytes(byte[] bytes) { byte[] vals = new BigInteger("700000017569056646655505781757157107570501575775705779575555657156756655").toByteArray();  System.arraycopy(vals, vals.length-bytes.length, bytes, 0, bytes.length); } };
byte[] kData = BigIntegers.asUnsignedByteArray(new BigInteger("700000017569056646655505781757157107570501575775705779575555657156756655"));  SecureRandom    k = new FixedSecureRandom(kData);
    private void testECNR239bitPrime()        throws Exception    {        BigInteger r = new BigInteger("308636143175167811492623515537541734843573549327605293463169625072911693");        BigInteger s = new BigInteger("852401710738814635664888632022555967400445256405412579597015412971797143");        SecureRandom    k = new SecureRandom()        {            public void nextBytes(byte[] bytes)            {                byte[] vals = new BigInteger("700000017569056646655505781757157107570501575775705779575555657156756655").toByteArray();                System.arraycopy(vals, vals.length-bytes.length, bytes, 0, bytes.length);            }        };        ECCurve curve = new ECCurve.Fp(            new BigInteger("883423532389192164791648750360308885314476597252960362792450860609699839"), // q            new BigInteger("7fffffffffffffffffffffff7fffffffffff8000000000007ffffffffffc", 16), // a            new BigInteger("6b016c3bdcf18941d0d654921475ca71a9db2fb27d1d37796185c2942c0a", 16)); // b        ECParameterSpec spec = new ECParameterSpec(            curve,            curve.decodePoint(Hex.decode("020ffa963cdca8816ccc33b8642bedf905c3d358573d3f27fbbd3b3cb9aaaf")), // G            new BigInteger("883423532389192164791648750360308884807550341691627752275345424702807307")); // n                ECPrivateKeySpec priKey = new ECPrivateKeySpec(            new BigInteger("876300101507107567501066130761671078357010671067781776716671676178726717"), // d            spec);        ECPublicKeySpec pubKey = new ECPublicKeySpec(            curve.decodePoint(Hex.decode("025b6dc53bc61a2548ffb0f671472de6c9521a9d2d2534e65abfcbd5fe0c70")), // Q            spec);        Signature           sgr = Signature.getInstance("SHA1withECNR", "BC");        KeyFactory          f = KeyFactory.getInstance("ECDSA", "BC");        byte[] message = new byte[] { (byte)'a', (byte)'b', (byte)'c' };                checkSignature(239, priKey, pubKey, sgr, k, message, r, s);    }