mirror of
https://github.com/moonD4rk/HackBrowserData.git
synced 2026-07-08 21:37:49 +02:00
feat: add Safari bookmark and download extraction from plist (#567)
* feat: add Safari bookmark and download extraction from plist files * test: add nested folder test for bookmark tree traversal Part of #565
This commit is contained in:
@@ -110,6 +110,10 @@ func (b *Browser) extractCategory(data *types.BrowserData, cat types.Category, p
|
||||
data.Histories, err = extractHistories(path)
|
||||
case types.Cookie:
|
||||
data.Cookies, err = extractCookies(path)
|
||||
case types.Bookmark:
|
||||
data.Bookmarks, err = extractBookmarks(path)
|
||||
case types.Download:
|
||||
data.Downloads, err = extractDownloads(path)
|
||||
default:
|
||||
return
|
||||
}
|
||||
@@ -127,6 +131,10 @@ func (b *Browser) countCategory(cat types.Category, path string) int {
|
||||
count, err = countHistories(path)
|
||||
case types.Cookie:
|
||||
count, err = countCookies(path)
|
||||
case types.Bookmark:
|
||||
count, err = countBookmarks(path)
|
||||
case types.Download:
|
||||
count, err = countDownloads(path)
|
||||
default:
|
||||
// Unsupported categories silently return 0.
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user