0
0
mirror of https://github.com/signalapp/libsignal.git synced 2024-09-20 03:52:17 +02:00
Commit Graph

2315 Commits

Author SHA1 Message Date
Alex Konradi
a6a8eae650
Fix expected canonical test case output 2024-07-16 15:40:43 -04:00
moiseev-signal
dee9c5a06e
svr3: Assorted connection handling improvements 2024-07-16 12:19:14 -07:00
Alex Konradi
f6acd4f98d
Update backup.proto to latest version 2024-07-16 14:20:53 -04:00
Alex Konradi
66cd3f0133
backup: bridge canonical serialization as ComparableBackup 2024-07-16 14:20:31 -04:00
moiseev-signal
854343294d
svr3: Make partial migration easier and add a test 2024-07-15 16:27:16 -07:00
Alex Konradi
eea07a5638
Include -testing fns in FFI on testing-fns feature 2024-07-15 14:57:40 -04:00
Alex Konradi
535241d423
backup: add canonically-serializable type
Add a type with a canonical serialized form that, for the same logical backup 
contents (even with frame reorderings), will always serialize to the same value.
2024-07-15 14:48:59 -04:00
Alex Konradi
784164d4bb
backup: Make message backup types serializable 2024-07-12 15:20:25 -04:00
Jordan Rose
07801c8153 CI: The NPM action needs perms to upload GitHub Release artifacts
Also, don't include the checksum files generated by the build process.
2024-07-11 16:32:07 -07:00
Jordan Rose
a4a0663528 Bump to version v0.52.3 2024-07-11 14:10:27 -07:00
Jordan Rose
5b63a03ecd node: Put an empty install script so node-gyp isn't invoked implicitly 2024-07-11 14:08:52 -07:00
Jordan Rose
7261c37b46 Bump to version v0.52.2 2024-07-11 12:33:46 -07:00
Jordan Rose
21ddea4135 node: If the logging channel backs up, drop logs
(and warn that we might be dropping logs)
2024-07-11 12:03:59 -07:00
Alex Konradi
eb0a8ef60e
Update to latest backup.proto definition
Notable changes:
- custom colors are now referenced indirectly
- SimpleChatUpdate changes w/ new test cases
2024-07-11 15:01:50 -04:00
Jordan Rose
efaa3c4b2f net: Remember to set the confirmation header name for proxies 2024-07-10 17:59:25 -07:00
Jordan Rose
1e8b7388e3 net: Avoid hot loops in reconnect
This can happen if we get into an error state, or if we have a bug
that has the connection attempt early-exit. We don't want to spin in
place trying to connect.
2024-07-10 17:59:17 -07:00
Alex Konradi
6d3c1b057f
Add libsignal-bridge-testing for Swift
Use a similar strategy as for Node, but with an additional crate that serves as 
the target for running cbindgen. The expectation is that since iOS links with 
the native signal_ffi statically, the linker will be able to prune out the 
unsued test-only code.
2024-07-10 17:45:53 -04:00
moiseev-signal
89547673af
Quick-fix for the race between auth and unauth ws connectors 2024-07-10 14:11:32 -07:00
Alex Konradi
7af57ad1dd
backup: make recipient type vary with method
This replaces the recipient ID, which is a weak logical reference to external 
data, with one of two types, depending on the mode. For streaming validation, 
only the minimal data is kept. For validation via the CLI or (soon) for 
canonicalization, the full data is kept behind an Arc.
2024-07-10 17:07:34 -04:00
moiseev-signal
f794998389
SVR3: implement migrate API 2024-07-10 11:40:56 -07:00
Alex Konradi
31759a5680
Add libsignal-bridge-testing for Node
Unlike Java, just bundle it into the exiting signal_node shared library. We 
don't care as much about code size here and splitting it into a separate 
library is significantly more complicated (though it might be worth it some 
day).
2024-07-10 14:09:35 -04:00
Alex Konradi
5816c03a2f
Use zerocopy for safe transmutes 2024-07-10 09:30:51 -04:00
Jordan Rose
36c6eebc0e node: Remove "install" script that invokes node-gyp-build
- For local development, this built the Rust library automatically
  when you invoked `yarn install`, whether you wanted it to or not.

