A Node JS implementation of the IPQualityScore flat file IP reputation database reader.
npm install node_js_ipqs_db_reader
The IPQS NodeJS DB reader allows you to read our flat file databases and get started implimenting our proxy detection easily.
Installation can be achieved via npm or via direct inclusion of the libraries provided.
npm install node_js_ipqs_db_reader
Using our flat file database system to lookup an IP address is simple:
let db = DBReader.Open("IPQualityScore-IP-Reputation-Database-IPv4.ipqs");
db.ready.then(async (success) => {
let record = db.fetch("8.8.0.0"); // IPQSRecord object.
record.ready.then(() => {
console.log(record.country);
});
});
Depending on which database file you receive some of these fields may be unavailable. If the field in question is unavailable in your database it will default to null.
| Field | Type | Description | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| record.isProxy | bool | Is this IP address suspected to be a proxy? (SOCKS, Elite, Anonymous, VPN, Tor, etc.) | ||||||||||||
| record.isVPN | bool | Is this IP suspected of being a VPN connection? This can include data center ranges which can become active VPNs at any time. The "proxy" status will always be true when this value is true. | ||||||||||||
| record.isTOR | bool | Is this IP suspected of being a TOR connection? This can include previously active TOR nodes and exits which can become active TOR exits at any time. The "proxy" status will always be true when this value is true. | ||||||||||||
| record.isCrawler | bool | Is this IP associated with being a confirmed crawler from a mainstream search engine such as Googlebot, Bingbot, Yandex, etc. based on hostname or IP address verification. | ||||||||||||
| record.isBot | bool | Indicates if bots or non-human traffic has recently used this IP address to engage in automated fraudulent behavior. Provides stronger confidence that the IP address is suspicious. | ||||||||||||
| record.recentAbuse | bool | This value will indicate if there has been any recently verified abuse across our network for this IP address. Abuse could be a confirmed chargeback, compromised device, fake app install, or similar malicious behavior within the past few days. | ||||||||||||
| record.isBlacklisted | bool | This value will indicate if the IP has been blacklisted by any 3rd party agency for spam, abuse or fraud. | ||||||||||||
| record.isPrivate | bool | This value will indicate if the IP is a private, nonrouteable IP address. | ||||||||||||
| record.isMobile | bool | This value will indicate if the IP is likely owned by a mobile carrier. | ||||||||||||
| record.hasOpenPorts | bool | This value will indicate if the IP has recently had open (listening) ports. | ||||||||||||
| record.isHostingProvider | bool | This value will indicate if the IP is likely owned by a hosting provider or is leased to a hosting company. | ||||||||||||
| record.activeVPN | bool | Identifies active VPN connections used by popular VPN services and private VPN servers. | ||||||||||||
| record.activeTOR | bool | Identifies active TOR exits on the TOR network. | ||||||||||||
| record.publicAccessPoint | bool | Indicates if this IP is likely to be a public access point such as a coffee shop, college or library. | ||||||||||||
| record.connectionType.raw | int |
|
||||||||||||
| record.connectionType.toString() | string |
|
||||||||||||
| record.abusevelocity.raw | int |
|
||||||||||||
| record.abuseVelocity.toString() | int |
|
||||||||||||
| record.country | string |
|
||||||||||||
| record.city | string |
|
||||||||||||
| record.ISP | string |
|
||||||||||||
| record.organization | string |
|
||||||||||||
| record.ASN | int |
|
||||||||||||
| record.timezone | string |
|
||||||||||||
| record.latitude | float |
|
||||||||||||
| record.longitude | float |
|
||||||||||||
| record.fraudScore.getFraudScore(level) | int |
|
Each database only holds either IPv4 or IPv6 data. Therefore you may need two instances of the reader available depending on your use case.