PHP :: Securely Provide Unique Secret Code To Winner Of Flash Game?

Feb 15, 2011

Here's what I want to do: when a player wins a game (coded in flash/actionscript), they are given a personalized secret key, which they can email to me in exchange for a prize. I can then validate the key on my end using a private algorithm. I need to design it so that it is practically impossible for hackers to generate a valid prize key without winning the game.

I assume that any SWF file is basically vulnerable to decompilation, but I don't know exactly how vulnerable they are. Perhaps any algorithm for generating a valid key will be accessible to hackers? I have at my disposal all the methods in actionscript 3, as well as a PHP/MySQL server, and I control the server where the game will be hosted.

View 5 Replies


Similar Posts:


ActionScript 2.0 :: Game Project - Placing Unique Instances Of Enemies On Screen

Mar 23, 2010

I've been working on a uni project. Basically, enemies are placed on the screen using a timer variable and using the attachMovie to put them on the screen. This is an example of the code I'm using:

Actionscript Code:
var enemies;var timer;
function onLoad(){
enemies = [];
timer = 0;}
function onEnterFrame(){timer++;
if (timer == 10) {
Timer = 0;
var enemy = _root.attachMovie("mc_1", "mc_1",
_root.getNextHighestDepth());
enemies.push(enemy);
}}

This works and places them on the screen, (and into the array) but by putting them into the array, I thought that each one would be a unique instance of the movieclip which doesn't always seem to be the case. If I shoot one of the enemies, sometimes another enemy will explode (or both of them) and other times I will knock into one enemy and another one will be the one who get's knocked.

For my collision code I'm using this:
Actionscript Code:
for(var i in _root.player.enemies){
if (some arguments..)
_root.player.enemies[i].health -= 10;
}}
The explosion code also uses a similar for loop. Should I look at another method to place unique instances of the enemies on the screen?

View 3 Replies

ActionScript 2.0 :: Display The Winner On The Next Frame?

Mar 23, 2010

The game goes like this. There are four frames; one frame is the title with a start button, which takes you to another frame, which has two input boxes for the two teams to write their names in. getFocus in used to store the names and display them in a dynamic text box in teh next frame.During the course of the game the two players take it in turns to hit a number of fish, with points adding up. There is a finish button at the top for when we want to finish the game, and from that point, when it goes to the 4th frame I would like a text box to display the name of the team that has the highest number of points.The points are displayed in a separate dynamic text box from the team name.

View 0 Replies

Php :: Securely Send POST Vars From Flash?

Jul 31, 2011

I have developed a facebook application in which I am sending data from Flash to Php.Its actually a game based on Flash 8 and at the end I send data by using

loadVarsNum()

using POST method to flash but the problem is this data can be easily tampered so I want know that how can I secure my data from theft or any hack

View 2 Replies

Actionscript 3 :: Securely Tie In Flash Project To A Database?

Mar 27, 2012

I'm creating a game for a viral marketing campaign where roughly one in 100 players will get access to a QR code for some exclusive thingamajig. The game will require information to be pulled and pushed from the database since the game environment will 'grow' over time.

I haven't decided yet on how to do this, but I had 2 ideas, each with their concerns:

solution 1: connect the SWF to a database

concern: I have decompiled SWF's before and it is remarkably easy. How do I protect my database credentials against this?

solution 2: have the SWF connect to .php scripts that query a database. This way my database connection credentials are safe inside the php file.

concern: However, how do I then make sure the PHP script isn't being accessed by a custom script? Somebody could get the php URL from the SWF source and just access it directly, bypassing the flash app.

View 2 Replies

Php :: Securely Sending POST Vars From Flash?

Apr 23, 2008

I have developed a facebook application in which I am sending data from Flash to Php.Its actually a game based on Flash 8 and at the end I send data by using

loadVarsNum()

using POST method to flash but the problem is this data can be easily tampered so I want know that how can I secure my data from theft or any hack.

