Class: FiberAudit::Static::Rules::DirectSocket
- Defined in:
- lib/fiber_audit/static/rules/direct_socket.rb
Overview
FA1006: Inventory and semantic classification for direct socket constructors.
Constant Summary collapse
- TITLE =
'Direct socket construction'- CATEGORY =
:network- EXACT =
OperationVocabulary::FA1006_EXACT
- CATEGORY_METADATA =
{ socket_allocation: { title: 'Direct socket allocation', message: 'This constructor is inventory-level socket setup without a client connection; ' \ 'later accept, connect, address resolution, or I/O may require scheduler cooperation.', remediation: 'Treat allocation as inventory and verify scheduler-aware behavior at later ' \ 'accept, connect, resolution, and I/O calls.' }, socket_resolve_connect: { title: 'Direct socket endpoint setup', message: 'This constructor may resolve an address and establish a network endpoint, requiring ' \ 'scheduler cooperation from address-resolution and I/O hooks.', remediation: 'Verify address_resolve and scheduler-aware I/O hooks, and confirm runtime progress ' \ 'for endpoint setup.' }, socket_local_connect: { title: 'Direct local-socket connection', message: 'This constructor may establish a local socket connection and wait for endpoint progress.', remediation: 'Verify runtime progress for local-socket connection and move blocking setup outside ' \ 'the fiber-scheduled path.' }, socket_constructor_unknown: { title: 'Direct socket subclass construction', message: 'This IPSocket subclass constructor has unknown allocation/connect semantics and may ' \ 'require scheduler cooperation.', remediation: 'Inspect the subclass constructor and verify scheduler-aware resolution, connection, ' \ 'and I/O behavior.' } }.freeze
Constants inherited from Base
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from Base
confidence, default_confidence, default_severity, description, id, #initialize, severity
Constructor Details
This class inherits a constructor from FiberAudit::Static::Rules::Base
Class Method Details
.category ⇒ Object
55 |
# File 'lib/fiber_audit/static/rules/direct_socket.rb', line 55 def category = CATEGORY |
.title ⇒ Object
54 |
# File 'lib/fiber_audit/static/rules/direct_socket.rb', line 54 def title = TITLE |
Instance Method Details
#analyze(call_sites:) ⇒ Object
58 59 60 |
# File 'lib/fiber_audit/static/rules/direct_socket.rb', line 58 def analyze(call_sites:) call_sites.filter_map { |site| match(site) } end |