{"id":40899972,"url":"https://github.com/alexey-lapin/eme-java","last_synced_at":"2026-01-22T02:30:21.599Z","repository":{"id":47614792,"uuid":"388577045","full_name":"alexey-lapin/eme-java","owner":"alexey-lapin","description":"EME (Encrypt-Mix-Encrypt) wide-block encryption for Java.","archived":false,"fork":false,"pushed_at":"2026-01-16T12:51:03.000Z","size":257,"stargazers_count":1,"open_issues_count":5,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-01-17T03:33:31.959Z","etag":null,"topics":["cipher","ecryption","wide-block-encryption"],"latest_commit_sha":null,"homepage":"","language":"Java","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/alexey-lapin.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2021-07-22T19:36:35.000Z","updated_at":"2026-01-08T01:55:30.000Z","dependencies_parsed_at":"2025-01-01T20:18:46.857Z","dependency_job_id":"0bb4adb9-a260-4cb6-8a90-19fa1af0d9c6","html_url":"https://github.com/alexey-lapin/eme-java","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/alexey-lapin/eme-java","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexey-lapin%2Feme-java","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexey-lapin%2Feme-java/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexey-lapin%2Feme-java/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexey-lapin%2Feme-java/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alexey-lapin","download_url":"https://codeload.github.com/alexey-lapin/eme-java/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexey-lapin%2Feme-java/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28651665,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-22T01:17:37.254Z","status":"online","status_checked_at":"2026-01-22T02:00:07.137Z","response_time":144,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["cipher","ecryption","wide-block-encryption"],"created_at":"2026-01-22T02:30:19.033Z","updated_at":"2026-01-22T02:30:21.583Z","avatar_url":"https://github.com/alexey-lapin.png","language":"Java","readme":"EME for Java [![Maven Central](https://img.shields.io/maven-central/v/com.github.alexey-lapin.eme-cipher/eme-cipher?color=%2349C41B)](https://central.sonatype.com/artifact/com.github.alexey-lapin.eme-cipher/eme-cipher) [![codecov](https://codecov.io/gh/alexey-lapin/eme-java/branch/master/graph/badge.svg?token=N4DYGSK1QZ)](https://codecov.io/gh/alexey-lapin/eme-java)\n==========\nThis is a port of [EME for Go](https://github.com/rfjakob/eme).\n\n**EME** (ECB-Mix-ECB or, clearer, **Encrypt-Mix-Encrypt**) is a wide-block\nencryption mode developed by Halevi\nand Rogaway in 2003.\n\nEME uses multiple invocations of a block cipher to construct a new\ncipher of bigger block size (in multiples of 16 bytes, up to 2048 bytes).\n\nQuoting from the original paper:\n\n\u003e We describe a block-cipher mode of operation, EME, that turns an n-bit block cipher into\n\u003e a tweakable enciphering scheme that acts on strings of mn bits, where m ∈ [1..n]. The mode is\n\u003e parallelizable, but as serial-efficient as the non-parallelizable mode CMC [6]. EME can be used\n\u003e to solve the disk-sector encryption problem. The algorithm entails two layers of ECB encryption\n\u003e and a “lightweight mixing” in between. We prove EME secure, in the reduction-based sense of\n\u003e modern cryptography.\n\nThis is an implementation of EME in Java, complete with test vectors from IEEE and Halevi.\n\nIt has no dependencies outside the standard library.\n\n## Usage\nMaven:\n```xml\n\u003cdependency\u003e\n    \u003cgroupId\u003ecom.github.alexey-lapin.eme-cipher\u003c/groupId\u003e\n    \u003cartifactId\u003eeme-cipher\u003c/artifactId\u003e\n    \u003cversion\u003e0.2.0\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\nGradle:\n```\nimplementation(\"com.github.alexey-lapin.eme-cipher:eme-cipher:0.2.0\")\n```\n\n### As a javax.crypto.Cipher\n```java\nimport com.github.alexeylapin.eme.cipher.AES128EMEProvider;\nimport javax.crypto.Cipher;\nimport javax.crypto.spec.IvParameterSpec;\nimport javax.crypto.spec.SecretKeySpec;\nimport java.security.Security;\n\npublic class Example {\n\n    public static void main(String[] args) throws Exception {\n        // register eme provider\n        Security.addProvider(new AES128EMEProvider());\n\n        // create cipher\n        Cipher cipher = Cipher.getInstance(\"AES/EME/PKCS7Padding\");\n\n        // initialize cipher\n        byte[] key = new byte[32];\n        SecretKeySpec keySpec = new SecretKeySpec(key, \"AES\");\n\n        byte[] iv = new byte[16];\n        cipher.init(Cipher.ENCRYPT_MODE, keySpec, new IvParameterSpec(iv));\n\n        // use cipher\n        byte[] data = new byte[100];\n        byte[] encrypted = cipher.update(data);\n    }\n    \n}\n```\n\n### As a custom impl\n```java\nimport com.github.alexeylapin.eme.EME;\n\npublic class Example {\n\n    public static void main(String[] args) throws Exception {\n        // initialize cipher\n        byte[] key = new byte[32];\n        \n        EME eme = EME.fromKey(key);\n        \n        byte[] iv = new byte[16];\n\n        // use cipher\n        byte[] data = new byte[512];\n        byte[] encrypted = eme.encrypt(iv, data);\n    }\n    \n}\n```","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falexey-lapin%2Feme-java","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falexey-lapin%2Feme-java","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falexey-lapin%2Feme-java/lists"}