{"id":19432956,"url":"https://github.com/bonifatius94/primegen","last_synced_at":"2026-05-15T22:04:34.420Z","repository":{"id":133709806,"uuid":"376396899","full_name":"Bonifatius94/PrimeGen","owner":"Bonifatius94","description":"a straight-forward prime generator (Miller-Rabin) and a naive implementation of the RSA algorithm","archived":false,"fork":false,"pushed_at":"2021-09-11T18:48:58.000Z","size":89,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-25T06:18:42.144Z","etag":null,"topics":["csharp","dotnet","miller-rabin-test","rsa-algorithm"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Bonifatius94.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-06-12T22:51:48.000Z","updated_at":"2021-09-11T18:49:00.000Z","dependencies_parsed_at":null,"dependency_job_id":"0806010e-fac9-4537-96ce-5928cba3b9e2","html_url":"https://github.com/Bonifatius94/PrimeGen","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Bonifatius94/PrimeGen","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Bonifatius94%2FPrimeGen","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Bonifatius94%2FPrimeGen/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Bonifatius94%2FPrimeGen/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Bonifatius94%2FPrimeGen/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Bonifatius94","download_url":"https://codeload.github.com/Bonifatius94/PrimeGen/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Bonifatius94%2FPrimeGen/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259589300,"owners_count":22880946,"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":["csharp","dotnet","miller-rabin-test","rsa-algorithm"],"created_at":"2024-11-10T14:37:45.002Z","updated_at":"2025-10-09T23:04:40.868Z","avatar_url":"https://github.com/Bonifatius94.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# PrimeGen\n\n## About\nThis project was created just for fun to try out some maths theory about\nprimality checks (Miller-Rabin) and the RSA algorithm.\n\n## Disclaimer\nDo not use this project for any critical RSA encryptions. This is just a \nstraight-forward approach not dealing with common security risks, etc.\n\n## Usage\nIf you haven't done already, install dotnet to your dev machine.\nFollowing commands show how to install dotnet onto Ubuntu 20.04.\n\n```sh\nwget https://packages.microsoft.com/config/ubuntu/20.04/packages-microsoft-prod.deb -O packages-microsoft-prod.deb\nsudo dpkg -i packages-microsoft-prod.deb\n\nsudo apt-get update; \\\n  sudo apt-get install -y apt-transport-https \u0026\u0026 \\\n  sudo apt-get update \u0026\u0026 \\\n  sudo apt-get install -y dotnet-sdk-5.0\n\n# official tutorial: https://docs.microsoft.com/de-de/dotnet/core/install/linux-ubuntu#2004-\n```\n\nDownload the source code by cloning this git repository.\n\n```sh\ngit clone https://github.com/Bonifatius94/PrimeGen\ncd PrimeGen\n```\n\nNow you can run the project to create some primes that are used to\nencrypt and decrypt a very simple message using the RSA algorithm.\n\n```sh\n# use a non-optimized binary, working on any system\ndotnet run\n\n# use an optimized binary (here: optimized for linux x64 systems)\ndotnet run --runtime linux-x64 --configuration Release\n```\n\nWhen running you may be prompted an output like the following example:\n\n```text\nGenerating keys for RSA encryption (keylen=128 bits):\n====================================================\np=22641425880588529119780961947471613697\nq=64691136216422834958231258782814769181\nN=1464699565775193873901347581743378875189028505571442438354476348766653072157\nphi(N)=1464699565775193873901347581743378875101695943474431074276464128036366689280\ne=84873714534479592302170843865699775323\nd=716060456532699376833342290190195238176394542272471939021456502928274835667\n====================================================\noriginal message:  'Hello World, RSA encryption!'\nencrypted message: ';/\u003cC;0???!\n                              ???? 0??;_??qr? ?'\ndecrypted message: 'Hello World, RSA encryption!'\n```\n\n## License\nThis software is available under the terms of the MIT license.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbonifatius94%2Fprimegen","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbonifatius94%2Fprimegen","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbonifatius94%2Fprimegen/lists"}