shadow1ng/fscan · error
config_read_urls_failed
config_read_urls_failed
Error message
%s
What it means
Wrapping error from parseURLs: reading the URL list file (fv.URLsFile) via parsers.ReadLinesFromFile failed, and the underlying error is reported through the i18n message config_read_urls_failed with the file path and cause. It fires only in the file branch, never for command-line URLs (those are silently skipped if empty).
Source
Thrown at common/config_builder.go:294
// 命令行 URL
if fv.TargetURL != "" {
for _, u := range strings.Split(fv.TargetURL, ",") {
u = strings.TrimSpace(u)
if u != "" {
urls = append(urls, normalizeURL(u))
}
}
}
// 从文件读取
if fv.URLsFile != "" {
if lines, err := parsers.ReadLinesFromFile(fv.URLsFile); err == nil {
for _, line := range lines {
urls = append(urls, normalizeURL(line))
}
} else {
return nil, fmt.Errorf("%s", i18n.Tr("config_read_urls_failed", fv.URLsFile, err))
}
}
return removeDuplicate(urls), nil
}
func normalizeURL(rawURL string) string {
rawURL = strings.TrimSpace(rawURL)
if rawURL == "" {
return rawURL
}
lowerURL := strings.ToLower(rawURL)
if !strings.HasPrefix(lowerURL, "http://") && !strings.HasPrefix(lowerURL, "https://") {
return "http://" + normalizeSchemelessURLTarget(rawURL)
}
parsed, err := url.Parse(rawURL)
if err != nil || parsed.Host == "" {
return rawURLView on GitHub (pinned to 95cc12e753)
Solutions
- Verify the URL list file exists and is readable
- Ensure one URL per line
- Pass a single URL via -u as a fallback
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at common/config_builder.go:294 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of shadow1ng/fscan@95cc12e753 (2026-09-06).
Data as JSON: /api/errors/b6824c4a1a2bf1c2.
Report an issue: GitHub.