{"id":18787944,"url":"https://github.com/wuhan005/onecode","last_synced_at":"2025-04-13T13:17:04.920Z","repository":{"id":108599865,"uuid":"106106842","full_name":"wuhan005/OneCode","owner":"wuhan005","description":"一个安全快捷的临时密码生成\u0026登录工具。可以生成一个临时密码用于登录/双重验证，密码五分钟后过期，使用一次后无效。","archived":false,"fork":false,"pushed_at":"2017-11-18T07:37:51.000Z","size":12,"stargazers_count":5,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-13T13:16:38.761Z","etag":null,"topics":["login-oauth","onecode","password","php"],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/wuhan005.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":"2017-10-07T15:06:54.000Z","updated_at":"2021-12-17T18:28:42.000Z","dependencies_parsed_at":null,"dependency_job_id":"588ce9a1-161d-4ee4-9eb3-a74772bf2bbf","html_url":"https://github.com/wuhan005/OneCode","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/wuhan005%2FOneCode","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wuhan005%2FOneCode/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wuhan005%2FOneCode/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wuhan005%2FOneCode/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wuhan005","download_url":"https://codeload.github.com/wuhan005/OneCode/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248717236,"owners_count":21150389,"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":["login-oauth","onecode","password","php"],"created_at":"2024-11-07T20:57:03.917Z","updated_at":"2025-04-13T13:17:04.834Z","avatar_url":"https://github.com/wuhan005.png","language":"PHP","readme":"# OneCode\n![OneCode Logo](https://onecode.wuhan5.cc/OneCode%20SUB.png)\n\n一个安全快捷的临时密码生成\u0026amp;登录的 PHP 小程序。可以生成一个临时密码用于登录/双重验证，密码五分钟后过期，使用一次后即失效，安全可靠。\n* * *\n## 安装\nClone from Github\n\n```\ngit clone https://github.com/wuhan005/OneCode.git\n```\n\n将文件拷贝到网站服务器目录即可。\n* * *\n## 使用\n### 1. 生成新的 OneCode\n```\nPOST https://www.yourwebsite.domain/GenerateKey.php\n```\n#### 请求参数\n`token` （在 config.php 中设置）\n\n`key` （在 config.php 中设置）\n#### 返回值\n`CODE`\n\n- `200` （成功 返回为新OneCode）\n\n- `501` （错误）\n\n`Message` （信息提示）\n* * *\n\n### 2. 验证 OneCode\n```\nPOST https://www.yourwebsite.domain/AuthKey.php\n```\n#### 请求参数\n`onecode`\n#### 返回值\n`CODE`\n\n- `200` （成功）\n- `501` （验证错误）\n- `502` （OneCode尝试次数用尽）\n- `503` （OneCode已过期）\n\n`Message` （信息提示）\n\n- `Authorization Error! ` 验证错误\n- `The Key is Not Available. ` OneCode尝试次数用尽\n- `Overtime!` OneCode 已过期\n\n### 3. 配置相关（config.php）\n- `$_salt` （加密所使用的 Salt 值）\n- `$_token` （验证用 Token）\n- `$_key` （验证用 Key，建议为4位数字）\n\n* * *\n## 目录文件\n* AuthKey.php 验证 OneCode\n* GenerateKey.php 生成新的 OneCode\n* OneCode.json 用于储存OneCode\n* config.php 配置文件\n* * *\n\n## 联系我\n- E-mail: 524306184@qq.com\n- Blog: [https://wuhan5.cc/](https://wuhan5.cc/) \n- QQ: 524306184\n\n* * *\n\n## LICENSE\nGNU General Public License v2.0\n\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwuhan005%2Fonecode","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwuhan005%2Fonecode","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwuhan005%2Fonecode/lists"}