@@ -42,7 +42,7 @@ func NewScanner(cfg config.NmapConfig, log interface {
4242 enhancedLogger .FinishOperation (ctx , span , "nmap.NewScanner" , start , nil )
4343 }()
4444
45- enhancedLogger .WithContext (ctx ).Infow ("Initializing Nmap scanner" ,
45+ enhancedLogger .WithContext (ctx ).Info ("Initializing Nmap scanner" ,
4646 "scanner_type" , "nmap" ,
4747 "component" , "network_scanner" ,
4848 "binary_path" , cfg .BinaryPath ,
@@ -65,7 +65,7 @@ func NewScanner(cfg config.NmapConfig, log interface {
6565 logger : enhancedLogger ,
6666 }
6767
68- enhancedLogger .WithContext (ctx ).Infow ("Nmap scanner initialized successfully" ,
68+ enhancedLogger .WithContext (ctx ).Info ("Nmap scanner initialized successfully" ,
6969 "scanner_type" , "nmap" ,
7070 "total_init_duration_ms" , time .Since (start ).Milliseconds (),
7171 "capabilities" , []string {"port_scanning" , "service_detection" , "os_detection" , "vulnerability_assessment" },
@@ -138,7 +138,7 @@ func (s *nmapScanner) Validate(target string) error {
138138 )
139139 }
140140
141- s .logger .WithContext (ctx ).Infow ("Nmap target validation successful" ,
141+ s .logger .WithContext (ctx ).Info ("Nmap target validation successful" ,
142142 "target" , target ,
143143 "validation_duration_ms" , time .Since (start ).Milliseconds (),
144144 )
@@ -159,7 +159,7 @@ func (s *nmapScanner) Scan(ctx context.Context, target string, options map[strin
159159 s .logger .FinishOperation (ctx , span , "nmap.Scan" , start , err )
160160 }()
161161
162- s .logger .WithContext (ctx ).Infow ("Starting Nmap scan" ,
162+ s .logger .WithContext (ctx ).Info ("Starting Nmap scan" ,
163163 "target" , target ,
164164 "scan_id" , scanID ,
165165 "available_options" , len (options ),
@@ -191,7 +191,7 @@ func (s *nmapScanner) Scan(ctx context.Context, target string, options map[strin
191191 profileArgs = s .cfg .Profiles ["default" ]
192192 }
193193
194- s .logger .WithContext (ctx ).Infow ("Profile selected" ,
194+ s .logger .WithContext (ctx ).Info ("Profile selected" ,
195195 "scan_id" , scanID ,
196196 "selected_profile" , profile ,
197197 "profile_args" , profileArgs ,
@@ -212,7 +212,7 @@ func (s *nmapScanner) Scan(ctx context.Context, target string, options map[strin
212212 profileArgsSlice := strings .Fields (profileArgs )
213213 args = append (args , profileArgsSlice ... )
214214
215- s .logger .WithContext (ctx ).Infow ("Nmap command prepared" ,
215+ s .logger .WithContext (ctx ).Info ("Nmap command prepared" ,
216216 "scan_id" , scanID ,
217217 "binary_path" , s .cfg .BinaryPath ,
218218 "total_args" , len (args ),
@@ -225,7 +225,7 @@ func (s *nmapScanner) Scan(ctx context.Context, target string, options map[strin
225225 cmdStart := time .Now ()
226226 cmd := exec .CommandContext (ctx , s .cfg .BinaryPath , args ... )
227227
228- s .logger .WithContext (ctx ).Infow ("Executing Nmap scan" ,
228+ s .logger .WithContext (ctx ).Info ("Executing Nmap scan" ,
229229 "scan_id" , scanID ,
230230 "command" , s .cfg .BinaryPath ,
231231 "target" , target ,
@@ -253,7 +253,7 @@ func (s *nmapScanner) Scan(ctx context.Context, target string, options map[strin
253253 return nil , err
254254 }
255255
256- s .logger .WithContext (ctx ).Infow ("Nmap execution completed successfully" ,
256+ s .logger .WithContext (ctx ).Info ("Nmap execution completed successfully" ,
257257 "scan_id" , scanID ,
258258 "command_duration_ms" , cmdDuration .Milliseconds (),
259259 "output_size_bytes" , len (output ),
@@ -274,7 +274,7 @@ func (s *nmapScanner) Scan(ctx context.Context, target string, options map[strin
274274 }
275275
276276 // Log scan completion with comprehensive metrics
277- s .logger .WithContext (ctx ).Infow ("Nmap scan completed successfully" ,
277+ s .logger .WithContext (ctx ).Info ("Nmap scan completed successfully" ,
278278 "scan_id" , scanID ,
279279 "target" , target ,
280280 "total_duration_ms" , time .Since (start ).Milliseconds (),
@@ -432,7 +432,7 @@ func (s *nmapScanner) parseNmapOutput(ctx context.Context, xmlData []byte, targe
432432 findings = append (findings , finding )
433433 }
434434
435- s .logger .WithContext (ctx ).Infow ("Host processing completed" ,
435+ s .logger .WithContext (ctx ).Info ("Host processing completed" ,
436436 "scan_id" , scanID ,
437437 "host_address" , address ,
438438 "open_ports" , hostPortCount ,
@@ -469,7 +469,7 @@ func (s *nmapScanner) parseNmapOutput(ctx context.Context, xmlData []byte, targe
469469 }
470470
471471 // Log comprehensive parsing summary
472- s .logger .WithContext (ctx ).Infow ("Nmap output parsing completed" ,
472+ s .logger .WithContext (ctx ).Info ("Nmap output parsing completed" ,
473473 "scan_id" , scanID ,
474474 "total_duration_ms" , time .Since (start ).Milliseconds (),
475475 "hosts_processed" , hostCount ,
0 commit comments