diff --git a/cerberus-core/src/main/java/com/nike/cerberus/util/CustomApiError.java b/cerberus-core/src/main/java/com/nike/cerberus/util/CustomApiError.java index a96df6b1a..a5c29d863 100644 --- a/cerberus-core/src/main/java/com/nike/cerberus/util/CustomApiError.java +++ b/cerberus-core/src/main/java/com/nike/cerberus/util/CustomApiError.java @@ -19,13 +19,12 @@ import com.nike.backstopper.apierror.ApiError; import com.nike.backstopper.apierror.ApiErrorBase; import com.nike.cerberus.error.DefaultApiError; -import java.util.UUID; public final class CustomApiError { public static ApiError createCustomApiError(DefaultApiError error, final String message) { return new ApiErrorBase( - "custom-error-wrapper-" + UUID.randomUUID().toString(), + error.getName(), error.getErrorCode(), error.getMessage() + " " + message, error.getHttpStatusCode()); diff --git a/cerberus-web/src/main/java/com/nike/cerberus/controller/authentication/AwsIamStsAuthController.java b/cerberus-web/src/main/java/com/nike/cerberus/controller/authentication/AwsIamStsAuthController.java index 8ba2f74cc..441da0afa 100644 --- a/cerberus-web/src/main/java/com/nike/cerberus/controller/authentication/AwsIamStsAuthController.java +++ b/cerberus-web/src/main/java/com/nike/cerberus/controller/authentication/AwsIamStsAuthController.java @@ -80,7 +80,7 @@ public AuthTokenResponse authenticate( authResponse = authenticationService.stsAuthenticate(iamPrincipalArn); } catch (Exception e) { auditLoggingFilterDetails.setAction("Failed to authenticate with AWS IAM STS Auth"); - throw e; // TODO, throw a Backstopper error here + throw e; } auditLoggingFilterDetails.setAction("Successfully authenticated with AWS IAM STS Auth");