Skip to content

Commit

Permalink
Open Correlation Lab by Default
Browse files Browse the repository at this point in the history
Also fixes bug where if webport isn't defined then the scan closes
early.
  • Loading branch information
s-rah committed Oct 30, 2016
1 parent 45b2de5 commit 510c3f0
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ func main() {
dbdir := flag.String("dbdir", "./onionscandb", "The directory where the crawl database will be stored")
crawlconfigdir := flag.String("crawlconfigdir", "", "A directory where crawl configurations are stored")
scans := flag.String("scans", "", "a comma-separated list of scans to run e.g. web,tls,... (default: run all)")
webport := flag.Int("webport", 0, "if given, onionscan will expose a webserver on localhost:[port] to enabled searching of the database")
webport := flag.Int("webport", 8080, "if given, onionscan will expose a webserver on localhost:[port] to enabled searching of the database")
mode := flag.String("mode", "scan", "one of scan or analysis. In analysis mode, webport must be set.")
cookiestring := flag.String("cookie", "", "if provided, onionscan will use this cookie")

Expand Down Expand Up @@ -87,7 +87,11 @@ func main() {
log.Printf("Starting Scan of %d onion services\n", len(onionsToScan))
}
log.Printf("This might take a few minutes..\n\n")
go doScanMode(onionScan, onionsToScan, *batch, *reportFile, *simpleReport, *jsonReport, *jsonSimpleReport)
if *webport > 0 {
go doScanMode(onionScan, onionsToScan, *batch, *reportFile, *simpleReport, *jsonReport, *jsonSimpleReport)
} else {
doScanMode(onionScan, onionsToScan, *batch, *reportFile, *simpleReport, *jsonReport, *jsonSimpleReport)
}
}

// Start up the web ui.
Expand Down

0 comments on commit 510c3f0

Please sign in to comment.