|
|
|
package hackbrowserdata
|
|
|
|
|
refactor: Refactor project as library layout
- Add new files `bookmark.go`, `chromium_darwin.go`, `browserdata/cookie.go`, `browser_windows.go`, `browser_linux.go`, `datatype.go`, `password.go`, `browserdata/browserdata.go`, `chromium_linux.go`, `chromium_windows.go`
- Refactor `NewChromium` function to accept an `Options` argument
- Refactor `options` code to use a struct instead of multiple arguments
- Modify `filterExistDataPaths` to return data paths instead of `BrowserData`
- Add `Passwords` and `Cookies` functions to `chromium`
- Delete unused files and functions ` errors.go`, `cookie.go`, `browsingdata.go`, `consts.go`, `firefox.go`, `password.go`, `chromium_test.go`, `firefox_test.go`
- Improve error messages for keychain related issues
- Change `BrowserData.Passwords()` to `Passwords()` for simplification
- Remove unused code for browsers `Yandex` and `Edge`, and unused map `browsers` and methods `BrowsingData()` and `AllBrowsingData()` from chromium and firefox structs
- Add `DefaultDBHandler` and `DefaultJSONHandler` functions for SQLite3 queries
1 year ago
|
|
|
type Options struct {
|
|
|
|
Name browser
|
|
|
|
Storage string
|
|
|
|
ProfilePath string
|
|
|
|
IsEnableAllUser bool
|
|
|
|
DataTypes []DataType
|
|
|
|
NewBrowserFunc func(*Options) (Browser, error)
|
|
|
|
}
|
|
|
|
|
refactor: Refactor project as library layout
- Add new files `bookmark.go`, `chromium_darwin.go`, `browserdata/cookie.go`, `browser_windows.go`, `browser_linux.go`, `datatype.go`, `password.go`, `browserdata/browserdata.go`, `chromium_linux.go`, `chromium_windows.go`
- Refactor `NewChromium` function to accept an `Options` argument
- Refactor `options` code to use a struct instead of multiple arguments
- Modify `filterExistDataPaths` to return data paths instead of `BrowserData`
- Add `Passwords` and `Cookies` functions to `chromium`
- Delete unused files and functions ` errors.go`, `cookie.go`, `browsingdata.go`, `consts.go`, `firefox.go`, `password.go`, `chromium_test.go`, `firefox_test.go`
- Improve error messages for keychain related issues
- Change `BrowserData.Passwords()` to `Passwords()` for simplification
- Remove unused code for browsers `Yandex` and `Edge`, and unused map `browsers` and methods `BrowsingData()` and `AllBrowsingData()` from chromium and firefox structs
- Add `DefaultDBHandler` and `DefaultJSONHandler` functions for SQLite3 queries
1 year ago
|
|
|
type BrowserOption func(*Options)
|
|
|
|
|
refactor: Refactor project as library layout
- Add new files `bookmark.go`, `chromium_darwin.go`, `browserdata/cookie.go`, `browser_windows.go`, `browser_linux.go`, `datatype.go`, `password.go`, `browserdata/browserdata.go`, `chromium_linux.go`, `chromium_windows.go`
- Refactor `NewChromium` function to accept an `Options` argument
- Refactor `options` code to use a struct instead of multiple arguments
- Modify `filterExistDataPaths` to return data paths instead of `BrowserData`
- Add `Passwords` and `Cookies` functions to `chromium`
- Delete unused files and functions ` errors.go`, `cookie.go`, `browsingdata.go`, `consts.go`, `firefox.go`, `password.go`, `chromium_test.go`, `firefox_test.go`
- Improve error messages for keychain related issues
- Change `BrowserData.Passwords()` to `Passwords()` for simplification
- Remove unused code for browsers `Yandex` and `Edge`, and unused map `browsers` and methods `BrowsingData()` and `AllBrowsingData()` from chromium and firefox structs
- Add `DefaultDBHandler` and `DefaultJSONHandler` functions for SQLite3 queries
1 year ago
|
|
|
func WithBrowserName(p string) BrowserOption {
|
|
|
|
return func(o *Options) {
|
|
|
|
o.Name = browser(p)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func WithProfilePath(p string) BrowserOption {
|
refactor: Refactor project as library layout
- Add new files `bookmark.go`, `chromium_darwin.go`, `browserdata/cookie.go`, `browser_windows.go`, `browser_linux.go`, `datatype.go`, `password.go`, `browserdata/browserdata.go`, `chromium_linux.go`, `chromium_windows.go`
- Refactor `NewChromium` function to accept an `Options` argument
- Refactor `options` code to use a struct instead of multiple arguments
- Modify `filterExistDataPaths` to return data paths instead of `BrowserData`
- Add `Passwords` and `Cookies` functions to `chromium`
- Delete unused files and functions ` errors.go`, `cookie.go`, `browsingdata.go`, `consts.go`, `firefox.go`, `password.go`, `chromium_test.go`, `firefox_test.go`
- Improve error messages for keychain related issues
- Change `BrowserData.Passwords()` to `Passwords()` for simplification
- Remove unused code for browsers `Yandex` and `Edge`, and unused map `browsers` and methods `BrowsingData()` and `AllBrowsingData()` from chromium and firefox structs
- Add `DefaultDBHandler` and `DefaultJSONHandler` functions for SQLite3 queries
1 year ago
|
|
|
return func(o *Options) {
|
|
|
|
o.ProfilePath = p
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
refactor: Refactor project as library layout
- Add new files `bookmark.go`, `chromium_darwin.go`, `browserdata/cookie.go`, `browser_windows.go`, `browser_linux.go`, `datatype.go`, `password.go`, `browserdata/browserdata.go`, `chromium_linux.go`, `chromium_windows.go`
- Refactor `NewChromium` function to accept an `Options` argument
- Refactor `options` code to use a struct instead of multiple arguments
- Modify `filterExistDataPaths` to return data paths instead of `BrowserData`
- Add `Passwords` and `Cookies` functions to `chromium`
- Delete unused files and functions ` errors.go`, `cookie.go`, `browsingdata.go`, `consts.go`, `firefox.go`, `password.go`, `chromium_test.go`, `firefox_test.go`
- Improve error messages for keychain related issues
- Change `BrowserData.Passwords()` to `Passwords()` for simplification
- Remove unused code for browsers `Yandex` and `Edge`, and unused map `browsers` and methods `BrowsingData()` and `AllBrowsingData()` from chromium and firefox structs
- Add `DefaultDBHandler` and `DefaultJSONHandler` functions for SQLite3 queries
1 year ago
|
|
|
func WithEnableAllUsers(e bool) BrowserOption {
|
|
|
|
return func(o *Options) {
|
|
|
|
o.IsEnableAllUser = e
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
func WithStorageName(s string) BrowserOption {
|
refactor: Refactor project as library layout
- Add new files `bookmark.go`, `chromium_darwin.go`, `browserdata/cookie.go`, `browser_windows.go`, `browser_linux.go`, `datatype.go`, `password.go`, `browserdata/browserdata.go`, `chromium_linux.go`, `chromium_windows.go`
- Refactor `NewChromium` function to accept an `Options` argument
- Refactor `options` code to use a struct instead of multiple arguments
- Modify `filterExistDataPaths` to return data paths instead of `BrowserData`
- Add `Passwords` and `Cookies` functions to `chromium`
- Delete unused files and functions ` errors.go`, `cookie.go`, `browsingdata.go`, `consts.go`, `firefox.go`, `password.go`, `chromium_test.go`, `firefox_test.go`
- Improve error messages for keychain related issues
- Change `BrowserData.Passwords()` to `Passwords()` for simplification
- Remove unused code for browsers `Yandex` and `Edge`, and unused map `browsers` and methods `BrowsingData()` and `AllBrowsingData()` from chromium and firefox structs
- Add `DefaultDBHandler` and `DefaultJSONHandler` functions for SQLite3 queries
1 year ago
|
|
|
return func(o *Options) {
|
|
|
|
o.Storage = s
|
|
|
|
}
|
|
|
|
}
|