DID 学习日记 - PolygonID - GetProofs
https://github.com/0xPolygonID/polygonid-flutter-sdk

需要注意的是, 这里生成的 ZKProof 并没有包含 Holder 的身份证明,只是对 VC 的真实性(claims 是否被篡改,是否来自指定的 issuer,是否颁布给对应的 holder)进行了证明。
所以建议是将 Holder 的身份证明 ZKProof 生成后,和这里的 VP(claims+zkproof)一起打包为 JWZ 格式。
Iden3 协议里的 Message 格式为
@JsonSerializable()
class AuthResponseDTO extends Equatable {
final String? id;
final String? typ;
final String? type;
final String? thid;
final AuthBodyResponseDTO? body;
final String? from;
final String? to;
AuthResponseDTO(
{this.id, this.typ, this.type, this.thid, this.body, this.from, this.to});
factory AuthResponseDTO.fromJson(Map<String, dynamic> json) =>
_$AuthResponseDTOFromJson(json);
Map<String, dynamic> toJson() => _$AuthResponseDTOToJson(this);
@override
List<Object?> get props => [id, typ, type, thid, body, from, to];
}