���Root Mod By V1rus_Alfa
User / IP
:
216.73.217.78
Host / Server
:
195.214.235.115 / npln.ir
System
:
Linux damavand.pws-dns.net 5.14.0-503.35.1.el9_5.x86_64 #1 SMP PREEMPT_DYNAMIC Fri Apr 4 05:23:43 EDT 2025 x86_64
Command
|
Upload
|
Mass Deface
|
Create
:
/
home2
/
cutunixc
/
.trash
/
node_modules.1
/
crossws
/
dist
/
adapters
/
Viewing: bun.mjs
import { d as defineWebSocketAdapter, M as Message, c as createCrossWS, P as Peer, t as toBufferLike } from '../shared/crossws.77e89680.mjs'; const bun = defineWebSocketAdapter( (options = {}) => { const crossws = createCrossWS(options); const getPeer = (ws) => { if (ws.data?._peer) { return ws.data._peer; } const peer = new BunPeer({ bun: { ws } }); ws.data = ws.data || {}; ws.data._peer = peer; return peer; }; return { async handleUpgrade(req, server) { const { headers } = await crossws.upgrade({ url: req.url, headers: req.headers }); return server.upgrade(req, { data: { req, server }, headers }); }, websocket: { message: (ws, message) => { const peer = getPeer(ws); crossws.$callHook("bun:message", peer, ws, message); crossws.callHook("message", peer, new Message(message)); }, open: (ws) => { const peer = getPeer(ws); crossws.$callHook("bun:open", peer, ws); crossws.callHook("open", peer); }, close: (ws) => { const peer = getPeer(ws); crossws.$callHook("bun:close", peer, ws); crossws.callHook("close", peer, {}); }, drain: (ws) => { const peer = getPeer(ws); crossws.$callHook("bun:drain", peer); }, ping(ws, data) { const peer = getPeer(ws); crossws.$callHook("bun:ping", peer, ws, data); }, pong(ws, data) { const peer = getPeer(ws); crossws.$callHook("bun:pong", peer, ws, data); } } }; } ); class BunPeer extends Peer { get addr() { let addr = this.ctx.bun.ws.remoteAddress; if (addr.includes(":")) { addr = `[${addr}]`; } return addr; } get readyState() { return this.ctx.bun.ws.readyState; } get url() { return this.ctx.bun.ws.data.req?.url || "/"; } get headers() { return this.ctx.bun.ws.data.req?.headers || new Headers(); } send(message, options) { return this.ctx.bun.ws.send(toBufferLike(message), options?.compress); } publish(topic, message, options) { return this.ctx.bun.ws.publish( topic, toBufferLike(message), options?.compress ); } subscribe(topic) { this.ctx.bun.ws.subscribe(topic); } unsubscribe(topic) { this.ctx.bun.ws.unsubscribe(topic); } } export { bun as default };
Coded With 💗 by
0x6ick Mod By V1rus_Alfa