Skip to content

Commit 058bd85

Browse files
authored
fix(security): do not reflect back error GET parameter (#59773)
In the past 3 months, there was no legitimate uses for reflecting the `error` GET parameter on a pipeline error view. It was only used as a target for automated scanners.
1 parent 3843815 commit 058bd85

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/sentry/identity/oauth2.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -319,7 +319,7 @@ def dispatch(self, request: Request, pipeline) -> HttpResponse:
319319

320320
if error:
321321
pipeline.logger.info("identity.token-exchange-error", extra={"error": error})
322-
return pipeline.error(error)
322+
return pipeline.error(ERR_INVALID_STATE)
323323

324324
if state != pipeline.fetch_state("state"):
325325
pipeline.logger.info(

0 commit comments

Comments
 (0)