Provider fp = new Gnu();
msg = "initialize(AlgorithmParameterSpec) MUST succeed";
try
{
AlgorithmParameters ap = AlgorithmParameters.getInstance("DSA", fp);
AlgorithmParameterSpec spec =
ap.getParameterSpec(DSAParameterSpec.class);
kpg.initialize(spec);
harness.check(true, msg);
}
catch (Exception x)
{
harness.debug(x);
harness.fail(msg);
}
msg = "initialize(AlgorithmParameterSpec, SecureRandom) MUST succeed";
try
{
AlgorithmParameters ap = AlgorithmParameters.getInstance("DSA", fp);
AlgorithmParameterSpec spec =
ap.getParameterSpec(DSAParameterSpec.class);
kpg.initialize(spec, rnd);
harness.check(true, msg);
}
catch (Exception x)
{