View 1 Replies

Actionscript 3 :: Hide Value Of The Secret Key Air App?

Jun 28, 2011

I am creating Air (AS3) project. It will be have own system of protection. All data from the server to the application and back is encrypted. I use a secret key which is registered in a server-side scripts and in the application. If a hacker decompiled the app, it can find out the secret key. The secret key is the string (constant). I do not want to make obfuscation for my application.

How can I hide this secret key? Can I obfuscate only it? Can I obfuscate separate AS3 class with secret data and then access to it from the main code when needed?

View 2 Replies

Add Advertisement Code Into Flash Game?

Aug 24, 2009

just want to ask about loading advertisement code!How do you add the advertisement code (adsense) into flash games??my site Funny Games have over 5k games but they are getting from others sites thus I have no original files. How can I add more code into the current files?

View 1 Replies

Flash 3.0 :: Code A Ps3 Question Game In It?

Dec 17, 2011

I am looking to make a simple ps3 game in actionscript 3.0. what i am aiming to do is, have scores for player one and player 2, I would also like to have the option to add players if at all possible up to say 6 players. I would also like to have say 1000 questions about movie trivia only appear in random order and wont re appear for the rest of a game once asked. for the next part i will use an example. Lets say player one is asked a question and gets it wrong player 2 answers the question and gets it right. how would I go about making player one get no points and player 2 get say 100 points? If say 2 players are playing and one gets it wrong and the other gets it worong or right the computer will reveal in a green highlight what is the right answer. I know I probably wont get all my answers solved i realize this is a complex thing to code i just cant find tutorials or answers anywhere on coding actionscript 3.0 for a ps3 game.

View 1 Replies

Facebook :: Access Token Secret?

Mar 26, 2012

I'm using the actionscript api for a flash application on the web. I would like to perform actions which require an access token, but I'm unsure of the security implications of using this in flash (which can be decompiled). Is the access token something I need to keep secret?

N.B. Specifically I'm trying to post game achievements which require the app's access token to be passed. But I'm not sure how I can do this securely from flash (or whether this is not an issue).

View 1 Replies

Securely Publish Live Stream To Adobe Flash Media Server?

Feb 7, 2011

I want to make sure that only authenticated users are publishing streams to my Adobe Flash Media Server.

Ideally I would like to limit the IPs which are allowed to publish streams to the server.

I read about the Adobe Authentication Plugin, but apparently it is broken since it works only for Adobe Flash Media Live Enconder. It doesn't secure the server for other encoders that publish streams.

View 1 Replies

Actionscript 3 :: Write Code For Flash Game Loop?

May 28, 2011

Im making a transition from Java to Flash/Actionscript and Im having sort of a hard time figuring out where to write my code for my flash game loop(or engine) due to flash having "frames" unlike Java.Am I able to put the loop inside the Document class even having like game menus in the game? I havent found a way to put it in there without it always running when the flash application begins.Or should I just have the game loop called every frame? For instance, frame 4 will be level 1 and so the engine will be called out there. And frame 5 will be level 2 and ill call a different instance of the game engine there.Im just having a difficult time due to the "frames". So where would be the best place to put the game loop?

View 4 Replies

ActionScript 3.0 :: Flash Game U Source Code Doesn't Work?

Apr 16, 2009

I picked up the book ActionScript 3.0 Game Programming University.so far it looks good. I have downloaded a few of the samples of code and some don't work or give an error message.TooEarlyExample gives me an error message of;TypeError: Error #1009: Cannot access a property or method of a null object reference.at TooEarlyExample()The flash file has two text fields and the code is supposed to populate them with some text. The first text field doesn't get populated with text but the second one does.

View 7 Replies

Java :: Sometime Provide Option To Install Flash And Sometime Not

Dec 27, 2010

In my web application i am facing a weird problem. In jsp there is code for Brightcove video player. For playing this you need flash with Internet Explorer 8. While running this jsp page it sometime provide the option to install flash and sometime not. But what i want that every time it must show the option to install flash at the client side if the flash is not available. Something like this

View 1 Replies

Flash :: IDE - Detect And Provide Alternative Content

Feb 24, 2010

I've tried all kinds of different ways to detect flash, and provide alternative content where the viewer doesn't have or doesn't want to download flash player. I want the viewer to see alternate static content on the same page if they don't have flash. I just can't seem to find the one definitive answer that works every time! I tried: [URL] but this seems to require installation of Adobe AIR which I have no idea what it is!

View 3 Replies

Professional :: Provide Alternative Image If Flash Player Not Available?

Jul 8, 2010

I`m designing a site with an interactive header created in Flash. how to display an alternative image (a .png) in it`s place if a user doesn`t have the Flash Player? Of course, this is especially important for visitors using iPhones! The site logo is part of the Flash movie, which makes it all the more important that something is displayed in the movie`s place. I`ve heard their are ways of doing it with Javascript, but is this really necessary?

View 2 Replies

Flash :: IDE - Accordion Style Website - Provide Feedback

Oct 7, 2009

I have been requested to create a website similar to the one on this page: [URL] I'm familiar with flash and some actionscript, but would anyone be able to provide feedback on how this site would be best be done?

View 2 Replies

Professional :: Provide An Option To View A Site In Flash Or Html?

Oct 13, 2010

if there was a way to provide an option to view a flash site in html.
 
The site is currently built in flash, but have had feedback from people trying to view the site that they need flash player 10, is there any way to have a link option on the page that asks you to download the latest flash player, to view the site in html (html site has also been developed).

View 5 Replies

Javascript :: Html - Provide Different Swfs Depending On Users Flash Player Version?

Dec 21, 2010

So I have swf9.swf swf10.0.swf and swf10.1 for fp 9.0, 10, 10.1. How to write such JS that would push difrent swfs to user? (I would like to keep using my default flex builder html swfobject.js script if possible - how to using it create code in main html file. )

View 1 Replies

Php :: Process AJAX Requests More Securely ?

Mar 19, 2010

I want to send AJAX requests to my website from my Flash games to process data, but I don't want people downloading them, decompiling them, then sending fake requests to be processed, so I'm trying to figure out the most secure way to process in the PHP files. My first idea was to use Apache's built in Authorization module to require a username and password to access the pages on a separate subdomain of my website, but then you'd have to include that username and password in the AJAX request anyway so that seems kind of pointless to even try.My current option looks pretty promising but I want to make sure it will work. Basically it just checks the IP address being sent using REMOTE_ADDR to make sure it's the IP address that my server runs on.

<?
$allowed = new Array("64.120.211.89", "64.120.211.90");
if (!in_array($_SERVER['REMOTE_ADDR'], $allowed)) header("HTTP/1.1 403 Forbidden");
?>

Both of those IP addresses point to my server. Things I'm worried about:

1) If I send a request from Flash/ActionScript, will that affect the IP address in any way?

2) Is it possible for malicious users to change the IP address that is being sent with REMOTE_ADDR to one of my IP addresses?

View 3 Replies

AS3 :: Php - Securely Pass Data From MySQL

Oct 1, 2011

I need to pass private data from MySQL to a flash file securely. I have a PHP script that is assigning variables on the server side - how do I pass this to flash without being available publically? I assume XML and an HTTP query string are out of the question because of security. What's the most secure way of doing this? Basically I have some file paths that I need to load into a music player - however, I don't want these URLs to be publicly known. I was hoping I could pass data directly to flash securely somehow.

View 2 Replies

ActionScript 2.0 :: Securely Loading External Files

Feb 3, 2007

I have an already built flash mp3 player. It works fine, but the client wants the mp3's inaccessible to to users except through the player.We currently have the mp3's themselves in folders inaccessible via http using .htaccess. We bypass this by loading the mp3's via a PHP script (using file_get_contents()). However, if a user accesses the path of the php script, they will be prompted to download the mp3 anyway.Does anyone know the method in which sites like myspace securely loads mp3's?

View 3 Replies

Data Integration :: Securely Sending Connection String To Swf?

Oct 15, 2006

ok so when i need to connect a swf to some sort of data source on the server be it XML, a .NET DLL, a CFC or what ever so that i can load data from a database or what ever, everyone is always saying that i shouldn't hard code the connection string into my actionscript as anyone can get it and do malicious things with it. So how should i load the connection string into flash. if i put them on the server in an XML file or somthing like that then i still need to put a connection string into the actionscript in order to load in my main connection strings into the actionscript.

Basically i need to know how to load an external string into a swf without anyone else being able to get hold of that string for them selves. i am developing an app for somone and i need it to connect to a database and i need it to be secure. i have everything sorted except making the connection string to the database unstealable.

View 1 Replies

Incorporate Scoring Code Into Current Game?

Apr 28, 2010

I'm trying to incorporate a scoring code into the current game.

View 3 Replies

C# :: How To Code An Web-browser Based Multiplayer Game

Jun 30, 2010

If I wanted to code a desktop-based game, I could pull some XNA code and UDP sockets and make a decent multiplayer game. I would have an extremely clear of how to code the game I wanted.But if I wanted to code a browser-based online multiplayer game, how would I do it?ou can't use XNA....I've been looking at some questions and I'm seeing PHP and ASP.NET and Silverlight and Flash and Java as the alternative languages...I really don't understand how it works. I mean, for a desktop-based game, you're opening a UDP socket and accepting clients and transferring data, updating player states, drawing the results using XNA. But in a browser, how do you open a socket and stuff? How does that concept work, communicating to people in realtime through a web-browser.

View 6 Replies

ActionScript 3.0 :: Check 'Coin Toss' Game Code?

Jan 15, 2010

Finished with coin toss gameWhat done good, what wrong..? what need change? what method better?And now in this user can be winner just 50% ?Attached files.Also code here:

import fl.controls.RadioButtonGroup;
coinToss_btn.label="Coin Toss";
coinToss_btn.useHandCursor=true;

[code].....

View 3 Replies

ActionScript 2.0 :: Multiple Collision Detection Code For A Platformer Game

Dec 15, 2002

I'm having a problem with my multiple collision detection code for a platformer game.. It checks for collisions on all objects separately and it checks only one object per frame. I need to make somekind of a loop so that it would check every object in one frame. Anyone got an idea? It's coded like this:

[Code]...

View 4 Replies

ActionScript 2.0 :: Flash8 - Pause Game As Start Point To Terminate Code

Oct 17, 2009

I'm designing a platformer game, in which the code is all held within the character MC. I want to pause the game using something like 'delete this.onEnterFrame' as a start point to terminate code. The code layout within the character is like so:

onClipEvent (enterFrame) {
...
this.onEnterFrame = function(){ //within clip event
...
if(btnon == 1){ // when button pressed(on stage)) global value of 1 is true
delete this.onEnterFrame;
}...}}

Due to the fact its within a clip event structure, it doesn't pause it, instead it slows everything down. Would I have to construct all my code in a frame layer or can I still use an MC to terminate this?

View 2 Replies

Actionscript 3.0 :: Change Code With Hex Editing To Make Game Always Show HEADS?

Mar 28, 2012

how can i change this as3 code with hex editing to make this game always show HEADs (or tail ) and be winner its game to bet and u should choose head or tail , and if u guess rite u get money ,if not u lost money i want to always answer be head( or tail) .as file attached.

[Code].....

View 3 Replies

Flex :: Provide Functionalities For Buttons In F3?

Nov 25, 2010

I am new to flex. I want to create some buttons and when v click on that button, it should open some images. how to give this functionality in flex builder 3.

View 3 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved