Loop/Architecture/Fingerprint Validation: Difference between revisions

Jump to navigation Jump to search
→‎Proof-of-Concept Monkeypatch Shim: Remove mention of setTimeout() since the example shows an event emitter instead. Removed success/failure callbacks from emitter, since these can't legally be called more than once.
(Change "newpc" to "add-fingerprint")
(→‎Proof-of-Concept Monkeypatch Shim: Remove mention of setTimeout() since the example shows an event emitter instead. Removed success/failure callbacks from emitter, since these can't legally be called more than once.)
 
Line 142: Line 142:
     var setDescriptionShim = function(sdp, success, failure, pc, localRemote) {
     var setDescriptionShim = function(sdp, success, failure, pc, localRemote) {
       var fingerprint = /a=fingerprint:([^\r\n]*)/.exec(sdp.sdp)[1];
       var fingerprint = /a=fingerprint:([^\r\n]*)/.exec(sdp.sdp)[1];
      // Note: This is where the fingerprint exfiltration and verification would
      // be enqueued using setTimeout().
       console.log(localRemote + " fingerprint = " + fingerprint);
       console.log(localRemote + " fingerprint = " + fingerprint);
        
        
       // Use any available event-emitter to decouple this code from the application.
       // Use any available event-emitter to decouple this code from the application.
       eventEmitter.emit("set" + localRemote + "Description", sdp, success, failure);
       eventEmitter.emit("set" + localRemote + "Description", sdp);
        
        
       pc["_originalSet" + localRemote + "Description"](sdp, success, failure);
       pc["_originalSet" + localRemote + "Description"](sdp, success, failure);
Confirmed users
632

edits

Navigation menu