{
  "id": "2025/1150",
  "url": "https://opencryptology.org/2025/1150",
  "original_url": "https://eprint.iacr.org/2025/1150",
  "title": "Lightweight Sorting in Approximate Homomorphic Encryption",
  "authors": [
    "Lorenzo Rovida",
    "Alberto Leporati",
    "Simone Basile"
  ],
  "affiliations": null,
  "abstract": "Sorting encrypted values is an open research problem that plays a crucial role in the broader objective of providing efficient and practical privacy-preserving online services. \nThe current state of the art work by Mazzone, Everts, Hahn and Peter (USENIX Security '25) proposes efficient algorithms for indexing and sorting based on the CKKS scheme, which deviates from the compare-and-swap paradigm, typically used by sorting networks, using a permutation-based approach. \nIn this work, we follow up their work and explore different approaches to approximate the nonlinear functions required by the circuit. We propose simpler and concrete solutions that allow for faster computations, smaller memory requirements and higher precision.\nFor example, our framework allows to sort 128 real elements in roughly 22 seconds, while maintaining a precision of $0.001$ and requiring 3 GB of memory.\nFurthermore, we propose an implementation of a swap-based bitonic network that is not based on approximations of the $\\text{sgn}(x)$ function, which scales linearly with the number of values, useful when the number of available slots is small.",
  "category": "Applications",
  "license": {
    "code": "CC BY-SA",
    "url": "https://creativecommons.org/licenses/by-sa/4.0/",
    "label": "CC BY-SA 4.0",
    "attribution": "“Lightweight Sorting in Approximate Homomorphic Encryption” by Lorenzo Rovida, Alberto Leporati, Simone Basile, Cryptology ePrint Archive, Paper 2025/1150, https://eprint.iacr.org/2025/1150. Licensed under CC BY-SA 4.0 (https://creativecommons.org/licenses/by-sa/4.0/).",
    "retroactive": false,
    "redistribute_verbatim_only": false,
    "non_commercial": false
  },
  "dates": {
    "submitted": "2025-06-18T11:01:28Z",
    "updated": "2026-05-27T13:24:26Z",
    "withdrawn": null
  },
  "withdrawn": false,
  "withdrawn_on": null,
  "pdf": {
    "url": "https://opencryptology.org/2025/1150.pdf",
    "sha256": "238f7b746381dae680f6d63a67af55de647afe013eae41069403c33ce871ff09",
    "size": 1052063,
    "source": "upload",
    "source_date": "2026-11-14T03:53:15.677Z",
    "maybe_stale": false,
    "newer_on_eprint": null,
    "eprint_size": null,
    "withdrawn": false
  },
  "versions": [
    {
      "url": "https://opencryptology.org/2025/1150/versions/20261114T035315Z.pdf",
      "captured_at": "2026-11-14T03:53:15.677Z",
      "label": "copy captured 2026-11-14",
      "source": "upload",
      "source_url": null,
      "size": 1052063,
      "sha256": "238f7b746381dae680f6d63a67af55de647afe013eae41069403c33ce871ff09",
      "is_default_pdf": true
    },
    {
      "url": "https://opencryptology.org/2025/1150/versions/20260428T172000Z.pdf",
      "captured_at": "2026-04-28T17:20:00Z",
      "label": "copy captured 2026-04-28",
      "source": "github-mirror",
      "source_url": "https://raw.githubusercontent.com/arturo-kong/IACR-eprint-mirror/master/2025/1150.pdf",
      "size": 1024705,
      "sha256": "e9658423af65ca8175dfd0e1dea9a1fa8d00f8be50b83005d6654f05678975ab",
      "is_default_pdf": false
    },
    {
      "url": "https://opencryptology.org/2025/1150/versions/20250620T121051Z.pdf",
      "captured_at": "2025-06-20T12:10:51Z",
      "label": "copy captured 2025-06-20",
      "source": "wayback",
      "source_url": "https://web.archive.org/web/20250620121051id_/https://eprint.iacr.org/2025/1150.pdf",
      "size": 1280490,
      "sha256": "fc721aef83eda11e0b8a83a07fa289e94884a6724bc06a929208c990e3294880",
      "is_default_pdf": false
    }
  ],
  "other_sources": [
    {
      "kind": "github-mirror",
      "url": "https://raw.githubusercontent.com/arturo-kong/IACR-eprint-mirror/master/2025/1150.pdf",
      "captured_at": "2026-04-28T17:20:00Z",
      "size": 1024705
    },
    {
      "kind": "wayback",
      "url": "https://web.archive.org/web/20260421022042id_/https://eprint.iacr.org/2025/1150.pdf",
      "captured_at": "2026-04-21T02:20:42Z",
      "size": 994381
    }
  ],
  "bibtex": "@misc{cryptoeprint:2025/1150,\n      author = {Lorenzo Rovida and Alberto Leporati and Simone Basile},\n      title = {Lightweight Sorting in Approximate Homomorphic Encryption},\n      howpublished = {Cryptology {ePrint} Archive, Paper 2025/1150},\n      year = {2025},\n      url = {https://eprint.iacr.org/2025/1150}\n}"
}
