forked from Concordium/concordium-ledger-app
-
Notifications
You must be signed in to change notification settings - Fork 0
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
Feat/LDG-537--nano-app-implement-initialize-method #40
Merged
n4l5u0r
merged 8 commits into
main
from
feat/LDG-537--nano-app-implement-initialize-method
Dec 11, 2024
Merged
Feat/LDG-537--nano-app-implement-initialize-method #40
n4l5u0r
merged 8 commits into
main
from
feat/LDG-537--nano-app-implement-initialize-method
Dec 11, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- Add new instruction INS_INIT_CONTRACT (0x07) for contract initialization - Create initContract.c/.h files with handler implementation - Add UI flow for displaying contract amount and module reference - Add new error codes for name/params length and module ref validation - Implement chunked processing for contract name and parameters - Add Python test client support for init contract instruction - Add test case with snapshots for contract initialization flow - Update handler.c and globals.h to support new instruction The implementation allows users to initialize contracts by providing the amount, module reference, contract name, and parameters, with appropriate UI confirmation steps and chunked data processing for larger inputs.
GuilaneDen
reviewed
Dec 11, 2024
- Increase amountDisplay buffer from 21 to 30 chars in initContract.h - Update test to use max uint64 value (0xFFFFFFFFFFFFFFFF) - Update test signature to match new amount value - Update snapshot images to reflect larger amount display Fixes buffer overflow issue when displaying large contract amounts by increasing the display buffer size to accommodate maximum uint64 values.
- Subtract data length from MAX_APDU_LEN when splitting messages - Fix chunk size calculation in deployModule and initContract - Update split_message calls to account for header bytes - Ensure first chunk (len + data) stays within MAX_APDU_LEN limit Fixes APDU length overflow where first chunk (2 bytes length + data) exceeded MAX_APDU_LEN by not accounting for the length bytes in the available space calculation.
- Generate golden snapshots
n4l5u0r
approved these changes
Dec 11, 2024
n4l5u0r
deleted the
feat/LDG-537--nano-app-implement-initialize-method
branch
December 11, 2024 15:40
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The implementation allows users to initialize contracts by providing the
amount, module reference, contract name, and parameters, with appropriate
UI confirmation steps and chunked data processing for larger inputs.