Commit graph

67 commits

Author SHA1 Message Date
lilia
4e21e783db Fix tests 2017-02-16 19:32:23 -08:00
lilia
02ca0a09ac Remove dead code 2016-10-05 21:11:58 +09:00
lilia
89cd40c1f5 Remove stale comment 2016-09-22 14:46:05 -07:00
lilia
0dd7ca2569 Fix tests 2016-09-22 14:35:58 -07:00
lilia
f8e176fd40 Dedupe methods
Define textsecure.crypto in terms of libsignal.crypto.

// FREEBIE
2016-05-18 13:15:57 -07:00
lilia
148bd32671 Update libsignal-protocol v0.10.0
* Changes policy for old session deletion
* Renames putIdentityKey to saveIdentity
* Remove device messages

// FREEBIE
2016-05-18 11:11:11 -07:00
lilia
891ddacd35 Remove processPreKey from protocol_wrapper
Use SessionBuilder directly instead of protocol_wrapper

// FREEBIE
2016-05-14 23:26:32 -07:00
lilia
92293f9da9 Update libsignal-protocol v0.5.0
Renames libsignal.util to libsignal.KeyHelper.

// FREEBIE
2016-05-13 19:47:39 -07:00
lilia
418adff2a8 Rename device_storage_test.js
// FREEBIE
2016-05-10 19:38:44 -07:00
lilia
56238136ca Remove trivial wrapper method
// FREEBIE
2016-05-10 19:38:44 -07:00
lilia
9f871db48a Update libsignal-protocol / Update prekey format
Integrates change in prekey object formatting, which now matches more
conveniently with the representation rendered by the server.

// FREEBIE
2016-05-04 00:33:05 -07:00
lilia
f173104c82 Tests for isTrustedIdentity
// FREEBIE
2016-05-04 00:25:01 -07:00
lilia
e659104cbf Add isTrustedIdentity to SignalProtocolStore
Adds a new required storage method for the protocol library.

// FREEBIE
2016-05-03 23:58:57 -07:00
lilia
91bdd37019 Fix tests
// FREEBIE
2016-04-22 13:48:56 -07:00
lilia
b160556d6e Change filename
// FREEBIE
2016-04-22 13:43:31 -07:00
lilia
9a1a3bdf64 Rename axolotl to libsignal
// FREEBIE
2016-04-22 13:43:30 -07:00
lilia
6bffd50009 Fix comment
// FREEBIE
2016-04-22 13:43:30 -07:00
lilia
1d60dc38fb Rename axolotl storage
// FREEBIE
2016-04-22 13:43:30 -07:00
lilia
c1e1dd97ba Change libsignal-protocol filenames
// FREEBIE
2016-04-21 18:42:43 -07:00
lilia
b1d370755a Rename AxolotlStore
// FREEBIE
2016-04-21 18:36:17 -07:00
lilia
1fe5d63015 Update protocol libs
Rename storage functions

// FREEBIE
2016-04-21 18:36:16 -07:00
lilia
3e0bce2b21 Move, rename, and simplify toArrayBuffer helper
This function is only ever used to convert groupIds from strings to
array buffers in sendmessage.

// FREEBIE
2016-03-13 04:56:28 -07:00
lilia
c22a205d2e Remove unnecessary conversion from test
// FREEBIE
2016-03-13 04:56:28 -07:00
lilia
7c17c5fa54 Update chai
// FREEBIE
2016-02-01 15:54:23 -08:00
lilia
1ee6a2e43f Rebuild libtextsecure test components w/ new chai
// FREEBIE
2016-01-28 18:03:51 -08:00
lilia
52b039a900 Remove unused function
This is now used only internally in libaxolotl, which provides its own
definition.

// FREEBIE
2015-11-27 14:40:20 -08:00
lilia
b9b01330fe Move jquery from libtextsecure components
Jquery is not required by libtextsecure, but our test coverage tool,
blanket, depends on it.

