# Chain Connection

### Two-way secure state management

YAR chain is connected to networks like Bitcoin and Ethereum via bidirectional security busses of the YAR protocol. This means that subjects and objects in networks may or may not be bound to subjects and objects in other networks. State management only synchronizes the state of a transaction or linked smart contract on the external network. Specifically, the system tracks:

* which part of an object has been moved;
* associated information such as the transaction ID;
* the address of the sender;
* the address of the person receiving the asset.

It's worth noting that only information about YAR-related transactions is synchronized, but not every transaction in the external network.

To make this possible, code must be written for each connected network, the so-called "network connectors", which describe possible scenarios for working with objects and subjects of the external network.


---

# 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://docs.yarchain.org/whitepaper/project-mechanics/chain-connection.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.
