Documentation ¶
Index ¶
- func DecryptToken(ciphertext64 string, protectionkey [32]byte) (string, error)
- func EncryptToken(token string, protectionkey [32]byte) (string, error)
- func EnsureProtectionKey() ([32]byte, bool, error)
- func FetchProtectionKey() ([32]byte, error)
- func FetchToken(server, project string) (string, bool, error)
- func GenerateProtectionKey() ([32]byte, error)
- func KeyringIsAvailable() bool
- func LoadCACerts(certfilepem string) (*tls.Config, error)
- func StoreProtectionKey(key [32]byte) error
- func StoreToken(server, project, data string) error
- func ValidateProtectionKeyArgon2(password string, params *ProtectionKeyArgon2Params) ([32]byte, error)
- type ProtectionKeyArgon2Params
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EnsureProtectionKey ¶
func FetchProtectionKey ¶
func GenerateProtectionKey ¶
func KeyringIsAvailable ¶
func KeyringIsAvailable() bool
func StoreProtectionKey ¶
func StoreToken ¶
func ValidateProtectionKeyArgon2 ¶
func ValidateProtectionKeyArgon2(password string, params *ProtectionKeyArgon2Params) ([32]byte, error)
Types ¶
type ProtectionKeyArgon2Params ¶
type ProtectionKeyArgon2Params struct { KeyLen uint32 Salt []byte Time uint32 Memory uint32 Parallelism uint8 Digest []byte DigestSalt []byte DigestTime uint32 DigestMemory uint32 }
func GenerateProtectionKeyArgon2 ¶
func GenerateProtectionKeyArgon2(password string) ([32]byte, *ProtectionKeyArgon2Params, error)
Click to show internal directories.
Click to hide internal directories.