Commit Graph

265 Commits

Author SHA1 Message Date
Mykhailo Prakhov 77214dcb5d
feat: admins can delete all members messages during the ban (#4834) 2024-02-29 18:54:17 +01:00
Michal Iskierko df930b1d73 feat: New field in TokenCriteria proto
AmountInWei will have a wei-like units.
Amount field becomes deprecated because it kept string with float value.

Comparison (in case of Decimals == 5):
Amount (deprecated) = "1.2"
AmountInWei = "120000"

Issue #11588
2024-02-27 16:25:26 +01:00
Patryk Osmaczko eeaff0d3e3 fix: sync&backup channels encryption keys
fixes: status-im/status-desktop#13356
2024-02-26 16:41:30 +01:00
Mykhailo Prakhov 92bc64bb41
feat: kicked/banned member should not have spectated mode after the kick/ban (#4806) 2024-02-26 13:33:07 +01:00
Mykhailo Prakhov 3959948c4c
chore: fix ban/unban flow and delete all messages feature (#4743)
feat: delete all messages for banned member and ban/unban AC notifications
2024-02-22 11:25:13 +01:00
Patryk Osmaczko e2cab1a8ae fix: ensure community events eventual consistency
- Extracted `community_events_factory.go`
- Introduced `eventsProcessor`
  - Improved processing logic order
  - Improved events filtering
- Introduced concept of `EventTypeID` to prevent redundant events handling
- Added sanity check before events appliance when reading community from
  database
- Removed reject&re-apply scheme (no more ping-pong issue)
- Fixed and added more variants to eventual consistency test

fixes: status-im/status-desktop#13387
fixes: status-im/status-desktop#13388
2024-02-20 21:07:01 +01:00
Pablo Lopez 3f19972c8e
enable custom community storenodes (#4532)
* enable custom community store nodes

* fix

* fix

* fix

* fix

* cleanup

* fix

* migration

* fix

* cleanup

* fix

* cleanup

* fix

* fix

* cleanup

* message to update the community storenodes

* rename

* fix test

* wait for availability only if global storenode

* fix test

* fix typo

* sync community storenodes

* remove unused

* add tests

* fix imports

* fix todo

* unused

* pr comments

* pr feedback

* revert merge deleted

* fix lint

* fix db and perform ms request

* typo

* fix log

* fix go imports

* refactor handle message

* cleanup public message

* add tests

* fix test

* cleanup test

* fix test

* avoid making one file to big to keep codeclimate from complaining

* fix lint

* revert

* Update protocol/storenodes/database.go

Co-authored-by: richΛrd <info@richardramos.me>

* Update protocol/messenger_mailserver_cycle.go

Co-authored-by: richΛrd <info@richardramos.me>

* PR comment

* fix tx

* proto files

* pr comment

---------

Co-authored-by: richΛrd <info@richardramos.me>
2024-02-20 17:49:39 +02:00
Cuteivist a866b8025e
feat: Community token received notification (#4682) 2024-02-19 14:55:38 +01:00
Andrea Maria Piana 27f0884b51 Exclude watch only accounts from permissions checks 2024-02-14 17:03:28 +00:00
Mikhail Rogachev 9b7926b23b
feat: delete profile showcase community entry on community leave or kicked (#4686) 2024-02-09 12:37:54 +03:00
Andrea Maria Piana c49a0fc314 [Fixes: #4687] Change requestsToJoinCommunity to a map
The test was flaky because of re-receiving the message, which resulted
in multiple identical requestsToJoin being added to messengerResponse.

We should in general avoid using arrays in messengerResponse and prefer
maps for exactly this reason.
2024-02-08 11:18:53 +00:00
Icaro Motta 4f8a66fc07 Create endpoint to get permissioned balances 2024-02-07 20:10:49 +00:00
Jonathan Rainville 18e7b6c331
Fix Discord Import getting stuck (#4681)
* fix(community_import): fix import getting stuck in case of error in msgs

Fixes #13438 and #13439

* fix(community_import): fixes a bug with the timestamp format

The importer didn't like `-` time zones like `-4`. Using the standard date format makes it work.
2024-02-07 13:02:47 -05:00
Andrea Maria Piana 605fe40e32 Fix encryption metadata issues #4613
This commit fixes a few issues with communities encryption:

Key distribution was disconnected from the community description, this created a case where the key would arrive after the community description and that would result in the client thinking that it was kicked.
To overcome this, we added a message that signals the user that is kicked. Also, we distribute the key with the community description so that there's no more issues with timing.
This is a bit expensive for large communities, and it will require some further optimizations.

Key distribution is now also connected to the request to join response, so there are no timing issues.

Fixes an issue with key distribution (race condition) where the community would be modified before being compared, resulting in a comparison of two identical communities, which would result in no key being distributed. This commit only partially address the issue.
2024-02-07 10:25:41 +00:00
richΛrd 98c1ebec05
fix: handle community shard unassignment and update (#4627) 2024-01-30 13:56:59 -04:00
Igor Sirotin 1f0fc2935c
fix: clear waku envelopes cache when deleting a chat (#4621)
* chore: extract `ErrPermissionToJoinNotSatisfied`
* chore: disable resending messages in communities tests
* chore: move newTestMessenger extraOptions to testMessengerConfig
* chore: `WithTestStoreNode` messenger option
* feat: waku `ClearEnvelopesCache` method
* fix: call `ClearEnvelopesCache` when deleting chat
* chore: `TestBecomeMemberPermissions` checks messages after rejoin
2024-01-30 13:43:34 +00:00
Patryk Osmaczko 4a7d15b36d fix: use CommunityShardKey's clock rather than community's clock 2024-01-29 21:31:11 +01:00
Patryk Osmaczko ac81c15805 fix: ignore outdated COMMUNITY_SHARD_KEY messages
This mitigates issue where community shard on client's side was not in
sync with owner's.

relates to: status-im/status-desktop#13217
2024-01-29 18:21:51 +01:00
Patryk Osmaczko 1a85a29b1b chore: cover community sharding with tests
closes: #4262
2024-01-24 14:24:57 +01:00
Ibrahem Khalil 436d229856
Add last opened at key for community (#4514) 2024-01-21 12:55:14 +02:00
Roman Volosovskyi 9aef13f83e
[#4200] Enable prevention of tx detection on unrevealed mnemonic/address (#4444) 2024-01-16 15:17:02 +01:00
Mykhailo Prakhov 94bee02ef7
chore: fetch comunity token metadata during handling community description (#4562) 2024-01-16 09:08:56 +01:00
Patryk Osmaczko 3ddec465c5 fix: restore FetchCommunity&TryDatabase fallback to store nodes
Add missing check caused by recent `communities.GetByID` refactoring.
2024-01-12 13:15:29 +01:00
Patryk Osmaczko 2a5dc6dec0 chore: remove boilerplate check of `communities.GetByID` clients
motivated by:
https://github.com/status-im/status-go/pull/4514#discussion_r1445808116
2024-01-10 18:58:17 +01:00
Dario Gabriel Lipicar 781a2c7c8e fix: ensure needed community tokens are available in the db
Fixes #13171
2024-01-10 12:57:10 -03:00
Dario Gabriel Lipicar 9d9c40b7cf fix: make fetchCommunity return latest available community
Fixes #13145
2024-01-08 18:09:21 -03:00
Igor Sirotin 405d468e0e
fix: force verifiedOwner in `handleSyncInstallationCommunity` (#4405) (#4538) 2024-01-08 15:57:57 +00:00
Michal Iskierko 53ac61bb8b fix: a few adjustments for matterbridge
- exposig Online info
- adding ability to disable backup loop and auto message loop

Issue #12710
2024-01-08 14:21:26 +01:00
Igor Sirotin 195982c950
fix_(StoreNodeRequestManager): various fixes and improvements (#4509) 2023-12-27 13:53:19 +00:00
Patryk Osmaczko 1d3c618fb4 feat: encrypt `CommunityDescription` fields
Extended `CommunityDescription` with a `privateData` map. This map
associates each hash ratchet `key_id` and `seq_no` with an encrypted
`CommunityDescription`. Each encrypted instance includes only data
requiring encryption.

closes: status-im/status-desktop#12851
closes: status-im/status-desktop#12852
closes: status-im/status-desktop#12853
2023-12-22 18:17:06 +01:00
Mykhailo Prakhov 134137f9c5
feat: implemented a mechanism to retrieve shard information for a given community ID (#4499)
* feat: a mechanism to retrieve shard information for a given community ID
2023-12-22 13:37:37 +01:00
Mykhailo Prakhov a5f6a6c2f6
fix: privileged member accepted/rejected request to join action is not approved by the control node after the member leaved and tries to join the community again (#4487) 2023-12-19 14:45:34 +01:00
Igor Sirotin e3ef8c649a
chore: store node requests manager (#4446) 2023-12-15 19:50:12 +00:00
Ibrahem Khalil 90c31afe7c
New way of sharing communities (#4341) 2023-12-15 13:55:32 +02:00
Ibrahem Khalil be8568e174
Community member joins the community if he sends a request to join an… (#4321) 2023-12-09 14:46:30 +02:00
Mykhailo Prakhov fe604b2806
fix: tokenMaster does not have members revealed addresses (#4425) 2023-12-07 17:27:14 +01:00
Mykhailo Prakhov 04c533b8d5
chore: API for getting all non-approved requests to join for all communities (#4422) 2023-12-05 15:50:45 +01:00
Mykhailo Prakhov 058120fad9
chore: parse all non confirmed requests to join of the community during getting all communities (#4409) 2023-12-04 19:20:09 +01:00
Andrea Maria Piana b4b9db8578 Fix panic syncing community token gated 2023-11-30 12:57:38 +00:00
Mykhailo Prakhov 19464eb345
feat: show activity center notification if user must reveal addressed to join/rejoin the community (#4373)
- show activity center notification if user must reveal addressed to join/rejoin the community
- fixed unit test, added validation that ex-owner receive AC notification
2023-11-27 10:54:46 +01:00
Igor Sirotin e32c5546e1
test: request community from storenode (#4364)
* feat: request community info from storenode test

* shutdownWaitGroup

* fix requestCommunityInfoFromMailserver timestamp roundin
2023-11-25 23:24:20 +00:00
Mykhailo Prakhov 5cd20ded4e
chore: fix sending request to join msg's to the new owner (#4371) 2023-11-23 16:58:43 +01:00
Richard Ramos c012f94681 fix: send request on non protected topics, and add missing shard information on invite 2023-11-18 12:12:06 -04:00
Vitaly Vlasov 1794b93c16 Always set PubsubTopic in filters 2023-11-18 02:26:34 +02:00
Patryk Osmaczko 5b51c32a4a refactor: extract messenger_curated_communities.go 2023-11-16 17:21:28 +01:00
Boris Melnik 44625a2904
chore(discord): Move import from discord functionality to separatefile (#4278) 2023-11-13 13:29:31 +03:00
richΛrd 2c954d42cf
feat: replace DefaultPubsubTopic by Shard 32 (#4161) 2023-11-09 20:29:15 -04:00
Patryk Osmaczko f7042e4b9e refactor: extract layers in StatusMessage
Extracted:
- TransportLayer
- EncryptionLayer
- ApplicationLayer
2023-11-08 21:46:22 +01:00
Volodymyr Kozieiev b5c82adb70
Increased timeouts when fetching curated communities (#4244)
* Timeouts increased
2023-11-08 13:06:40 +00:00
Michal Iskierko d909faf504 feat: add AC messages for setting signer operations
Issue #11964
2023-11-08 12:54:29 +01:00