DependencyTrack / DependencyTrack/dependency-track

Internal Component Classification Should Be Repository-Based

Open
#5,826 1 comment 0 reactions 0 assignees View on GitHub
defect in triage
Dominant language
Java
Stars
4.2k
Forks
811
Avg merge
8h 39m
Merged PRs (30d)
237

Description

### Current Behavior

Dependency-Track identifies Internal Components using regular expressions applied to the component namespace (group) and/or name.

For ecosystems such as PyPI, where no namespace exists (`pkg:pypi/name@version`), detection relies entirely on name-based regex matching.

This makes internal classification dependent on naming conventions rather than the actual repository origin of the component.

### Steps to Reproduce

1. Configure an internal PyPI (or other ecosystem) repository in Dependency-Track.
2. Mark the repository as internal (if applicable).
3. Configure Internal Component rules using regex on namespace and/or name.
4. Upload an SBOM containing components from both public and internal repositories (with identical naming patterns).
5. Observe that classification as internal depends solely on regex matching and not on the repository origin.

### Expected Behavior

When a repository is configured and marked as internal in Dependency-Track, components originating from that repository should automatically be classified as internal.

Internal component identification should be based on the actual repository origin (or repository URL qualifier in the purl), rather than relying solely on regex matching of name or namespace.

Regex-based matching could remain as an optional fallback, but repository-based classification should take precedence for determinism and accuracy.

### Dependency-Track Version

4.13.6

### Dependency-Track Distribution

Container Image

### Database Server

PostgreSQL

### Database Server Version

_No response_

### Browser

Google Chrome

### Checklist

- [x] I have read and understand the [contributing guidelines](https://github.com/DependencyTrack/dependency-track/blob/master/CONTRIBUTING.md#filing-issues)
- [x] I have checked the [existing issues](https://github.com/DependencyTrack/dependency-track/issues) for whether this defect was already reported

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.