-
Notifications
You must be signed in to change notification settings - Fork 14
Closed
Description
Issue Description
Summary
When using RepositoryId (package-url / purl) in filter.json to remove components, capycli does not match or remove the component. The same filtering mechanism works when using other fields like Name, but purl-based matching does not trigger any removal.
There is also no documentation or examples showing how RepositoryId-based filtering is intended to work (exact match, prefix match, wildcards, etc.).
Filter File Used
The following is the exact filter.json used:
{
"Components": [
{
"component": {
"RepositoryId": "pkg:maven/it.softeco*"
},
"Mode": "remove"
}
]
}
Observed Behavior
- No components are removed from the SBOM.
- Wildcard matching (*) has no effect.
- Using RepositoryId alone results in zero matches, even when the SBOM contains components with purls like:
pkg:maven/it.softeco.example/library@1.0.0
Expected Behavior
- Components whose RepositoryId (purl) starts with or equals pkg:maven/it.softeco should be matched and removed.
- capycli should support:
- exact purl matching
- wildcard/prefix matching (if intended)
- RepositoryId filtering should behave consistently with Name/Version filtering.
Steps to Reproduce
- Use any SBOM (CycloneDX XML/JSON) containing Maven components whose purl begins with pkg:maven/it.softeco...
- Create the above filter.json.
- Run the capycli command that applies filters (e.g., components apply-filter or the equivalent).
- Observe that:
- No components are matched.
- The output SBOM is unchanged.
Actual Behavior
- The component removal based on RepositoryId does not work.
- No documentation describes whether:
- RepositoryId is supported for filtering
- purl needs to be exact or normalized
- wildcards are supported for purl matching
Environment
capycli version: 2.10.1
Python version: 3.13.7
OS: Microsoft Windows [Version 10.0.22631.6649]
SBOM format: CycloneDX JSON
Requested Actions
- Confirm whether RepositoryId (purl) matching is officially supported in filters.
- If supported, fix the logic so purl-based filtering works correctly.
- Document how RepositoryId matching is supposed to work:
- exact match?
- prefix match?
- wildcard support?
- Provide at least one example in the documentation showing valid RepositoryId-based filtering in filter.json.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels