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

FEATURE: CIP30 data sign doesn't support generating hashed content #447

Open
matiwinnetou opened this issue Sep 29, 2024 · 3 comments
Open
Labels
enhancement New feature or request

Comments

@matiwinnetou
Copy link
Collaborator

Hardware wallets, e.g. ledger typically will only return message as a blake224 hash. If this is the case they typically add: hashed: TRUE in the unprotected header section.

Please add support for ability to sign hashed content to the java class.

Typically I would expect a new overloaded method where I can sing the payload and the signature will be using blake2b224.

@matiwinnetou matiwinnetou added the enhancement New feature or request label Sep 29, 2024
@matiwinnetou
Copy link
Collaborator Author

matiwinnetou commented Sep 29, 2024

Example:

payload (text):
{"action":"LOGIN","actionText":"Login","data":{"event":"CARDANO_SUMMIT_AWARDS_2024","network":"MAIN","role":"VOTER","walletId":"stake1uypayp2nyzy66tmcz6yjuth59pym0df83rjpk0758fhqrncq8vcdz","walletType":"CARDANO"},"slot":"136068943"}

signature: 84582aa201276761646472657373581de103d205532089ad2f7816892e2ef42849b7b52788e41b3fd43a6e01cfa166686173686564f5581c1c1afc33a1ed48205eadcbbda2fc8e61442af2e04673616f21b7d0385840954858f672e9ca51975655452d79a8f106011e9535a2ebfb909f7bbcce5d10d246ae62df2da3a7790edd8f93723cbdfdffc5341d08135b1a40e7a998e8b2ed06

key: a4010103272006215820c13745be35c2dfc3fa9523140030dda5b5346634e405662b1aae5c61389c55b3

payload (hex): 7b22616374696f6e223a224c4f47494e222c22616374696f6e54657874223a224c6f67696e222c2264617461223a7b226576656e74223a2243415244414e4f5f53554d4d49545f4157415244535f32303234222c226e6574776f726b223a224d41494e222c22726f6c65223a22564f544552222c2277616c6c65744964223a227374616b6531757970617970326e797a793636746d637a36796a757468353970796d3064663833726a706b30373538666871726e6371387663647a222c2277616c6c657454797065223a2243415244414e4f227d2c22736c6f74223a22313336303638393432227d


@matiwinnetou
Copy link
Collaborator Author

image

@satran004
Copy link
Member

Thanks @matiwinnetou . We will look into it.

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

2 participants