Help - Search - Members - Calendar
Full Version: Tutorial | How To Make A Flash Menu Password Protected In 5 Steps!
SE-NSE Forums > SE Firmware > Firmware Tutorials & Guides
RD274
In this tutorial, I'll show you an extremely simple way to secure your phone with a Flash Menu or make any Flash Menu password protected.

First of all we'll need 2 programs -
Adobe Flash CS3/CS4
SWF Decompiler


The SWF Decompiler will decompile the menu for us, while Flash CS3 is where we will be doing all the real work. Any number written in brackets correspond to the number in the image.

For the sake of this tutorial, I will be password-protecting the Flash Menu "Connecto" which comes with the W595.

----------------------------------------------

STEP 1-
Using SWF Decompiler decompile the "Connecto_Desktop.swf" file and open it in Flash CS3.
Make any necessary changes to the Flash Menu (like the icons or whatever you wish to do). Then proceed to Step 2.

----------------------------------------------

STEP 2-

Now look at the top, on the layers panel .... Select all the layers (1) and drag them to Frame 3 (2).

----------------------------------------------

STEP 3-

-Click on the First Frame on Actionscript Layer (3).
-Now Press "F9" to bring down the Actionscript Toolbox. Now Copy-Paste the Following Script into the ActionScript Toolbox(4).

CODE
stop();
pass="";

keyCap2 = new Object();
Key.addListener(keyCap2);
keyCap2.onKeyDown = function() {
    Ascii = Key.getAscii();
    if (Key.isDown(49)) {
        pass += "1";
    } else if (Key.isDown(50)) {
        pass += "2";
    } else if (Key.isDown(51)) {
        pass += "3";
    } else if (Key.isDown(52)) {
        pass += "4";
    } else if (Key.isDown(53)) {
        pass += "5";
    } else if (Key.isDown(54)) {
        pass += "6";
    } else if (Key.isDown(55)) {
        pass += "7";
    } else if (Key.isDown(56)) {
        pass += "8";
    } else if (Key.isDown(57)) {
        pass += "9";
    } else if (Key.isDown(13)) {
        play();
    }
};


----------------------------------------------

STEP 4-

-Now right-click on Frame 2 on ActionScript Layer and click "Convert to KeyFrame" (5).
-With Frame 2 highlighted (6), Copy-Paste the Following Script into the ActionScript Toolbox (7).
-Remember to Replace "xxxx" in the code with your preffered password.

CODE
Key.removeListener(keyCap2);
if (pass=="xxxx")
{
    gotoAndStop(3);
}
else
{
    pass="";
    gotoAndPlay(1);
}

Your Menu is now password enabled.

----------------------------------------------

STEP 5-

Now Create Some Visual Elements (if you wish to) for your menu (Like what I made in the Image below).
- Make a Box in the lowermost layer (Layer 1 as reference) like I made a dark green one.
- In the Middle layer (Layer 3 as reference)->
+Make the "Password" text box (8).
+Make the other text box blank but with type as 'dynamic' (9) and put the variable as "pass" (10).
-Now click File>Export>"Export As..." and export it as per you're requirements.

Enjoy smile.gif !

Remember to Test the Menu on your phone once before actually implementing it!

Final Files> Click to view attachment (Password is 123)
derhenne
nice tutorial

I think it is better that the password is invisible

put the "pass" text box outside from ur stage.
make a new blank text box with variable as "pass2"

change the code as shown below
then the password only watch as stars

CODE
stop();
pass="";
pass2="";

keyCap2 = new Object();
Key.addListener(keyCap2);
keyCap2.onKeyDown = function() {
    Ascii = Key.getAscii();
    if (Key.isDown(49)) {
        pass += "1";
        pass2 += "*";
    } else if (Key.isDown(50)) {
        pass += "2";
        pass2 += "*";

etc.





greets derhenne
Corman
Is it possible to have the .swf read the code from a .txt file somewhere on the phone?
RD274
QUOTE (derhenne @ 2009-07-13 21:47) *
nice tutorial

I think it is better that the password is invisible

greets derhenne

Thats a good idea .... I never really bothered hiding them anywayz!

QUOTE (-corman- @ 2009-07-13 21:54) *
Is it possible to have the .swf read the code from a .txt file somewhere on the phone?

From the phone - NO .... Flash Menu dont have access to the FS.
jock
Maybe using full path would work then store on phone like C:\other\
SifJar
Where can I get SWF Decompiler?
Corman
You have to buy it smile.gif
SifJar
Oh. Never mind then. There are no free alternatives I assume?
Corman
Yes, 'buying' the app wink.gif
SifJar
I'm a law abiding citizen, I dont pirate stuff. However, I googled SWF Decompiler the other day, and was pointed to the following site: http://www.sothink.com/product/flashdecompiler/ where you can download a SWF Decompiler for free. Is this an illegal site, or is that a legimate free SWF Decompiler? Or is it a free trial which decompile it halfway then conk out, or something crap like that?
Jinx13
Well it's their site so i'd say it's a demo wink.gif I'm not sure of the limitations though...
Better to 'buy' it lol.gif
Sebatsian
QUOTE (Jinx13 @ 2009-09-23 21:08) *
Well it's their site so i'd say it's a demo wink.gif I'm not sure of the limitations though...
Better to 'buy' it lol.gif


Is this that you have to give a password to acces the menu?
So if you click menu. You have to give a password? and does the c902 support this?
Sebatsian
Anyone? And can you just protect the messages and media. instead of the whole menu?
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2009 Invision Power Services, Inc.