diff --git a/lib/config.go b/lib/config.go index fd615c426d..f24e272fc2 100644 --- a/lib/config.go +++ b/lib/config.go @@ -226,6 +226,8 @@ type NetworkConfig struct { MaxHostError int // Maximum number of host errors to allow before skipping that host TrackError []string // Adds given errors to max host error watchlist DisableMaxHostErr bool // Disable max host error optimization (Hosts are not skipped even if they are not responding) + Interface string // Interface to use for network scan + } // WithNetworkConfig allows setting network config options @@ -238,6 +240,7 @@ func WithNetworkConfig(opts NetworkConfig) NucleiSDKOptions { e.opts.Retries = opts.Retries e.opts.LeaveDefaultPorts = opts.LeaveDefaultPorts e.hostErrCache = hosterrorscache.New(opts.MaxHostError, hosterrorscache.DefaultMaxHostsCount, opts.TrackError) + e.opts.Interface = opts.Interface return nil } }