> For the complete documentation index, see [llms.txt](https://nervenetwork.gitbook.io/nerve/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://nervenetwork.gitbook.io/nerve/core-module-description/cross-chain-module.md).

# Cross-Chain Module

NerveChian's cross-chain interaction is divided into two parts:<br>

1. NULS cross-chain ecological docking: realize the interaction of all blockchains in the NULS ecosystem based on the general NULS cross-chain protocol.<br>
2. &#x20;For independent public chains such as Bitcoin, Ethereum and Binance chain, NerveNetwork defines a set of interface protocols, which can facilitate the interaction of different blockchains. The cross-chain interface protocol includes the following aspects:

* &#x20;address mapping
* creating multi-signature addresses/creating smart contracts
* transaction verification
* transaction assembly
* transaction broadcast
* signature verification
* additional signature

The architecture of cross-chain interaction protocol is designed as follows:

Every time a blockchain is docked, it needs to implement a set of interface protocol components for data interaction between the two chains.

A certain number of virtual bank nodes are selected from the consensus nodes to create and manage multi-signature addresses (smart contracts). Virtual banks are responsible for the verification of assets transfer in and execution of asset transfer out.\
&#x20;

Taking BTC as an example, the cross-chain interaction process is as follows:

Transfer in cross-chain assets (deposit - Cross In):

The user transfers BTC to the multi-signature account of the Bitcoin chain managed by the virtual bank, and fill in the remarks with his/her NerveNetwork address of Nerve-ADDR. The virtual bank of NerveNetwork monitors the transaction of the Bitcoin network, verifies the confirmation number, prevents the fork rollback attack, assembles a coin-creating transaction to the user's mapping address of Nerve-ADDR, and signs the transaction. Then it will broadcast the transaction, collect 66% signatures from the virtual bank, pack the transaction into the block, and then update the ledger. After that, the user has BTC assets in the NerveNetwork ecosystem. The actual BTC assets on Bitcoin network are guaranteed not to be used by the virtual bank.

&#x20;

<figure><img src="/files/3kkMSjSmWnE3EtNlfyPd" alt="" width="563"><figcaption></figcaption></figure>

Transfer out cross-chain assets (withdrawal - Cross Out):

The user assembles the transfer-out transaction, with the target address of Bitcoin address of BTC-ADDR, signs and broadcasts the transaction. Once the consensus node receives the transaction, it will validate the transaction signature and pack the transaction into the block after approving. After the block is confirmed, each node assembles the multi-signature transaction, and broadcasts it to the NerveNetwork. When the number of signatures is sufficient, the transaction will be broadcast to the Bitcoin main network, and BTC will be transferred to the BTC-ADDR from the Bitcoin multi-signature account. After that, the transaction is completed.<br>

<figure><img src="/files/0tvW9aczB6IhszvrZsVx" alt="" width="563"><figcaption></figcaption></figure>

&#x20;


---

# 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://nervenetwork.gitbook.io/nerve/core-module-description/cross-chain-module.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.
