Skip to content

Conversation

aigerimu
Copy link
Contributor

@aigerimu aigerimu commented Oct 2, 2025

closes #135

@aigerimu aigerimu requested a review from a team as a code owner October 2, 2025 19:20
Copy link

github-actions bot commented Oct 2, 2025

To fix the formatting issues:

  1. Install necessary dependencies: npm ci
  2. Then, run this command:
npx remark -o --quiet --silently-ignore ecosystem/wallet-apps/overview.mdx 

@aigerimu aigerimu changed the title wallets-overview-draft wallets-overview Oct 2, 2025
Copy link

github-actions bot commented Oct 2, 2025

Thanks for the updates to the wallet apps overview. A few high‑severity doc fixes are needed before merge, focused in ecosystem/wallet-apps/overview.mdx.

Findings (3)

High (3)

[HIGH] TODO placeholders left in content

Location:

**TODO: clarify account moments**
**TODO: add links**

Description:
Visible TODO placeholders on lines 5–7 indicate incomplete content, which blocks publication and undermines clarity and trust.

Suggestion:
Remove the placeholders (minimal removal shown):

-**TODO: clarify account moments**
-
-**TODO: add links**

[HIGH] Unresolved placeholder in account initialization

Location:

A wallet account begins in the [nonexist state](/ton/statuses#status-variety), which is the default for accounts with no transaction history, code, data, or balance. At this stage, the account does not exist on-chain. However, its **wallet address** can already be computed from the wallet’s **TODO**. This address can be used to receive funds even before the wallet is initialized.

Description:
Line 26 contains an unresolved placeholder “wallet’s TODO” where the mechanism for computing the wallet address should be named, blocking comprehension at a critical point.

Suggestion:

- However, its **wallet address** can already be computed from the wallet’s **TODO**.
+ However, its wallet address can already be computed from the contract’s `StateInit`.

[HIGH] Missing code formatting for literal seqno

Location:

- Sequence number (seqno) — ensures uniqueness and prevents replay attacks.
- Submission — the signed message is sent to the blockchain network.
- Processing — validators verify the signature, apply fees, and update the account's balance and state.
Each processed transaction increments the wallet's seqno and updates its state. Transactions can carry Toncoin or other supported assets and interact with other smart contracts.

Description:
The literal field name “seqno” appears without code formatting in the key steps list and the following paragraph, violating the style guide and reducing scanability.

Suggestion:

- - Sequence number (seqno) — ensures uniqueness and prevents replay attacks.
+ - Sequence number (`seqno`) — ensures uniqueness and prevents replay attacks.
@@
- Each processed transaction increments the wallet's seqno and updates its state.
+ Each processed transaction increments the wallet's `seqno` and updates its state.

@aigerimu aigerimu marked this pull request as draft October 2, 2025 19:37
Copy link

github-actions bot commented Oct 3, 2025

To fix the formatting issues:

  1. Install necessary dependencies: npm ci
  2. Then, run this command:
npx remark -o --quiet --silently-ignore ecosystem/wallet-apps/overview.mdx standard/wallets/mnemonics.mdx 

@aigerimu aigerimu requested a review from verytactical October 3, 2025 21:58
@aigerimu aigerimu marked this pull request as ready for review October 3, 2025 21:58
Copy link

github-actions bot commented Oct 5, 2025

Thanks for the updates to the wallet apps documentation. A couple of safety callouts need fixes to meet the style guide before merge.

Findings (2)

High (2)

[HIGH] Safety callout lacks required structure for funds risk

Location:

<Aside type="caution">
Developer wallets, such as TonDevWallet, are intended for Testnet only. Do **not** use them on Mainnet, as this may result in irreversible loss of funds.
</Aside>

Description:
The developer-wallet callout warns about testnet/mainnet but omits mandatory safety-callout elements: explicit risk, scope, rollback/mitigation, and environment. Without these, readers may attempt mainnet usage with developer wallets and risk irreversible fund loss.

Suggestion:

--- a/ecosystem/wallet-apps/overview.mdx
+++ b/ecosystem/wallet-apps/overview.mdx
@@
-<Aside type="caution">
-  Developer wallets, such as TonDevWallet, are intended for Testnet only. Do **not** use them on Mainnet, as this may result in irreversible loss of funds.
-</Aside>
+<Aside type="warning" title="Funds at risk — Testnet only">
+  Risk: Using developer wallets on TON Mainnet can irreversibly transfer or expose funds.
+  Scope: Applies to developer wallets (e.g., TonDevWallet).
+  Environment: Use on TON Testnet only; do not use on TON Mainnet.
+  Rollback: None — on-chain transfers are final.
+</Aside>

[HIGH] Safety callout lacks required details for mnemonic secrecy

Location:

<Aside type="caution">
Keep it secret. Keep it safe.
</Aside>

Description:
The mnemonic caution (“Keep it secret. Keep it safe.”) omits required elements. Per the safety-callout rules, it must include risk, scope, rollback/mitigation, and an environment label with testnet as the safer default. Because mnemonics involve secrets, this is release-blocking.

Suggestion:

-<Aside type="caution">
-  Keep it secret. Keep it safe.
-</Aside>
+<Aside type="warning" title="Secrets at risk">
+Exposing or storing your mnemonic can allow account takeover and loss of funds.
+Scope: your wallet and any derived subwallets.
+Rollback: none. If exposed, move funds to a new wallet and abandon the old mnemonic.
+Environment: use testnet mnemonics for tutorials; never reuse them on mainnet.
+</Aside>


Wallets manage accounts, control keys, sign messages, and initiate transactions. This process starts with mnemonic decoding and continues through transaction execution.

### Mnemonic decoding
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you mean that it's already written?


## How wallet apps work

Wallets manage accounts, control keys, sign messages, and initiate transactions. This process starts with mnemonic decoding and continues through transaction execution.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wallets or wallet apps?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should probably start with an explanation of what "custodial" means.


A wallet account starts in the [nonexist state](/ton/statuses#status-variety), which is the default for accounts with no transaction history, code, data, or balance. At this stage, the account does not exist on-chain.

However, its **wallet address** can be computed from the [workchain_id](/ton/addresses/addresses-general-info#workchain-id) and [account_id](/ton/addresses/addresses-general-info#account-id). This address can be used to receive funds even before the wallet is initialized.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From its initial state, as for any other contract.

Initial state for some wallet contracts do have workchain id, but in fact the list of fields depends on the exact wallet contract used.


However, its **wallet address** can be computed from the [workchain_id](/ton/addresses/addresses-general-info#workchain-id) and [account_id](/ton/addresses/addresses-general-info#account-id). This address can be used to receive funds even before the wallet is initialized.

After receiving coins, the account enters the [uninit state](/ton/statuses#status-variety). In this state, it holds a balance and metadata but cannot execute transactions or process messages.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It can be a part of transaction. It cannot execute code, because it doesn't have the code.

Please refer to corresponding section of block.tlb.


When making a transaction, the wallet goes through these steps:
- **Message creation** — builds an external message with the recipient, amount, and optional payload.
- **Sequence number check** — reads the account's current on-chain `seqno` and includes it to prevent [replay attacks](/standard/wallets/how-it-works#how-replay-protection-works).
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not necessarily. Not all wallets have or must have seqno.

Copy link
Collaborator

@verytactical verytactical left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The article doesn't describe things mentioned in the ticket, but instead repeats "How it works" article (in some parts even better than that article).

In order not to waste this good effort, most of this text might be landed to that article. For an "Overview" article please stick closer to the ticket.

@hacker-volodya hacker-volodya removed the request for review from a team October 7, 2025 18:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Ecosystem > Wallet apps > Overview]
2 participants