throws InvalidKeyException
{
if (key instanceof BCMcEliecePrivateKey)
{
BCMcEliecePrivateKey k = (BCMcEliecePrivateKey)key;
return new McEliecePrivateKeyParameters(k.getOIDString(), k.getN(), k.getK(), k.getField(), k.getGoppaPoly(),
k.getSInv(), k.getP1(), k.getP2(), k.getH(), k.getQInv(), k.getMcElieceParameters());
}
throw new InvalidKeyException("can't identify McEliece private key.");
}