{"id":13841144,"url":"https://github.com/ipipdotnet/ipdb-go","last_synced_at":"2026-01-25T10:19:53.789Z","repository":{"id":39441788,"uuid":"144925286","full_name":"ipipdotnet/ipdb-go","owner":"ipipdotnet","description":"IPIP.net officially supported IP database ipdb format parsing library","archived":false,"fork":false,"pushed_at":"2024-10-09T06:11:53.000Z","size":1352,"stargazers_count":318,"open_issues_count":3,"forks_count":50,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-08-13T16:58:48.946Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ipipdotnet.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-08-16T02:18:09.000Z","updated_at":"2025-08-11T05:58:47.000Z","dependencies_parsed_at":"2024-03-21T09:42:21.064Z","dependency_job_id":null,"html_url":"https://github.com/ipipdotnet/ipdb-go","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"purl":"pkg:github/ipipdotnet/ipdb-go","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipipdotnet%2Fipdb-go","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipipdotnet%2Fipdb-go/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipipdotnet%2Fipdb-go/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipipdotnet%2Fipdb-go/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ipipdotnet","download_url":"https://codeload.github.com/ipipdotnet/ipdb-go/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipipdotnet%2Fipdb-go/sbom","scorecard":{"id":493878,"data":{"date":"2025-08-11","repo":{"name":"github.com/ipipdotnet/ipdb-go","commit":"a6a2f5d964c9a12f53616571fd62607a92c6f508"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3,"checks":[{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Code-Review","score":0,"reason":"Found 0/30 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"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"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: Apache License 2.0: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-19T19:56:44.912Z","repository_id":39441788,"created_at":"2025-08-19T19:56:44.912Z","updated_at":"2025-08-19T19:56:44.912Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28751421,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-25T09:58:17.166Z","status":"ssl_error","status_checked_at":"2026-01-25T09:55:56.104Z","response_time":113,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-04T17:01:03.265Z","updated_at":"2026-01-25T10:19:53.773Z","avatar_url":"https://github.com/ipipdotnet.png","language":"Go","funding_links":[],"categories":["Go (531)","Go"],"sub_categories":[],"readme":"# ipdb-go\n[![TravisCI Build Status](https://travis-ci.org/ipipdotnet/ipdb-go.svg?branch=master)](https://travis-ci.org/ipipdotnet/ipdb-go)\n[![Coverage Status](https://coveralls.io/repos/github/ipipdotnet/ipdb-go/badge.svg?branch=master)](https://coveralls.io/github/ipipdotnet/ipdb-go?branch=master)\n[![IPDB Database API Document](https://godoc.org/github.com/ipipdotnet/ipdb-go?status.svg)](https://godoc.org/github.com/ipipdotnet/ipdb-go)\n\nIPIP.net officially supported IP database ipdb format parsing library\n\n# Installing\n\u003ccode\u003e\n    go get github.com/ipipdotnet/ipdb-go\n\u003c/code\u003e\n\n# Code Example\n\n## 支持IPDB格式\n\u003cpre\u003e\n\u003ccode\u003e\npackage main\n\nimport (\n\t\"github.com/ipipdotnet/ipdb-go\"\n\t\"fmt\"\n\t\"log\"\n)\n\nfunc main() {\n\tdb, err := ipdb.NewCity(\"/path/to/city.ipv4.ipdb\")\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n\n\tdb.Reload(\"/path/to/city.ipv4.ipdb\") // 更新 ipdb 文件后可调用 Reload 方法重新加载内容\n\n\tfmt.Println(db.IsIPv4()) // check database support ip type\n\tfmt.Println(db.IsIPv6()) // check database support ip type\n\tfmt.Println(db.BuildTime()) // database build time\n\tfmt.Println(db.Languages()) // database support language\n\tfmt.Println(db.Fields()) // database support fields\n\n\tfmt.Println(db.FindInfo(\"2001:250:200::\", \"CN\")) // return CityInfo\n\tfmt.Println(db.Find(\"1.1.1.1\", \"CN\")) // return []string\n\tfmt.Println(db.FindMap(\"118.28.8.8\", \"CN\")) // return map[string]string\n\tfmt.Println(db.FindInfo(\"127.0.0.1\", \"CN\")) // return CityInfo\n\n\tfmt.Println()\n}\n\u003c/code\u003e\n\u003c/pre\u003e\n## 数据字段说明\n\u003cpre\u003e\ncountry_name : 国家名字 \nregion_name  : 省名字 \ncity_name    : 城市名字 \nowner_domain : 所有者  \nisp_domain  : 运营商 \nlatitude  :  纬度  \nlongitude : 经度  \ntimezone : 时区    \nutc_offset : UTC时区   \nchina_admin_code : 中国行政区划代码 \nidd_code : 国家电话号码前缀 \ncountry_code : 国家2位代码\ncontinent_code : 大洲代码   \nidc : IDC |  VPN  \nbase_station : 基站 | WIFI \ncountry_code3 : 国家3位代码 \neuropean_union : 是否为欧盟成员国： 1 | 0 \ncurrency_code : 当前国家货币代码  \ncurrency_name : 当前国家货币名称  \nanycast : ANYCAST   \n\u003c/pre\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fipipdotnet%2Fipdb-go","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fipipdotnet%2Fipdb-go","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fipipdotnet%2Fipdb-go/lists"}