Actionscript 3 :: Adobe AIR, URLRequest, And Local Ports?

Feb 28, 2011

I'm looking at writing an app with Adobe AIR, but I wanted to figure out if this is feasible with the platform first. (Mostly new to Flash and AIR).What I would like to do is know ahead of time what local port a URLRequest will be using. If possible, I would like to hold a connection open even and keep using the same socket.What I'm basically trying to accomplish is doing some NAT-Traversal and port negotiation ahead of time. Once I have both the client and the server negotiated, I'd like them to connect and basically use HTTP in a peer-to-peer way to stream media, like this sample:

var s = new air.Sound();
var url = "http://www.example.com/sounds/bigSound.mp3";
var req = new air.URLRequest(url); [code].........

The problem is that I don't see this happening unless I can get some information from AIR on what ports it's planning to use. I would be OK with creating my own Socket connections to the server and using them, but I would need a way to leverage the Sound framework to stream in the same way from a socket.

View 1 Replies


Similar Posts:


ActionScript 3.0 :: Opening Local Files Using A URLRequest?

Nov 16, 2009

is it possible to open a file from say C drive when your flash file is in C:somefolder?

View 1 Replies

ActionScript 3 :: Loading Images By Making URLRequest To Local Folder?

Jul 8, 2010

I want to make an application that loads some images with a Loader by making URLRequests to a local folder. Can I build the application and include somehow this folder so when I send it from a server to a client the URLRequests operate normally on clients side? Also if this is possible, the folder may be not viewable/accessible by the client but only from the Flash application that comes with it? So for example, this piece of code that runs nicely, locally, to my machine, if i send it to a client will continue to run to its machine. Can somehow send the folder and the SWF as one object?

private function clothesOn( outfit:String ) {
var clothier:Loader = new Loader();
var item:String = "clothes/" + outfit + ".gif";
var getItem:URLRequest = new URLRequest( item );
clothier.load( getItem );
this.addChild( clothier );
}

View 1 Replies

Actionscript 3 :: Assign A Request Timeout For Adobe Air URLRequest And Get The Response Without Using EventListne?r

Mar 13, 2012

Below code is used to read a file in the disk and upload as 1MB chunks to a php server via adobe AIR application.It iterates the do/while loop till the end of the file and uploading part is handled by function getConnection. The servers returns an XML as the response.With the eventListnters currently it goes to fuction onRequestComplete when it recieves the response. Because of that issue current code exits the loop when it receives the response from the server.Is there any way that I can get the responce of the request send by the function getConnection when it calling inside function startUpload ? also hw can I define the request timeout for this single requests?

