Issue Type: Bug Created: 2009-08-16T09:05:07.000+0000 Last Updated: 2012-11-20T21:37:39.000+0000 Status: Open Fix version(s): Reporter: Brannon B. King (brannon) Assignee: None Tags: - Zend_Amf
Related issues: Attachments: - Main.mxml
The Request.php and Response.php used by the Zend_Amf_Server are hard-coded to use the Amf0 serializer. This serializer does not support the Zend_Amf_Value_ByteArray class. Therefore, we have no way to return a ByteArray using the Zend_Amf_Server.
Is there some immediate workaround that lets us return a ByteArray using the present Zend_Amf_Server code? Can Zend_Amf_Server chose the serialization according to the objectEncoding member of the NetConnection object created on the client side? Is there some way to cast a string to a ByteArray in ActionScript3?
I'm using the mcrypt library in PHP and attempting to return encrypted strings to the client.
Posted by Brannon B. King (brannon) on 2009-08-17T06:46:11.000+0000
Sweet. I was able to make this work by modifying the Request.php file's _objectEncoding to 3. Do we just need some public function to set that near the server declaration?
Posted by Wade Arnold (wadearnold) on 2009-08-17T20:03:53.000+0000
All AMF requests are AMFO by default. They transfer to AMF3 for the rest of the serialization and deserilization process after they encounter and AMF3 object data type for the first time. That's why the default value is AMF0 but is updates after it changes object types to 3. Can you post a simple bytearray test that showcases the bug? I use it all the time and it works just fine.
Posted by Brannon B. King (brannon) on 2010-01-11T21:42:04.000+0000
I attempted tonight to make a simple test case for this issue. However, I can't even get any data back tonight (using trunk code 20213). I don't know what the deal is. I'll attach my two test files.
Posted by Brannon B. King (brannon) on 2010-01-11T21:43:44.000+0000
These files make up a basic return-a-ByteArray test.
Have you found an issue?
See the Overview section for more details.