Tulir Asokan
9722361288
Use contexts in signal stores properly
2024-01-04 01:06:45 +02:00
Tulir Asokan
0829e48069
Use uuid type everywhere in signalmeow
2024-01-03 23:14:54 +02:00
Tulir Asokan
429125dbf5
Clean up some attachment-related things
2024-01-03 22:35:24 +02:00
Tulir Asokan
b47620f6dd
More debugging things
2024-01-03 17:58:21 +02:00
Tulir Asokan
c03b0f84f5
Handle read receipts properly
2024-01-03 17:02:15 +02:00
Tulir Asokan
c2a7b6aa01
Check sender certificate expiry
2024-01-03 12:48:31 +02:00
Tulir Asokan
75078c7964
Adjust some logs
2024-01-03 12:26:24 +02:00
Sumner Evans
897eda98e1
zerolog: remove instances of using global log
...
Signed-off-by: Sumner Evans <me@sumnerevans.com>
2024-01-02 21:45:06 -07:00
Sumner Evans
36cca66190
provisioning: use structured logging
...
Signed-off-by: Sumner Evans <me@sumnerevans.com>
2024-01-02 21:45:06 -07:00
Sumner Evans
59e4efd598
signalmeow: use structured logging
...
Signed-off-by: Sumner Evans <me@sumnerevans.com>
2024-01-02 21:45:06 -07:00
Sumner Evans
5558469743
http: use http.Method* instead of hard-coded methods
...
Signed-off-by: Sumner Evans <me@sumnerevans.com>
2024-01-02 21:35:42 -07:00
Tulir Asokan
616f4f4a29
Don't allow copying structs with finalizers
2024-01-03 00:16:19 +02:00
Tulir Asokan
31c48d9e83
Add trace log with raw Signal message data
2024-01-03 00:16:19 +02:00
Tulir Asokan
9b459150c4
Refactor Matrix -> Signal message handling
2024-01-03 00:16:19 +02:00
Tulir Asokan
a0fbdee4c0
Fix handling sync messages in group
2024-01-02 19:22:16 +02:00
Tulir Asokan
9efe31d789
Refactor Signal -> Matrix message handling
...
Also add support for edits
2024-01-02 19:04:45 +02:00
Tulir Asokan
5842da7c4a
Add Signal root CA cert
2023-12-31 17:14:22 +01:00
Tulir Asokan
35db0abe8b
Refactor database tables and query wrappers ( #402 )
...
* Change most columns to `NOT NULL`, including primary keys
(because SQLite).
* Change columns only storing signal user IDs (portal receiver, message
sender, user uuid) to use the `uuid` type instead of `TEXT`.
* Drop chat ID from message table primary key.
* Add part index to message table to replace timestamp hack for storing
multiple parts of the same message.
* Change query wrappers to use new QureyHelper struct in dbutil, and
pass contexts and errors everywhere.
As a part of changing the portal receiver from phone number to uuid,
old portals whose receiver isn't logged in anymore may be discarded.
The discarded portals will be stored in the lost_portals table for
cleanup or recovery.
2023-12-31 16:12:58 +02:00
Tulir Asokan
b7c0e6ee74
Fix panic if bridge is stopped before websocket connects
2023-12-30 21:01:37 +01:00
Tulir Asokan
5c5c822624
Add support for device names
2023-12-30 21:00:11 +01:00
Tulir Asokan
bb94d392a7
Improve ping command
2023-12-30 20:53:47 +01:00
Sumner Evans
9152313cde
modules: un-modulify libsignalgo and signalmeow
...
I don't see any reason why they should have their own go.mod. I think
this is legacy from when I had them in separate repositories.
If we ever need to split those packages out into their own repo, we can
just:
1. Copy the directories to a new repo
2. Copy the go.mod/go.sum files
3. Run `go mod tidy` in this repo and the new repo.
This commit also removes the go.work and go.work.sum files.
Signed-off-by: Sumner Evans <me@sumnerevans.com>
2023-12-29 18:33:31 -07:00
Tulir Asokan
38e0c5fca6
Partially fix replying to files
2023-12-26 19:53:49 +01:00
Tulir Asokan
d78e006bc6
Fix panics when receiving stickers
2023-12-26 19:39:01 +01:00
Tulir Asokan
c6d22f403b
Fix sending captions. Fixes #393
2023-12-26 17:56:43 +01:00
Tulir Asokan
3a3c7299fe
Remove custom UUID type
2023-12-22 14:48:47 +02:00
Tulir Asokan
5efa86b627
Fix method receiver name
2023-12-22 13:50:56 +02:00
Tulir Asokan
df03fcdeb9
Fix over-indentation of incoming request handler
2023-12-22 13:49:38 +02:00
Tulir Asokan
ae60c41282
Actually update protobufs
2023-12-21 18:06:58 +02:00
Tulir Asokan
8260ba1559
Add support for Matrix -> Signal formatting
2023-12-21 16:57:21 +02:00
Tulir Asokan
54aab69650
Merge remote-tracking branch 'AndrewFerr/inbound-descriptions'
2023-12-18 01:02:29 +02:00
Tulir Asokan
61ef8904e9
Add support for Signal -> Matrix formatting
2023-12-17 22:50:09 +02:00
Tulir Asokan
06d0939645
Hack message conversion to make captions optional
2023-12-17 18:14:09 +02:00
Tulir Asokan
ea6b2df562
Fix contact avatar mime types
2023-12-17 17:39:40 +02:00
Tulir Asokan
5e1025cdca
Fix displayname template and add use contact avatar option
2023-12-17 17:32:20 +02:00
Tulir Asokan
49ce1f530c
Add copyright headers
2023-12-17 15:54:35 +02:00
Tulir Asokan
61841ca4f1
Organize imports
2023-12-17 15:21:21 +02:00
Tulir Asokan
396071be12
Update dependencies
2023-12-17 15:16:18 +02:00
Tulir Asokan
d73ba502ef
Switch signalmeow upgrades to dbutil
2023-12-17 15:14:31 +02:00
Tulir Asokan
0c009e58fa
Merge remote-tracking branch 'element-hq/go/fix-contact-profile-key-column-type'
2023-12-17 14:52:37 +02:00
Scott Weber
63b24c86d1
Send BAD_CREDENTIALS on signalgo migration
...
Or really any time Signal device credentials should be in signalmeow DB
but aren't there.
2023-12-14 14:54:18 +00:00
Scott Weber
3953789ef0
Support kyber prekeys and use them during provisioning
2023-12-13 22:15:41 +00:00
Scott Weber
607f33e069
New provisioning flow (for /v1/devices/link)
...
Note: this returns 422, I think I need to include kyber prekeys
2023-12-12 22:54:38 +00:00
Scott Weber
9ea94243a9
Update bridge to use libsignal v0.36.1 and latest protobufs
...
- Update libsignal to v0.36.1 and run protobuf fetch and update
- Update libsignalgo to work with libsignal v0.36.1
2023-12-10 21:39:43 -05:00
Andrew Ferrazzutti
bdc2fec369
Refactor for code reuse
2023-12-07 00:41:59 -05:00
Andrew Ferrazzutti
dd48c404c2
Bridge descriptions from Signal
2023-12-07 00:41:59 -05:00
Scott Weber
7d487dbd2f
Hack to fix bridging multiple images from Signal
...
and include very basic and buggy support for reacting to them
2023-11-29 13:07:20 -05:00
Andrew Ferrazzutti
6f378d1b99
Upgrade only for postgres
2023-11-24 11:41:24 -05:00
Andrew Ferrazzutti
afab8bf265
Set contact table profile key type to bytea
...
Make it use the same data type as the profile keys table.
This fixes UTF encoding errors when using a postgres store.
2023-11-24 01:40:31 -05:00
Scott Weber
8f3f50eb87
Handle ws == nil, and ws reconnect loops
2023-11-22 23:06:41 -05:00