Git Product home page Git Product logo

Comments (8)

GoogleCodeExporter avatar GoogleCodeExporter commented on August 19, 2024
ignacioalles's fix worked wonders for me when my client would not handshake 
with a 
server.

Thx ignacioalles!

Original comment by [email protected] on 15 Jan 2009 at 7:34

from as3crypto.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 19, 2024
You're welcome. Are you developing a web application? Or a desktop one?

I think it would be nice to have it applied to the project. 

Original comment by [email protected] on 15 Jan 2009 at 7:50

from as3crypto.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 19, 2024
Incorporated most of this into the current commit.

Original comment by [email protected] on 4 Jun 2009 at 11:42

from as3crypto.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 19, 2024
Hello,
We are trying to connect with a JAVA socket server.
Without the encryption it works fine.
Encryption enabled, connection works fine ( note: debug player )
But when published for flash player 10.2 in a browser ( Published with Flex or 
CS5 ) as (sandboxtype:remote), doesn't work anymore...

In short:
At first without encryption, connection works fine as sandboxtype: remote.
So, policy file is exchanged etc. and connection is made.
After as3crypto wrapper it connects fine in debug player ( 
sandboxtype:localThrusted )
Of course here is no policy file exchanged...
Chears!

Original comment by [email protected] on 8 Mar 2011 at 2:39

from as3crypto.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 19, 2024
Hello everybody,

We debugged the as3crypto side, en determined that there is something wrong 
with the handshaking routines ( sandbox:remote ). The weird thing is, that when 
you try to connect a few times, the connection is estabished... Every time you 
must connect a few times...
But in de sandbox:thrusted local, one connect action is needed to connect...

So, at the moment looking at JAVA side...

Anybody?

Cheers ( not Chears ).

Ivo

Original comment by [email protected] on 13 Mar 2011 at 1:34

from as3crypto.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 19, 2024
Guys,

Please read:"http://forums.adobe.com/thread/497758?tstart=0"
Mister [email protected] allready solved my problem!!! Thank you buddy!

Why are these changes improvements not commited???
[code]
        public function connect(host:String, port:int, config:TLSConfig = null):void {
            init(new Socket, config, host);
            _socket.connect(host, port);
            // make sure socket connects before having the engine start to use it
            //_engine.start();
        }

        public function startTLS(socket:Socket, host:String, config:TLSConfig = null):void {
            if (!socket.connected) {
                throw new Error("Cannot STARTTLS on a socket that isn't connected.");
            }
            init(socket, config, host);
            _engine.start();
        }

        private function init(socket:Socket, config:TLSConfig, host:String):void {
            _iStream = new ByteArray;
            _oStream = new ByteArray;
            _iStream_cursor = 0;
            objectEncoding = ObjectEncoding.DEFAULT;
            endian = Endian.BIG_ENDIAN;
            _socket = socket;
            //_socket.addEventListener(Event.CONNECT, dispatchEvent);
      // make sure socket connects before having the engine start to use it
      _socket.addEventListener(Event.CONNECT, onSocketConnected);
            _socket.addEventListener(IOErrorEvent.IO_ERROR, dispatchEvent);
            _socket.addEventListener(SecurityErrorEvent.SECURITY_ERROR, dispatchEvent);
            _socket.addEventListener(Event.CLOSE, dispatchEvent);

            if (config == null) {
                config = new TLSConfig(TLSEngine.CLIENT);
            }

            _engine = new TLSEngine(config, _socket, _socket, host);

            _engine.addEventListener(TLSEvent.DATA, onTLSData);
            _engine.addEventListener(TLSEvent.READY, onTLSReady);
            _engine.addEventListener(Event.CLOSE, onTLSClose);
            _engine.addEventListener(ProgressEvent.SOCKET_DATA, function(e:*):void { _socket.flush(); });
            _socket.addEventListener(ProgressEvent.SOCKET_DATA, _engine.dataAvailable);

            _ready = false;
        }

    // make sure socket connects before having the engine start to use it
        private function onSocketConnected(evt:Event):void
        {
          _engine.start();
          this.dispatchEvent(evt);
        }

        public function flush():void {
            commitWrite();
            _socket.flush();
        }

[/code]

Original comment by [email protected] on 16 Mar 2011 at 8:34

from as3crypto.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 19, 2024
Thank you VERY much. I've spent ages checking my code, checking the many 
examples (with plain sockets), checking traffic, and wondering WHY it wasn't 
working (note there are examples for standard sockets out there that suffer the 
same problem namely using the socked before it's ready).
I only found the root problem when using openssl s_server, and I could see 
there was a problem with the handshake.
This change is really important; without it TLSSocket is pretty broken. We 
should let Mr. Hurlant (who I am also very grateful to) know.
Thanks again (and bjonhston),
Nick

Original comment by [email protected] on 27 Oct 2011 at 5:04

from as3crypto.

GoogleCodeExporter avatar GoogleCodeExporter commented on August 19, 2024
Yes!

As I mentioned : "Why are these changes improvements not commited???"

At the moment, we left AS3Crypto development, and use red5 already...

Ivo

Original comment by [email protected] on 28 Oct 2011 at 10:42

from as3crypto.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.