Memos Format Standard #103
Replies: 2 comments 3 replies
-
I don't think this is a correct rule to follow / assumption:
I propose to remove these examples from the opening post in this discussion, it will without a doubt land us in episode 143 of the "I'll put my files on ledger in chunks" discussion. While sane people know this is a bad idea, attempts are being made every now and then. These examples might come across as endorsement.
✅ Agree Final note worth mentioning: "application/version" could be a bad idea to use as an example, as including app name and version in Memos could give away extra attack/scam surface: it could help to provide an easy to use attack vector when a user is already identified by r-address. |
Beta Was this translation helpful? Give feedback.
-
|
I agree that standardisation should be brought into memos, and, please, not only for that particular transaction type. Although, nothing prevents anyone to create a transaction blob with something they deem to be useful. Libraries should enforce and popularise the practice.
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Purpose and Scope
The purpose of this standard is to define a format for the memo field in XRP Ledger transactions. The memo field can be used for various applications, including but not limited to adding on-chain analytics information for a transaction. This standard is intended to be used by client libraries and user agents across various applications.
This document covers the general format for memos and includes a specific subsection for the
fundWalletfunction in client libraries for Testnet transactions.Data Structure and Format
The memo field should be an object with the following properties:
data: An optional string that represents the data.type: An optional string that represents the type of data.format: An optional string that represents the format of the data.The
typeandformatfields should follow existing standards for user agent identification. Thetypefield should specify the type of data, and theformatfield should specify the format of the data.The
formatfield should follow the format of standard MIME types. MIME types are used to specify the format of files sent over the Internet, such as images, videos, and audio files. The format of a MIME type is as follows:type/subtype
The
typefield indicates the general category of the data, such as text, image, or audio. Thesubtypefield indicates the specific format of the data within the category.Example
Validation Rules
To ensure that the memo field is consistent with the standard and can be read by compatible software, the following validation rules should be followed:
data,type, andformatfields should be strings.datafield is optional.typefield is optional.formatfield is optional.formatfield is present, it should follow the format of standard MIME types.Best Practices
To ensure that the memo field is easy to read and consistent across different user agents, the following best practices are recommended:
typeandformatfields.typefield.formatfield, such as MIME types.datafield only when necessary.fundWallet Function (Testnet)
For the fundWallet function used in Testnet transactions across all client libraries, the memo field is used to add on-chain analytics information for a transaction. This tracking is only done for Testnet transactions and is not applicable to Mainnet usage.
In order to protect user privacy and security, client details (such as name and version number) should not be included in the memo field. Rather, client analytics can be collected during the connection process and do not need to be included in the memo field.
References
Beta Was this translation helpful? Give feedback.
All reactions