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

[annotation] Enc annotation is not working correctly for serialization <---> deserialization roundtrip #416

Open
satran004 opened this issue Aug 22, 2024 · 0 comments

Comments

@satran004
Copy link
Member

@Constr
public class Person {
    private String name;

    @Enc("hex")
    private String publicKey;

    private int age;
}

'0x' is missing in the publicKey field of the de-serialized object.

Example:

Person data : Person{name='Alice', publicKey='0x6dcf4915b05a1358d86e87d352f2fa7392fa6c092b337af705b577822d06d17e', age=25}

CBOR Hex : d8799f45416c69636558206dcf4915b05a1358d86e87d352f2fa7392fa6c092b337af705b577822d06d17e1819ff

Deserialized Person object : Person{name='Alice', publicKey='6dcf4915b05a1358d86e87d352f2fa7392fa6c092b337af705b577822d06d17e', age=25}
@satran004 satran004 modified the milestone: 0.6.0-beta2 Sep 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant