dcsimg
A Flash Developer Resource Site

Results 1 to 8 of 8

Thread: Multiple passwords to login

  1. #1
    Junior Member
    Join Date
    Mar 2004
    Location
    malaysia
    Posts
    26

    Multiple passwords to login

    I am using Flash MX Professional
    I am doing a flash website.

    i want to make a multiple password to login.

    what i know to do now is making one password to login.

    the code is stated below.

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

    on (release) {
    if (pass=="letmein") {
    gotoAndStop(2);

    }

    }


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

    is there a code to put in as other than the password "letmein", we can put more than one password? like password "123", "456", "def" and etc....
    Last edited by vongasbuzteng; 12-12-2004 at 08:59 AM.
    ---vongasbuzteng---

  2. #2
    Senior Member
    Join Date
    Mar 2001
    Posts
    141
    if you're going to use this method, then you can simply use:

    code:

    on (release) {
    if (pass=="letmein" || pass=="123" || pass=="dainbramage" ) {
    gotoAndStop(2);
    }
    }



    because '||' stands for 'or'.
    tired of you // http://www.indextwo.net

  3. #3
    Registered User
    Join Date
    Feb 2001
    Posts
    13,044
    Hi,

    it wont take more than a few minutes to read all the passwords from a movie with that kind of login ...

    Musicman

  4. #4
    Junior Member
    Join Date
    Mar 2004
    Location
    malaysia
    Posts
    26
    thank you... and it works!
    ---vongasbuzteng---

  5. #5
    Junior Member
    Join Date
    Mar 2004
    Location
    malaysia
    Posts
    26
    wut do u mean musicman?

    do u have any other ideas how to create a securely login?
    ---vongasbuzteng---

  6. #6
    Registered User
    Join Date
    Feb 2001
    Posts
    13,044
    Hi,

    if you can avoid at all, passwords should not be stored within a file that one can download from the server and read (as you can with swf or text files)
    Rather, the movie should send user and pass to the server. The server will compare data with some kind of list or database and send an ay or nay back.
    You usually need something like php, cgi, asp, cfmx as part of your hosting package

    Musicman

  7. #7
    Junior Member
    Join Date
    Mar 2004
    Location
    malaysia
    Posts
    26
    ----------------------------------------------------------------------------------
    Hi,

    if you can avoid at all, passwords should not be stored within a file that one can download from the server and read (as you can with swf or text files)
    Rather, the movie should send user and pass to the server. The server will compare data with some kind of list or database and send an ay or nay back.
    You usually need something like php, cgi, asp, cfmx as part of your hosting package

    Musicman
    -----------------------------------------------------------------------------------

    i noe...but i am using a free host. they dont have the cgi thingie... how can i do that then?
    ---vongasbuzteng---

  8. #8
    Registered User
    Join Date
    Feb 2001
    Posts
    13,044
    Hi,

    the other realistic way is to use non-reversable code (common example, which exists as AS code, is MD5 - there should be simpler ones too) to generate some value from user's supplied name and password, and to compare that value against pre-calculated ones.
    You can even load a text file with crypted passwords from your server, so that you do not have to include the list in your movie

    Musicman

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center