Conversation
mike-hunhoff
left a comment
There was a problem hiding this comment.
Thanks @akshat4703 , I've left comments for your review. Additionally, several architectural and precision refinements are needed:
-
Rule Consolidation: Move generic BITS job creation strings (e.g.,
bitsadmin /create,Start-BitsTransfer) into the existingcreate BITS job.ymlrule to unify COM and CLI detection. Your proposedtransfer files via BITSshould then rely onmatch: create BITS joband focus strictly on intent-specific indicators like/addfileor/transfer. -
Regex Precision: Add word boundaries (
\b) to all new regex patterns to prevent false positives (e.g.,/\bSet-BitsTransfer\b/i,/\bPendingFileRenameOperations\b/i). Specifically, remove the trailing space in/Set-BitsTransfer /iin favor of a word boundary. -
Anchoring: Ensure the
PendingFileRenameOperationsregistry rule is properly anchored with word boundaries for both the key and the path components to maintain function-scope reliability.
nursery/persist-via-pendingfilerenameoperations-registry-value.yml
Outdated
Show resolved
Hide resolved
Thanks for the guidance — I have made the requested changes. Rule consolidation Regex precision PendingFileRenameOperations anchoring + description |
8c8e268 to
618b29c
Compare
618b29c to
207993a
Compare
Summary
Implements #967 by adding a general rule to detect usage of BITS (Background Intelligent Transfer Service).
What Changed
Added:
rules/communication/http/client/use-bits.yml
The rule detects:
COM-based BITS usage via the existing create BITS job rule
Command-line BITS usage such as bitsadmin, Start-BitsTransfer, or Set-BitsTransfer when process creation behavior is observed
Validation
capafmt passed
lint --thorough -t "use BITS" rules passed