Skip to content

Commit

Permalink
Generic internal authorization error
Browse files Browse the repository at this point in the history
  • Loading branch information
tudor-da committed Oct 20, 2021
1 parent 0d92e8e commit 3bb5005
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -94,10 +94,10 @@ object LedgerApiErrors extends LedgerApiErrorGroup {
id = "INTERNAL_AUTHORIZATION_ERROR",
ErrorCategory.SystemInternalAssumptionViolated,
) {
case class ClaimsFromMetadataExtractionFailed(throwable: Throwable)(implicit
case class Reject(message: String, throwable: Throwable)(implicit
loggingContext: ContextualizedErrorLogger
) extends LoggingTransactionErrorImpl(
cause = "Failed to get claims from request metadata",
cause = message,
throwableO = Some(throwable),
)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ class ErrorFactories private (errorCodesVersionSwitcher: ErrorCodesVersionSwitch
)
},
v2 = LedgerApiErrors.AuthorizationChecks.InternalAuthorizationError
.ClaimsFromMetadataExtractionFailed(exception)
.Reject(securitySafeMessage, exception)
.asGrpcError,
)

Expand Down

0 comments on commit 3bb5005

Please sign in to comment.