private function startUpload():void {
var localFilePath:String =localFilesToUpload[currentUploadedVideoIndex].file.nativePath;
var filePathArray = localFilePath.split("/");[code]......

View 1 Replies

ActionScript 3.0 :: Adobe Flash Player Has Stopped A Potentially Unsafe Operation URLloader URLrequest

Oct 29, 2011

I am working on a flash website that loads live inventory data from a public csv file publish by google docs.  the csv file is located at a public address on google docs server:[URL].. I am using a URLloader and URLrequest within my flash movie to grab this data and assign it to different variables.

It works great when I preview the movie in flash. However, when I go to publish the movie and preview the html file its loaded into in dreamweaver, I get a security warning from adobe flash player: Adobe Flash Player has stopped a potentially unsafe operation

I went ahead and published the html file that contains the swf file to the web, and when I go to my site, I don't even get the flash player warning; it just sits there like its trying to load the URLrequest and never completes.

I understand that flash player has a security measures that prevents flash files from accessing files outside of the server directory that the swf file is published to.  I know you can create policy xml files to tell flash it's okay to load the data, but those policy files have to be located on the public server from which the data is being grabbed. But it's not like I can waltz on to google's servers a stick a policy file in there!

Is there any way to tell the flash player it's okay to load this data without getting that security error?  I can't have the end user having to go into their flash settings and adding the location manually.  I just need it to work without the security warning.

Is there another method of loading data from an external server without tripping up flash player security? aka, something other than URLloader and URLrequest?

[Code]...

View 25 Replies

Flex :: Adobe Air Local FLV Playback?

Jul 22, 2009

I'd like to distribute FLV files from my website, however I want a level of DRM control over the files. So far, I've been able to modify the FLV files to contain a 60 character ID at the very front of the file, but I can't figure out how to get AIR to extract the ID and therefore play the file. All I can figure out is using NetStream, but that won't let me skip 60 bytes, and so it thinks the FLV is invalid.

View 1 Replies

Actionscript 3 :: Store A ByteArray In Adobe AIR Local SQL?

Nov 12, 2010

I can read an image from hard drive and get a ByteArray from its source. Is there any way to store those bytes in local SQL database? What datatype for this field I need to choose?Or maybe there is a more clever way to save an Image file itself into AIR SQL?..

View 1 Replies

Flex :: Adobe AIR. Local Network Error?

Apr 16, 2011

For example, in local network, when Adobe Air is reading files from local server (\Serverstorage) and network will be in down for a second, Air becomes eat a lot of memory and it is increasing up to 1GB (while normal memory use is 100 kb or less).Just reading file with File('file path on local server'); from unstable network can cause this error.
Have anybody seen that in projects?

private function init() : void
{
file = new File("\Serverdragracing

[code].....

View 1 Replies

Actionscript 3 :: Adobe AIR - Save Local Data

Sep 9, 2011

I'ld like to save variables to an Encrypted Local Store. This example is working but how can I extend it to save more than 1 variable?

[Code]....

View 1 Replies

Actionscript 3 :: Unzip Local File In Adobe Air?

Oct 12, 2011

Does anyone know a good library to unzip local files in adobe AIR for with actionscript 3? I have: A local file named somefile.zip I need:To give some external library a path where I want to save the unzipped version of file.It must be able to process the file and not load it all into the memory.I found the FZip library - but it loads all archived data into the memory.And also found the nochump library, but there is no such parameter to choose where I want to unzip the file.

View 1 Replies

Flash :: SWF Local Trusted Sandbox And Adobe Air?

Oct 27, 2011

We are a research group from the University of Zaragoza (Spain). We are developing educational games for children with special needs, (in particular, with)social and cognitive disabilities. We develop our games with Adobe Flash CS5, so we are enough handy with Action Script language.The emerged problem is related with the security sandboxes in Flash.

At the moment, we are designing a new educative application where image and sound resources come from the Internet, using web services through a "loader.load(new URLRequest(name))" command. We are using the adequate crossdomain file, and it is working fine when published on the web.HOWEVER, now we are thinking on developing a desktop educative application, where educators will configure the game, and keep their work in a local system file. This is where problems arise. As the Flash player sandboxes limits us to "only network", or "only local file system" use, we are not able to access the Internet and to generate local files at the same time.

We are not trying to make a flash virus, we are only trying to make an application for educators, where resources came from the Internet but the application requires access to local file system in order to let educators to save and to load their work in their disk.Reading the Adobe doc, we found the different flash player sandboxes: http:[url]....

It seems that there is a sandbox which enables us to both access internet and local files:"Security.LOCAL_TRUSTED—The SWF file is a local file and has been trusted by the user, using either the Settings Manager or a Flash Player trust configuration file. The SWF file can both read from local data sources and communicate with the Internet." And it seems that Local_trusted SWF files are set by the final user or by installer programs. As we intend to publish the application on the web, and educators will download the application, the installer programs seems a nice option, but we are not able to find info about SWF installer programs.

On the other hand, we know about the Adobe Air solution. We understand that AIR is a substitute to Flash Player. It seems adequate as it will expand our application to other environments like android IOS (tablets, mobiles, ...).The question is: using AIR, would we gain network and local access in our SWF application? And what about the final user? Would he/she be able to download the SWF from our web, and any kind of AIR player and executing our application in an easy way on the device? Finally, what do you think is the best solution for the kind of application we are aiming to?

View 1 Replies

Professional :: URLRequest Lost - Error 1046: Type Was Not Found Or Was Not A Compile-time Constant: URLRequest

Aug 12, 2009

In my movie i have a link button with following, simple, function creating a link:

[Code]...

lately i've associated a class file (.as) to my movie and immediately after, when publishing the movie i got the following error message: 1046: Type was not found or was not a compile-time constant: URLRequest. as well as a couple of other related error messages: 1180: Call to a possibly undefined method URLRequest. 1180: Call to a possibly undefined method navigateToURL. when i remove the link to the class file, the problem goes away. also, i have checked the class file for mentioning of "URLRequest" and nothing is there.

View 9 Replies

Professional :: Adobe Air - Packaging External Local Files With Application?

Feb 17, 2011

I'd like my application to be pretty light so it loads quickly. So i'd like to place all my assets (XML files, graphics, etc) outside from the main Air file and when the main Air file is loaded into memory, I'd like it to load in the asset files at runtimeSo how do I go about telling Flash builder to save my asset files locally when it packages my Air Application and also ensure I can access these files while debudding my application?

View 2 Replies

Adobe - Access Local File System From Flex Web Application?

Jan 5, 2011

I'm trying to access local file system from Flex web application. I know it is pretty difficult, but I think there must be a way. Is there a way that Flex app can use AIR components or maybe web application can call some AIR module in order to choose files and upload?

View 2 Replies

Flex :: Show A Local Html Content In Adobe Air Application?

Apr 19, 2011

I want to show a local html file into my application but I could't find to do that.

I used <mx:HTML> component with using its location property but it is not working when I try to do it with a local file which is in applicationdirectory.

EDIT: Here is my code :

<fx:Script>
<![CDATA[
private function init():void {

[Code].....

View 2 Replies

Flex :: Fix Choppy Video Playback Of Local Flv File In Adobe Air Application?

Aug 17, 2011

I have made a application that plays videos that are stored in a assets folder of the air application but when ever I run it on an hp slate the videos are really choppy. Is there a way to preload the video or does it have to do with the processing power? the videos are 1.72mb or smaller. They are flv format and they auto play when that application is started. I am using flash builder.

View 1 Replies

Flash - Adobe Cirrus (Stratus) Doesn't Work If User Have Local Network

Aug 20, 2011

I am developing flash p2p chat. It works fine on my friends' computers (they can chat each other), but not on mine. The problem is that I have local network at home, and I think that Flash Player tries to make p2p requests to peers inside my local network.Can I check if user have local network in AS3 and up the level of network to the WWW?

View 1 Replies

ActionScript 3.0 :: Error #2148: Only Local-with-filesystem And Trusted Local SWF Files May Access Local Resources

Jul 4, 2010

I'm trying to load a local xml file:

xmlLoader.load(new URLRequest("../xml/xmlData.xml"));

But I'm getting this security sandbox violation:

#2148: Only local-with-filesystem and trusted local SWF files may access local resources.

I don't get this error when I embed the XML file directly with the EMBED metadata tag.

View 3 Replies

Java :: Configure Jboss For Two Different Ports?

Jun 23, 2011

I have a ear file and a war file, need to deploy them in two different ports such as 8443 and 5480 respectively. How to configure two ports seperately for those two files. I have no experience configuring JBoss.

View 1 Replies

Media Server :: FMS 3.5 Upgrades Not Binding To Ports 80, 1935?

Nov 14, 2011

I have installed and ran FMS Development Server 3.5 on my Fedora 15 x32 for a long while now. Everything works fine. However, recently I found out about the upgrades for the server. So I downloaded all of them (3.5.2 - 3.5.7)... the current version I have is 3.5.1... and it works fine. Installing any of the new upgrade versions on the server works fine... and when starting the server doesn't give any errors.

In /var/logs/messages it says:

Server starting...
Server started (/opt/adobe/fms/conf/Server.xml).

however, checking the binding of my IP address, it shows no bindings to ports 80 and 1935. The admin server works successfully because I can see binding to port 1111.Whenever I run my test application which I used to run successfully on FMS 3.5.1, I cannot get a connection.So I was wondering whats wrong... why it doesn't bind anymore? is there something wrong with my upgrade process?? I even tried uninstalling whatever I currenltly have and installing the new upgrade... same result.

View 6 Replies

Flash :: P2P Video Chat - Open Firewall Ports

Jan 4, 2011

I just wrote a P2P video chat similiar to the Cirrus example application on my web site. It works great, as long as both users manually open the ports required for RTMFP. Naturally this is a deal breaker for me - since no one will use it. What is the standard solution in this case? Should I publish the instructions of how to open the ports on different firewalls? Should I write a small batch file to be downloaded that programmatically opens the ports? Is there a different (commercial) tool that allows me to bypass it in any other way?

View 1 Replies

ActionScript 3.0 :: Scripted Movie Won't Run Outside Of Firewall ... Open Multiple Ports?

Sep 14, 2009

I'm new to Flash and AS3, but with the help of many examples I have managed to created a scripted movie using some time lapse photography. I load the images from an XML file and use an event listener to add each image as a child of a movie clip. As the number of children grew, it caused the frame rate to slow, so I figured out that I could remove them after they were viewed and just keep looping through the array.

This works great on the local machine and when served up from the web server behind the firewall. However, if I try to access the file from outside the firewall, it loads the first image or two very slowly (if at all) then hangs. I've performed a net stat from the server and noticed that it is opening an inordinate number of connections to the remote client on various client ports (from 6 to 60+).

[Code]...

View 1 Replies

Facebook :: Port 843 For Socket Policy Files - Often Are Users' Ports Closed?

Oct 28, 2011

I'm working on a Flash/Facebook game. My swf and socket server are on different domains, so I have to use a socket policy file. According to Adobe, they have "filed with IANA, the Internet Assigned Numbers Authority, to reserve port 843 for the purposes of serving socket policy files." Unfortunately, my server has port 843 closed. I asked my server guy to open the port. Here's his reply:

[quote]One of the points Matt mentioned is even if we open that particular port how would you ensure the scores of people accessing this game from their schools, libraries or even people internal to OurCompany will have connectivity on the port. Let me explain, in order for traffic to flow on port 843 from the browser to the smart fox server, the users ISP also has to allow for that traffic to pass outbound from the users browser. It is possible that several users would not be able to run it, is that risk acceptable ?[/quote]

How common is it for ISPs to block port 843? I assumed that, since this is an Adobe standard, that ISPs would now have it open by default. What's the scoop?

View 2 Replies

Media Server :: FMS 4.5 Ports To Open On Development Server Firewall?

Oct 26, 2011

I work on a project for a client so i can do otherthings while i wait on this answer. Anyway what ports do i need to open so I can stream video with hls for Apple/IOS devices? i've opened 80,8080,1935 but i think i saw somewhere that i need to open a port range.

View 2 Replies

Flash :: Execute An External .exe From A Local .swf Using A Local XML Socket Server (C#)

Jan 7, 2012

I'm developing a game add-on/plugin which replaces a built in feature of an online game. The game loads an .swf therefore, my solution also has to be an swf for it to work 'in-game'.

I would like to be able to have the user press a button in the custom .swf I am making - and this would open an external application (amongst other things). I.e. if there was a button that said Notepad, it would open Notepad.exe on the machine.

My initial thinking was that i could have a XML Socket server 'daemon' runnning (c#) , which i could connect to with flash - however, as both the swf and the daemon are local, flash complained and gave this error: "Error #2010: Local-with-filesystem SWF files are not permitted to use sockets."

The only way i know to fix this - is to change the security settings of flash - not very user friendly!

So! Any thoughts on how I could otherwise go about this? I was thinking a custom http server could do the trick (connected with URLRequest) although i'm not too sure.

View 1 Replies

ActionScript 2.0 :: Launching A Local Html File From Local Swf?

Jan 16, 2007

i am having a problem launching a local html file from my swf. i have a button called print that when clicked it is supposed to open the local html file and print out the content. this is the code i used on the button

on (release){
getURL("folder/folder/file.htm","_self");
}

[code].....

View 4 Replies

Flash :: Adding A Folder On The Local Network To The List Of "local-trusted" Places

Jul 22, 2011

I have a SWF file located at the local network in the public shared folder that I do not control over trying to read the external file on the local network.

I am currently hitting instead an security violation

Error #2148: SWF file file://....mySWF.swf cannot access local resource file://...config.xml"

I've added the network path where SWF an XML file resides to "trusted locations" via Flash Player Global Settings.

The added network path is successfully displayed at the list of "trusted locations" within Global Settings Manager, but it does not look like Flash Player is able to really parse the local network path as a "trusted location"

FP 10.3.181.23, Win XP

View 1 Replies

Javascript :: Access An Local Image (not In App Workspace) From A Local HTML File (in App Workspace)

Mar 12, 2011

I have a HTML box and load a local html file from the project. In this HTML file I use jquery and I want to load an image from my user directory. I see the image from my user directory but jquery doesn't works. I get this error:

[Code]...

But if I load an image from the app workspace, everything works fine (I see the image and Jquery works). Is this a policy problem? The error says that is a "null object reference" problem, but this can't be true...

View 2 Replies

ActionScript 3.0 :: Adobe.utils.Extension Not Found In Adobe Flash Professional CS5

Dec 23, 2010

In my machine I have installed only  Adobe Flash CS5 proffesional trial version. Now this installation is not supporting adobe.utils.Extension class in this version. I have tried with all latest updates from adobe site. My doubt is does adobe.utils.Extension class is available in licensed version of Adobe Flash CS5 proffesional?

View 12 Replies

Actionscript 3 :: Network Game By Adobe Air Programming In Adobe Flash

Dec 28, 2011

I want to create a simple game (Adobe Air) based on 2 players using ActionScript 3.Let's assume I want to create online chess game.So that I can play with my friend at work, at home, from anywhere via internet.Should I use flash server? Or something similar for this purpose, or there is simpler way to connect 2 players and make fully functional interaction between them?

View 2 Replies







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