Looks like the sdk internally expects an utf-8 string despite the respective parameter being called messageHex. Could you please adjust the docstring/parameter name to match reality and avoid confusion?
|
* @param path - The derivation path for the private key used to sign the message. |
|
* @param messageHex - A hexadecimal string that represents the message to be signed. |
|
* @return A Promise that resolves to an object with properties: |
|
* - r: A string representing the "r" value of the signature. |
|
* - s: A string representing the "s" value of the signature. |
|
* - v: A string representing the "v" value of the signature. |
|
*/ |
|
async signPersonalMessage(path: string, messageHex: string): Promise<{ r: string, s: string, v: string }> { |
|
const messageBuffer = Buffer.from(messageHex, 'utf-8'); |
|
return this.sign(path, messageBuffer, DataType.personalMessage); |
|
} |
Looks like the sdk internally expects an
utf-8string despite the respective parameter being calledmessageHex. Could you please adjust the docstring/parameter name to match reality and avoid confusion?keystone-sdk-usb/packages/hw-app-eth/src/new.ts
Lines 170 to 180 in 1dd504a