Comments (7)
Same problem on Windows...
from node-ip.
Confirm the problem on Windows 10 ...
Not only VM network, but pretty much everything has higher priority than Wifi adapter including VPN
from node-ip.
the same here
from node-ip.
same, running docker and it has a DockerNAT running. ip.address()
and any combination of parameters will return the docker ipv4
from node-ip.
When you are in VPN you are only accessible using VPN internal address, but not a regular network interface address. Correct me if I am not right. So it is a question which behavior is correct.
from node-ip.
No solution in years? Hmm - docker takes priority over Ethernet
from node-ip.
/**
* @param {string} name **Optional** {'public'|'private'},
* Name or security of the network interface like "Docket" | "Wi-Fi",
* if neme set `undefined` return first address of the interface with `ipv4` or loopback address,
* if name set `public` return first public ip address,
* or if name set `private` return first public ip address.
* @param {string} family **Optional** {ipv4|ipv6} IP family of the address (defaults: ipv4).
* @returns {string} Returns the address for the network interface on the current system.
*/
ip.address() // my ip address
ip.address('Wi-Fi') // Obtain Wi-Fi IPV4 address
ip.address('vEthernet (DockerNAT)') // Obtain DocketNAt IPV4 address
ip.address('private') // Obtain private IPV4 address
ip.address('public','ipv6') // Obtain public IPV6 address
from node-ip.
Related Issues (20)
- [BUG] error: var numberOfAddresses = 2 ** (32 - maskLength); SyntaxError: Unexpected token * HOT 3
- Version 2.0.0 is not marked as latest
- Add LICENSE.md
- Private IPv4 mapped regions are only matched in dot-notation
- IPv6 to Int or Long
- V2.0.0 Broke the support for older Node versions
- Found a possible security concern HOT 1
- Incompatibilty with webpack 5 because of missing polyfills
- Project Dead? Does it need more maintainers? HOT 5
- How to verify and validate ip/cidr? HOT 1
- Buffer is not a constructor HOT 1
- isPrivate should include 198.18.0.0/15
- isV6Format returns true with IPv4 input
- 🚨 HIGH Severity Vulnerability: Package unsafe for use as of v1.1.8 🚨 HOT 25
- Semantic of `address()` is wrong HOT 1
- Breaking changes - isPrivate and isPublic now throws HOT 1
- NPM IP package incorrectly identifies some private IP addresses as public HOT 4
- Security Advisory: NPM ip package still incorrectly identifies some private IP addresses as public HOT 11
- Is
- HIGH SEVERITY VULNERABILITY ISSUE HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from node-ip.