Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: filter subscription with pubsubTopic1 and decoder with pubsubTopic2 #1675

Merged
merged 4 commits into from
Oct 23, 2023

Conversation

danisharora099
Copy link
Collaborator

@danisharora099 danisharora099 commented Oct 20, 2023

Problem

Our current Filter implementation has a flaw where if the subscription object is created with pubsubTopic1 but during subscriptions, decoders with different pubsub topics can be passed with no error thrown.

Solution

Add checks to ensure that the decoders passed to the subscription are all for the same pubsub topic

@github-actions
Copy link

github-actions bot commented Oct 20, 2023

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
Waku core 83.85 KB (0%) 1.7 s (0%) 410 ms (+38.77% 🔺) 2.1 s
Waku Simple Light Node 264.2 KB (+0.04% 🔺) 5.3 s (+0.04% 🔺) 1.2 s (+66.89% 🔺) 6.5 s
ECIES encryption 79.46 KB (0%) 1.6 s (0%) 675 ms (+27.05% 🔺) 2.3 s
Symmetric encryption 79.47 KB (0%) 1.6 s (0%) 636 ms (+12.43% 🔺) 2.3 s
DNS discovery 111.22 KB (0%) 2.3 s (0%) 571 ms (+14.05% 🔺) 2.8 s
Privacy preserving protocols 131.77 KB (0%) 2.7 s (0%) 615 ms (-1.88% 🔽) 3.3 s
Light protocols 81.57 KB (+0.11% 🔺) 1.7 s (+0.11% 🔺) 403 ms (+16.12% 🔺) 2.1 s
History retrieval protocols 80.54 KB (0%) 1.7 s (0%) 471 ms (+50.99% 🔺) 2.1 s
Deterministic Message Hashing 5.65 KB (0%) 113 ms (0%) 57 ms (-24.46% 🔽) 170 ms

@danisharora099 danisharora099 changed the title test: filter subscription with pubsubTopic1 and decoder with pubsubTopic2 fix: filter subscription with pubsubTopic1 and decoder with pubsubTopic2 Oct 20, 2023
@danisharora099 danisharora099 marked this pull request as ready for review October 20, 2023 10:33
@danisharora099 danisharora099 requested a review from a team as a code owner October 20, 2023 10:33
@danisharora099 danisharora099 merged commit 491366b into master Oct 23, 2023
@danisharora099 danisharora099 deleted the chore/failing-filter branch October 23, 2023 08:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants