Commit Graph

929 Commits

Author SHA1 Message Date
Evgeny Poberezkin 4c0414d2d6 update readme 2022-01-11 20:51:39 +00:00
Efim Poberezkin 2f342d3914 clarify wording in Linode script comment on server address 2022-01-11 21:58:40 +04:00
Efim Poberezkin 70823b899f remove Linode referral link (#283) 2022-01-11 21:11:27 +04:00
Efim Poberezkin b6aa0c886a link to smp-server by simplexchat StackScript (#282) 2022-01-11 20:57:47 +04:00
Efim Poberezkin 3909c7b10e remove Subject Alternative Names from server certificate (#281) 2022-01-11 20:48:27 +04:00
Efim Poberezkin 5306489d72 initialize server with IP and FQDN; specify FQDN as address if provided (#279) 2022-01-11 20:24:39 +04:00
Evgeny Poberezkin f62cc8bda5 Update CHANGELOG.md
Co-authored-by: Efim Poberezkin <8711996+efim-poberezkin@users.noreply.github.com>
2022-01-11 16:11:04 +00:00
Evgeny Poberezkin d8a61de290 Merge branch 'master' into ep/v1-rc 2022-01-11 16:02:10 +00:00
Evgeny Poberezkin 083d39be22 store missing port as empty string instead of NULL (#280) 2022-01-11 16:01:09 +00:00
Efim Poberezkin d48da40f7e add IP and FQDN to online certificate (#278) 2022-01-11 16:35:06 +04:00
Evgeny Poberezkin 1cf68ae448 note in readme 2022-01-11 07:49:49 +00:00
Evgeny Poberezkin c81e667e01 update version and changelog 2022-01-11 07:41:41 +00:00
Evgeny Poberezkin c95854ee3f Merge branch 'master' into ep/v1-rc 2022-01-11 07:28:26 +00:00
Evgeny Poberezkin b5cb5618c1 JSON instances for ConnectionRequestUri (#276) 2022-01-11 07:21:53 +00:00
Efim Poberezkin 14afa24a0a disable websockets by default (#277) 2022-01-11 11:21:02 +04:00
Efim Poberezkin 0bfac998a5 update Linode and DigitalOcean server recipes (#274) 2022-01-11 10:41:02 +04:00
Evgeny Poberezkin 0775bceb5e remove unnecessary separation of UnliftIO instance for ExceptT (#275) 2022-01-10 19:06:04 +00:00
Efim Poberezkin db5ae65f3c Merge branch 'stable' 2022-01-10 22:17:33 +04:00
Efim Poberezkin 92b3137b79 non interactive apt commands in server recipes (#272) 2022-01-10 22:08:38 +04:00
Evgeny Poberezkin 77b1d05da2 preparing v1 release 2022-01-10 14:04:41 +00:00
Evgeny Poberezkin 2a89394174 integrate double ratchet into agent (#268)
* separate skipped messages from ratchet

* return diff for skipped messages instead of the whole state (tests fail)

* fix ratchet tests

* JSON encoding/decoding for ratchet state

* schema for ratchets

* split MonadUnliftIO instance for ExceptT to a separate file

* update StrEncoding instance for Str

* ratchet store methods

* updateRatchet store method

* move E2E ratchet params to Ratchet module

* x3dh key agreement for double ratchet

* test/fix x3dh, use x3dh for ratchets initialization

* store/get x3dh keys, save ratchet of fixed X448 type

* double-ratchet encryption integration (tests fail)

* fix double ratchet

* fix padding and message length

* remove unused code for "activations"

* remove comment

* add version checks for forward/backward compatibility

* split loading ratchet and skipped message keys

* remove unused encoding instances for Algorithm types

* update ratchet initialization params
2022-01-10 12:01:54 +00:00
Efim Poberezkin 4d68042884 change initial migration date (migrations merged) (#267) 2022-01-07 17:03:00 +04:00
Efim Poberezkin 5e57c5dfd7 rename remaining occurrences of connection alias into connection id (#265) 2022-01-07 15:37:40 +04:00
Efim Poberezkin d87ff42cf5 start with internal message id 1; fix id ordering in tests (#264) 2022-01-07 14:52:37 +04:00
Evgeny Poberezkin c4f7020aae Merge pull request #263 from simplex-chat/ep/delete-control-messages
delete control messages after ACK to server
2022-01-07 08:54:20 +00:00
Evgeny Poberezkin 624360bf39 delete control messages after ACK to server 2022-01-07 08:47:35 +00:00
Evgeny Poberezkin ee5f144ea5 Merge pull request #259 from simplex-chat/ep/message-delivery
concurrent message delivery with a separate thread/queue per connection
2022-01-06 16:47:07 +00:00
Evgeny Poberezkin 7ca0ead6a2 Merge branch 'master' into ep/message-delivery 2022-01-06 16:42:16 +00:00
Evgeny Poberezkin b415537ba5 simplify message delivery 2022-01-06 16:41:39 +00:00
Evgeny Poberezkin a5a00f3d02 Merge branch 'stable' into ep/message-delivery 2022-01-06 16:38:22 +00:00
Evgeny Poberezkin dd4ccce1ba 0.5.2 v0.5.2 2022-01-06 13:52:54 +00:00
Evgeny Poberezkin 584f230c4d update versions for 0.5.2, changelog (#261) 2022-01-06 13:50:50 +00:00
Evgeny Poberezkin 10c62e7fa2 fix message delivery when quota exceeded - making it concurrent per queue, not per server (#260)
* test: HELLO blocking message delivery on the same server

* test: quota exceeded in one queue should not block delivery in other queues

* fix test to work in stable branch

* simplify pending message delivery (#202)

* simplify pending message delivery (WIP)

* refactor

* fix concurrent message delivery

* remove type synonym
2022-01-06 08:56:19 +00:00
Evgeny Poberezkin 02c023f939 remove message statuses and unused timestamps (#257) 2022-01-06 08:41:39 +00:00
Evgeny Poberezkin 6f1d9db8ec test: quota exceeded in one queue should not block delivery in other queues 2022-01-05 21:48:40 +00:00
Evgeny Poberezkin 3c923a3dc0 test: HELLO blocking message delivery on the same server 2022-01-05 21:12:31 +00:00
Evgeny Poberezkin ec0881f50f remove message statuses and unused timestamps 2022-01-05 19:57:04 +00:00
Evgeny Poberezkin 488398df9f change message envelopes and encoding, unify message delivery (#252)
* types and encodings for double ratchet integration

* upgrade stack resolver

* type classes for version agreement, encode/decode connection request links and E2E params with versioning

* encode/decode client parameters (version and DH key) in SMP queue URI using query string parameters

* restore support of the current SMP queue URI format

* update AMessage to only send queues in REPLY message (not the full connection request)

* new agent message evnvelopes (tests fail)

* new message envelopes - tests pass

* store fully encrypted messages before sending

* unify message delivery via DB queue (excluding confirmation and invitation)

* remove activateSecuredQueue

* linter hints

* remove comment

* export order

* save rachet-encrypted message, not per-queue encrypted

* delete message after it is accepted by the server, reduce message delivery interval for the tests

Co-authored-by: Efim Poberezkin <8711996+efim-poberezkin@users.noreply.github.com>
2022-01-05 19:52:37 +00:00
Efim Poberezkin e452c6ebff delete received messages after sending ACK to server (#256) 2022-01-05 16:52:28 +04:00
Efim Poberezkin 19edf09ae2 add deleteMsg to agent store interface (#255) 2022-01-05 16:11:52 +04:00
Efim Poberezkin 4727e568d5 fix x509 call to be compatible with openssl version 1.1.1 (#253) 2022-01-03 20:59:53 +04:00
Evgeny Poberezkin 4a73a7ecd4 remove public header from all messages, fix envelope sizes (#251)
* fix envelope sizes

* only send sender DH pub key for per-queue E2E with confirmation message
2022-01-03 14:33:30 +00:00
Evgeny Poberezkin 83d085cadc amend SMP protocol doc (#232)
* amend SMP protocol doc

* Update protocol/simplex-messaging.md

Co-authored-by: Efim Poberezkin <8711996+efim-poberezkin@users.noreply.github.com>

* Update protocol/simplex-messaging.md

Co-authored-by: Efim Poberezkin <8711996+efim-poberezkin@users.noreply.github.com>

* Update protocol/simplex-messaging.md

* Update protocol/simplex-messaging.md

Co-authored-by: Efim Poberezkin <8711996+efim-poberezkin@users.noreply.github.com>
2022-01-02 22:48:01 +00:00
Evgeny Poberezkin f3523bbba9 make KeyHash non-optional, verify KeyHash in SMP handshake, use StrEncoding class (#250)
* make KeyHash non-optional, StrEncoding class

* change server URI format in agent config, refactor with StrEncoding

* refactor Crypto using checkAlgorithm

* refactor parsing connection requests

* prepare to validate CA fingerprint sent in client handshake

* KeyHash check in handshake

* rename type to CliCommand

* server validates keyhash sent by the client

* validate -a option when parsing

* more of StrEncoding
2022-01-02 22:24:43 +00:00
Efim Poberezkin 33bb38299b refactor server Main.hs (#248) 2022-01-02 21:49:40 +04:00
Evgeny Poberezkin f314ff1bb6 add links to overview (#249) 2022-01-01 14:22:43 +00:00
Evgeny Poberezkin 1737686c1e update overview (#233)
* update overview

* network/framework -> platform

* fix links

* corrections

* corrections

* correction

* correction

* corrections

* update acknowledgements

* remove old overview.md

* update cyptographic primitives, remove acknoledgement

Co-authored-by: Efim Poberezkin <8711996+efim-poberezkin@users.noreply.github.com>
2022-01-01 13:59:03 +00:00
Evgeny Poberezkin 5e29e3698e binary SMP protocol encoding, split Command type to two types (#245)
* binary SMP protocol encoding (server tests fail)

* use 1 byte for bytestring length when encoding/decoding

* Encoding class, binary tags

* update server tests

* negotiate SMP version in client/server handshake

* add version columns to queues and connections

* split parsing SMP client commands and server responses to different functions

* check uniqueness of protocol tags

* split client commands and server responses/messages to separate types

* update types in SMP client

* remove pattern synonyms for SMP errors

* simplify getHandshake

* update SMP protocol encoding in protocol spec

* encode time as a number of seconds (64-bit integer) since epoch
2022-01-01 13:10:19 +00:00
Evgeny Poberezkin 5e3f66a4cb update DB fields presentations: port, QueueStatus, RcvMsgStatus, SndMsgStatus (#244)
* make port nullable

* make conversions of enum types to/from text explicit; remove unused statuses/fields

* Update src/Simplex/Messaging/Agent/Store.hs

* rename RcvMsgStatus constructors

Co-authored-by: Efim Poberezkin <8711996+efim-poberezkin@users.noreply.github.com>
2021-12-30 09:33:47 +00:00
Evgeny Poberezkin c8178e7f1f improve crypto key type classes (#246)
* improve crypto key type classes

* add inline pragmas
2021-12-30 08:51:20 +00:00