Ledger object IDs: update diagram

This commit is contained in:
mDuo13
2020-10-29 15:10:07 -07:00
parent ed279d247c
commit 332a66e577
6 changed files with 1801 additions and 4 deletions

View File

@@ -3,8 +3,7 @@
レジャーの状態ツリーのすべてのオブジェクトには一意のIDがあります。このフィールドは、オブジェクトの内容と同じレベルでJSONの`index`フィールドとして返されます。IDは、オブジェクトの重要な内容をハッシュし、[名前空間ID](https://github.com/ripple/rippled/blob/master/src/ripple/protocol/LedgerFormats.h#L99)を使用して生成されます。[レジャーオブジェクトタイプ](ledger-object-types.html)により、使用する名前空間IDとハッシュに含める内容が決定します。これにより、すべてのIDが一意になります。ハッシュを計算するため、`rippled`はSHA-512を使用し、その結果を最初の256バイトで切り捨てます。**SHA-512ハーフ**と呼ばれるこのアルゴリズム出力は、SHA-256と同等のセキュリティで、64ビットプロセッサーでは実行にかかる時間が短くなります。
![図: rippledによる、SHA-512ハーフを使用したレジャーオブジェクトIDの生成。スペースキーは、異なるオブジェクトタイプIDの競合を防止します。](img/ledger-indexes.ja.png)
{{ include_svg("img/ledger-object-ids.ja.svg", "図: rippledによる、SHA-512ハーフを使用したレジャーオブジェクトIDの生成。スペースキーは、異なるオブジェクトタイプIDの競合を防止します。") }}
## 関連項目
@@ -15,4 +14,4 @@
<!--{# common link defs #}-->
{% include '_snippets/rippled-api-links.md' %}
{% include '_snippets/tx-type-links.md' %}
{% include '_snippets/rippled_versions.md' %}
{% include '_snippets/rippled_versions.md' %}

View File

@@ -7,7 +7,7 @@ Generally, a ledger object's ID is returned as the `index` field in JSON, at the
**Tip:** The `index` or `LedgerIndex` field of an object in the ledger is the ledger object ID. This is not the same as a [ledger index][].
![Diagram: rippled uses SHA-512Half to generate IDs for ledger objects. The space key prevents IDs for different object types from colliding.](img/ledger-indexes.png)
{{ include_svg("img/ledger-object-ids.svg", "Diagram: rippled uses SHA-512Half to generate IDs for ledger objects. The space key prevents IDs for different object types from colliding.") }}
## See Also