
Research
Malicious npm Packages Impersonate Flashbots SDKs, Targeting Ethereum Wallet Credentials
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
href-checker
Advanced tools
Hyperlink checker for HTML pages which checks href attributes by actually visiting linked pages and also checking existence of URL fragments.
Hyperlink checker for HTML pages which checks href attributes by visiting linked pages. Also checks existence of URL fragments.
$ npm install -g href-checker
$ href-checker https://example.com
# or, with npx
$ npx href-checker https://example.com
# See available options and examples
$ href-checker --help
This package relies on puppeteer. If you already have Chromium installed (e.g. own your computer, or CI like GitHub Actions), you can avoid installing another copy of Chromium by setting following two environment variables (before installation and as well as usage):
export PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=1
export PUPPETEER_EXECUTABLE_PATH=/usr/bin/google-chrome
# Replace the path above with your actual Chromium browser path. Some common values might be:
# on MacOS: "/Applications/Google Chrome.app/Contents/MacOS/Google chrome"
# on Ubuntu: /usr/bin/google-chrome
# on Windows 10: C:\Users\USER\AppData\Local\Google\Chrome\Application\chome.exe
npm install href-checker
const { checkLinks } = require("href-checker");
for await (const result of checkLinks(url, options)) {
console.log(result.type);
// -> "samePage", "sameSite", "offSite"
console.log(result.input);
// -> {
// "link": string, // URL of page being visited.
// "count": number, // Number of occurences of URL.
// }
console.log(result.output);
// -> {
// "pageExists": boolean, // Page resolved with HTTP 20* code.
// "status": number, // HTTP status code.
// "fragExists": boolean, // Element corresponding to fragment exists.
// "error": Error, // Error, if any.
// }
}
See available options.
TypeScript declarations are included in the package.
Following is an example how to use this tool in a GitHub Action:
jobs:
name: Validate Hyperlinks
runs-on: ubuntu-latest
steps:
- run: npx href-checker https://example.com
env:
PUPPETEER_SKIP_CHROMIUM_DOWNLOAD: 1
PUPPETEER_EXECUTABLE_PATH: /usr/bin/google-chrome
FAQs
Hyperlink checker for HTML pages which checks href attributes by actually visiting linked pages and also checking existence of URL fragments.
The npm package href-checker receives a total of 7 weekly downloads. As such, href-checker popularity was classified as not popular.
We found that href-checker 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
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
Security News
Following last week’s supply chain attack, Nx published findings on the GitHub Actions exploit and moved npm publishing to Trusted Publishers.