import java.util.Properties;
import es.gob.afirma.core.AOException;
import es.gob.afirma.core.signers.CounterSignTarget;
import es.gob.afirma.core.signers.TriphaseData;
public interface TriPhasePreProcessor {
<BUG>byte[] preProcessPreSign(byte[] data, String algorithm, X509Certificate[] cert, Properties extraParams) throws IOException, AOException;
</BUG>
byte[] preProcessPostSign(byte[] data, String algorithm, X509Certificate[] cert, Properties extraParams, byte[] session) throws NoSuchAlgorithmException, IOException, AOException;
byte[] preProcessPostSign(byte[] data, String algorithm, X509Certificate[] cert, Properties extraParams, TriphaseData sessionData) throws NoSuchAlgorithmException, IOException, AOException;
<BUG>byte[] preProcessPreCoSign(byte[] data, String algorithm, X509Certificate[] cert, Properties extraParams) throws IOException, AOException;
</BUG>
byte[] preProcessPostCoSign(byte[] data, String algorithm, X509Certificate[] cert, Properties extraParams, byte[] session) throws NoSuchAlgorithmException, AOException, IOException;

import java.util.Properties;
import es.gob.afirma.core.AOException;
import es.gob.afirma.core.signers.CounterSignTarget;
import es.gob.afirma.core.signers.TriphaseData;
public interface TriPhasePreProcessor {
TriphaseData preProcessPreSign(byte[] data, String algorithm, X509Certificate[] cert, Properties extraParams) throws IOException, AOException;
byte[] preProcessPostSign(byte[] data, String algorithm, X509Certificate[] cert, Properties extraParams, byte[] session) throws NoSuchAlgorithmException, IOException, AOException;
byte[] preProcessPostSign(byte[] data, String algorithm, X509Certificate[] cert, Properties extraParams, TriphaseData sessionData) throws NoSuchAlgorithmException, IOException, AOException;
TriphaseData preProcessPreCoSign(byte[] data, String algorithm, X509Certificate[] cert, Properties extraParams) throws IOException, AOException;
byte[] preProcessPostCoSign(byte[] data, String algorithm, X509Certificate[] cert, Properties extraParams, byte[] session) throws NoSuchAlgorithmException, AOException, IOException;
