refactor(discovery): decompose the fingerprint god-file by role (WS-D)#1708
Merged
Conversation
Split internal/discovery/fingerprint.go (786 LOC) into role-based files in the same package — pure move: core probing/port-scan orchestration stays in fingerprint.go; OS fingerprinting, service-version detection, and TLS probing move to their own files. All files under the 600-line size-gate threshold. Declaration sets and code-line multisets verified identical to the original. Related to #187
📋 License Compliance Report✅ All dependencies pass license compliance checksGo Dependencies
npm DependenciesSee full report in workflow artifacts Allowed Licenses: MIT, Apache-2.0, BSD-*, ISC, CC0-1.0, MPL-2.0 |
📋 License Compliance Report✅ All dependencies pass license compliance checksGo Dependencies
npm DependenciesSee full report in workflow artifacts Allowed Licenses: MIT, Apache-2.0, BSD-*, ISC, CC0-1.0, MPL-2.0 |
📋 License Compliance Report✅ All dependencies pass license compliance checksGo Dependencies
npm DependenciesSee full report in workflow artifacts Allowed Licenses: MIT, Apache-2.0, BSD-*, ISC, CC0-1.0, MPL-2.0 |
📋 License Compliance Report✅ All dependencies pass license compliance checksGo Dependencies
npm DependenciesSee full report in workflow artifacts Allowed Licenses: MIT, Apache-2.0, BSD-*, ISC, CC0-1.0, MPL-2.0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Splits
internal/discovery/fingerprint.go(786 LOC) into four role-based files in packagediscovery:fingerprint.go— core probing + port-scan orchestrationosfp.go— OS fingerprinting (banner/HTTP/server matchers)service.go— service-version detection (SSH/FTP/SMTP/Telnet)tls.go— TLS probing + version stringificationPure move — no behavior change, no API change. All new files are under the
600-line size-gate threshold; declaration sets and code-line multisets
verified identical to the original.
Linked Issue
Related to #187
Type of Change
Risk
Testing Evidence
Independently verified from a clean worktree of the branch (not the agent's word):
Security and Release Checklist