Its been a while since I’ve done a Why It Works That Way. My apologies, it has been a busy time working on the new Flash Player and doing lots of things for Adobe Max.

One of the questions I’ve gotten a few times has been about security and BitmapData.draw. In Flash Player there are restrictions on BitmapData.draw to prevent content theft. Recently, a “workaround” was found for the restriction on snapshotting RTMP content (streamed video). Unfortunately, one person’s workaround is another’s exploit or bug.

To maintain the protection on streamed content, the bug that enabled the workaround was closed as of Flash Player 9.0.115. However, the Flash Player and Flash Media Server teams recognize the benefits of the functionality and so we’ve created a way to keep the protections while allowing content owners to relax permissions when they want.

This new permissions system for RTMP snapshotting is a two-part solution. It requires a change in Flash Player and also a change in Flash Media Server. The change in player went out this week. On the same day, Adobe announced Flash Media Server 3. Content streamed through the new server can have a flag added that Flash Player 9.0.115 can recognize and then permit the snapshotting code to run.

I apologize for the inconvenience that you may experience during the time between Flash Player 9.0.115 launching and the launch of Flash Media Server 3, but I hope you agree that having the functionality as an actual supported feature is a good thing for building applications.

As a rule of thumb though, using workarounds for security or protection features is not a good idea. You can generally count on the workaround being closed in the next release of the player. The good news is that Adobe listens to its community and we try to provide new solutions that let you do what you want in a supported and safe way.

Future WIWTWs:
If there is a question you want me to ask about the inner workings of Flash Player or ActionScript, go to this page and submit a comment. I’d like to keep comments on this post relevant to the post itself.