{"record":{"id":"78c74438ad47b055","repo":"projectdiscovery/nuclei","slug":"both-follow-redirects-and-disable-redirects-specif","errorCode":null,"errorMessage":"both follow redirects and disable redirects specified","messagePattern":"both follow redirects and disable redirects specified","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/runner/options.go","lineNumber":167,"sourceCode":"\t\terrs := []string{}\n\t\tfor _, err := range err.(validator.ValidationErrors) {\n\t\t\terrs = append(errs, err.Namespace()+\": \"+err.Tag())\n\t\t}\n\t\treturn errors.Wrap(errors.New(strings.Join(errs, \", \")), \"validation failed for these fields\")\n\t}\n\tif options.Verbose && options.Silent {\n\t\treturn errors.New(\"both verbose and silent mode specified\")\n\t}\n\n\tif (options.HeadlessOptionalArguments != nil || options.ShowBrowser || options.UseInstalledChrome) && !options.Headless {\n\t\treturn errors.New(\"headless mode (-headless) is required if -ho, -sb, -sc or -lha are set\")\n\t}\n\n\tif options.FollowHostRedirects && options.FollowRedirects {\n\t\treturn errors.New(\"both follow host redirects and follow redirects specified\")\n\t}\n\tif options.ShouldFollowHTTPRedirects() && options.DisableRedirects {\n\t\treturn errors.New(\"both follow redirects and disable redirects specified\")\n\t}\n\t// loading the proxy server list from file or cli and test the connectivity\n\tif err := loadProxyServers(options); err != nil {\n\t\treturn err\n\t}\n\tif options.Validate {\n\t\tvalidateTemplatePaths(options.Logger, config.DefaultConfig.TemplatesDirectory, options.Templates, options.Workflows)\n\t}\n\tif options.DAST {\n\t\tif err := validateDASTOptions(options); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\n\t// Verify if any of the client certificate options were set since it requires all three to work properly\n\tif options.HasClientCertificates() {\n\t\tif generic.EqualsAny(\"\", options.ClientCertFile, options.ClientKeyFile, options.ClientCAFile) {\n\t\t\treturn errors.New(\"if a client certification option is provided, then all three must be provided\")","sourceCodeStart":149,"sourceCodeEnd":185,"githubUrl":"https://github.com/projectdiscovery/nuclei/blob/265b3a3dec374741614e342f813c10f8b38d2bb7/internal/runner/options.go#L149-L185","documentation":"interfaceAddress walks the named interface's addresses and keeps the first non-loopback IPv4; if none exists (IPv6-only, loopback-only, or unassigned interface) dialer setup fails with this error. The -interface code path requires a concrete IPv4 bind address.","triggerScenarios":"nuclei -interface <iface> where iface is an IPv6-only tunnel, an unaddressed bridge, or a dummy loopback interface.","commonSituations":"Freshly created VPN or bridge interfaces without IPv4; IPv6-only links; interface not yet up or lacking a DHCP lease.","solutions":["Assign an IPv4 address to the interface or select a different one","Use -source-ip with an IPv4 the host owns instead of -interface","Bring the interface up or renew its lease and retry"],"exampleFix":"# before\nnuclei -interface tun6   # IPv6-only interface\n# after\nnuclei -interface eth0","handlingStrategy":"validation","validationCode":"import \"net\"\n\nfunc hasBindableIPv4(iface string) bool {\n    i, err := net.InterfaceByName(iface)\n    if err != nil {\n        return false\n    }\n    addrs, _ := i.Addrs()\n    for _, a := range addrs {\n        if ipnet, ok := a.(*net.IPNet); ok && !ipnet.IP.IsLoopback() && ipnet.IP.To4() != nil {\n            return true\n        }\n    }\n    return false\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Check ip addr show <iface> lists a non-loopback IPv4 before using -interface","Prefer -source-ip with a known local IPv4","Avoid IPv6-only interfaces for the bind path"],"tags":["network","cli","ipv6","configuration"],"backgroundTag":null,"analyzedSha":"265b3a3dec374741614e342f813c10f8b38d2bb7","analyzedAt":"2026-08-15T20:05:51.855Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}