Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TrustAtoms allow content over 900 bytes, stored in "extra" entry #7

Open
harlantwood opened this issue Feb 16, 2022 · 1 comment · May be fixed by #21
Open

TrustAtoms allow content over 900 bytes, stored in "extra" entry #7

harlantwood opened this issue Feb 16, 2022 · 1 comment · May be fixed by #21
Assignees

Comments

@harlantwood
Copy link
Member

harlantwood commented Feb 16, 2022

Feature

If content exceeds 900 bytes:

  • In the link tag: it ends with (unicode char) as a hint

  • Full content is stored in the extra Entry under the key __FULL_TRUST_ATOM_CONTENT__

      eg: extra is equal to
      { "__FULL_TRUST_ATOM_CONTENT__": "abcdefg....",  ... }
    
  • Validation error if user passes in extra hash with __FULL_TRUST_ATOM_CONTENT__ as top level key

      eg: if user sends us an extra hash with:
      { "__FULL_TRUST_ATOM_CONTENT__": "zzzzz....",  ... }
      and they also send content > 900 bytes: "aaaa..."
    
@dauphin3 dauphin3 linked a pull request Mar 1, 2022 that will close this issue
@harlantwood
Copy link
Member Author

harlantwood commented May 5, 2022

from discussion:

trustatom::create_trust_atom( 
  target: string version of EntryHash // TBH would be better to be more readable thing
  content: string // semantic
  value: number as string // scalar
  extra: { foo: "bar", bar2: "baz", baz2: 333 } // valid
  extra: { {foo: "bar"}, bar2: "baz", baz2: 333 } // invalid
  extra: [ "foo" ] // invalid
)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants