{"id":13757440,"url":"https://github.com/encryptedsystems/Clusion","last_synced_at":"2025-05-10T05:32:07.993Z","repository":{"id":41225925,"uuid":"61377581","full_name":"encryptedsystems/Clusion","owner":"encryptedsystems","description":"A searchable encryption library from the Encrypted Systems Lab @ Brown University.","archived":false,"fork":false,"pushed_at":"2022-06-29T16:46:39.000Z","size":263,"stargazers_count":195,"open_issues_count":10,"forks_count":55,"subscribers_count":20,"default_branch":"master","last_synced_at":"2024-11-16T13:35:12.866Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/encryptedsystems.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-06-17T13:58:15.000Z","updated_at":"2024-11-02T22:53:00.000Z","dependencies_parsed_at":"2022-08-28T01:01:05.753Z","dependency_job_id":null,"html_url":"https://github.com/encryptedsystems/Clusion","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/encryptedsystems%2FClusion","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/encryptedsystems%2FClusion/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/encryptedsystems%2FClusion/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/encryptedsystems%2FClusion/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/encryptedsystems","download_url":"https://codeload.github.com/encryptedsystems/Clusion/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253371076,"owners_count":21897998,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-03T12:00:38.370Z","updated_at":"2025-05-10T05:32:07.598Z","avatar_url":"https://github.com/encryptedsystems.png","language":"Java","funding_links":[],"categories":["Implementations","安全"],"sub_categories":["Constructions"],"readme":"# The Clusion Library\n\nClusion is an easy to use software library for searchable symmetric encryption\n(SSE). Its goal is to provide modular implementations of various\nstate-of-the-art SSE schemes. Clusion includes constructions that handle\nsingle, disjunctive, conjunctive and (arbitrary) boolean keyword search.  All\nthe implemented schemes have *sub-linear* asymptotic search complexity in the\nworst-case.  \n\nClusion is provided as-is under the *GNU General Public License v3 (GPLv3)*. \n\n\n## Implementation\n\n*Indexing.* The indexer takes as input a folder that can contain pdf files,\nMicorosft files such .doc, .ppt, media files such as pictures and videos as\nwell as raw text files such .html and .txt. The indexing step outputs two\nlookup tables. The first associates keywords to document filenames while the\nsecond associates filenames to keywords. For the indexing, we use Lucene to\ntokenize the keywords and get rid of noisy words.  For this phase, Apache\nLucene, PDFBox and POI are required. For our data structures, we use Google\nGuava.\n\n*Cryptographic primitives.* All the implementations make use of the Bouncy\nCastle library. The code is modular and all cryptographic primitives are\ngathered in the `CryptoPrimitives.java` file.  The file contains AES-CTR,\nHMAC_SHA256/512, AES-CMAC, key generation based on PBE PKCS1 and random string\ngeneration based on SecureRandom.  It also contains a synthetic IV AES encryption and AES based authenticated encryption. \nIn addition, it also contains an\nimplementation of the HCB1 online cipher from \\[[BBKN07][BBKN07]\\]. \n\n\n\nThe following SSE schemes are implemented:\n\n+ **2Lev**:  a static and I/O-efficient SSE scheme \\[[CJJJKRS14][CJJJKRS14]]\\. \n\n+ **Dyn2Lev**:  a dynamic variation of \\[[CJJJKRS14][CJJJKRS14]], comes with two instantiations, a first instantiation that \nonly handles add operations, and a second one that handles delete operations in addition. Both instantiations have forward-security guarantees but at the cost of more interactions and non-optimality (in the case of delete). \n\n+ **BIEX-2Lev**: a  worst-case sub-linear boolean SSE scheme \\[[KM17][KM17]\\].\n  This implementation makes use of 2Lev as a building block.  The\ndisjunctive-only IEX-2Lev construction from \\[[KM17][KM17]\\] is a special case\nof IEX^B-2Lev where the number of disjunctions is set to 1 in the Token\nalgorithm.\n\n+ **ZMF**: a compact single-keyword SSE scheme \n  (with linear search complexity) \\[[KM17][KM17]\\]. The construction is\ninspired by  the Z-IDX construction \\[[Goh03][Goh03]\\] but handles\nvariable-sized collections of Bloom filters called *Matryoshka filters*. ZMF\nalso makes a non-standard use of online ciphers.  Here, we implemented the\nHCBC1 construction from  \\[[BBKN07][BBKN07]\\] but would like to replace this\nwith the more efficient COPE scheme from \\[[ABLMTY13][ABLMTY13]\\]. \n\n+ **BIEX-ZMF**: a compact worst-case optimal boolean SSE scheme. Like our\n  IEX^B-2Lev implementation, the purely disjunctive variant IEX-ZMF is a special case with the number of disjunctions set to 1. \n\n+ **IEX-2Lev-Amazon**: a distributed implementation of text indexing based on MapReduce/Hadoop\non [Amazon AWS](https://aws.amazon.com/fr/). \n\n+ **Dls^D**: a dual secure (breach resistant and forward private) structured encryption scheme \\[[AKM19][AKM19]\\].\n+ We also plan to share our Client-Server implementation for 2Lev, Dyn2Lev, IEX^B-2Lev, IEX^B-ZMF once finalized. \n\n## Build Instructions\n\n+ Install Java (1.7 or above)\n+ Install Maven (3.3.9 or above)\n+ Download/Git clone Clusion\n+ Run below commands to build the jar\n\n\t`cd Clusion`\n\t\n\t`mvn clean install`\n\t\n\t`cd target`\n\t\n\t`ls Clusion-1.0-SNAPSHOT-jar-with-dependencies.jar`\n\t\n+ If the above file exists, build was successful and contains all dependencies\n\n## Quick Test\n\nFor a quick test, create folder and store some input files, needed jars and test classes are already created\n\n+ export Java classpath\n\n\trun `export CLASSPATH=$CLASSPATH:/home/xxx/Clusion/target:/home/xxx/Clusion/target/test-classes`\n\t\n\tEnsure the directory paths are correct in the above\n\t\n+ to test 2Lev (response-revealing)\n\n\trun `java org.crypto.sse.TestLocalRR2Lev`\t\n\t\n+ to test 2Lev (response-hiding)\n\n\trun `java org.crypto.sse.TestLocalRH2Lev`\t\n\t\n+ to test DynRH2Lev (response-hiding)\n\n\trun `java org.crypto.sse.TestLocalDynRH2Lev`\t\n\t\n+ to test DynRH (response-hiding)\n\n\trun `java org.crypto.sse.TestLocalDynRH`\t\t\n\n+ to test ZMF \n\n\trun `java org.crypto.sse.TestLocalZMF`\t\n\t\n+ to test IEX-2Lev \n\n\trun `java org.crypto.sse.TestLocalIEX2Lev`\n\t\n+ to test IEX-2Lev (response-hiding)\n\n\trun `java org.crypto.sse.TestLocalIEXRH2Lev` \n\t\n+ to test IEX-ZMF \n\n\trun `java org.crypto.sse.TestLocalIEXZMF`\n\t\n+ to test IEX-2Lev on Amazon \n\n\trun `java org.crypto.sse.IEX2LevAMAZON`\n\n\n## Documentation\n\nClusion currently does not have any documentation. The best way to learn how to\nuse the library is to read through the source of the test code:\n\n+ `org.crypto.sse.TestLocalRR2Lev.java`\n+ `org.crypto.sse.TestLocalRH2Lev.java`\n+ `org.crypto.sse.TestLocalDynRH2Lev.java`\n+ `org.crypto.sse.TestLocalDynRH.java`\n+ `org.crypto.sse.TestLocalZMF.java`\n+ `org.crypto.sse.TestLocalIEX2Lev.java`\n+ `org.crypto.sse.TestLocalIEXRH2Lev.java`\n+ `org.crypto.sse.TestLocalIEXZMF.java`\n\n## Requirements\nClusion is written in Java.\n\nBelow are Dependencies added via Maven (3.3.9 or above) , need not be downloaded manually\n\n+ Bouncy Castle\t\t\t\t\thttps://www.bouncycastle.org/\n\n+ Apache Lucene\t\t\t\t\thttps://lucene.apache.org/core/\n\n+ Apache PDFBox\t\t\t\t\thttps://pdfbox.apache.org/\n\n+ Apache POI\t\t\t\t\thttps://poi.apache.org/\n\n+ Google Guava\t\t\t\t\thttps://poi.apache.org/\n\n+ SizeOF (needed to calculate object size in Java)\thttp://sizeof.sourceforge.net/\n\n+ [Hadoop-2.7.1](http://hadoop.apache.org/releases.htm) was used for our\n  distributed implementation of the IEX-2Lev setup algorithm. Earlier releases\n of Hadoop may work as well but were not tested \n\nClusion was tested with Java version `1.7.0_75`.\n\n## References\n\n1. \\[[CJJJKRS14](https://eprint.iacr.org/2014/853.pdf)\\]:  *Dynamic Searchable Encryption in Very-Large Databases: Data Structures and Implementation* by D. Cash, J. Jaeger, S. Jarecki, C. Jutla, H. Krawczyk, M. Rosu, M. Steiner.\n\n2. \\[[KM17](https://eprint.iacr.org/2017/126.pdf)\\]: :  *Boolean Searchable Symmetric Encryption with Worst-Case Sub-Linear Complexity* by S. Kamara and T. Moataz. \n\n3. \\[[Goh03](https://eprint.iacr.org/2003/216.pdf)\\]: *Secure Indexes* by E. Goh. \n\n4. \\[[ABLMTY13](https://eprint.iacr.org/2013/790.pdf)\\]: *Parallelizable and\n   Authenticated Online Ciphers* by E. Andreeva, A.  Bogdanov, A. Luykx, B.\nMennink, E. Tischhauser, and K. Yasuda. . \n\n5. \\[[BBKN07](https://cseweb.ucsd.edu/~mihir/papers/olc.pdf)\\]:  *On-Line\n   Ciphers and the Hash-CBC Constructions* by M. Bellare, A. Boldyreva, L.\nKnudsen and C. Namprempre.\n\n6. \\[[AKM19](https://eprint.iacr.org/2018/195.pdf)\\]: *Breach-Resistant Structured Encryption* by \n\tG. Amjad, S. Kamara and T. Moataz.\n\n\n[CJJJKRS14]: https://eprint.iacr.org/2014/853.pdf\n[KM17]: https://eprint.iacr.org/2017/126.pdf\n[Goh03]: https://eprint.iacr.org/2003/216.pdf\n[ABLMTY13]: https://eprint.iacr.org/2013/790.pdf\n[BBKN07]: https://cseweb.ucsd.edu/~mihir/papers/olc.pdf\n[AKM19]: https://eprint.iacr.org/2018/195.pdf\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fencryptedsystems%2FClusion","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fencryptedsystems%2FClusion","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fencryptedsystems%2FClusion/lists"}