owasp-amass / amass

In-depth attack surface mapping and asset discovery
https://owasp.org/www-project-amass/
Other
11.63k stars 1.85k forks source link

Amass is not working in Kali Linux, Error Output #945

Closed cyb3rzest closed 1 year ago

cyb3rzest commented 1 year ago

Amass version - v4.1.0 OS - Kali Linux 6.3.0-kali1-amd64 Debian 6.3.7-1kali1 (2023-06-29) x86_64 GNU/Linux

Amass is not working, after 3-5 time of clean-reinstallation. Updated the config.yaml, everything I got in my mind, I did. But error is here

┌──(root㉿ViTi-Security)-[~/vasuki_results/newegg.com/2023-07-28.12.42] └─# amass enum -d example.com -dir tmp/ -v -list -config /root/.config/amass/config.yaml -rf /root/50resolvers.txt panic: failed to connect to host=localhost user=username database=database: dial error (dial tcp 127.0.0.1:5432: connect: connection refused)

goroutine 1 [running]: github.com/owasp-amass/asset-db/repository.New(...) /root/go/pkg/mod/github.com/owasp-amass/asset-db@v0.3.2/repository/sql.go:39 github.com/owasp-amass/asset-db.New({0x139c25c?, 0x4?}, {0xc008a36640?, 0x47879e?}) /root/go/pkg/mod/github.com/owasp-amass/asset-db@v0.3.2/assetdb.go:20 +0xb8 github.com/caffix/netmap.NewGraph({0xc00039c0f0?, 0x2d?}, {0xc008a36640?, 0x5?}, {0x5?, 0xc00103a788?}) /root/go/pkg/mod/github.com/caffix/netmap@v0.2.4/graph.go:49 +0x13a github.com/owasp-amass/amass/v4/systems.(*LocalSystem).setupGraphDBs(0xc00012c720, 0xc000468000) /root/go/pkg/mod/github.com/owasp-amass/amass/v4@v4.1.0/systems/local.go:231 +0x317 github.com/owasp-amass/amass/v4/systems.NewLocalSystem(0xc000468000) /root/go/pkg/mod/github.com/owasp-amass/amass/v4@v4.1.0/systems/local.go:90 +0x305 main.GetAllSourceInfo(0x0?) /root/go/pkg/mod/github.com/owasp-amass/amass/v4@v4.1.0/cmd/amass/main.go:137 +0x5d main.argsAndConfig({0xc00012e020, 0xa, 0xa}) /root/go/pkg/mod/github.com/owasp-amass/amass/v4@v4.1.0/cmd/amass/enum.go:338 +0xa8f main.runEnumCommand({0xc00012e020?, 0xc00012e010?, 0xc0003aa4e8?}) /root/go/pkg/mod/github.com/owasp-amass/amass/v4@v4.1.0/cmd/amass/enum.go:150 +0x45 main.main() /root/go/pkg/mod/github.com/owasp-amass/amass/v4@v4.1.0/cmd/amass/main.go:120 +0x32f

caffix commented 1 year ago

Looks like you did not setup your PostgreSQL database as shown in the Amass user guide, or remove the database option from your configuration file

https://github.com/owasp-amass/amass/blob/master/doc/user_guide.md

cyb3rzest commented 1 year ago

After creating postgresql database and other stuffs, still not able to parse any subdomains using amass enum -passive -d domain.com -o output.txt

Try to update and make it output as it was in v3

caffix commented 1 year ago

amass db -names -d domain.com

Be sure the same configuration is being used with both commands

cyb3rzest commented 1 year ago

I have created an automated bash script for bug hunting process, and amass is also an tool used in that. If this much things have to do, then the only option I left is to remove amass from that tool. You can check for the tool in my repository section.

caffix commented 1 year ago

It's not very hard to make the changes @cyb3rzest. Give it a shot, and I'll be happy to assist if needed

caffix commented 1 year ago

You can reach us on the Amass Discord server with related questions: https://discord.gg/HNePVyX3cp

cyb3rzest commented 1 year ago

Tried there, not a good shot.. stuck over amass enum -passive -d domain command and have to manually exit the command Note- this issue came when running without script.