{"id":43482006,"url":"https://github.com/xlstudio/wxbizdatacrypt","last_synced_at":"2026-02-03T08:34:13.492Z","repository":{"id":57482566,"uuid":"73391625","full_name":"xlstudio/wxbizdatacrypt","owner":"xlstudio","description":"微信小程序加密数据解密算法Go版","archived":false,"fork":false,"pushed_at":"2020-12-10T08:09:05.000Z","size":13,"stargazers_count":148,"open_issues_count":0,"forks_count":46,"subscribers_count":7,"default_branch":"master","last_synced_at":"2024-11-17T12:48:41.571Z","etag":null,"topics":["wechat","wechat-sdk","weixin","wxbizdatacrypt"],"latest_commit_sha":null,"homepage":"https://reqres.cn","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/xlstudio.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}},"created_at":"2016-11-10T14:52:45.000Z","updated_at":"2024-09-26T11:24:47.000Z","dependencies_parsed_at":"2022-09-02T06:20:49.166Z","dependency_job_id":null,"html_url":"https://github.com/xlstudio/wxbizdatacrypt","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/xlstudio/wxbizdatacrypt","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xlstudio%2Fwxbizdatacrypt","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xlstudio%2Fwxbizdatacrypt/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xlstudio%2Fwxbizdatacrypt/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xlstudio%2Fwxbizdatacrypt/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/xlstudio","download_url":"https://codeload.github.com/xlstudio/wxbizdatacrypt/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xlstudio%2Fwxbizdatacrypt/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29038652,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-03T06:39:36.383Z","status":"ssl_error","status_checked_at":"2026-02-03T06:39:32.787Z","response_time":96,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["wechat","wechat-sdk","weixin","wxbizdatacrypt"],"created_at":"2026-02-03T08:34:12.295Z","updated_at":"2026-02-03T08:34:13.487Z","avatar_url":"https://github.com/xlstudio.png","language":"Go","funding_links":[],"categories":["Go"],"sub_categories":[],"readme":"### 微信小程序加密数据解密算法Go语言版\n\n**微信小程序开发官方说明文档 - 签名加密篇文档链接**\n\n***~~1. 最早的文档链接（已失效）~~***\n\u003e ~~http://mp.weixin.qq.com/debug/wxadoc/dev/api/signature.html?t=20161107~~\n\n***~~2. 旧文档链接（已失效）~~***\n\u003e ~~https://developers.weixin.qq.com/miniprogram/dev/api/signature.html~~\n\n***3. 最新文档链接（当前官方最新文档）***\n\u003e https://developers.weixin.qq.com/miniprogram/dev/framework/open-ability/signature.html\n\n**使用方法**\n\n\u003e go get github.com/xlstudio/wxbizdatacrypt\n\n**引入方法**\n```Go\nimport (\n\t\"github.com/xlstudio/wxbizdatacrypt\"\n)\n```\n**使用示例**\n\n```Go\npackage main\n\nimport (\n\t\"fmt\"\n\t\"github.com/xlstudio/wxbizdatacrypt\"\n)\n\nfunc main() {\n\tappId := \"wx4f4bc4dec97d474b\"\n\tsessionKey := \"tiihtNczf5v6AKRyjwEUhQ==\"\n\tencryptedData := \"CiyLU1Aw2KjvrjMdj8YKliAjtP4gsMZMQmRzooG2xrDcvSnxIMXFufNstNGTyaGS9uT5geRa0W4oTOb1WT7fJlAC+oNPdbB+3hVbJSRgv+4lGOETKUQz6OYStslQ142dNCuabNPGBzlooOmB231qMM85d2/fV6ChevvXvQP8Hkue1poOFtnEtpyxVLW1zAo6/1Xx1COxFvrc2d7UL/lmHInNlxuacJXwu0fjpXfz/YqYzBIBzD6WUfTIF9GRHpOn/Hz7saL8xz+W//FRAUid1OksQaQx4CMs8LOddcQhULW4ucetDf96JcR3g0gfRK4PC7E/r7Z6xNrXd2UIeorGj5Ef7b1pJAYB6Y5anaHqZ9J6nKEBvB4DnNLIVWSgARns/8wR2SiRS7MNACwTyrGvt9ts8p12PKFdlqYTopNHR1Vf7XjfhQlVsAJdNiKdYmYVoKlaRv85IfVunYzO0IKXsyl7JCUjCpoG20f0a04COwfneQAGGwd5oa+T8yO5hzuyDb/XcxxmK01EpqOyuxINew==\"\n\tiv := \"r7BXXKkLb8qrSNn05n0qiA==\"\n\n\tpc := wxbizdatacrypt.WxBizDataCrypt{AppId: appId, SessionKey: sessionKey}\n\tresult, err := pc.Decrypt(encryptedData, iv, true) //第三个参数解释： 需要返回 JSON 数据类型时 使用 true, 需要返回 map 数据类型时 使用 false\n\tif err != nil {\n\t\tfmt.Println(err)\n\t} else {\n\t\tfmt.Println(result)\n\t}\n}\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxlstudio%2Fwxbizdatacrypt","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fxlstudio%2Fwxbizdatacrypt","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxlstudio%2Fwxbizdatacrypt/lists"}