yggdrasil-scaffold


Nameyggdrasil-scaffold JSON
Version 0.1.0.dev6 PyPI version JSON
download
home_pagehttps://github.com/Silverteal/yggdrasil-scaffold
SummaryYggdrasil Scaffold for Authlib-injector
upload_time2024-10-04 13:01:55
maintainerNone
docs_urlNone
authorSilverteal
requires_python<4.0,>=3.12
licenseMIT
keywords minecraft mc authlib authlib-injector implementaion api yggdrasil
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Yggdrasil Scaffold for Authlib-injector

基于 FastAPI 和 [ADOFAI](https://github.com/silverteal/adofai) 的 Yggdrasil 身份验证协议实现脚手架。

Yggdrasil 是 Minecraft 中身份验证服务的实现名称。

## 使用方式

### 安装

```shell
pip install yggdrasil-scaffold
```

详细的文档还没有写。但是这里有些资料:

### 可用资源

* `test`目录下有一些样例,模块内部有中文 docstring 和一些注释,暂时可供参考。

* `CONTRIBUTING.md` 中有本项目的术语表

* 关于 Yggdrasil API 的更多信息可参见
  [此文章](https://github.com/yushijinhun/authlib-injector/wiki/Yggdrasil-%E6%9C%8D%E5%8A%A1%E7%AB%AF%E6%8A%80%E6%9C%AF%E8%A7%84%E8%8C%83)

### 实现速查

如果你打算将本项目用于 Authlib-injector,那么下表列出了你需要实现的端点:

| 端点类型 | 客户端(原版)          | 服务端(原版)          |
|------|------------------|------------------|
| 用户   | /                | /                |
| 会话   | `join`           | `hasJoined`      |
| 查询   | `query_by_names` | `query_by_names` |
| 材质管理 | /                | /                |
| 元数据  | 全部               | 全部               |

注: Mojang 的身份认证库 Authlib 的一些早期版本包含对用户端点的调用,但最新版本中已移除。
我不确定用户端点是否在某些版本的游戏上有用,抑或是本就只在 Minecraft 启动器上可用。

游戏只会在”需要从玩家名获取 UUID“时才会访问查询端点。其它时候会从 `usercache.json` 或者类似的地方获取。

客户端进行多人游戏时,会访问元数据端点来验证材质签名。

如果你打算将本项目用于服务启动器,那么最好实现除`hasJoined`以外的全部端点,启动器很可能会用到它们。

## 警告

Yggdrasil Scaffold 并非被设计用于高并发或安全性要求高的用途,且未经严格测试。请谨慎在生产环境使用。

## 另请参阅

[ADOFAI](https://github.com/silverteal/adofai) 是一组数据模型和配套工具,旨在简化自定义实现 Authlib-injector 的规范
Yggdrasil 服务端、客户端及其配套程序的过程。

[Yggdrasil Client](https://github.com/Silverteal/yggdrasil-client) 是基于 ADOFAI 和 aiohttp 的 Minecraft Yggdrasil
协议兼容客户端,支持 Mojang 后端。
            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/Silverteal/yggdrasil-scaffold",
    "name": "yggdrasil-scaffold",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.12",
    "maintainer_email": null,
    "keywords": "minecraft, mc, authlib, authlib-injector, implementaion, api, yggdrasil",
    "author": "Silverteal",
    "author_email": "67404722+Silverteal@users.noreply.github.com",
    "download_url": "https://files.pythonhosted.org/packages/4c/b0/4cee220aa66c04bf52723b401289a509bbcfc55b971afe2e67e57f97f3f5/yggdrasil_scaffold-0.1.0.dev6.tar.gz",
    "platform": null,
    "description": "# Yggdrasil Scaffold for Authlib-injector\n\n\u57fa\u4e8e FastAPI \u548c [ADOFAI](https://github.com/silverteal/adofai) \u7684 Yggdrasil \u8eab\u4efd\u9a8c\u8bc1\u534f\u8bae\u5b9e\u73b0\u811a\u624b\u67b6\u3002\n\nYggdrasil \u662f Minecraft \u4e2d\u8eab\u4efd\u9a8c\u8bc1\u670d\u52a1\u7684\u5b9e\u73b0\u540d\u79f0\u3002\n\n## \u4f7f\u7528\u65b9\u5f0f\n\n### \u5b89\u88c5\n\n```shell\npip install yggdrasil-scaffold\n```\n\n\u8be6\u7ec6\u7684\u6587\u6863\u8fd8\u6ca1\u6709\u5199\u3002\u4f46\u662f\u8fd9\u91cc\u6709\u4e9b\u8d44\u6599\uff1a\n\n### \u53ef\u7528\u8d44\u6e90\n\n* `test`\u76ee\u5f55\u4e0b\u6709\u4e00\u4e9b\u6837\u4f8b\uff0c\u6a21\u5757\u5185\u90e8\u6709\u4e2d\u6587 docstring \u548c\u4e00\u4e9b\u6ce8\u91ca\uff0c\u6682\u65f6\u53ef\u4f9b\u53c2\u8003\u3002\n\n* `CONTRIBUTING.md` \u4e2d\u6709\u672c\u9879\u76ee\u7684\u672f\u8bed\u8868\n\n* \u5173\u4e8e Yggdrasil API \u7684\u66f4\u591a\u4fe1\u606f\u53ef\u53c2\u89c1\n  [\u6b64\u6587\u7ae0](https://github.com/yushijinhun/authlib-injector/wiki/Yggdrasil-%E6%9C%8D%E5%8A%A1%E7%AB%AF%E6%8A%80%E6%9C%AF%E8%A7%84%E8%8C%83)\n\n### \u5b9e\u73b0\u901f\u67e5\n\n\u5982\u679c\u4f60\u6253\u7b97\u5c06\u672c\u9879\u76ee\u7528\u4e8e Authlib-injector\uff0c\u90a3\u4e48\u4e0b\u8868\u5217\u51fa\u4e86\u4f60\u9700\u8981\u5b9e\u73b0\u7684\u7aef\u70b9\uff1a\n\n| \u7aef\u70b9\u7c7b\u578b | \u5ba2\u6237\u7aef\uff08\u539f\u7248\uff09          | \u670d\u52a1\u7aef\uff08\u539f\u7248\uff09          |\n|------|------------------|------------------|\n| \u7528\u6237   | /                | /                |\n| \u4f1a\u8bdd   | `join`           | `hasJoined`      |\n| \u67e5\u8be2   | `query_by_names` | `query_by_names` |\n| \u6750\u8d28\u7ba1\u7406 | /                | /                |\n| \u5143\u6570\u636e  | \u5168\u90e8               | \u5168\u90e8               |\n\n\u6ce8\uff1a Mojang \u7684\u8eab\u4efd\u8ba4\u8bc1\u5e93 Authlib \u7684\u4e00\u4e9b\u65e9\u671f\u7248\u672c\u5305\u542b\u5bf9\u7528\u6237\u7aef\u70b9\u7684\u8c03\u7528\uff0c\u4f46\u6700\u65b0\u7248\u672c\u4e2d\u5df2\u79fb\u9664\u3002\n\u6211\u4e0d\u786e\u5b9a\u7528\u6237\u7aef\u70b9\u662f\u5426\u5728\u67d0\u4e9b\u7248\u672c\u7684\u6e38\u620f\u4e0a\u6709\u7528\uff0c\u6291\u6216\u662f\u672c\u5c31\u53ea\u5728 Minecraft \u542f\u52a8\u5668\u4e0a\u53ef\u7528\u3002\n\n\u6e38\u620f\u53ea\u4f1a\u5728\u201d\u9700\u8981\u4ece\u73a9\u5bb6\u540d\u83b7\u53d6 UUID\u201c\u65f6\u624d\u4f1a\u8bbf\u95ee\u67e5\u8be2\u7aef\u70b9\u3002\u5176\u5b83\u65f6\u5019\u4f1a\u4ece `usercache.json` \u6216\u8005\u7c7b\u4f3c\u7684\u5730\u65b9\u83b7\u53d6\u3002\n\n\u5ba2\u6237\u7aef\u8fdb\u884c\u591a\u4eba\u6e38\u620f\u65f6\uff0c\u4f1a\u8bbf\u95ee\u5143\u6570\u636e\u7aef\u70b9\u6765\u9a8c\u8bc1\u6750\u8d28\u7b7e\u540d\u3002\n\n\u5982\u679c\u4f60\u6253\u7b97\u5c06\u672c\u9879\u76ee\u7528\u4e8e\u670d\u52a1\u542f\u52a8\u5668\uff0c\u90a3\u4e48\u6700\u597d\u5b9e\u73b0\u9664`hasJoined`\u4ee5\u5916\u7684\u5168\u90e8\u7aef\u70b9\uff0c\u542f\u52a8\u5668\u5f88\u53ef\u80fd\u4f1a\u7528\u5230\u5b83\u4eec\u3002\n\n## \u8b66\u544a\n\nYggdrasil Scaffold \u5e76\u975e\u88ab\u8bbe\u8ba1\u7528\u4e8e\u9ad8\u5e76\u53d1\u6216\u5b89\u5168\u6027\u8981\u6c42\u9ad8\u7684\u7528\u9014\uff0c\u4e14\u672a\u7ecf\u4e25\u683c\u6d4b\u8bd5\u3002\u8bf7\u8c28\u614e\u5728\u751f\u4ea7\u73af\u5883\u4f7f\u7528\u3002\n\n## \u53e6\u8bf7\u53c2\u9605\n\n[ADOFAI](https://github.com/silverteal/adofai) \u662f\u4e00\u7ec4\u6570\u636e\u6a21\u578b\u548c\u914d\u5957\u5de5\u5177\uff0c\u65e8\u5728\u7b80\u5316\u81ea\u5b9a\u4e49\u5b9e\u73b0 Authlib-injector \u7684\u89c4\u8303\nYggdrasil \u670d\u52a1\u7aef\u3001\u5ba2\u6237\u7aef\u53ca\u5176\u914d\u5957\u7a0b\u5e8f\u7684\u8fc7\u7a0b\u3002\n\n[Yggdrasil Client](https://github.com/Silverteal/yggdrasil-client) \u662f\u57fa\u4e8e ADOFAI \u548c aiohttp \u7684 Minecraft Yggdrasil\n\u534f\u8bae\u517c\u5bb9\u5ba2\u6237\u7aef\uff0c\u652f\u6301 Mojang \u540e\u7aef\u3002",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Yggdrasil Scaffold for Authlib-injector",
    "version": "0.1.0.dev6",
    "project_urls": {
        "Homepage": "https://github.com/Silverteal/yggdrasil-scaffold",
        "Repository": "https://github.com/Silverteal/yggdrasil-scaffold"
    },
    "split_keywords": [
        "minecraft",
        " mc",
        " authlib",
        " authlib-injector",
        " implementaion",
        " api",
        " yggdrasil"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "cca95f772663f0260e5598089f9d650d8235ce4f6f11b3ba331bf34e55e14463",
                "md5": "adea455e060625a64bd2217cf1e368c0",
                "sha256": "caf74b7205425bd80d42d16e1f21d50f735d351526819eae940566adbc6f4a97"
            },
            "downloads": -1,
            "filename": "yggdrasil_scaffold-0.1.0.dev6-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "adea455e060625a64bd2217cf1e368c0",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.12",
            "size": 22791,
            "upload_time": "2024-10-04T13:01:53",
            "upload_time_iso_8601": "2024-10-04T13:01:53.208153Z",
            "url": "https://files.pythonhosted.org/packages/cc/a9/5f772663f0260e5598089f9d650d8235ce4f6f11b3ba331bf34e55e14463/yggdrasil_scaffold-0.1.0.dev6-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "4cb04cee220aa66c04bf52723b401289a509bbcfc55b971afe2e67e57f97f3f5",
                "md5": "c5ab9c72ffa7ba322c9c81dae155de72",
                "sha256": "a3b42692c589f3d23f5c8cc051f454e2e67bb42f35db5c70908ea5172e46caae"
            },
            "downloads": -1,
            "filename": "yggdrasil_scaffold-0.1.0.dev6.tar.gz",
            "has_sig": false,
            "md5_digest": "c5ab9c72ffa7ba322c9c81dae155de72",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.12",
            "size": 16758,
            "upload_time": "2024-10-04T13:01:55",
            "upload_time_iso_8601": "2024-10-04T13:01:55.618354Z",
            "url": "https://files.pythonhosted.org/packages/4c/b0/4cee220aa66c04bf52723b401289a509bbcfc55b971afe2e67e57f97f3f5/yggdrasil_scaffold-0.1.0.dev6.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-10-04 13:01:55",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "Silverteal",
    "github_project": "yggdrasil-scaffold",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "yggdrasil-scaffold"
}
        
Elapsed time: 0.82411s