return RestResponse.failure(e.getMessage());
}
String secureTaskKey = this.apiKeyService.generateNewSecureRandomKey();
Task returnTask = null;
String errorMessage = null;
try {
returnTask = this.scanQueueService.requestTask(scanners, agentConfig, secureTaskKey);
if (returnTask == null) {