Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Pad = oldpad
Pad can be modified and probably should be for each version of your application.
Functions ¶
This section is empty.
Types ¶
type Key ¶
type Key []byte
Key holds the password. You can use it like this:
seconf.Key([]byte("mypassword").Marshal(myConfigStruct) seconf.Key([]byte("mypassword").Unmarshal(myEncryptedConfig)
It is up to the application to validate the key. Key size is 32 bits. If a key is too small, it will be padded using seconfig.Pad, which should be customized per application. If a key is too large, it will be truncated.
func (Key) Lock ¶
Lock acts like JSON Marshal, which contents can only be seen after using seconf.Unlock https://godoc.org/encoding/json#Marshal
Directories
¶
Path | Synopsis |
---|---|
example
|
|
seconfig-tester
Usage demo for seconfig package (https://github.com/aerth/seconfig)
|
Usage demo for seconfig package (https://github.com/aerth/seconfig) |
Click to show internal directories.
Click to hide internal directories.