Gathering detailed insights and metrics for @tahul/whoiser
Gathering detailed insights and metrics for @tahul/whoiser
Gathering detailed insights and metrics for @tahul/whoiser
Gathering detailed insights and metrics for @tahul/whoiser
npm install @tahul/whoiser
Typescript
Module System
Node Version
NPM Version
73
Supply Chain
98.8
Quality
79.8
Maintenance
100
Vulnerability
99.6
License
JavaScript (100%)
Total Downloads
2,958
Last Day
4
Last Week
34
Last Month
189
Last Year
2,958
222 Stars
259 Commits
33 Forks
7 Watching
2 Branches
15 Contributors
Latest Version
2.0.4
Package Id
@tahul/whoiser@2.0.4
Unpacked Size
59.47 kB
Size
15.72 kB
File Count
8
NPM Version
10.1.0
Node Version
20.7.0
Publised On
24 Mar 2024
Cumulative downloads
Total Downloads
Last day
100%
4
Compared to previous day
Last week
-47.7%
34
Compared to previous week
Last month
-20.6%
189
Compared to previous month
Last year
0%
2,958
Compared to previous year
whoiser is a WHOIS client for Node.js that helps with querying WHOIS servers for TLDs, domain names, AS numbers and IPs.
Has support for auto-discovery WHOIS servers for TLDs and IPs allocators, making it easy to get WHOIS info with a single call like whoiser('google.com')
or whoiser('1.1.1.1')
.
Applies minimal parsing to results, returning same data format from different WHOIS servers.
→ See it in action here https://dmns.app
npm i whoiser
The library has a simple API.
Use whoiser(query)
with any query you would want OR use specific functions with options like whoiser.domain(domain, {options})
, whoiser.ip(ip, {options})
1const whoiser = require('whoiser') 2 3const domainWhois = whoiser('google.com') 4const tldWhois = whoiser('.net') 5const ipWhois = whoiser('1.1.1.1')
whoiser(query, options)
- Get WHOIS data for any internet addresswhoiser.domain(domain, options)
- Get parsed WHOIS data for a domainwhoiser.tld(tld, options)
- Get WHOIS data for a TLDwhoiser.asn(asn, options)
- Get WHOIS data for an AS numberwhoiser.ip(ip, options)
- Get WHOIS data for a IPwhoiser.allTlds
- Returns a list of all TLDs, downloaded from IANAwhoiser.query(options)
- Query a WHOIS server for dataGet WHOIS info for domains.
whoiser.domain(domain, options): Promise<Object<whoisServer>>
domain
- Domain name, excluding any subdomain. Ex: 'google.com'options
- Object of options to use, all optional:
host
- WHOIS server to query. Default: WHOIS server from IANAtimeout
- WHOIS server request timeout in ms. Default: 1500follow
- How many WHOIS server to query. 1 = registry server (faster), 2 = registry + registrar (more domain details). Default: 2raw
- Return the raw WHOIS result in response. Added to __raw
ignorePrivacy
- Show or hide the WHOIS protected data from response, accepts boolean. Default: true1const whoiser = require('whoiser'); 2 3(async () => { 4 5 // WHOIS info from Registry (Verisign) AND Registrar (MarkMonitor) whois servers 6 let domainInfo = await whoiser('google.com') 7 8 // OR with options for whois server and how many WHOIS servers to query 9 let domainInfo2 = await whoiser.domain('blog.google', {host: 'whois.nic.google', follow: 1}) 10 11 console.log(domainInfo, domainInfo2) 12})();
Returns a promise which resolves with an Object
of WHOIS servers checked:
1{ 2 "whois.verisign-grs.com": { 3 "Domain Name": "GOOGLE.COM", 4 "Registrar WHOIS Server": "whois.markmonitor.com", 5 ... 6 }, 7 "whois.markmonitor.com": { 8 "Domain Name": "google.com", 9 "Creation Date": "1997-09-15T00:00:00-0700", 10 "Expiry Date": "2020-09-13T21:00:00-0700", 11 "Registrar": "MarkMonitor, Inc.", 12 "Domain Status": [ 13 "clientUpdateProhibited", 14 "clientTransferProhibited" 15 ], 16 ... 17 "Name Server": [ 18 "ns1.google.com", 19 "ns2.google.com" 20 ], 21 "text": [ 22 "For more information on WHOIS status codes, please visit:", 23 ... 24 ] 25 } 26}
Get WHOIS info for IPs
whoiser.ip(ip, options): Promise<Object>
ip
- IP. Ex: '1.1.1.1'options
- Object of options to use, all optional:
host
- WHOIS server to query. Default: WHOIS server from IANAtimeout
- WHOIS server request timeout in ms. Default: 1500raw
- Return the raw WHOIS result in response. Added to __raw
1const whoiser = require('whoiser'); 2 3(async () => { 4 5 // WHOIS info with auto-discovering for WHOIS server 6 let ipInfo = await whoiser('1.1.1.1') 7 8 // OR with options for whois server 9 let ipInfo2 = await whoiser.ip('8.8.8.8', {host: 'whois.arin.net'}) 10 11 console.log(ipInfo, ipInfo2) 12})();
Returns a promise which resolves with an Array
of WHOIS info lines:
1{ 2 range: '2606:4700:: - 2606:4700:FFFF:FFFF:FFFF:FFFF:FFFF:FFFF', 3 route: '2606:4700::/32', 4 NetName: 'CLOUDFLARENET', 5 NetHandle: 'NET6-2606-4700-1', 6 Parent: 'NET6-2600 (NET6-2600-1)', 7 NetType: 'Direct Allocation', 8 asn: 'AS13335', 9 Organization: 'Cloudflare, Inc. (CLOUD14)', 10 RegDate: '2011-11-01', 11 Updated: '2017-02-17', 12 Comment: 'All Cloudflare abuse reporting can be done via https://www.cloudflare.com/abuse', 13}
Get WHOIS info for an AS number
whoiser.asn(asn, options): Promise<Object>
asn
- ASN. Ex: 'AS15169' or 15169
options
- Object of options to use, all optional:
host
- WHOIS server to query. Default: WHOIS server from IANAtimeout
- WHOIS server request timeout in ms. Default: 1500raw
- Return the raw WHOIS result in response. Added to __raw
1const whoiser = require('whoiser'); 2 3(async () => { 4 5 // WHOIS info for ASN15169 6 let whois = await whoiser.asn(15169) 7 8 console.log(whois) 9})();
Returns a promise which resolves with an Object
of WHOIS info:
1{ 2 ASNumber: '15169', 3 ASName: 'GOOGLE', 4 ASHandle: 'AS15169', 5 RegDate: '2000-03-30', 6 Updated: '2012-02-24', 7 Ref: 'https://rdap.arin.net/registry/autnum/15169', 8}
Aiming to have these features:
whoiser.query()
whoiser.tld()
whoiser.domain()
whoiser.ip()
whoiser.asn()
.ch
- WHOIS server for .ch doesn't return WHOIS info, works only in browser https://www.nic.ch/whois/. This library can be used only to check .ch domain availability, example here https://runkit.com/andreiigna/5efdeaa8e4f2d8001a00312dPlease report any issues here on GitHub. Any contributions are welcome
Copyright (c) Andrei Igna, Layered
No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
0 existing vulnerabilities detected
Reason
security policy file detected
Details
Reason
Found 4/20 approved changesets -- score normalized to 2
Reason
dependency not pinned by hash detected -- score normalized to 2
Details
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
project is not fuzzed
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Score
Last Scanned on 2024-12-16
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More