Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Hold on, we're currently generating a fresh version of this report
Generated on Apr 8, 2024 via pnpm

ip 2.0.0

[![](https://badge.fury.io/js/ip.svg)](https://www.npmjs.com/package/ip)
Package summary
Share
2
issues
2
moderate severity
vulnerability
2
1
license
1
MIT
Package created
15 Aug 2012
Version published
10 May 2022
Maintainers
5
Total deps
1
Direct deps
0
License
MIT

Issues

2

2 moderate severity issues

moderate
Recommendation: Upgrade to version 2.0.1 or later
via: ip@2.0.0
Recommendation: Upgrade to version 2.0.1 or later
via: ip@2.0.0
Collapse
Expand

Licenses

MIT License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
sublicense
private-use
Cannot
hold-liable
Must
include-copyright
include-license
1 Packages, Including:
ip@2.0.0
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

0
All Dependencies CSV
β“˜ This is a list of ip 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities

Visualizations

Frequently Asked Questions

What does ip do?

The "ip" npm package provides utilities for handling IP addresses in Node.js. It allows users to perform operations like getting an IP address, comparing IP addresses, validating IP addresses, as well as advanced operations like IP masking, subnet information extraction, and IP range checking.

How do you use ip?

To use the "ip" npm package, first, install it using your npm package manager with the command npm install ip or clone it from its GitHub repository with git clone https://github.com/indutny/node-ip.git.

Then, require the package in your JavaScript file using the require() function and access its methods as shown below:

var ip = require('ip');

console.log(ip.address()); // displays your ip address
console.log(ip.isEqual('::1', '::0:1')); // compares IP addresses, returns true
console.log(ip.toBuffer('127.0.0.1')); // converts IP address to buffer
console.log(ip.isPrivate('127.0.0.1')); // checks if IP address is private, returns true
//...additional features...

Where are the ip docs?

The documentation for the "ip" package is available in the README file in its source code repository on GitHub. This README contains a comprehensive guide on installing and using the package, with examples of all its utility functions.