mirror of
https://github.com/go-i2p/go-i2p.git
synced 2025-07-05 14:13:30 -04:00
16 lines
449 B
Go
16 lines
449 B
Go
![]() |
package crypto
|
||
|
|
||
|
// decrypts data
|
||
|
type Decrypter interface {
|
||
|
// decrypt a block of data
|
||
|
// return decrypted block or nil and error if error happens
|
||
|
Decrypt(data []byte) ([]byte, error)
|
||
|
}
|
||
|
|
||
|
type PrivateEncryptionKey interface {
|
||
|
|
||
|
// create a new decryption object for this private key to decrypt data encrypted to our public key
|
||
|
// returns decrypter or nil and error if the private key is in a bad format
|
||
|
NewDecrypter() (Decrypter, error)
|
||
|
}
|