Skip to content

Google DevSite Flask Session Pickle RCE - #3166

Merged
carlospolop merged 2 commits into
masterfrom
update_Google_DevSite_Flask_Session_Pickle_RCE_1cd7e5411ffa4f04
Oct 21, 2026
Merged

carlospolop merged 2 commits into
masterfrom
update_Google_DevSite_Flask_Session_Pickle_RCE_1cd7e5411ffa4f04

Conversation

@carlospolop

Copy link
Copy Markdown
Collaborator

Blog URL

https://simonkoeck.com/writeups/google-devsite-flask-session-pickle-rce

Blog Title

Google DevSite Flask Session Pickle RCE

Blog high summary

Documents an unauthenticated RCE chain in Google’s shared DevSite Flask OAuth flow. A roughly 1,200-byte client-side cookie exposed an OAuth2WebServerFlow pickle and reused its OAuth client_secret as Flask’s signing key; reproducing the itsdangerous HMAC enabled arbitrary session forgery.

An attacker-chosen CSRF/state key placed a base64 pickle in the matching flow entry, reaching pickle.loads(); time.sleep(N) via __reduce__ yielded 0.207, 3.193, 5.194, and 8.283-second responses, proving callable execution. The recovered key also signed sessions across five DevSite domains. Fixes were secret rotation, isolated keys, server-side flow state, and data-only serialization.

PR changes

Errors

mdbook build unavailable

@carlospolop

Copy link
Copy Markdown
Collaborator Author

Decision: keep

The researcher’s write-up supports the secret exposure, signing-key validation, callback deserialization, and timing controls. Flask source confirms tagged-byte serialization and the escape behavior for a literal tag-shaped dictionary. The base book covers Flask signing and generic pickle risks, but not this nested application-session failure mode. The repaired directory link and heading r…

Head: a507a7af76c1e3dd0922e5058b2155126477d764

@carlospolop

Copy link
Copy Markdown
Collaborator Author

merge

@carlospolop
carlospolop merged commit 598cd60 into master Oct 21, 2026
2 checks passed
@carlospolop
carlospolop deleted the update_Google_DevSite_Flask_Session_Pickle_RCE_1cd7e5411ffa4f04 branch October 21, 2026 17:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant