{"id":20904839,"url":"https://github.com/haskell-cryptography/cryptography-blake3-bindings","last_synced_at":"2025-08-17T19:45:01.176Z","repository":{"id":39645266,"uuid":"450699441","full_name":"haskell-cryptography/cryptography-blake3-bindings","owner":"haskell-cryptography","description":"Vendored low-level bindings to BLAKE3 C implementation","archived":false,"fork":false,"pushed_at":"2022-01-27T00:20:22.000Z","size":80,"stargazers_count":7,"open_issues_count":1,"forks_count":0,"subscribers_count":5,"default_branch":"main","last_synced_at":"2025-08-15T00:48:16.297Z","etag":null,"topics":["blake3","cryptography","haskell"],"latest_commit_sha":null,"homepage":null,"language":"Assembly","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/haskell-cryptography.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-01-22T02:42:11.000Z","updated_at":"2023-08-05T12:39:53.000Z","dependencies_parsed_at":"2022-08-28T10:10:30.405Z","dependency_job_id":null,"html_url":"https://github.com/haskell-cryptography/cryptography-blake3-bindings","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/haskell-cryptography/cryptography-blake3-bindings","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/haskell-cryptography%2Fcryptography-blake3-bindings","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/haskell-cryptography%2Fcryptography-blake3-bindings/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/haskell-cryptography%2Fcryptography-blake3-bindings/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/haskell-cryptography%2Fcryptography-blake3-bindings/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/haskell-cryptography","download_url":"https://codeload.github.com/haskell-cryptography/cryptography-blake3-bindings/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/haskell-cryptography%2Fcryptography-blake3-bindings/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270899480,"owners_count":24664714,"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","status":"online","status_checked_at":"2025-08-17T02:00:09.016Z","response_time":129,"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":["blake3","cryptography","haskell"],"created_at":"2024-11-18T13:19:15.644Z","updated_at":"2025-08-17T19:45:01.100Z","avatar_url":"https://github.com/haskell-cryptography.png","language":"Assembly","funding_links":[],"categories":[],"sub_categories":[],"readme":"# `cryptography-blake3-bindings` [![CI](https://github.com/haskell-cryptography/cryptography-blake3-bindings/actions/workflows/ci.yml/badge.svg)](https://github.com/haskell-cryptography/cryptography-blake3-bindings/actions/workflows/ci.yml) [![made with Haskell](https://img.shields.io/badge/Made%20in-Haskell-%235e5086?logo=haskell\u0026style=flat-square)](https://haskell.org)\n\n## What is this?\n\nA set of low-level bindings (and helpers) wrapping the [C implementation of\nBLAKE3](https://github.com/BLAKE3-team/BLAKE3/tree/master/c), version 1.6.0.\n\n## What're the goals of this project?\n\n### Ease of use\n\nNo user of this library should ever have to think about C, linking to system\nlibraries, enabling SIMD through weird flags, or any similar issues. Just add\nthis as a dependency and go.\n\n### Minimality\n\nNo weird lawless type class hierarchy. No dependencies outside of `base`. These\nare truly minimal bindings, for those who want the ability to operate as close\nto the original code as posssible.\n\n### Stability and clarity\n\nJust by reading the documentation of this library, you should know everything\nyou need to use it. No reading the C 'documentation' should ever be required.\nFurthermore, you shouldn't need to doubt that this behaves - our CI should prove\nit to you. No surprises on upgrades either - _impeccable_\n[PVP](https://pvp.haskell.org) compliance only here.\n\n## How do I use this?\n\n```haskell\n{-# LANGUAGE ScopedTypeVariables #-}\n\nmodule Sample where\n\nimport Foreign.Marshal.Alloc (mallocBytes, free)\nimport Foreign.C.Types (CSize, CUChar)\nimport Foreign.Ptr (Ptr)\nimport Cryptography.BLAKE3.Bindings (\n  blake3HasherSize,\n  blake3OutLen,\n  blake3HasherUpdate,\n  blake3HasherFinalize\n  )\n\nhashMeSomeData :: IO (Ptr Word8)\nhashMeSomeData = do\n  -- allocate an initialize a hasher\n  hasherPtr \u003c- mallocBytes . fromIntegral $ blake3HasherSize\n  blake3HasherInit hasherPtr\n  -- get some data to hash (we assume this is done in some user-specific way)\n  (dataLen :: CSize, dataPtr :: Ptr CUChar) \u003c- mkSomeDataWithLength\n  -- feed the data into the hasher\n  blake3HasherUpdate hasherPtr dataPtr dataLen\n  -- make a place to fit the hash into\n  outPtr \u003c- mallocBytes . fromIntegral $ blake3OutLen\n  -- output the hash\n  blake3HasherFinalize hasherPtr outPtr blake3OutLen\n  -- deallocate the hasher, since we don't need it anymore\n  free hasherPtr\n  -- use the hash output however we please\n```\n\n## What does this run on?\n\nOur CI currently checks Windows, Linux (on Ubuntu) and macOS. Additionally, we\nalso verify that the embedded BLAKE3 compiles correctly on SIMD and non-SIMD\nplatforms: we currently test x86-64 (Github Actions default), aarch64 and armv7.\n\n## What can I do with this?\n\nThe bindings themselves are licensed under `BSD-3-Clause`, while the C code for\nBLAKE3 is under `Apache-2.0`. See the `LICENSE` and `LICENSE.BLAKE3` files for\nmore information.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhaskell-cryptography%2Fcryptography-blake3-bindings","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhaskell-cryptography%2Fcryptography-blake3-bindings","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhaskell-cryptography%2Fcryptography-blake3-bindings/lists"}