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

Add metadata parameter to application-message #448

Open
tim-mchale opened this issue Apr 21, 2020 · 0 comments
Open

Add metadata parameter to application-message #448

tim-mchale opened this issue Apr 21, 2020 · 0 comments
Labels
enhancement New feature or request

Comments

@tim-mchale
Copy link

Problem
There is a need to be able to optionally append implementation-specific data to an application-message independent of the current businessProcessMessage payload.

Solution
Modifications to /hcs-sxc-java-proto/src/main/proto/Messages.proto

Add:

import "google/protobuf/any.proto"

Modify application-message to:

ApplicationMessageID applicationMessageId = 1;
    bytes businessProcessMessage = 2;  // the payload
    bytes unencryptedBusinessProcessMessageHash  = 3;
    bytes businessProcessSignatureOnHash  = 4;
    bytes encryptionRandom = 5;  // random number used for ivspec. it doubles as a flag to test if message is encrypted
    google.protobuf.Any metadata = 6; // container for extensibility and/or inclusion of filtering criteria
    bytes metadataHash = 7;
    bytes metadataSignatureOnHash = 8;
}

The additional metadataHash and metadataSignatureOnHash are included to support discretionary proof after the fact on metadata if included; this mechanism is identical to that which is currently implemented on businessProcessMessage.

Additional Context

  • This modification allows external references to be added to simplify correlation with external systems using their own identifiers.
  • In addition, data can be included to allow more granular filtering on a modified mirror-node to reduce message processing requirements on appnet participants subscribed to that mirror-node. This is of particular value if the businessProcessMessage is encrypted.
  • Care must be taken to avoid inclusion of any PII data inside the metadata parameter.
@tim-mchale tim-mchale added the enhancement New feature or request label Apr 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant