Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
@manypkg/get-packages
Advanced tools
> A simple utility to get the packages from a monorepo, whether they're using Yarn, Bolt, Lerna, pnpm or Rush
A simple utility to get the packages from a monorepo, whether they're using Yarn, Bolt, Lerna, pnpm or Rush
This library exports getPackages
and getPackagesSync
. It is intended mostly for use of developers building tools that want to support different kinds of monorepos as an easy way to write tools without having to write tool-specific code. It supports Yarn, Bolt, Lerna, pnpm, Rush and single-package repos(where the only package is the the same as the root package). This library uses @manypkg/find-root
to search up from the directory that's passed to getPackages
or getPackagesSync
to find the project root.
import { getPackages, getPackagesSync } from "@manypkg/get-packages";
const { tool, packages, rootPackage, rootDir } = await getPackages(process.cwd());
const { tool, packages, rootPackage, rootDir } = getPackagesSync(process.cwd());
// From @manypkg/tools
interface Tool {
readonly type: string;
isMonorepoRoot(directory: string): Promise<boolean>;
isMonorepoRootSync(directory: string): boolean;
getPackages(directory: string): Promise<Packages>;
getPackagesSync(directory: string): Packages;
}
interface Package {
packageJson: PackageJSON;
dir: string;
relativeDir: string;
}
interface Packages {
tool: Tool;
packages: Package[];
rootPackage?: Package;
rootDir: string;
}
FAQs
> A simple utility to get the packages from a monorepo, whether they're using Yarn, Bolt, Lerna, pnpm or Rush
The npm package @manypkg/get-packages receives a total of 1,303,808 weekly downloads. As such, @manypkg/get-packages popularity was classified as popular.
We found that @manypkg/get-packages demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers 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
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.