php - sending message out of a sandbox to a custom application -


i got application uses flash it's interfaces, , want extract information application, , parse/use in own application (which processes data, stores essentials in mysqldb , on). .swf files written in as2 , can modded quite easily.

so goal send information (really information. being able send numbers (of @ least decent size) enable me implement own protocol of encoding , partitioning) means, not picky means.

here current approach (not own idea, credits koreanrandom.org. merely use source learn):

  • use dokanlib mount virtual filesystem (and implement getfileinformation-handler)
  • use loadvars inside as2-environment parameters "../.logger/@encoded_information"
  • since getfileinformation gets accessed filename parameter, can decode it, put several ones (if had splitted, windows not seem filenames several hundred characters length) , use decoded data

however, application causes bluescreens quite (dont ask why. got no clue, bluescreen messages different) , devs @ koreanrandom.org dont being asked many questions, came ask here other means pass information sandboxed flash-environment prepared listener.

i started thinking weird stuff (ok, abusing virtual filesystem & filenames means of transport information might weird - still great idea imo) provoking windows-functions called , work global hooks, didnt grasp serious plan yet.

the "usual" methods accessing webservers via methods dont appear work:

var target_mc = createemptymovieclip("target_mc", this.getnexthighestdepth()); loadvariables("http://127.0.0.1/tools/indata.php", "target_mc", "get"); 

(indata.php have created file, if accessed, didnt.)

xmlsocket doesnt work either, tried following code sample (using netcat -l on port 12345):

logger.add("begin"); var thesocket:xmlsocket = new xmlsocket(); thesocket.onconnect = function(mystatus) {     if (mystatus) {         logger.add("xmlsocket sucessfully connected")     }   else {         logger.add("xmlsocket no connection");     } }; thesocket.connect("127.0.0.1", 12345); var myxml:xml = new xml(); var mysend = myxml.createelement("thenode"); mysend.attributes.mydata = "somedata"; myxml.appendchild(mysend); thesocket.send(myxml); logger.add("socket sent"); 

doesnt work @ either, output of logger begin , socket sent

annotation: logger created guys koreanrandom.org , relies on dokan implementation, never caused bluescreen me. cant spot mistake in implementation though, started other means of solving problem.

edit: hell wrong "quality messages system"? appearently didnt me using tags "escaping" and/or "information".

hmm, hard say, try sendandload instead of loadvariables

example:

var result_lv:loadvars = new loadvars(); var send_lv:loadvars = new loadvars(); send_lv.variable1=value1; send_lv.variable2=value2;      f=this;//zachytka  result_lv.onload = function(success:boolean) {   if (success) { trace("ok");   } else {     trace("error");   }  };  send_lv.sendandload("http://127.0.0.1/tools/indata.php", result_lv, "get"); //you may use post 

this should work. reason it's not working may flash security settings. try either moving stuff real server or open flash settings manager (there's alternative online version too) , add 127.0.0.1 trusted domains and/or testing file location trusted locations (i use c:*)


Comments

Popular posts from this blog

c# - Send Image in Json : 400 Bad request -

jquery - Fancybox - apply a function to several elements -

An easy way to program an Android keyboard layout app -