Flash
  Home arrow Flash arrow Page 2 - Undocumented ActionScript Flash Hack
Dev Articles Forums 
ADO.NET  
Apache  
ASP  
ASP.NET  
C#  
C++  
ColdFusion  
COM/COM+  
Delphi-Kylix  
Design Usability  
Development Cycles  
DHTML  
Embedded Tools  
Flash  
Graphic Design  
HTML  
IIS  
Interviews  
Java  
JavaScript  
MySQL  
Oracle  
Photoshop  
PHP  
Reviews  
Ruby-on-Rails  
SQL  
SQL Server  
Style Sheets  
VB.Net  
Visual Basic  
Web Authoring  
Web Services  
Web Standards  
XML  
Dedicated Servers  
Actuate Whitepapers 
Moblin 
IBM® developerWorks 
Sun Developer Network 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
FLASH

Undocumented ActionScript Flash Hack
By: O'Reilly Media
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 25
    2004-09-27

    Table of Contents:
  • Undocumented ActionScript Flash Hack
  • ASSetPropFlags( )
  • Looking at the Prototype Property
  • Trace() Statements

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT

    Stay one step ahead of the competition. Evaluate and give feedback on some of the hottest web development tools on the market today. Make your opinion heard! Click Here

    Undocumented ActionScript Flash Hack - ASSetPropFlags( )


    (Page 2 of 4 )

    ASSetPropFlags( ) takes the following form:

    ASSetPropFlags(object, properties, setTrue, setFalse)

    where:

    object

    Is the object or scope that you want to examine.

    properties

    Is the properties/methods ofobject for which you want to change the protection flags. You also have the option of settingproperties tonull, which acts as a wildcard that means “all properties.”

    setTrue

    Is an integer bitmask specifying the configuration flags. The last 3 bits of this integer are the important ones and represent (rightmost bit to leftmost) the “protect from overwrite,” “protect from deletion,” and “hide” flags. For example, settingsetTrue to 110 binary (06 in hex or 6 in decimal) keeps them protected from overwrite and deletion but unhides the properties specified byproperties.

    setFalse

    Is another integer bitmask that works likesetTrue, except it sets the attributes to false. ThesetFalse bitmask is applied beforesetTrue is applied.

    The FlashCoders Wiki (http://chattyfig.figleaf.com/flashcoders-wiki/ ?ASSetPropFlags) includes a chart describing various bitmasks used with ASSetPropFlags( ).

    The properties/methods we want to make visible are those of the_globalscope, which contains all the built-in ActionScript classes. We can thus make the entire set of classes within ActionScript enumerable via a for...in loop:

    ASSetPropFlags(_global, null, 6, 1);

    The following code unhides all of ActionScript and then looks to see what classes it can find:

    // Set protection flags to 110 for _global to unhide everything ASSetPropFlags(_global, null, 6, 1);
    // List all objects in _globa
    l
    for (thisObject in _global) {
    trace(thisObject);
    }

     

    Buy the book!If you've enjoyed what you've seen here, or to get more information, click on the "Buy the book!" graphic. Pick up a copy today!

    Visit the O'Reilly Network http://www.oreillynet.com for more online content.

    More Flash Articles
    More By O'Reilly Media


     

    FLASH ARTICLES

    - Using XML and ActionScript with Flex Applica...
    - Interfaces and Events with ActionScript and ...
    - Manipulating Data with ActionScript in Flex ...
    - ActionScript Syntax for Flex Applications
    - ActionScript in Flex Applications
    - A Closer Look at Apollo`s File System API
    - Using the File System API
    - ActionScript 101
    - Flash Buttons
    - Advanced Flash Animation
    - Creating Your First Animated Movie with Flas...
    - Flash: Building Blocks
    - Building Preloaders
    - Fun Things to Do with Movie Clips in Flash MX
    - Referencing Movie Clips in Flash MX







    © 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway