mirror of
https://github.com/moonD4rk/HackBrowserData.git
synced 2026-12-04 05:43:27 +01:00
* refactor: pass secrets as values, fetched once per scope A master key travelled through five layers of function values and three sync.Once guarded reuse; holding each secret where its scope lives shows where it comes from. Only the keychain prompt still waits for first use. * docs(rfcs): fetch secrets per extraction, not per record
19 lines
478 B
Go
19 lines
478 B
Go
//go:build darwin
|
|
|
|
package app
|
|
|
|
import (
|
|
"path/filepath"
|
|
|
|
"github.com/moond4rk/hackbrowserdata/internal/keychain"
|
|
)
|
|
|
|
// newLoginKeychain builds the run's login keychain without opening it, so a run that never decrypts never prompts.
|
|
func newLoginKeychain(path string, password keychain.PasswordFunc) loginKeychain {
|
|
return keychain.New(path, password)
|
|
}
|
|
|
|
func loginKeychainPath(home string) string {
|
|
return filepath.Join(home, "Library", "Keychains", "login.keychain-db")
|
|
}
|