Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9260827
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T12:59:35+00:00 2026-06-18T12:59:35+00:00

I have a flash project with adobe flash that is written in AS2, and

  • 0

I have a flash project with adobe flash that is written in AS2, and I have the .fla file of course.
this program has kind of authentication to change the parameter that is used in writing the code. it means that I wrote something like:

if (userEnteredPassword == "xyz")
{
//login success logic
}

now the only thing I give to user is the .exe file. I want the user to have the ability to change the password. how can I do that? how can I change the “xyz” in above code when it is compiled? I thought I can hash the password and store in a file next to the .exe file; and check the hashed strings for authentication.I can make a simple hash function.is it possible? how can I work with files? thank you

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T12:59:36+00:00Added an answer on June 18, 2026 at 12:59 pm

    Without having the FLA file it is hard to give you a specific solution. I can only give you a nutshell. Your initial compilation still requires Flash, and you can easily get a trial for 60-days.

    The solution one is to externalize this password in an AS class, but still keep it compiled with the SWF for a little better security (but not by much because a decompiler can easily find the password).

    You would need to locate the area where the password is encoded, let’s say it is a frame with a blob of ActionScript. Let’s say the statement is like

    if (userEnteredPassword == "xyz")
    {
        //login success logic
    }
    

    You can rewrite it as

    if (userEnteredPassword == appsetting.Settings.password )
    {
        //login success logic
    }
    

    You then create an AS file Settings.as in the appsetting folder :

    class appsetting.Settings
    {
        public static var password:String = "xyz";
    }
    

    Compile the FLA into SWF, and make sure there is no error. Subsequently, your SWF may be updated by MTASC without Flash IDE.

    So let’s say the SWF and the password AS file are in the same directory, your MTASC command would look like

    mtasc.exe -swf your_swf_file.swf -cp ./ -out your_swf_with_new_password.swf

    Security Consideration
    As I said earlier, the password stored as plain text is BAD. A slightly approach would be encrypting the password with one-way encryption like MD5, then you would need to compared the encyrpted user input with the encrypted password. This also requires encryption libraries which you would need some knowledge of Flash to do so.

    The best solution is to have server verify the password. You can make an http call and have the server verify if the password matches, in this way you would never expose the password in any shape of form. This approach is more involved.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We have a project that has been built in Flash and as3. It is
I have a Flash program that loads AS2 and AS3 SWF files dynamically with
I have a project written in ActionScript 3 using Adobe Flash Builder 4.5. It
I have a project that was written using ACtionScript 3 in the Flash Builder
I have a flash project that consists of a .fla and a number of
I have a Flash CS5 project with an FLA file and 20 to 30
I have an Actionscript project that I was building using Flash CS4. I embedded
new to Flash - I have a main FLA that loads and runs my
I have an ActionScript only Flex project that was written by someone else. I
I have a large number of Flash projects that have been written in Flash

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.