use of org.apache.cxf.xkms.model.xkms.RevokeRequestType in project cxf by apache.
the class CheckXKRSS method checkRevokeWithoutXKRSS.
@Test
public void checkRevokeWithoutXKRSS() {
RevokeRequestType request = new RevokeRequestType();
request.setId("1");
request.setService(XKMSConstants.XKMS_ENDPOINT_NAME);
ResultType result = createXKMSService(false).revoke(request);
assertNotSupported(result);
}
use of org.apache.cxf.xkms.model.xkms.RevokeRequestType in project cxf by apache.
the class CheckXKRSS method createXKMSService.
XKMSService createXKMSService(boolean enableXKRSS) {
XKMSService xkmsService = new XKMSService();
List<Register> keyRegisterHandlers = new ArrayList<>();
keyRegisterHandlers.add(new Register() {
@Override
public RevokeResultType revoke(RevokeRequestType request, RevokeResultType response) {
return response;
}
@Override
public ReissueResultType reissue(ReissueRequestType request, ReissueResultType response) {
return response;
}
@Override
public RegisterResultType register(RegisterRequestType request, RegisterResultType response) {
return response;
}
@Override
public boolean canProcess(RequestAbstractType request) {
return true;
}
@Override
public RecoverResultType recover(RecoverRequestType request, RecoverResultType response) {
return response;
}
});
xkmsService.setKeyRegisterHandlers(keyRegisterHandlers);
xkmsService.setEnableXKRSS(enableXKRSS);
return xkmsService;
}
Aggregations