Skip to content

Support OpenID4VP multi-signed request in Rust matcher#45

Open
QZHelen wants to merge 1 commit into
mainfrom
multisigned-rust-matcher
Open

Support OpenID4VP multi-signed request in Rust matcher#45
QZHelen wants to merge 1 commit into
mainfrom
multisigned-rust-matcher

Conversation

@QZHelen

@QZHelen QZHelen commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

No description provided.

@QZHelen
QZHelen requested a review from netheril96 July 7, 2026 03:54
pub dcql_query: Option<DcqlQuery>,
pub offer: Option<JsonValue>,
pub transaction_data: Vec<String>,
pub request: String,

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd like to avoid using JsonValue as much as possible. It removes the clarity and guardrails provided by static typing.

We should make request an enum of either a string or a struct with the right fields, and implement a custom DeJson for it, just like how ProtocolRequestData is done.

In addition, the payload field seems to be a mistake. Judging from the test data, it is a subfield of request instead.

@QZHelen
QZHelen force-pushed the multisigned-rust-matcher branch from 10fefde to 090ffde Compare July 17, 2026 05:29
}

#[derive(Debug, Clone)]
pub enum OpenId4VpRequestData {

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This struct is only for signed requests, right? Let's add "signed" to the name so it is clear to readers that unsigned requests have no use for this struct.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was referring to it as a struct, but it is actually an enum. Sorry for the mistake. The naming comment still stands.


#[derive(DeJson, Debug, Clone, Default)]
#[nserde(default)]
pub struct OpenId4VpRequestObject {

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similarly, if this is only valid in the context multisigned, we should add multisigned to its name. If this struct is valid for both single-signed and multi-signed cases, we should add signed to its name instead.

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

Successfully merging this pull request may close these issues.

2 participants