Linux: uses `secret-tool` from libsecret
(account string)
| 170 | |
| 171 | // Linux: uses `secret-tool` from libsecret |
| 172 | func (ks *KeychainStore) linuxGet(account string) ([]byte, error) { |
| 173 | cmd := exec.Command("secret-tool", "lookup", // #nosec G204 |
| 174 | "service", keychainServiceName, "account", account) |
| 175 | out, err := cmd.Output() |
| 176 | if err != nil { |
| 177 | return nil, fmt.Errorf("secret-tool lookup failed: %w", err) |
| 178 | } |
| 179 | return out, nil |
| 180 | } |
| 181 | |
| 182 | func (ks *KeychainStore) linuxSet(account string, data []byte) error { |
| 183 | cmd := exec.Command("secret-tool", "store", // #nosec G204 |