{"id":21331427,"url":"https://github.com/tempdata73/ebmus","last_synced_at":"2025-03-16T00:42:38.931Z","repository":{"id":112502602,"uuid":"582754520","full_name":"tempdata73/ebmus","owner":"tempdata73","description":"a simple proof-of-work library","archived":false,"fork":false,"pushed_at":"2022-12-27T20:28:00.000Z","size":9,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-22T13:47:58.128Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Rust","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/tempdata73.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":"2022-12-27T19:22:50.000Z","updated_at":"2022-12-30T02:00:23.000Z","dependencies_parsed_at":"2023-04-19T10:05:27.811Z","dependency_job_id":null,"html_url":"https://github.com/tempdata73/ebmus","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tempdata73%2Febmus","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tempdata73%2Febmus/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tempdata73%2Febmus/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tempdata73%2Febmus/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tempdata73","download_url":"https://codeload.github.com/tempdata73/ebmus/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243809848,"owners_count":20351407,"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":[],"created_at":"2024-11-21T22:33:05.784Z","updated_at":"2025-03-16T00:42:38.913Z","avatar_url":"https://github.com/tempdata73.png","language":"Rust","readme":"# EBMUS\n**Simple proof-of-work library**. Given an arbitrary string, it finds a nonce such that, when\nappended to the string, its BLAKE 3 hash starts with a given number of hexadecimal zeros.\n\n# How to use\nBy default:\n```rust\nuse ebmus::Puzzle;\n\nlet difficulty = 5;\nlet template = \"EBMUS:::\"\nlet mut puzzle = Puzzle::new(template);\n\npuzzle.solve(difficulty).unwrap();\nprintln!(\"{}\", puzzle.to_string()); // EBMUS:::1437302\nprintln!(\"{}\", puzzle.nonce); // 1437302\nprintln!(\"{}\", puzzle.hash()); // 000004c14153250a5234dfdca6a4a40c09ce8545fbe323463567631d05759516\n```\nIf you are using the \"template\" feature:\n```rust\nuse ebmus::template::Template;\n\nlet template = Template::new(\"EBMUS\"); // EBMUS:  1672169715:9doEQzRH3U76KKH2:::\nlet mut puzzle = Puzzle::new(template);\n\n//...\n```\n\nYou can create your own custom template, as long as it implements the `ToString` trait. For example,\nthe \"template\" feature contains a `Template` struct defined by\n\n```rust\nstruct Template {\n  name: String,\n  timestamp: i64,\n  token: String,\n}\n```\nwhich resolves to the string \"EBMUS:  1672169715:9doEQzRH3U76KKH2:::\".\n\n# TODO\n- add documentation\n- add tests\n- instead of looking for hexadecimal zeros, find binary zeros.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftempdata73%2Febmus","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftempdata73%2Febmus","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftempdata73%2Febmus/lists"}