- For the published package, this either did nothing (if the correct
  prebuilds were present) or produced a weird error (if they weren't).
  You can't use the published package without prebuilds, so maybe this
  was useful, but you'd find that out pretty quickly when loading the
  module failed.

- If you used the "link" feature to build Signal Desktop with a local
  checkout of libsignal, this would build the Rust library
  automatically when you `install`ed in the *Desktop* directory,
  whether you wanted it to or not.

- If you pointed Signal Desktop at a local checkout by copy instead of
  link, this would just fail, because the Rust parts wouldn't be
  copied with it.

Overall, it's simpler to just have this step be explicit.
2024-07-09 18:04:14 -07:00
Jordan Rose
773530ecd1 Add type annotations to all our Python scripts
The main benefit of this is not our *own* type-checking; it's that
mypy will error out if you try to use a too-new Python API. And in
fact, we were already relying on Python 3.9 and didn't realize.

check_code_size.py works with JSON, so it still uses Any a fair bit.
2024-07-09 17:01:10 -07:00
Jordan Rose
377ca153ab node: Attach debug info to the GitHub Release 2024-07-09 17:00:36 -07:00
Jordan Rose
9aa5d07c10 node: Build with (split) debug info
We don't save that debug info anywhere yet, but it's a start!
This is following the pattern of build-electron in RingRTC.
2024-07-09 13:26:21 -07:00
Alex Konradi
0e4d420f69
Add libsignal-jni-testing crate with test-only functions for Java
This parallels the exiting libsignal-jni crate but exports functions from 
libsignal-bridge-testing instead of libsignal-bridge. The crate is compiled as 
a separate shared object that is included in the published libsignal package, 
but which can be excluded at Android packaging time.
2024-07-09 13:07:36 -04:00
Alex Konradi
c6857dd58e
Don't assume EOF on 0-length read for Node
Remove the special handling code that detects EOF now that the upstream crate 
has fixed the bug that was being worked around. This also fixes a bug where EOF 
was being incorrectly detected when the provided buffer was empty. Add a test 
case to prevent regression in the future.
2024-07-09 11:58:43 -04:00
Jordan Rose
2feac3495b swift: Replace last use of NSLog with new logging protocol 2024-07-08 14:49:22 -07:00
moiseev-signal
c870e23a5b
svr3: Implement restore with fallback function 2024-07-08 14:03:51 -07:00
Max Moiseev
4694d0a1a8 svr3: Support latest tpm2snp enclave 2024-07-08 14:03:10 -07:00
Max Moiseev
562f03abda attest: Stop validating PCR5 for tpm2snp 2024-07-08 14:03:10 -07:00
Alex Konradi
9355467f01 Add documentation for bridge crates
Explain the difference between libsignal-bridge and libsignal-bridge-types, and
how the pieces fit together.
2024-07-08 15:51:29 -04:00
moiseev-signal
b9efb3cc1b
Regenerate acknowledgements 2024-07-01 15:25:02 -07:00
Max Moiseev
2b48d18d23 Bump to version 0.52.1 2024-06-28 15:16:18 -07:00
Alex Konradi
a9868eccff
Bump NPM publish workflow macOS image version 2024-06-28 15:09:37 -07:00
Alex Konradi
e13e3de8b2 Bump to version v0.52.0 2024-06-28 14:55:58 -04:00
Alex Konradi
4cce5633d1
Avoid calling AsyncRead::read with empty target 2024-06-28 10:11:57 -04:00
Chris Eager
f26fd13631 Add SealedSenderMultiRecipientMessage#serialized 2024-06-26 17:01:01 -05:00
Sergey Skrobotov
4243979826
net: support status codes when responding to server messages 2024-06-26 14:40:04 -07:00
Alex Konradi
fc4e1dbcd6
Switch to JSON5 for backup .jsonproto parsing 2024-06-26 15:35:40 -04:00
Alex Konradi
ff864cce4d
Refactor gen_{ts,java}_decl.py
No behavior change, just moving code into named functions to improve 
readability and maintainability, and applying some Python conventions.

Co-authored-by: moiseev-signal <122060238+moiseev-signal@users.noreply.github.com>
2024-06-26 15:05:21 -04:00
Alex Konradi
bb44874400
Use a single source of truth for version file list 2024-06-26 14:11:04 -04:00
Harry
72aae8c00f
Remove SignalCoreKit dependency in libsignal 2024-06-26 09:44:22 -07:00
moiseev-signal
b85148cc1f
svr3: Implement query function 2024-06-25 14:27:09 -07:00
Alex Konradi
b064ec78c5
Upgrade rustc to latest nightly 2024-06-25 11:31:59 -04:00
Alex Konradi
49f9fa5498
Use --no-fail-fast for cargo test
Fix slow tests workflow
2024-06-24 12:45:37 -04:00
Chris Eager
2b5b51c7b3 Fix error string whitespace 2024-06-21 16:34:27 -07:00
Jordan Rose
6313b9715b ffi: Simplify error attribute getters using trait methods
It ought to be possible to go even further and use bridge_fn for these
now as well, but this is a start.
2024-06-21 16:34:13 -07:00
Jordan Rose
2a2ef524d2 Update to Node 20.11.1 2024-06-21 14:35:17 -07:00