try {
PkcsPkiEnvelopeDecoder envDecoder = new PkcsPkiEnvelopeDecoder(
getRecipient(), getRecipientKey());
PkiMessageDecoder decoder = new PkiMessageDecoder(reqCert,
envDecoder);
msg = decoder.decode(sd);
} catch (MessageDecodingException e) {
LOGGER.error("Error decoding request", e);
throw new ServletException(e);
}