{"id":35535780,"url":"https://github.com/aboutcode-org/purlvalidator-go","last_synced_at":"2026-04-06T03:11:06.136Z","repository":{"id":324776789,"uuid":"1095100795","full_name":"aboutcode-org/purlvalidator-go","owner":"aboutcode-org","description":"Offline Package URL validator using a prebuilt FST of known packages.","archived":false,"fork":false,"pushed_at":"2026-03-26T01:49:28.000Z","size":1139821,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-26T07:05:36.520Z","etag":null,"topics":["airgapped","fst","packageurl","purl","sbom-tool"],"latest_commit_sha":null,"homepage":"https://pkg.go.dev/github.com/aboutcode-org/purlvalidator-go","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/aboutcode-org.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":"aboutcode-org","open_collective":"aboutcode","custom":"https://causes.benevity.org/causes/056-5528680976845_a486"}},"created_at":"2025-11-12T15:37:51.000Z","updated_at":"2026-03-26T01:49:30.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/aboutcode-org/purlvalidator-go","commit_stats":null,"previous_names":["aboutcode-org/purlvalidator-go"],"tags_count":66,"template":false,"template_full_name":null,"purl":"pkg:github/aboutcode-org/purlvalidator-go","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aboutcode-org%2Fpurlvalidator-go","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aboutcode-org%2Fpurlvalidator-go/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aboutcode-org%2Fpurlvalidator-go/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aboutcode-org%2Fpurlvalidator-go/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aboutcode-org","download_url":"https://codeload.github.com/aboutcode-org/purlvalidator-go/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aboutcode-org%2Fpurlvalidator-go/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31269462,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-01T06:57:45.811Z","status":"ssl_error","status_checked_at":"2026-04-01T06:57:42.389Z","response_time":53,"last_error":"SSL_read: 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":["airgapped","fst","packageurl","purl","sbom-tool"],"created_at":"2026-01-04T03:20:32.973Z","updated_at":"2026-04-02T00:28:08.545Z","avatar_url":"https://github.com/aboutcode-org.png","language":"Go","readme":"# purlvalidator\n\n[![License](https://img.shields.io/badge/License-Apache--2.0-blue.svg?style=for-the-badge)](https://opensource.org/licenses/Apache-2.0)\n[![Version](https://img.shields.io/github/v/release/aboutcode-org/purlvalidator-go?style=for-the-badge)](https://github.com/aboutcode-org/purlvalidator-go/releases)\n[![Test](https://img.shields.io/github/actions/workflow/status/aboutcode-org/purlvalidator-go/ci.yml?style=for-the-badge\u0026logo=github)](https://github.com/aboutcode-org/purlvalidator-go/actions)\n\n**purlvalidator** is a Go library for validating [Package-URLs (PURLs)](https://github.com/package-url/purl-spec). It works fully offline, including in **air-gapped** or **restricted environments**, and answers one key question: **Does the package this PURL represents actually exist?**\n\n## How It Works?\n\n**purlvalidator** is shipped with a pre-built FST (Finite State Transducer), a set of compact automata containing latest Package-URLs mined by the MineCode[^1]. Library uses this FST to perform lookups and confirm whether the **base PURL**[^2] exists.\n\n## Currently Supported Ecosystems\n\n- **apk**\n- **cargo**\n- **composer**\n- **conan**\n- **cpan**\n- **cran**\n- **debain**\n- **maven**\n- **npm**\n- **nuget**\n- **pypi**\n- **swift**\n\n## Usage\n\nAdd `purlvalidator` as dependency in your go.mod\n\n```bash\nrequire github.com/aboutcode-org/purlvalidator-go v1.0.0\n```\n\nUse it in your code like this:\n\n```go\nimport \"github.com/aboutcode-org/purlvalidator-go\"\n\nfunc main() {\n\tresult, e := purlvalidator.Validate(\"pkg:nuget/FluentValidation\");\n\tif err != nil {\n\t\tpanic(err)\n\t}\n}\n```\n\nExamples and errors:\n```go\n// This will return: true\npurlvalidator.Validate(\"pkg:nuget/FluentValidation\");\n\n// This will return: false\npurlvalidator.Validate(\"pkg:nuget/non-existent-foo-bar\");\n\n\n// This will return an error: \"only base PURL is supported (no version, qualifiers, or subpath)\"\npurlvalidator.Validate(\"pkg:nuget/FluentValidation@10.2.3\");\n\n// This will return an error: \"purl scheme is not \\\"pkg\\\": \\\"test\\\"\"\npurlvalidator.Validate(\"test:nuget/FluentValidation\");\n\n```\n\n## How to get latest Package-URL data?\n\nA patch release is published daily with the latest FST generated from newly mined package-urls.\n\n\n## Contribution\n\nWe welcome contributions from the community! If you find a bug or have an idea for a new feature, please open an issue on the GitHub repository. If you want to contribute code, you can fork the repository, make your changes, and submit a pull request.\n\n* Please try to write a good commit message, see [good commit message wiki](https://aboutcode.readthedocs.io/en/latest/contributing/writing_good_commit_messages.html).\n* Add DCO `Sign Off` to your commits.\n\n## Development Setup\n\nRun these commands, starting from a git clone of [https://github.com/aboutcode-org/purlvalidator-go.git](https://github.com/aboutcode-org/purlvalidator-go.git)\n\nGenerate FST:\n\n```bash\nmake build-fst\n```\n\nRun tests:\n\n```bash\nmake test\n```\n\nFix formatting and linting:\n\n```bash\nmake valid\n```\n\n## License\n\nSPDX-License-Identifier: Apache-2.0\n\npurl-validator is licensed under Apache License version 2.0.\n\n```text\nYou may not use this software except in compliance with the License.\nYou may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n```\n\n[^1]: MineCode continuously collects package metadata from various package ecosystems to maintain an up-to-date catalog of known packages.\n[^2]: A Base Package-URL is a Package-URL without a version, qualifiers or subpath.\n","funding_links":["https://github.com/sponsors/aboutcode-org","https://opencollective.com/aboutcode","https://causes.benevity.org/causes/056-5528680976845_a486"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faboutcode-org%2Fpurlvalidator-go","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faboutcode-org%2Fpurlvalidator-go","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faboutcode-org%2Fpurlvalidator-go/lists"}