Skip to content

Security1 publisher2 min readPublished

Hacktron chained a Claude-written libheif exploit into OpenAI's internal repositories

The libheif bug was fixed upstream a year earlier without a security label or a CVE, so a Discourse image check that ignored HEIC left it reachable, and forum sign-in tokens carried full API access to the accounts behind them.

The Watch · Security desk

Photograph accompanying Hacktron chained a Claude-written libheif exploit into OpenAI's internal repositories
Photo: aa.com.tr

What happened

  • Hacktron needed several attempts with Claude Opus 4.8 and Opus 5 to build reliable remote code execution for an unpatched libheif flaw, testing it on a Discourse instance before running it on OpenAI's forum.
  • Discourse's built-in image checks did not support HEIC/HEIF, so uploads in that format were handed to ImageMagick, which decodes them using libheif.
  • Because community.openai.com accepted OpenAI account sign-in, code execution on the forum meant any user or employee who had logged in could have had their ChatGPT and Codex accounts taken over.
  • Hacktron took over an OpenAI employee account whose Codex integration was linked to OpenAI's GitHub organization, opened a pull request in an internal repository, and stopped testing there.
  • OpenAI confirmed a fix about 14 hours after the Bugcrowd report and paid a $6,500 bounty, while Discourse had a fix ready within two days and added image-processing sandboxing.

Compiled by The WatchSomething wrong?How this is made

Why it matters

  • constraint Catching this required tracking the libheif version in the dependency tree, because a CVE-keyed patch program had no identifier to alert on.
  • exposure A community forum wired to production identity puts every employee who signs in, and whatever they have connected to that account, within reach of a file upload.
  • capability If a few LLM attempts are enough to weaponise an obscure decoder bug, the gap between a quiet upstream fix and a working exploit narrows for anyone reading commit logs.
  • contradiction Hacktron and OpenAI do not agree on reach: OpenAI says the Slack access Hacktron raises was never verified, so how far the intrusion is scoped depends on which account a responder takes.

Hacktron says the libheif bug was corrected upstream a year before this work, was never flagged as a security issue, and so was never assigned a CVE [3]. A patch program that reads CVE feeds has nothing to match. No vulnerability feed would have told community.openai.com that its decoder was behind [2].

When the validator's list of supported formats is shorter than the decoder's, the formats the validator does not recognise still reach the library [3].

OpenAI's half of the chain was permission scope. Sign-in tokens generated for the community forum carried excessive permissions and granted full API access to the associated ChatGPT and Codex accounts, according to SecurityWeek's account of the finding [5].

OpenAI draws a line between the two bugs. It told SecurityWeek that the image-processing flaw lived in the third-party service Discourse, while the account-takeover path was a separate, OpenAI-side issue [4]. Both halves were required. Closing them took two bug bounty programs, Bugcrowd for the token permissions and HackerOne for the decoder [1].

On scope, OpenAI said its own review of the incident found limited reads of private-repository metadata and commits, followed by the researcher-submitted pull request, to a README file [8]. The report does not date the fixes.

In a statement, OpenAI said, "We thank the researchers for contacting us and sharing their findings. We narrowed the permissions on Community sign-in tokens and revoked affected tokens and sessions." [14]

What to watch

  • Whether libheif maintainers or distributions retroactively assign a CVE to the silently fixed bug, giving scanners something to match.
  • Whether other services that accept OpenAI-account sign-in were issued tokens with the same API permissions OpenAI says it has now narrowed.
  • Whether other Discourse-hosted community sites federated to corporate identity check their own HEIC upload handling after the advisory.
Loading claim ledger
Loading source directory links
Loading share composer
Loading topic controls
Loading related stories