moonD4rk / HackBrowserData

Extract and decrypt browser data, supporting multiple data types, runnable on various operating systems (macOS, Windows, Linux).
MIT License
11.19k stars 1.57k forks source link

Fix: Add more error handler #255

Closed M09Ic closed 10 months ago

M09Ic commented 1 year ago

数据能正常导出, 但有报错, 建议添加错误捕获

.\hack-browser-data-windows-64bit.exe
[NOTICE] [browser.go:47,pickChromium] find browser Chrome Beta failed, profile folder does not exist
[NOTICE] [browser.go:47,pickChromium] find browser Vivaldi failed, profile folder does not exist
[NOTICE] [browser.go:47,pickChromium] find browser CocCoc failed, profile folder does not exist
[NOTICE] [browser.go:47,pickChromium] find browser Yandex failed, profile folder does not exist
[NOTICE] [browser.go:47,pickChromium] find browser QQ failed, profile folder does not exist
[NOTICE] [browser.go:51,pickChromium] find browser Chrome success
[NOTICE] [browser.go:53,pickChromium] find browser chrome_def success
[NOTICE] [browser.go:53,pickChromium] find browser chrome_user_2 success
[NOTICE] [browser.go:53,pickChromium] find browser chrome_default success
[NOTICE] [browser.go:53,pickChromium] find browser chrome_guest_user success
[NOTICE] [browser.go:53,pickChromium] find browser chrome_user_1 success
[NOTICE] [browser.go:51,pickChromium] find browser Microsoft Edge success
[NOTICE] [browser.go:53,pickChromium] find browser microsoft_edge_payments success
[NOTICE] [browser.go:53,pickChromium] find browser microsoft_edge_default success
[NOTICE] [browser.go:53,pickChromium] find browser microsoft_edge_autofill success
[NOTICE] [browser.go:47,pickChromium] find browser Chromium failed, profile folder does not exist
[NOTICE] [browser.go:47,pickChromium] find browser Opera failed, profile folder does not exist
[NOTICE] [browser.go:47,pickChromium] find browser OperaGX failed, profile folder does not exist
[NOTICE] [browser.go:47,pickChromium] find browser Brave failed, profile folder does not exist
[NOTICE] [browser.go:47,pickChromium] find browser 360speed failed, profile folder does not exist
[NOTICE] [browser.go:96,pickFirefox] find browser firefox firefox-emsuomtn.default-release success
[NOTICE] [browsingdata.go:71,Output] output to file results/chrome_user_2_extension.csv success
[NOTICE] [browsingdata.go:71,Output] output to file results/chrome_user_2_history.csv success
[NOTICE] [browsingdata.go:71,Output] output to file results/chrome_user_2_cookie.csv success
[NOTICE] [browsingdata.go:71,Output] output to file results/chrome_user_2_localstorage.csv success
[NOTICE] [browsingdata.go:71,Output] output to file results/chrome_user_2_bookmark.csv success
[NOTICE] [browsingdata.go:71,Output] output to file results/chrome_user_2_password.csv success
[ERROR] [main.go:60,func1] open C:\Users\Hunter\AppData\Local\Google\Chrome\User Data\Default\Network\Cookies: The process cannot access the file because it is being used by another process.
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xc0000005 code=0x0 addr=0x0 pc=0xac837b]

goroutine 1 [running]:
hack-browser-data/internal/browingdata.(*Data).Output(0xc0003038f0?, {0xcb74b9, 0x7}, {0xc000024020, 0xe}, {0xcb2217?, 0x0?})
        /source/internal/browingdata/browsingdata.go:51 +0x7b
main.Execute.func1(0xc0000ec240?)
        /source/cmd/hack-browser-data/main.go:62 +0x23e
github.com/urfave/cli/v2.(*App).RunContext(0xc00006dba0, {0xd3bf48?, 0xc000024088}, {0xc000078200, 0x1, 0x1})
        /go/pkg/mod/github.com/urfave/cli/v2@v2.4.0/app.go:322 +0x97c
github.com/urfave/cli/v2.(*App).Run(...)
        /go/pkg/mod/github.com/urfave/cli/v2@v2.4.0/app.go:224
main.Execute()
        /source/cmd/hack-browser-data/main.go:73 +0x7f6
main.main()
        /source/cmd/hack-browser-data/main.go:24 +0x17