Documentation ¶
Overview ¶
Package chefcrypto bundles up crytographic routines for goairdi.
Index ¶
- func Auth12HeaderVerify(pkPem string, hashed, sig []byte) error
- func GenerateRSAKeys() (string, string, error)
- func GenerateSalt() ([]byte, error)
- func HashPasswd(passwd string, salt []byte) (string, error)
- func HeaderDecrypt(pkPem string, data string) ([]byte, error)
- func ValidatePublicKey(publicKey interface{}) (bool, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Auth12HeaderVerify ¶
Auth12HeaderVerify verifies the newer version 1.2 Chef authentication protocol headers.
func GenerateRSAKeys ¶
GenerateRSAKeys creates a pair of private and public keys for a client.
func GenerateSalt ¶
GenerateSalt makes a new salt for hashing a password.
func HashPasswd ¶
HashPasswd SHA512 hashes a password string with the provided salt.
func HeaderDecrypt ¶
HeaderDecrypt decrypts the encrypted header with the client or user's public key for validating requests. This function is informed by chef-golang's privateDecrypt function.
func ValidatePublicKey ¶
ValidatePublicKey checks that the provided public key is valid.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.