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.
@types/lerna__package
Advanced tools
TypeScript definitions for @lerna/package
npm install --save @types/lerna__package
This package contains type definitions for @lerna/package (https://github.com/lerna/lerna/tree/main/core/package).
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/lerna__package.
import type { Result } from "npm-package-arg";
/**
* Partial package.json representation
*/
export type RawManifest = {
name: string;
version: string;
private?: boolean;
bin?: Record<string, string> | string;
scripts?: Record<string, string>;
dependencies?: Record<string, string>;
devDependencies?: Record<string, string>;
optionalDependencies?: Record<string, string>;
peerDependencies?: Record<string, string>;
publishConfig?: Record<string, string>;
workspaces?: string[] | { packages: string[] };
} & { [key: string]: any };
/**
* Lerna's internal representation of a local package, with
* many values resolved directly from the original JSON.
*/
export class Package {
/**
* Create a Package instance from parameters, possibly reusing existing instance.
* @param ref A path to a package.json file, Package instance, or JSON object
* @param [dir] If `ref` is a JSON object, this is the location of the manifest
*/
static lazy(ref: string | Package | RawManifest, dir?: string): Package;
constructor(pkg: RawManifest, location: string, rootPath?: string);
name: string;
get location(): string;
get private(): boolean;
get resolved(): Result;
get rootPath(): string;
get scripts(): RawManifest["scripts"];
get bin(): RawManifest["scripts"];
get binLocation(): string;
get manifestLocation(): string;
get nodeModuleLocation(): string;
get __isLernaPackage(): boolean;
get version(): string;
set version(v: string);
get contents(): string;
set contents(subDirectory: string);
get dependencies(): RawManifest["dependencies"];
get devDependencies(): RawManifest["devDependencies"];
get optionalDependencies(): RawManifest["optionalDependencies"];
get peerDependencies(): RawManifest["peerDependencies"];
get<K extends keyof RawManifest | string>(key: K): RawManifest[K];
set<K extends keyof RawManifest | string>(key: K, val: RawManifest[K]): this;
/**
* Provide shallow copy for munging elsewhere
*/
toJSON(): RawManifest;
/**
* Refresh internal state from disk (e.g., changed by external lifecycles)
*/
refresh(): Promise<this>;
/**
* Write manifest changes to disk
*/
serialize(): Promise<this>;
/**
* Mutate local dependency spec according to type
*/
updateLocalDependency(resolved: Result, depVersion: string, savePrefix: string): void;
}
These definitions were written by DonMahallem.
FAQs
TypeScript definitions for @lerna/package
We found that @types/lerna__package 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
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.