// FREEBIE
2015-10-19 12:51:59 -07:00
lilia
7414828bb3 Disable keepalive tests
These are failing because MockSocket doesn't implement an EventTarget
interface like an actual WebSocket does, so we get an exception when
trying to call addEventListener on it. :(

// FREEBIE
2015-10-11 13:18:51 -07:00
lilia
5eabfa2559 Fix libtextsecure tests
// FREEBIE
2015-10-02 15:08:21 -07:00
lilia
f764445c86 Remove erroneous license file and headers
We only use GPLV3 around here.

// FREEBIE
2015-09-07 14:58:42 -07:00
lilia
2b563212b4 Change default for keepalive autodisconnect config
By default, automatically disconnect if no response. This is preferable
because we can sometimes lose connectivity without receiving a close
event from the socket, but it's also possible that the endpoint may not
support responses.

// FREEBIE
2015-07-29 11:30:58 -07:00
lilia
ebca58b282 Fix multiple calls to done
Triggered by multiple keepalives.
2015-07-28 17:11:11 -07:00
lilia
7c0eb5e080 Add keepalive reset test 2015-07-28 14:59:16 -07:00
lilia
01ca1be24e Fix test 2015-07-28 14:59:09 -07:00
lilia
44b7b32385 Update tests 2015-07-28 14:15:49 -07:00
lilia
4c9d69094d Work on message receiver tests
Not quite working yet

// FREEBIE
2015-07-27 18:16:47 -07:00
lilia
17e515f886 Add identity key conflict tests 2015-07-22 12:48:08 -07:00
lilia
7d3d634a2d Move/refactor keepalive logic and add disconnect timer
We now disconnect ourselves if we don't get the server's response to a
keepalive request within 30s. This way we will eventually disconnect if
the network goes away but the socket is not closed.*

* See code.google.com/p/chromium/issues/detail?id=197841 and
https://stackoverflow.com/questions/11755605/chrome-websocket-connection-not-closed-when-browser-closed

We will then try to reconnect once a minute (See 8a10c96);

Keepalives belong at this level anyway, since the format is defined by
both the websocket resource protocol and our specific server url
structure.

// FREEBIE
2015-07-16 15:01:34 -07:00
lilia
5925c2fe84 Support for group sync
Protocol and handling is all analogous to contact sync: Multiple
GroupDetails structs are packed into a single attachment blob and parsed
on our end. We don't display the synced groups in the conversation list
until a new message is sent to one of them.

// FREEBIE
2015-06-25 13:24:32 -07:00
lilia
8dc4e34aaf Bug and test fixes for contact sync
Closes #135

// FREEBIE
2015-06-18 13:48:32 -07:00
lilia
316838cfe9 Add tests and bug fixes for ContactBuffer 2015-06-17 12:29:40 -07:00
lilia
6d9854f456 Remove plaintext message test case
Support for the PLAINTEXT message type is not present in the latest
protobuf definitions. Leaving it out for now since we don't have any use
case for it currently.
2015-06-17 12:29:39 -07:00
lilia
a833d62a71 Implement sync protocol changes
Update protobuf definitions and refactor message receive and decrypt
codepath to support new protocol, including various flavors of sync
messages (sent messages, contacts, and groups).

Also cleans up background.js and lets libtextsecure internalize
textsecure.processDecrypted and ensure that it is called before handing
DataMessages off to the application.

The Envelope structure now has a generic content field and a
legacyMessage field for backwards compatibility. We'll send outgoing
messages as legacy messages, and sync messages as "content" while
continuing to support both legacy and non-legacy messages on the receive
side until old clients have a chance to transition.
2015-06-17 12:29:39 -07:00
lilia
029c9754f0 Fix tests 2015-05-15 11:39:23 -07:00
lilia
359b4a15a2 Move group storage to axolotl store
Add async get/put/removeGroup to axolotl store and let libtextsecure
use it for group state storage.
2015-05-06 17:49:23 -07:00
lilia
f413f03a6b Add getDeviceIds to axolotlstore
And add tests for getDeviceIds and removeAllSessions
2015-05-05 17:44:58 -07:00
lilia
7eda48f755 Move Session Storage to indexedDB 2015-05-05 17:44:58 -07:00
lilia
f38b18ef63 Move Session storage to axolotlstore 2015-05-05 17:44:57 -07:00
lilia
9e7d8c0a08 Rename textsecure.api and make it internal-only 2015-05-05 17:44:56 -07:00
lilia
f465bdddbf Add textsecure.AccountManager
This class should be used for account registration and for refreshing
prekeys for your account.
2015-05-05 17:44:55 -07:00