Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
url-ok
is a HTTP and HTTPS status checker for URLs. The default timeout is 120 seconds at
which point it will abort the checks and the process will have an exit code of 1. If all
the checks are successfull (success is defined as returning 200), the process will have an
exit code of 0.
If a URL cannot be reached, it will continue to try to reach the URL every second up to the timeout. For HTTP, it uses a HEAD request while for HTTPS it uses GET.
--timeout to set a specific timeout in seconds (default 120 seconds)
--interval to set a specific interval between attempts (defaults to one second)
--verbose to enable verbose output
--debug to enable extremely verbose output
# url-ok http://www.google.com/ http://www.microsoft.com/ http://www.apple.com/ --verbose
Waiting up to 120 seconds for response(s).
Requesting http://www.google.com/
Requesting http://www.microsoft.com/
Requesting http://www.apple.com/
200 'http://www.google.com/'
200 'http://www.apple.com/'
200 'http://www.microsoft.com/'
Received successful response for all URLs.
# echo $?
0
# url-ok http://no.such.server.localhost/ --timeout 10 --interval 2 --verbose
Waiting up to 10 seconds for response(s).
Requesting http://no.such.server.localhost/
Aborting after 10 seconds!
At least one URL failed to respond!
# echo $?
1
# url-ok http://no.such.server.localhost/ --timeout 10 --interval 2 --verbose --debug
Waiting up to 10 seconds for response(s).
Requesting http://no.such.server.localhost/
DEBUG: requesting http://no.such.server.localhost/
DEBUG: error http://no.such.server.localhost/ Error: getaddrinfo ENOTFOUND
DEBUG: requesting http://no.such.server.localhost/
DEBUG: error http://no.such.server.localhost/ Error: getaddrinfo ENOTFOUND
DEBUG: requesting http://no.such.server.localhost/
DEBUG: error http://no.such.server.localhost/ Error: getaddrinfo ENOTFOUND
DEBUG: requesting http://no.such.server.localhost/
DEBUG: error http://no.such.server.localhost/ Error: getaddrinfo ENOTFOUND
DEBUG: requesting http://no.such.server.localhost/
DEBUG: error http://no.such.server.localhost/ Error: getaddrinfo ENOTFOUND
Aborting after 10 seconds!
At least one URL failed to respond!
npm install -g url-ok
FAQs
check http or https status for number of URLs with timeout
The npm package url-ok receives a total of 0 weekly downloads. As such, url-ok popularity was classified as not popular.
We found that url-ok 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.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.