Documentation ¶
Index ¶
- Constants
- Variables
- type BlockSizeError
- type Database
- func (d *Database) Decrypt() error
- func (d *Database) Load() error
- func (d *Database) Parse() error
- func (d Database) Parsed() *parser.Document
- func (d Database) Path() string
- func (d Database) Plaintext() []byte
- func (d *Database) Save() error
- func (d *Database) SaveToPath(path string) error
- func (d *Database) SetPassword(password string)
- func (d *Database) VerifyHeaderHash() (bool, error)
- func (d Database) Version() version
- type FileError
- type IRSID
- type ParseError
Constants ¶
View Source
const ( WORD = 2 DWORD = 4 QWORD = 8 )
View Source
const ( TLV_TYPE_LEN = 1 TLV_LENGTH_LEN = 2 MASTER_SEED_LEN = 32 TRANSFORM_SEED_LEN = 32 INNER_RANDOM_STREAM_KEY_LEN = 32 STREAM_START_BYTES_LEN = 32 MAX_UINT16 = ^uint16(0) )
View Source
const ( // End of headers EOH headerCode = iota Comment CipherID CompressionFlag MasterSeed TransformSeed TransformRounds EncryptionIV ProtectedStreamKey StreamStartBytes InnerRandomStreamID // Store number of header codes so that we can iterate NUM_HEADER_CODES )
View Source
const ( COMPRESSION_None = 0 COMPRESSION_GZip = 1 )
View Source
const ( IRS_None = iota IRS_ARC4 IRS_Salsa20 )
Variables ¶
View Source
var ( FILE_SIGNATURE [4]byte = [4]byte{0x03, 0xD9, 0xA2, 0x9A} VERSION_SIGNATURE [4]byte = [4]byte{0x67, 0xFB, 0x4B, 0xB5} AES_CIPHER_ID [16]byte = [16]byte{0x31, 0xC1, 0xF2, 0xE6, 0xBF, 0x71, 0x43, 0x50, 0xBE, 0x58, 0x05, 0x21, 0x6A, 0xFC, 0x5A, 0xFF} // KeePass files contain this sequence as the data for the final header field, we just copy that behavior EOH_DATA [4]byte = [4]byte{0x0d, 0x0a, 0x0d, 0x0a} )
Functions ¶
This section is empty.
Types ¶
type BlockSizeError ¶
type BlockSizeError struct {
// contains filtered or unexported fields
}
func (BlockSizeError) Error ¶
func (e BlockSizeError) Error() string
type Database ¶
type Database struct {
// contains filtered or unexported fields
}
func (*Database) SaveToPath ¶
func (*Database) SetPassword ¶
func (*Database) VerifyHeaderHash ¶
type ParseError ¶
type ParseError error
Click to show internal directories.
Click to hide internal directories.