Skip to content
Memory corruption Disclosed report Advanced CVE-2016-4248

Adobe Flash Player PSDK Class Use After Free Vulnerability

The PSDK class in Adobe Flash Player has a release() method that frees the underlying memory but leaves AS3 references intact, allowing a use-after-free. An attacker could exploit this to execute shellcode by occupying the freed memory with a controlled AS3 object.

hhj4ck Follow

Originally disclosed on HackerOne

Bounty$5,000 View original
  • Fixed in 41 days
  • Paid in 41 days
  • Disclosed after 3.3 years

I. Summary Adobe Flash Player is prone to a vulnerability which leads to Use After Free. Since the release condition is highly controllable, it is feasible to build a fully working exploit for shellcode execution with proper AS3 object occupied the original PSDK memory.

II. Description PSDK Class expose a member function "release()", which can be called directly to release the inner memory of PSDK.pSDK. However, Not all of PSDK's AS3 references are cleaned, it is still possible to invoke virtual functions on a release memory block.

Source Code of crash.swf: package { import com.adobe.tvsdk.mediacore.PSDK;
import flash.display.Sprite;

        public class poc extends Sprite
        {
                    public function poc()
                    {
                                var ps:PSDK = PSDK.pSDK;
                                var ps_:PSDK = PSDK.pSDK;
                                ps.release();
                                ps_.currentTime;
                    }
        }

}

III. Impact Use After Free

IV. Affected Adobe Flash Player 22.0.0.192

V. Credit Wen Guanxing from Pangu LAB is credited for this vulnerability.

It has been assigned as CVE-2016-4248 by Adobe: https://helpx.adobe.com/security/products/flash-player/apsb16-25.html

The original report as published on HackerOne, by hhj4ck. Images and videos are our own copies; raw HTML is shown as text. View it on HackerOne.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the release() method frees the internal PSDK memory without invalidating all AS3 references, so virtual function calls can still be made on the freed block.

Impact

A use-after-free that could lead to shellcode execution if the freed memory is occupied by a controlled AS3 object.

What the attacker needed

Adobe Flash Player [redacted]; Ability to run crafted SWF content

How it was found

  1. Obtain two references to the PSDK singleton.
  2. Call release() on one reference to free the underlying memory.
  3. Access a property (currentTime) on the other reference, triggering a use-after-free.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

A use-after-free happens when a program frees a piece of memory but still keeps a pointer to it. If an attacker can control what gets written into that freed memory, they can make the program run their own code. Here, calling release() frees the memory but the PSDK object can still be used, so an attacker could take over the freed memory with a crafted object.

What is Memory corruption?

Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.

More by hhj4ck

View all

20 more disclosed reports, best first.

More from Internet Bug Bounty

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Memory corruption

The lesson behind this report.

Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.