DEROutputStream dOut = new DEROutputStream(bOut);
GOST3410PublicKeyAlgParameters gost3410P = new GOST3410PublicKeyAlgParameters(new DERObjectIdentifier(currentSpec.getPublicKeyParamSetOID()), new DERObjectIdentifier(currentSpec.getDigestParamSetOID()), new DERObjectIdentifier(currentSpec.getEncryptionParamSetOID()));
try
{
dOut.writeObject(gost3410P);
dOut.close();
}
catch (IOException e)
{
throw new RuntimeException("Error encoding GOST3410Parameters");