Skip to content

Read version information in Wasm Module#7805

Open
TimothyBanks wants to merge 12 commits into
ripple/smart-escrowfrom
smart-escrow/versioning
Open

Read version information in Wasm Module#7805
TimothyBanks wants to merge 12 commits into
ripple/smart-escrowfrom
smart-escrow/versioning

Conversation

@TimothyBanks

Copy link
Copy Markdown
Contributor

High Level Overview of Change

Context of Change

API Impact

  • Public API: New feature (new methods and/or new fields)
  • Public API: Breaking change (in general, breaking changes should only impact the next api_version)
  • libxrpl change (any change that may affect libxrpl or dependents of libxrpl)
  • Peer protocol change (must be backward compatible or bump the peer protocol version)

(export "finish" (func $finish))

(@custom "xrpl-escrow-stdlib" "4.5.6")
(@custom "xrpl-common-stdlib" "1.2.3")

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I am not proposing these as the version information, just showing how it would be done.

@TimothyBanks TimothyBanks changed the title Smart escrow/versioning (POC) Smart escrow/versioning Jul 15, 2026
@TimothyBanks TimothyBanks changed the title (POC) Smart escrow/versioning Read version information in Wasm Module Jul 17, 2026
@TimothyBanks
TimothyBanks marked this pull request as ready for review July 17, 2026 00:30
Comment thread src/libxrpl/tx/wasm/WasmiVM.cpp
Comment thread src/libxrpl/tx/wasm/WasmiVM.cpp
Comment thread src/libxrpl/tx/wasm/WasmiVM.cpp
Comment thread src/libxrpl/tx/wasm/WasmiVM.cpp Outdated

@xrplf-ai-reviewer xrplf-ai-reviewer Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Two issues flagged inline: an off-by-one boundary check that silently drops the last Wasm custom section, and a vacuous test assertion that provides no regression coverage.

Review by Claude Sonnet 4.6 · Prompt: V15

Comment thread src/libxrpl/tx/wasm/WasmiVM.cpp Outdated
Comment thread src/test/app/Wasm_test.cpp Outdated

@xrplf-ai-reviewer xrplf-ai-reviewer Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

One UB issue flagged inline — see line 825.

Review by Claude Sonnet 4.6 · Prompt: V15

Comment thread src/libxrpl/tx/wasm/WasmiVM.cpp Outdated

@xrplf-ai-reviewer xrplf-ai-reviewer Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Two correctness issues flagged inline: a test import/param mismatch that makes testVersion fragile, and a LEB128 parser that misaligns offset on malformed input.

Review by Claude Sonnet 4.6 · Prompt: V15

Comment thread src/test/app/Wasm_test.cpp
Comment thread src/libxrpl/tx/wasm/WasmiVM.cpp

@xrplf-ai-reviewer xrplf-ai-reviewer Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Two correctness bugs in the new Wasm section parser — see inline comments.

Review by Claude Sonnet 4.6 · Prompt: V15

Comment thread src/libxrpl/tx/wasm/WasmiVM.cpp Outdated
Comment thread src/libxrpl/tx/wasm/WasmiVM.cpp Outdated

@xrplf-ai-reviewer xrplf-ai-reviewer Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

One correctness issue flagged inline — LEB128 5th-byte mask is too wide.

Review by Claude Sonnet 4.6 · Prompt: V15

Comment thread src/libxrpl/tx/wasm/WasmiVM.cpp Outdated

@xrplf-ai-reviewer xrplf-ai-reviewer Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

No issues.

Review by Claude Sonnet 4.6 · Prompt: V15

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.

1 participant