
Security News
/Research
Wallet-Draining npm Package Impersonates Nodemailer to Hijack Crypto Transactions
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
RFC 6455 Compliant WebSocket client for ruby. See report for compliance: View Autobahn Report
$ gem install em-ws-client
require "em-ws-client"
EM.run do
# Establish the connection
ws = EM::WebSocketClient.new("ws://server/path")
# Simple echo
# If the binary flag is set, then
# the message is a string encoded as ASCII_8BIT
# otherwise it's encoded as UTF-8
ws.onmessage do |msg, binary|
conn.send_message msg, binary
end
# Send a text message
ws.send_message "hello!"
# Send a binary message
ws.send_message [2,3,4].pack("NnC"), true
end
require "em-ws-client"
EM.run do
# Establish the connection
ws = EM::WebSocketClient.new("ws://server/path")
ws.onopen do
# fire away
end
ws.onclose do |code, explain|
# could be good, or not
end
ws.onping do |msg|
# we automatically pong, but this is here
end
ws.onerror do |code, message|
# errors close the connection (per spec), but you can at
# least learn why with this
end
ws.ping "ping"
ws.onpong do |msg|
# mes -> what you called ping with
end
end
Thoughts appreciated.
# streaming in
ws.onstream do |stream|
# stream started
# stream.binary?
stream.ondata do |chunk|
# ...
end
stream.onclose do
# stream finished
end
end
# streaming out
ws.stream(true) do |stream|
100.times do |i|
stream << [i].pack("N")
end
stream.close
end
FAQs
Unknown package
We found that em-ws-client demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
/Research
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
Security News
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.
Security News
/Research
Malicious Nx npm versions stole secrets and wallet info using AI CLI tools; Socket’s AI scanner detected the supply chain attack and flagged the malware.