> For the complete documentation index, see [llms.txt](https://hacking-notes.jord4n.pro/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://hacking-notes.jord4n.pro/zh/active-directory/kerberos/general-kerberos-flow.md).

# Kerberos 总体流程

### 第1步 — AS-REQ

当用户登录时，其客户端会向 KDC 发送请求：

```bash
AS-REQ
```

此请求对应于初始身份验证请求。

### 第2步 — AS-REP

如果身份验证有效，KDC 会返回一个响应：

```bash
AS-REP
```

此响应中尤其包含一个 **TGT**，或 **票据授予票据**.

TGT 可以被视为一种通用票据，允许你请求服务票据。

### 第3步 - TGS-REQ

当用户想要访问某个资源，例如网络共享时，他会向 KDC 出示自己的 TGT。

然后客户端发送：

```bash
TGS-REQ
```

此请求用于为特定服务申请票据。

### 第4步 — TGS-REP

KDC 会检查 TGT 并返回一个服务票据：

```bash
TGS-REP
```

此票据专用于所请求的服务。

### 第5步 — 访问资源

客户端将服务票据出示给目标服务器。

例如，要访问：

```bash
//WS01/C$
```

客户端向服务器提交服务票据 `WS01`.

如果票据有效，但用户在共享上没有必要的权限，身份验证可能会成功，但 SMB 访问将被拒绝。


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://hacking-notes.jord4n.pro/zh/active-directory/kerberos/general-kerberos-flow.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
