rverton / webanalyze

Port of Wappalyzer (uncovers technologies used on websites) to automate mass scanning.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

error: can not open host file : open : no such file or directory

Den1al opened this issue · comments

Apparently the command line binary tries to read the hosts file when using the "update" flag. When using this flag, the check should stop right after the update:

if update {
		err = webanalyze.DownloadFile(webanalyze.WappalyzerURL, "apps.json")
		if err != nil {
			log.Fatalf("error: can not update apps file: %v", err)
		}

		log.Println("app definition file updated from ", webanalyze.WappalyzerURL)

	}

// DEN1AL - this should not run!
	// check single host or hosts file
	if host != "" {

Hi @Den1al,
I implemented this so you can always append -update and have a fresh version of apps.json. It should not force the program to exit here, so thats the purpose. Does this make a problem for your usecase? If yes let me know and we can add a return here.

Greetings,
robin

I think it would be more elegant, that if you wish only to update, to suppress other messages regarding other operations.

The latest commit should fix this.