Commit Graph

1295 Commits

Author SHA1 Message Date
Igor Sirotin a6d46756f5
fix(ImageUnfurler): set title for image links (#4215) 2023-10-26 17:52:52 +01:00
Teodor M. Ionita 4744ee899e Add TestPinMessageInCommunityChat, adjust pin permissions
Also check pin post permission a bit earlier for the sender, with
canPost() in sendPinMessage(), even though there is a later check down
the line in dispatchMessage().

Fixes #4138
2023-10-26 13:22:32 +03:00
frank 06a9fe4f81
fix: sync decision on join community request (#4190)
* fix: sync community request decision

* make generate

* simplify test

* make generate
2023-10-26 12:17:18 +08:00
Mohsen 27b770c41b
fix: publish group member info (#4184) 2023-10-25 21:11:04 +03:00
Patryk Osmaczko 445135eb94 fix: ensure receivedMessage.CommunityID in chat message handler is set
This enables clients to obtain invitation's community ID even when
description processing is queued.

part of: status-im/status-desktop#12481
2023-10-25 20:10:01 +02:00
Jonathan Rainville 6e0d4e697f
chore(messenger_communities): use new name for community Access (#4210) 2023-10-25 13:33:49 -04:00
Cuteivist debf3b6e4d
feat: Added ERC20 community id (#4189) 2023-10-25 18:49:18 +02:00
Boris Melnik 8ae6e3035b
feat(discord): Import single channel from discord (#4160) 2023-10-25 12:32:21 -04:00
Patryk Osmaczko 3452eb72a8 refactor: remove community invitation only access 2023-10-25 17:34:37 +02:00
Patryk Osmaczko b262d7e88c refactor: rename Community.OnRequest() -> AutoAccept() 2023-10-25 17:34:37 +02:00
Patryk Osmaczko b321f28c9d refactor: update community access enum naming 2023-10-25 17:34:37 +02:00
Shinnok 3805662a18
fix(messenger_communities): block messages and reactions to token gated or spectated communities (#4064)
Which specifies that if a user is not a community member & a
chat member, he can't post, react or pin messages in that chat.

Notes:
- also fix&cleanup associated failing tests.
- refactor Community.CanPost() to reflect the new requirement.
- grant code is not fully implemented and is to be removed later.

Fixes https://github.com/status-im/status-desktop/issues/11915
2023-10-25 10:26:18 -04:00
Igor Sirotin c6ff315dfc
fix: set pubsubTopic in request community info from mailserver (#4194) 2023-10-25 11:13:35 +01:00
Andrea Maria Piana 23f71c1125 Fix encryption id && rekey with a single message
This commit changes the format of the encryption id to be based off 3
things:

1) The group id
2) The timestamp
3) The actual key

Previously this was solely based on the timestamp and the group id, but
this might lead to conflicts. Moreover the format of the key was an
uint32 and so it would wrap periodically.

The migration is a bit tricky, so first we cleared the cache of keys,
that's easier than migrating, and second we set the new field hash_id to
the concatenation of group_id / key_id.
This might lead on some duplication in case keys are re-received, but it
should not have an impact on the correctness of the code.

I have added 2 tests covering compatibility between old/new clients, as
this should not be a breaking change.

It also adds a new message to rekey in a single go, instead of having to
send multiple messages
2023-10-24 20:48:54 +01:00
Mikhail Rogachev 1be356af93
feat: Profile showcase backend (#4005)
* feat: profile showcase preferences basic impl

(squashed)

* feat: save preferences in batch for profile showcase

* chore: add validation for profile showcase settings request

and fix migration order
2023-10-24 14:43:18 +04:00
Igor Sirotin e83be20def
fix: shared links and link previews contain full self information (#4169)
* fix(StatusUnfurler): allow contact without icon
2023-10-24 11:15:32 +01:00
frank 311e463eed
make lint-fix ignore for messenger_handlers.go (#4181)
* make lint-fix ignore messenger_handlers.go

* make lint-fix
2023-10-24 11:42:56 +08:00
Patryk Osmaczko dc6fe5613a fix: decouple permissions reevaluation from torrent client readiness 2023-10-22 21:50:41 +02:00
Patryk Osmaczko bd245ab45b refactor: unify `Owned()` and `ControlledCommunities()` 2023-10-22 21:50:41 +02:00
Patryk Osmaczko 345851c396 feat: ensure unique control node across devices
closes: status-im/status-desktop#11962
2023-10-22 21:50:41 +02:00
frank 624996a7e9
only sync decisions/state of AC notifications (#3979) 2023-10-22 17:41:20 +08:00
Patryk Osmaczko eb232d4680 fix: use `messengerSignalsHandler` instead of global object 2023-10-20 18:09:12 +02:00
Patryk Osmaczko 148721b680 chore: add `WaitOnSignaledMessengerResponse` test utility 2023-10-20 18:09:12 +02:00
Patryk Osmaczko fc8ce915af fix: prevent nil dereference in `IsControlNode` for existing communities 2023-10-19 22:11:53 +02:00
Patryk Osmaczko 05db628406 chore: omit `CommunityDescription` queuing if owner is already verified 2023-10-19 22:11:53 +02:00
Mykhailo Prakhov 74c13fd363
fix: setup owner as CommunityDescription signer after minting community owner token (#4168) 2023-10-19 13:03:41 +02:00
Patryk Osmaczko 3292c1c883 feat: rekey community on control node change
closes: status-im/status-desktop#11963
2023-10-18 22:32:29 +02:00
Patryk Osmaczko 246b68a8c0 refactor: rename and simplify `UpdatePrivateKeyAndControlNode` 2023-10-18 22:32:29 +02:00
Patryk Osmaczko 6c4ce3dedf fix: make `testJoinedPrivilegedMemberReceiveRequestsToJoin` less flaky 2023-10-18 17:11:20 +02:00
Patryk Osmaczko a9cde06e44 refactor: simplify community requests logic
With the recent introduction of pending states, the community requests
logic became more complex. This commit simplifies the flow and
appropriately delegates logic to its corresponding abstraction levels:
messenger, manager and community. Additionally, it eliminates
redundancies in notifications and request-saving mechanism.
2023-10-18 17:11:20 +02:00
Patryk Osmaczko b932cc97bb fix: ensure owners and token masters receive revealed addresses with
request to join
2023-10-18 17:11:20 +02:00
frank 3326362b90
optimised finding server cert (#4148)
* optimised finding server cert

* make sure `close(done)` invoked only once

* remove sleep

* resolve IDE warning

* refactor for findServerCert
2023-10-18 14:17:49 +08:00
Patryk Osmaczko 0881d8cdb0 Add queue for processing community description & configurable control node 2023-10-17 21:00:24 +01:00
Jonathan Rainville c8910d69fe
feat(pairing): sync 1-1 chats and groups on pairing devices (#4102)
Fixes #3547
2023-10-17 09:24:15 -04:00
Igor Sirotin 036173cfed
fix: always unfurl status links (#4159) 2023-10-17 08:25:45 +01:00
Michal Iskierko f2464cccfd fix: HandleCommunityTokensMetadata
Add all tokens in the loop.
Get MaxSupply instead of TotalSupply

Issue #12104
2023-10-15 20:32:47 +02:00
Igor Sirotin 176bdd297d
feat: url unfurling settings (#4128) 2023-10-13 15:31:56 +01:00
Igor Sirotin aded258ccb
feature: Unfurl status links (#4033) 2023-10-13 13:25:34 +01:00
Khushboo-dev-cpp ac813ef5d8
chore: Remove include watch only accounts settings as it is out dated and not needed anymore (#4153) 2023-10-13 11:23:24 +02:00
Jonathan Rainville 466dccc809
feat(backup): add 1-1 chats and group chats to backup (#4073)
* feat(backup): add 1-1 chats and group chats to backup

* add active

* add clock

* add muted
2023-10-12 17:15:05 -04:00
Richard Ramos de5c7b8e5b feat: shard fleet
Adds shard.test fleet and changes the non protected shard index to 64
2023-10-12 17:07:57 -04:00
Richard Ramos ace5b26137 fix: do not send the requests to join and cancel in the protected topic 2023-10-12 17:07:57 -04:00
Richard Ramos 350a952116 waku2: static shards
- use protected topics for communities
- associate chats to pubsub topics and populate these depending if the chat belongs to a community or not
- mailserver functions should be aware of pubsub topics
- generate private key for pubsub topic protection when creating a community
- add shard cluster and index to communities
- setup shards for existing communities
- distribute pubsubtopic password
2023-10-12 17:07:57 -04:00
richΛrd ba5ed725ce
waku2: static shards (#3944)
- use protected topics for communities
- associate chats to pubsub topics and populate these depending if the chat belongs to a community or not
- mailserver functions should be aware of pubsub topics
- generate private key for pubsub topic protection when creating a community
- add shard cluster and index to communities
- setup shards for existing communities
- distribute pubsubtopic password
- fix: do not send the requests to join and cancel in the protected topic
- fix: undefined shard values for backward compatibility
- refactor: use shard message in protobuffers
2023-10-12 15:21:49 -04:00
Alexander e17a247d0f
Revert unviewed message count changes (#4101) 2023-10-12 14:27:56 +02:00
Patryk Osmaczko 653df822da fix: derive community.Encrypted() from permissions 2023-10-12 01:45:33 +02:00
Jonathan Rainville 11f670636b
fix(communities): set state correctly on request accept or decline (#4144)
Fixes https://github.com/status-im/status-desktop/issues/12413
2023-10-11 15:55:52 -04:00
Vitaliy Vlasov 1fedf5503a Use WakuV2 in MessengerCommunitiesTokenPermissionsSuite 2023-10-11 12:56:38 +03:00
Patryk Osmaczko 1410b1e422 fix: ensure community channels are dehydrated on publish 2023-10-10 20:11:31 +02:00
Jonathan Rainville 736779d94b
fix(communities): make sure to join the community if we are a member (#4118)
Fixes https://github.com/status-im/status-desktop/issues/12368
2023-10-10 14:03:55 -04:00