{"id":15687584,"url":"https://github.com/gizmo-ds/totp-wasm","last_synced_at":"2025-05-07T17:21:07.837Z","repository":{"id":62380936,"uuid":"534441364","full_name":"gizmo-ds/totp-wasm","owner":"gizmo-ds","description":"HOTP \u0026 TOTP \u0026 Steam Guard TOTP","archived":false,"fork":false,"pushed_at":"2024-03-04T07:35:22.000Z","size":621,"stargazers_count":24,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-06T06:32:44.151Z","etag":null,"topics":["bun","deno","nodejs","rust","wasm","webassembly"],"latest_commit_sha":null,"homepage":"https://jsr.io/@gizmo-ds/totp-wasm","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/gizmo-ds.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-09-09T00:28:35.000Z","updated_at":"2025-04-28T06:28:10.000Z","dependencies_parsed_at":"2024-10-23T20:41:18.327Z","dependency_job_id":"4d6dfcc4-ad92-48f6-a553-63037b4f7c9e","html_url":"https://github.com/gizmo-ds/totp-wasm","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gizmo-ds%2Ftotp-wasm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gizmo-ds%2Ftotp-wasm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gizmo-ds%2Ftotp-wasm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gizmo-ds%2Ftotp-wasm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gizmo-ds","download_url":"https://codeload.github.com/gizmo-ds/totp-wasm/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252922307,"owners_count":21825641,"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":["bun","deno","nodejs","rust","wasm","webassembly"],"created_at":"2024-10-03T17:50:13.919Z","updated_at":"2025-05-07T17:21:07.813Z","avatar_url":"https://github.com/gizmo-ds.png","language":"Rust","funding_links":[],"categories":["Rust"],"sub_categories":[],"readme":"# totp-wasm\n\nHOTP([RFC 4226](https://tools.ietf.org/html/rfc4226)) \u0026 TOTP([RFC 6238](https://tools.ietf.org/html/rfc6238)) \u0026 Steam Guard TOTP\n\n## Demo\n\n[https://totp-wasm.vercel.app](https://totp-wasm.vercel.app)\n\n## Usage\n\n### Deno\n\n```typescript\nimport {\n  totp,\n  init,\n  wasm_data,\n} from 'https://deno.land/x/totp_wasm/deno/mod.ts'\n\nawait init(wasm_data)\nconst code = totp('GM4VC2CQN5UGS33ZJJVWYUSFMQ4HOQJW', 1662681600, 6, 30)\nconsole.log(code)\n// 473526\n```\n\n### Browser\n\n[example](./examples/browser)\n\n### Node.js\n\n[example](./examples/node)\n\n### Bun\n\n[example](./examples/bun)\n\n## Build\n\nPrerequisites\n\n- [Rust](https://www.rust-lang.org)\n- [Node.js](https://nodejs.org)\n\n```bash\nrustup target add wasm32-unknown-unknown\ncargo install --version=0.2.86 wasm-bindgen-cli\npnpm install\nnode scripts/build.mjs\n```\n\n## Runing examples\n\n```bash\ncd examples/browser\npnpm install\npnpm dev\n```\n\n# Related Projects\n\nHere are some related projects that you may find useful:\n\n- [totp-wasm-zig](https://github.com/gizmo-ds/totp-wasm-zig): Zig implementation of this project.\n- [UdonOTPLib](https://github.com/gizmo-ds/UdonOTPLib): C# implementation for the VRChat game.\n\n## License\n\nCode is distributed under [MIT](./LICENSE) license, feel free to use it in your proprietary projects as well.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgizmo-ds%2Ftotp-wasm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgizmo-ds%2Ftotp-wasm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgizmo-ds%2Ftotp-wasm/lists"}