Closed Zakistt closed 3 years ago
Mm, I don't know why this doesn't work for you, it works for me:
[stephen@dev-centos8 ping]$ cat tcp.js
var raw = require("raw-socket")
var socket = raw.createSocket({protocol: raw.Protocol.TCP})
[stephen@dev-centos8 ping]$ sudo node tcp.js
^C
[stephen@dev-centos8 ping]$
That was on Linux.
Perhaps your platform does not support TCP based raw sockets.
I'm using windows 10 and it turned out that windows has some restrictions
on TCP raw-sockets ...
If i could make a suggestion, that next version would be based on
Thanks for replying and thanks for this fantastic module , wish you all the best
On Wed, 30 Dec 2020, 21:47 Stephen Vickers, notifications@github.com wrote:
Mm, I don't know why this doesn't work for you, it works for me:
[stephen@dev-centos8 ping]$ cat tcp.js
var raw = require("raw-socket")
var socket = raw.createSocket({protocol: raw.Protocol.TCP})
[stephen@dev-centos8 ping]$ sudo node tcp.js ^C [stephen@dev-centos8 ping]$
That was on Linux. Perhaps your platform does not support TCP based raw sockets. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub <https://github.com/nospaceships/node-raw-socket/issues/71#issuecomment-752753531>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AKHVXOG5QHLDW6TJXLCRNE3SXOGXTANCNFSM4VMOIYTA> .
@Zakistt There is already a PCAP node module I think, maybe you could try that, as in the ability to use PCAP might already be available for you.
Yes, i'm aware of that but the pcap module un node is used for capturing data , the pcap.h i talked about is used in c++ to enable bypassing windows restrictions on raw-sockets
On Wed, 30 Dec 2020, 22:23 Stephen Vickers, notifications@github.com wrote:
@Zakistt https://github.com/Zakistt There is already a PCAP node module I think, maybe you could try that, as in the ability to use PCAP might already be available for you.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/nospaceships/node-raw-socket/issues/71#issuecomment-752762715, or unsubscribe https://github.com/notifications/unsubscribe-auth/AKHVXOG4ORFLD6JBPPYIQPDSXOK4VANCNFSM4VMOIYTA .
Do you have a link to this?
I will take a look and see if what would be inolved.
here's the library website https://www.winpcap.org/ which is supported by windows 7 /8 ... but not 10 , for windows 10 refer to http://www.win10pcap.org/ i don't know much about c++ but this https://www.winpcap.org/docs/docs_40_2/html/group__wpcap__tut8.html might be a good guide
On Wed, 30 Dec 2020 at 22:35, Stephen Vickers notifications@github.com wrote:
Do you have a link to this?
I will take a look and see if what would be inolved.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/nospaceships/node-raw-socket/issues/71#issuecomment-752765578, or unsubscribe https://github.com/notifications/unsubscribe-auth/AKHVXOAY4LMOTAQM7XT55HTSXOMILANCNFSM4VMOIYTA .
Long story short ... whenever I use
var socket = raw.createSocket({protocol: raw.Protocol.TCP})
node throws an Error: An invalid argument was supplied. exception I used UDP , ICMP , ICMPv6 and all worked just fine , I don't really know what's the problem ... if anybody can help it would be appreciatedP.S: on the target end all i got was bunch of RDP, SSDP packets , if it means anything ...