Installations
npm install micro-geoip-lite
Developer Guide
Typescript
No
Module System
CommonJS
Node Version
12.22.12
NPM Version
6.14.16
Score
48.8
Supply Chain
73.7
Quality
76.2
Maintenance
100
Vulnerability
100
License
Releases
Contributors
Unable to fetch Contributors
Languages
JavaScript (100%)
Developer
Download Statistics
Total Downloads
50,856
Last Day
41
Last Week
124
Last Month
393
Last Year
13,244
GitHub Statistics
5 Stars
30 Commits
3 Watching
3 Branches
1 Contributors
Bundle Size
7.24 kB
Minified
2.80 kB
Minified + Gzipped
Package Meta Information
Latest Version
1.0.0
Package Id
micro-geoip-lite@1.0.0
Unpacked Size
9.40 kB
Size
3.83 kB
File Count
6
NPM Version
6.14.16
Node Version
12.22.12
Publised On
17 Jul 2024
Total Downloads
Cumulative downloads
Total Downloads
50,856
Last day
70.8%
41
Compared to previous day
Last week
25.3%
124
Compared to previous week
Last month
-20%
393
Compared to previous month
Last year
29.5%
13,244
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
Dependencies
2
Dev Dependencies
22
micro-geoip-lite
🌍 An extremely lite geoip decoder utilizing the micro-geoip-lite microservice to geo decode the IP info via an https request - the microservice utilizes MaxMind's IP info dataset.
Installation
- Run
yarn add micro-geoip-lite
,npm i micro-geoip-lite
Usage
-
params:
- ip?: string - optional, defaults to client's IP
- options?:
1{ 2 serviceUrl?: string, // called instead of the default provider URL. You can also provide this via an env var `REACT_APP_SERVICE_URL_GEOIP` or `SERVICE_URL_GEOIP` 3 timeout?: string, // timeout in ms 4}
-
returns:
1{ 2 ip: string, // if ip param was not provided, this defaults to request.ip 3 range: [ number, number ], 4 country: string, 5 region: string, 6 eu: string, // '0' or '1' 7 timezone: string, 8 city: string, 9 ll: [ number, number ], 10 metro: number, 11 area: number, 12 // error: 'Error text', // only exists if an error happened 13}
-
example - fetch own ip info:
1import geodecodeIp from 'micro-geoip-lite'; 2 3const result = await geodecodeIp(); 4 5{ 6 ip: '207.97.227.239', // if ip param was not provided, this defaults to request.ip 7 range: [ 3479298048, 3479300095 ], 8 country: 'US', 9 region: 'TX', 10 eu: '0', 11 timezone: 'America/Chicago', 12 city: 'San Antonio', 13 ll: [ 29.4969, -98.4032 ], 14 metro: 641, 15 area: 1000, 16 // error: 'Error text', // only exists if an error happened 17}
-
example - fetch specific ip info:
1import geodecodeIp from 'micro-geoip-lite'; 2 3const result = await geodecodeIp('207.97.227.239');
No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
license file detected
Details
- Info: project has a license file: LICENSE:0
- Info: FSF or OSI recognized license: MIT License: LICENSE:0
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
Found 0/16 approved changesets -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
- Warn: no topLevel permission defined: .github/workflows/label-assign-creator-reviewers.yml:1
- Warn: no topLevel permission defined: .github/workflows/test-publish.yml:1
- Info: no jobLevel write permissions found
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/label-assign-creator-reviewers.yml:13: update your workflow using https://app.stepsecurity.io/secureworkflow/a-tokyo/micro-geoip-lite-js/label-assign-creator-reviewers.yml/main?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/label-assign-creator-reviewers.yml:17: update your workflow using https://app.stepsecurity.io/secureworkflow/a-tokyo/micro-geoip-lite-js/label-assign-creator-reviewers.yml/main?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/label-assign-creator-reviewers.yml:21: update your workflow using https://app.stepsecurity.io/secureworkflow/a-tokyo/micro-geoip-lite-js/label-assign-creator-reviewers.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test-publish.yml:14: update your workflow using https://app.stepsecurity.io/secureworkflow/a-tokyo/micro-geoip-lite-js/test-publish.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test-publish.yml:18: update your workflow using https://app.stepsecurity.io/secureworkflow/a-tokyo/micro-geoip-lite-js/test-publish.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test-publish.yml:24: update your workflow using https://app.stepsecurity.io/secureworkflow/a-tokyo/micro-geoip-lite-js/test-publish.yml/main?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/test-publish.yml:34: update your workflow using https://app.stepsecurity.io/secureworkflow/a-tokyo/micro-geoip-lite-js/test-publish.yml/main?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/test-publish.yml:47: update your workflow using https://app.stepsecurity.io/secureworkflow/a-tokyo/micro-geoip-lite-js/test-publish.yml/main?enable=pin
- Info: 0 out of 3 GitHub-owned GitHubAction dependencies pinned
- Info: 0 out of 5 third-party GitHubAction dependencies pinned
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
- Warn: no security policy file detected
- Warn: no security file to analyze
- Warn: no security file to analyze
- Warn: no security file to analyze
Reason
project is not fuzzed
Details
- Warn: no fuzzer integrations found
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
- Warn: 0 commits out of 16 are checked with a SAST tool
Reason
27 existing vulnerabilities detected
Details
- Warn: Project is vulnerable to: GHSA-67hx-6x53-jw92
- Warn: Project is vulnerable to: GHSA-v88g-cgmw-v5xw
- Warn: Project is vulnerable to: GHSA-93q8-gq69-wqmw
- Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg
- Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275
- Warn: Project is vulnerable to: GHSA-gxpj-cx7g-858c
- Warn: Project is vulnerable to: GHSA-4gmj-3p3h-gm8h
- Warn: Project is vulnerable to: GHSA-ww39-953v-wcq6
- Warn: Project is vulnerable to: GHSA-896r-f27r-55mw
- Warn: Project is vulnerable to: GHSA-282f-qqgm-c34q
- Warn: Project is vulnerable to: GHSA-fvqr-27wr-82fm
- Warn: Project is vulnerable to: GHSA-4xc9-xhrj-v574
- Warn: Project is vulnerable to: GHSA-x5rq-j2xg-h7qm
- Warn: Project is vulnerable to: GHSA-jf85-cpcp-j695
- Warn: Project is vulnerable to: GHSA-p6mc-m468-83gw
- Warn: Project is vulnerable to: GHSA-29mw-wpgm-hmr9
- Warn: Project is vulnerable to: GHSA-35jh-r3h4-6jhm
- Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv
- Warn: Project is vulnerable to: GHSA-5fw9-fq32-wv5p
- Warn: Project is vulnerable to: GHSA-p8p7-x288-28g6
- Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw
- Warn: Project is vulnerable to: GHSA-44c6-4v22-4mhx
- Warn: Project is vulnerable to: GHSA-4x5v-gmq8-25ch
- Warn: Project is vulnerable to: GHSA-4rq4-32rv-6wp6
- Warn: Project is vulnerable to: GHSA-64g7-mvw6-v9qj
- Warn: Project is vulnerable to: GHSA-72xf-g2v4-qvf3
- Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q
Score
2.8
/10
Last Scanned on 2025-01-27
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