# 135 - msrpc

<pre><code><strong># msrpc 바인딩
</strong>rpcclient -U '&#x3C;username>' '&#x3C;server-address>'

<strong># 익명 바인딩
</strong>rpcclient -U "" -N '&#x3C;server-address>' 
</code></pre>

연결이 성공되어 명령을 실행할 권한이 있다면 아래와 같은 명령을 통해 다양한 정보 수집 및 원격 실행이 가능합니다.

| 명령               | 결과                 |
| ---------------- | ------------------ |
| querydominfo     | 도메인 정보             |
| querydispinfo    | 도메인 유저 정보          |
| enumdomains      | 사용중인 도메인 목록        |
| srvinfo          | 서버 정보              |
| netshareenumall  | 사용 가능한 모든 쉐어 절대 경로 |
| enumdomusers     | 모든 도메인 사용자 열거      |
| queryuser \<RID> | 특정 사용자에 대한 정보를 제공  |


---

# Agent Instructions: 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:

```
GET https://www.pentestwiki.com/post-exploit/protocols/135-msrpc.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
