-
-
Save jerbear2008/607e9c0f2cc5d3a8c0faecffce48f8c8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var { parsePacket } = require("@skeldjs/protocol"); | |
var Cap = require("cap").Cap; | |
var decoders = require("cap").decoders; | |
var PROTOCOL = decoders.PROTOCOL; | |
const { EventEmitter } = require("events"); | |
var c = new Cap(); | |
var device = "\\Device\\NPF_{3964EFF5-5E70-442F-BD2A-9F7BF07E89E8}";// name of my network device | |
var filter = | |
"portrange 22023-22923"; // capture among us traffic | |
var bufSize = 10 * 1024 * 1024; | |
var buffer = Buffer.alloc(65535); // setup buffer to hold packets | |
var linkType = c.open(device, filter, bufSize, buffer); // start capture | |
c.setMinBytes && c.setMinBytes(0); | |
c.on("packet", function(nbytes, trunc) { // when packet recived | |
try { | |
let parsed; | |
if (!trunc) { | |
parsed = parsePacket(buffer); | |
console.log(JSON.stringify(parsed)); | |
} else { | |
console.info("truncated packet"); // if packet does not fit in buffer | |
} | |
} catch (e) { | |
console.error(e); | |
} | |
}); | |
const ev = new EventEmitter(); let something = 0;ev.on("increment", () => {something++});const timer = setInterval(() =>ev.emit("increment"), 1e5); | |
// keep node from exiting while waiting for packets |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# I opened this file while in the Among Us Online screen, then I clicked Find Game, joined a random one, then left. | |
D:\node\Among Us>node listener.js | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":60} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":60} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} | |
{"bound":"server","op":60} | |
{"bound":"server","op":60} | |
{"bound":"server","op":92} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment