Since there are strict storage and computational limits forced by a VM some operations for enterprise-level contracts are impossible. Is there some Bloom filter implementation available in existing library for use in Solidity? It could be used to optimise some algorithms. I do not feel ready for porting some algorithm myself :(

closed as off-topic by max taldykin, Badr Bellaj, Rob Hitchens - B9lab, Waqar Lim Mar 8 '17 at 12:38

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions asking us to recommend or find a book, tool, software library, tutorial or other off-site resource are off-topic for Ethereum Stack Exchange as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it." – max taldykin, Waqar Lim
If this question can be reworded to fit the rules in the help center, please edit the question.

  • Please provide an example of what you claim is impossible. – T9b Apr 16 '16 at 14:01
  • Agreed. Need a better example. Ethereum events actually function from bloom filters. – VoR0220 Apr 16 '16 at 18:56
  • Looks like the Aldekein is simply looking for a library which implements a bloom filter. There are op-codes for various hashes and Bitwise logic operations so should be possible to implement a simple she256 based BF – JackWinters Apr 16 '16 at 20:20
  • @JackWinters is correct, I'm searching for a library. – Aldekein Apr 19 '16 at 0:38

I don't think bloom filter would be useful in contracts as it is prone to bloating attacks.

Malicious user can add to a bloom filter a number of entries specifically prepared to increase number of false positives (by increasing number of 1-bits in filter).

  • 1
    Though in a private Ethereum-based blockchain, where you could all but guarantee the safety of the network, such attacks wouldn't be a concern :-) – Richard Horrocks Mar 3 '17 at 22:03

Not the answer you're looking for? Browse other questions tagged or ask your own question.