{"id":27289881,"url":"https://github.com/elefthei/krypto","last_synced_at":"2025-07-10T20:32:33.949Z","repository":{"id":57514189,"uuid":"63511434","full_name":"elefthei/krypto","owner":"elefthei","description":"OpenSSL and Erlang crypto bindings in Elixir, a crypto library with ease of use in mind","archived":false,"fork":false,"pushed_at":"2018-08-23T20:29:49.000Z","size":8,"stargazers_count":6,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-18T07:12:06.508Z","etag":null,"topics":["crypto-library","elixir","krypto","openssl"],"latest_commit_sha":null,"homepage":null,"language":"Elixir","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/elefthei.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-07-17T02:37:58.000Z","updated_at":"2020-09-25T10:15:08.000Z","dependencies_parsed_at":"2022-08-31T23:00:58.899Z","dependency_job_id":null,"html_url":"https://github.com/elefthei/krypto","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/elefthei/krypto","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elefthei%2Fkrypto","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elefthei%2Fkrypto/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elefthei%2Fkrypto/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elefthei%2Fkrypto/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/elefthei","download_url":"https://codeload.github.com/elefthei/krypto/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elefthei%2Fkrypto/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264652630,"owners_count":23644292,"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":["crypto-library","elixir","krypto","openssl"],"created_at":"2025-04-11T21:19:37.619Z","updated_at":"2025-07-10T20:32:33.925Z","avatar_url":"https://github.com/elefthei.png","language":"Elixir","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Krypto\n\n**Crypto library in Elixir, using Erlang public_key and OpenSSL ports**\n\n## Installation\n\nThe package can be installed as:\n\n  1. Add krypto to your list of dependencies in `mix.exs`:\n  ```\n  def deps do\n      [{:krypto, \"~\u003e 0.1.4\"}]\n  end\n  ```\n  2. Ensure krypto is started before your application:\n  ```\n  def application do\n      [applications: [:krypto]]\n  end\n  ```\n## Overview\n\nKrypto is an opinionated, light-weight crypto implementation for Elixir with native OpenSSL bindings.\n\n## Example\n\nYou can use krypto in your Elixir application to do the following:\n\n  1. Generate an RSA key pair (in DER format):\n  ```\n  { publicKey, privateKey } = Krypto.RSA.getKeypair()\n  ```\n  2. Encrypt using the public key:\n  ```\n  encrypted_secret = Krypto.RSA.encrypt(\"Super secret message\", publicKey)\n  ```\n  3. Decrypt using the private key:\n  ```\n  decrypted_secret = Krypto.RSA.decrypt(encrypted_secret, privateKey)\n  ```\n  4. Sign a message:\n  ```\n  message = \"This message should be signed\",\n  signature = Krypto.RSA.sign(message, privateKey)\n  if Krypto.RSA.verify(message, signatre, publicKey) do\n      IO.puts \"This signature matches!\"\n  end\n  ```\n  5. Get message digests:\n  ```\n  hash_md5 = Krypto.Hash.md5(\"Hash me in md5!\")\n  hash_sha224 = Krypto.Hash.sha224(\"Hash me in sha224!\")\n  hash_sha256 = Krypto.Hash.sha256(\"Hash me in sha256 (our prefered one)!\")\n  hash_sha384 = Krypto.Hash.sha384(\"Hash me in sha384!\")\n  ```\n  \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felefthei%2Fkrypto","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Felefthei%2Fkrypto","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felefthei%2Fkrypto/lists"}