passforios-gopenpgp/crypto
marinthiercelin c46ed8ed9e
Add a streaming api to KeyRing and SessionKey (#131)
* barebone streaming functionality

* encryption needs to return a writecloser

* added eof check

* workaround for reader problem with copies

* separate mobile wrappers from main api

* add a clone in the read result to avoid memory corruption

* refactor to reuse code, and fix verification

* have to give the verify key at the start of the decryption

* enfore readAll before signature verification

* streaming api for SessionKey

* add split message stream apis

* name interface params

* fix streaming api so it's supported by go-mobile

* hide internal writeCloser

* fix nil access

* added detached sigs methods

* started unit testing

* unit testing and fixed a bug where key and data packets where inverted

* remove unecessary error wrapping

* figured out closing order and error handling

* add GC calls to mobile writer and reader

* remove debugging values and arrays

* writer with builtin sha256

* unit testing the mobile helpers

* comments and linting

* Typo in error

Co-authored-by: wussler <aron@wussler.it>

* Add GetKeyPacket doc

Co-authored-by: wussler <aron@wussler.it>

* Add rfc reference in comments

Co-authored-by: wussler <aron@wussler.it>

* small improvements

* add compatibility tests with normal methods

* remove unecessary copies in the tests

* update go-crypto to the merged changes commit

* update comments of core internal functions

* remove unused nolint comment

* group message metadata in a struct

* fix comments

* change default values for metadata

* change the mobile reader wrapper to fit the behavior of java

* remove gc calls in the wrappers to avoid performance penalties

* bring back the former Go2MobileReader to be used for ios

* Update crypto/keyring_streaming.go

Co-authored-by: wussler <aron@wussler.it>

* return an error when verifying an embedded sig with no keyring

* Update crypto/sessionkey_streaming.go

Co-authored-by: wussler <aron@wussler.it>

* linter error

* update changelog

* update changelog

Co-authored-by: wussler <aron@wussler.it>
2021-06-30 16:49:30 +02:00
..
testdata Add new attachment processor that uses pre-allocated buffer (#120) 2021-03-29 20:46:47 +02:00
attachment.go Removed the cloning of the final data in the attachment processor (#114) 2021-02-19 14:54:31 +01:00
attachment_manual.go Add new attachment processor that uses pre-allocated buffer (#120) 2021-03-29 20:46:47 +02:00
attachment_manual_test.go Add new attachment processor that uses pre-allocated buffer (#120) 2021-03-29 20:46:47 +02:00
attachment_test.go Fix various keys issues (#117) 2021-03-09 19:06:35 +01:00
base_test.go Update go-crypto (#129) 2021-04-28 18:33:14 +02:00
gopenpgp.go Refactor internals of client time (#134) 2021-06-16 17:24:25 +02:00
key.go Add methods to get key capabilities (#125) 2021-04-09 12:32:10 +02:00
key_clear.go Update go-crypto (#129) 2021-04-28 18:33:14 +02:00
key_test.go Update go-crypto (#129) 2021-04-28 18:33:14 +02:00
keyring.go Add methods to get key capabilities (#125) 2021-04-09 12:32:10 +02:00
keyring_message.go Add a streaming api to KeyRing and SessionKey (#131) 2021-06-30 16:49:30 +02:00
keyring_session.go Fix various keys issues (#117) 2021-03-09 19:06:35 +01:00
keyring_streaming.go Add a streaming api to KeyRing and SessionKey (#131) 2021-06-30 16:49:30 +02:00
keyring_streaming_test.go Add a streaming api to KeyRing and SessionKey (#131) 2021-06-30 16:49:30 +02:00
keyring_test.go Update go-crypto (#129) 2021-04-28 18:33:14 +02:00
message.go WIP: Add tests for attachments (#116) 2021-03-08 17:59:03 +01:00
message_getters.go
message_test.go Update x/crypto fork to github.com/ProtonMail/go-crypto (#106) 2020-12-08 18:34:39 +01:00
mime.go Update x/crypto fork to github.com/ProtonMail/go-crypto (#106) 2020-12-08 18:34:39 +01:00
mime_test.go
password.go Update x/crypto fork to github.com/ProtonMail/go-crypto (#106) 2020-12-08 18:34:39 +01:00
sessionkey.go Add a streaming api to KeyRing and SessionKey (#131) 2021-06-30 16:49:30 +02:00
sessionkey_streaming.go Add a streaming api to KeyRing and SessionKey (#131) 2021-06-30 16:49:30 +02:00
sessionkey_streaming_test.go Add a streaming api to KeyRing and SessionKey (#131) 2021-06-30 16:49:30 +02:00
sessionkey_test.go Add methods for embedded signatures using session keys (#128) 2021-04-27 17:38:25 +02:00
signature.go Update x/crypto fork to github.com/ProtonMail/go-crypto (#106) 2020-12-08 18:34:39 +01:00
signature_collector.go Update x/crypto fork to github.com/ProtonMail/go-crypto (#106) 2020-12-08 18:34:39 +01:00
signature_test.go Improve error handling, fix linter (#92) 2020-10-29 12:42:32 +01:00
time.go Refactor internals of client time (#134) 2021-06-16 17:24:25 +02:00
time_test.go Remove monotonic clock (#133) 2021-06-16 14:06:07 +02:00