{"id":19595250,"url":"https://github.com/matchy233/mpc-rsa","last_synced_at":"2025-04-27T15:34:27.845Z","repository":{"id":112878987,"uuid":"379480688","full_name":"matchy233/mpc-rsa","owner":"matchy233","description":"🔐 Containerized distributed RSA keypair generation and decryption module","archived":false,"fork":false,"pushed_at":"2021-06-23T04:52:31.000Z","size":226,"stargazers_count":5,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-21T23:05:16.125Z","etag":null,"topics":["distributed-computing","grpc-java","multiparty-computation","rsa-cryptography"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/matchy233.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-06-23T04:41:56.000Z","updated_at":"2022-08-23T06:13:36.000Z","dependencies_parsed_at":"2023-06-01T06:15:59.497Z","dependency_job_id":null,"html_url":"https://github.com/matchy233/mpc-rsa","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/matchy233%2Fmpc-rsa","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matchy233%2Fmpc-rsa/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matchy233%2Fmpc-rsa/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matchy233%2Fmpc-rsa/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/matchy233","download_url":"https://codeload.github.com/matchy233/mpc-rsa/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251162971,"owners_count":21545854,"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":["distributed-computing","grpc-java","multiparty-computation","rsa-cryptography"],"created_at":"2024-11-11T08:46:18.090Z","updated_at":"2025-04-27T15:34:27.839Z","avatar_url":"https://github.com/matchy233.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Secure Multiparty Computing (MPC) Module for RSA Keypair Generation and Message Decryption\r\n\r\n![GitHub top language](https://img.shields.io/github/languages/top/matchy233/mpc-rsa?color=orange) ![last commit](https://img.shields.io/github/last-commit/matchy233/mpc-rsa) ![GitHub Workflow Status](https://img.shields.io/github/workflow/status/7942jun/mpc-project/Java%20CI) ![Codecov](https://img.shields.io/codecov/c/github/7942jun/mpc-project) ![Docker Pulls](https://img.shields.io/docker/pulls/matchy233/mpc-project_manager?label=docker%20pulls\u0026logo=manager) ![Docker Pulls](https://img.shields.io/docker/pulls/matchy233/mpc-project_worker?label=docker%20pulls\u0026logo=manager)\r\n\r\nSecure Multiparty Computing (MPC) is a heated research field in cryptography with the goal of creating methods for\r\nmultiple parties to jointly contribute to the computation while keeping the input private to each party.\r\n\r\nRSA encryption algorithm, which requires lots of computations involving multiplication and modulus on large prime\r\nnumbers, is suitable to be modified to working in an MPC scenario.\r\n\r\nThis project aims to implement a containerized MPC module for RSA keypair generation and message decryption.\r\n\r\nRefined version of [a course project](https://github.com/7942jun/mpc-project).\r\n\r\n## Build and Run the Project\r\n\r\n### Run from Docker image\r\n\r\nThe Docker image is available in the Docker hub. You can simply do a `docker pull` to acquire the images.\r\n\r\n```bash\r\n$ docker pull matchy233/mpc-project_manager\r\n$ docker pull matchy233/mpc-project_worker\r\n```\r\n\r\nIt's also possible to build the image from source. We use Docker compose to distribute `manager` and `worker` conveniently. [Install Docker compose](https://docs.docker.com/compose/install/) if not already installed and simply run:\r\n\r\n```bash\r\n$ docker-compose build\r\n```\r\n\r\nAfterwards, you should be able to check the generated images by\r\n\r\n```bash\r\n$ docker images\r\nREPOSITORY            TAG           IMAGE ID       CREATED             SIZE\r\nmpc-project_manager   latest        56c59ec8a29d   1 minute ago        445MB\r\nmpc-project_worker    latest        3432307d295f   2 minutes ago       244MB\r\n```\r\n\r\nTo run the application, a simple `docker run` will easily get the manager or worker set up. \r\n\r\nThe following 2 commands set up 2 containers. One is named `manager` running in manager mode with the exposed port published to port `8350` of the local machine; the other is named `worker1` running in worker mode with the exposed port published to port `8353` of the local machine. \r\nThese containers are then accessible through `\u003clocal_machine_IP\u003e:\u003cpublished_port\u003e` from other machines.\r\n\r\n```bash\r\n$ docker run --rm --it --name manager mpc-project_manager -p 8350:8080\r\n$ docker run --rm --itd --name worker1 mpc-project_worker -p 8353:8080\r\n```\r\n\r\n### Build from source\r\n\r\nWe use `Gradle` to manage and build the project. Thus, you can simply build the project from source with `Gradle`. Simply run the following command if you have `Gradle` installed on your\r\nmachine:\r\n\r\n```bash\r\n$ gradle clean install\r\n```\r\n\r\nIf you don't have `gradle` installed, you can build with the `Gradle` wrapper:\r\n\r\n```bash\r\n$ gradlew clean install\r\n```\r\n\r\nAfter running either command, you can find the executable in `/app/build/install/`. \r\n\r\n## Reference\r\n\r\n1. Malkin, M., Wu, T. D., \u0026 Boneh, D. (1999, February). Experimenting with Shared Generation of RSA Keys. In **NDSS** (*The Network and Distributed System Security Symposium*).\r\n2. Boneh, D., \u0026 Franklin, M. (1997, August). Efficient generation of shared RSA keys. In **CRYPTO** (*Annual\r\n   international cryptology conference*) (pp. 425-439). Springer, Berlin, Heidelberg.\r\n3. Catalano, D., Gennaro, R., \u0026 Halevi, S. (2000, May). Computing inverses over a shared secret modulus. In **Eurocrypt**(*International Conference on the Theory and Applications of Cryptographic Techniques*) (pp. 190-206).\r\n   Springer, Berlin, Heidelberg.\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmatchy233%2Fmpc-rsa","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmatchy233%2Fmpc-rsa","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmatchy233%2Fmpc-rsa/lists"}