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

Identity Rebased alpha tracking hub #1436

Open
wants to merge 79 commits into
base: main
Choose a base branch
from

Conversation

wulfraem
Copy link
Contributor

@wulfraem wulfraem commented Nov 22, 2024

⚠️ DON'T MERGE ⚠️

Okay, after that loud heading, let's clarify, why it shouldn't be merged. :)

This PR is used to track the status of commits and to compare file changes for the updates regarding compatibility with IOTA Rebased networks. It will be merged in the future, but not for now.

About the changes in this PR

At the moment, the project has two main-ish branches in the repository:

The changes previewed here will be applied to main but not until IOTA mainnet has shifted to Rebased protocol. For now this PR is our tracking hub for the upcoming changes.

wulfraem and others added 30 commits May 3, 2024 17:00
- migration registry in move code
- migration registry integration
* add initial resolving for migrated and undmigrated alias did docs

* fix issues after merge conflicts
* test harness & integration tests

* naming, removed unused script

store active-address to check cache invalidation
* add initial resolving for migrated and undmigrated alias did docs

* fix issues after merge conflicts

* add resolving of new documents, resolve documents in parallel

* test harness & integration tests

* naming, removed unused script

* move kinesis did resolval to new project, add tests

* refactor error mapping (apply review suggestion)

* add missing license headers

* fix test document sharing, add missing license header

---------

Co-authored-by: Enrico Marconi <[email protected]>
* add initial resolving for migrated and undmigrated alias did docs

* fix issues after merge conflicts

* add resolving of new documents, resolve documents in parallel

* test harness & integration tests

* naming, removed unused script

* move kinesis did resolval to new project, add tests

* refactor error mapping (apply review suggestion)

* add missing license headers

* fix test document sharing, add missing license header

* disable resolver integration of kinesis crate

* add publishing and tests, error handling still to be done

* add error handling

* refactor `publish_did` fn into smaller helper functions

* remove outdated signing code and tests

* refactor config to make singing arguments optinal when resolving dids

* add did resolving to client

* remove oudated comments

* Update identity_sui_name_tbd/src/client.rs

Co-authored-by: Enrico Marconi <[email protected]>

---------

Co-authored-by: Enrico Marconi <[email protected]>
Co-authored-by: Enrico Marconi <[email protected]>
* multiple controllers, add controller request

* remove controller & factor out common operation for did change requests

* tests

* rename Document to Identity, unwrap assets, verify threshold when presenting request

* update document request

* add Identity::new_with_controller

* transfer control request

* integrate with rust code

* remove stronghold snapshots & print

* enhancement of multi controller proposal inspired by kraken

* chore: add tests

* chore: add migrate alias test

* review comments, proposal's expiration & test

* chore: fix migrate alias test

* chore: fix tests

* chore: address review comments

* Rust glue code

* chore: add non did doc tests

* resolve identities instead of bytes

* on chain identity creation

* update identity did document

* test client

* add (raw) document publishing via signer example

* add support for publishing of new documents, example

* add feature flag for kinesis integration

* add resolve example

* update example folder structure

- split into `iota` and `kinesis` folders (names tbd)

* add non-did-modifying basic examples

* add non-updating, non-chain advanced examples

* bump copyright years in new examples

* update sui/kinesis/iota dependencies

- update dependency on `sui`/`kinesis` components to `iota` (and update names of those components)
- update dependency on `iota-sdk` to `iota-sdk-classic` in tbd project

* add attempt to fix `initial_shared_version` arg

* update examples and resolve to fit structure update after merge

* apply clippy suggestions

* update `secret-storage` dependency to git branch

* fix dependencies in iota (legacy) examples

* fix unwraps and anyhows in client

* update tests to follow integration update

* fix examples after client update

* rename alias `iota-sdk-classic` to `iota-sdk-legacy`

* cleanup dependencies

* add did update example, update argument handling in update impl

* add capability reloading to allow passing it in consecutive tx

* add did deactivation

* add revoke vc example

* update "kinesis" naming:

- `KinesisKeySignature` -> `IotaKeySignature`
- `Error::DIDResolutionErrorKinesis` -> `Error::DIDResolutionError`

---------

Co-authored-by: Enrico Marconi <[email protected]>
Co-authored-by: Yasir <[email protected]>
Co-authored-by: Yasir <[email protected]>
* multiple controllers, add controller request

* remove controller & factor out common operation for did change requests

* tests

* rename Document to Identity, unwrap assets, verify threshold when presenting request

* update document request

* add Identity::new_with_controller

* transfer control request

* integrate with rust code

* remove stronghold snapshots & print

* enhancement of multi controller proposal inspired by kraken

* chore: add tests

* chore: add migrate alias test

* review comments, proposal's expiration & test

* chore: fix migrate alias test

* chore: fix tests

* chore: address review comments

* Rust glue code

* chore: add non did doc tests

* resolve identities instead of bytes

* on chain identity creation

* update identity did document

* test client

* add (raw) document publishing via signer example

* add support for publishing of new documents, example

* add feature flag for kinesis integration

* add resolve example

* update example folder structure

- split into `iota` and `kinesis` folders (names tbd)

* add non-did-modifying basic examples

* add non-updating, non-chain advanced examples

* bump copyright years in new examples

* update sui/kinesis/iota dependencies

- update dependency on `sui`/`kinesis` components to `iota` (and update names of those components)
- update dependency on `iota-sdk` to `iota-sdk-classic` in tbd project

* add attempt to fix `initial_shared_version` arg

* update examples and resolve to fit structure update after merge

* apply clippy suggestions

* update `secret-storage` dependency to git branch

* fix dependencies in iota (legacy) examples

* fix unwraps and anyhows in client

* update tests to follow integration update

* fix examples after client update

* rename alias `iota-sdk-classic` to `iota-sdk-legacy`

* cleanup dependencies

* add did update example, update argument handling in update impl

* add capability reloading to allow passing it in consecutive tx

* add did deactivation

* add revoke vc example

* add history example and impl

* update "kinesis" naming:

- `KinesisKeySignature` -> `IotaKeySignature`
- `Error::DIDResolutionErrorKinesis` -> `Error::DIDResolutionError`

* update error handling

- remove panics
- align ptb.pure and ptb.obj error handling
- align identifier parsing

* remove unwraps in non-test code

* add domain linkage example

* add paging to history example

---------

Co-authored-by: Enrico Marconi <[email protected]>
Co-authored-by: Yasir <[email protected]>
Co-authored-by: Yasir <[email protected]>
* multiple controllers, add controller request

* remove controller & factor out common operation for did change requests

* tests

* rename Document to Identity, unwrap assets, verify threshold when presenting request

* update document request

* add Identity::new_with_controller

* transfer control request

* integrate with rust code

* remove stronghold snapshots & print

* enhancement of multi controller proposal inspired by kraken

* chore: add tests

* chore: add migrate alias test

* review comments, proposal's expiration & test

* chore: fix migrate alias test

* chore: fix tests

* chore: address review comments

* Rust glue code

* chore: add non did doc tests

* resolve identities instead of bytes

* on chain identity creation

* update identity did document

* test client

* update sui/kinesis/iota dependencies

- update dependency on `sui`/`kinesis` components to `iota` (and update names of those components)
- update dependency on `iota-sdk` to `iota-sdk-classic` in tbd project

* add attempt to fix `initial_shared_version` arg

* Feat/authenticated asset

* AuthenticatedAsset & TransferProposal

* use proposal for trasfering AuthenticatedAssets

* authenticated asset creation

* transfer of assets between addresses

* transfer proposal conclusion

* refinement

* update mutable asset

* delete asset

* fix bug, refinement

* approval of proposals

* propose config change glue code

* execute proposal, test config change

* proposal refactor

* fix move tests

* allow chained execution of proposals

* documentation for ProposalResult

* adapt merged code

* export request_funds for examples

* Update examples/iota/Cargo.toml

Co-authored-by: wulfraem <[email protected]>

* Update identity_iota_core/Cargo.toml

Co-authored-by: wulfraem <[email protected]>

* fix logic for propose_modify

---------

Co-authored-by: Yasir <[email protected]>
Co-authored-by: Yasir <[email protected]>
Co-authored-by: Sebastian Wolfram <[email protected]>
* client refactor

* add package_id to client construction

* rename secret_storage's error import

* Update identity_storage/src/storage/storage_signer.rs

Co-authored-by: wulfraem <[email protected]>

* review comments

* Update identity_sui_name_tbd/src/client/read_only.rs

Co-authored-by: wulfraem <[email protected]>

---------

Co-authored-by: wulfraem <[email protected]>
* client refactor

* publish VCs

* add move struct, validate credential in test

* add package_id to client construction

* rename secret_storage's error import

* Update identity_storage/src/storage/storage_signer.rs

Co-authored-by: wulfraem <[email protected]>

* review comments

* clippy & fmt

---------

Co-authored-by: wulfraem <[email protected]>
* identity refactor

* apply new tx design to authenticated assets

* switch to new transaction model

* use max gas budget instead of u64::max

* [feat] Public Available Credential

* client refactor

* publish VCs

* add move struct, validate credential in test

* add package_id to client construction

* rename secret_storage's error import

* Update identity_storage/src/storage/storage_signer.rs

Co-authored-by: wulfraem <[email protected]>

* review comments

* clippy & fmt

---------

Co-authored-by: wulfraem <[email protected]>

* test structure, fix random drop of dispatch task

---------

Co-authored-by: Sebastian Wolfram <[email protected]>
Co-authored-by: Sebastian Wolfram <[email protected]>
- re-add history tests
- remove fixed versions as sequence numbers depend of faucet
- fix `hosting_vc_works` test
feat: Add document creation and identity creation

This commit adds functionality for creating a document and an identity. It includes the following changes:

Refactor grpc imports in server and services modules

Refactor grpc imports in server and services modules; Update deps
fix: update path for identity_sui_name_tbd in examples/Cargo.toml

feat: add linked verifiable presentation example and update dependencies
* feat: add linked verifiable presentation example and update dependencies

* identity send & borrow assets

* TransactionOutput to return both parsed output and raw tx response

* identity send & borrow assets

* identity send & borrow assets

* de-duplicate code in tests

* rename move function

---------

Co-authored-by: Yasir <[email protected]>
itsyaasir and others added 26 commits November 26, 2024 17:24
* chore: update CI

* fmt
* rebase commit

* remove dead code
* update examples and fix wording

* update `identity_iota` dependency in examples
* add package version, identity version and upgrade proposal

* rust implementation of upgrade identity proposal

* commit missing files

* review comments

* fix merge issues & emit events when dealing with upgrade proposals
… on sub-Identities (#1454)

* rebase commit

* borrow controller cap proposal

* e2e test for controller execution

* fix merge issues

* fix merge
* feat: compilation error; clippy fixes and fmt

* chore: temporarily ignore additional RustSec advisory and disable wasm build checks

---------

Co-authored-by: Enrico Marconi <[email protected]>
* fix cargo fmt issues

* fix clippy issues
* re-add openssl dep to gRPC bindings and limit it to `x86_64-unknown-linux-musl` target
* update naming to refer to identities

* fix typos
* debug output

* test

* publish package before running the test harness

* remove 'with' clause in workflow

* publish package without script

* fix typo

* request funds and add dbg statement

* remove faucet call

* debug error

* add output that could not be parsed to error message

* comment out debug log in publishing script

* make sure package id env is set

* update publish package script handling in tests and grpc to follow update

* fix clippy issues

* fix dependencies for doc test

* fix clippy issues

* fix clippy issues

* fix clippy issues

* fix clippy issues

* fix examples from readme

* add action auth token to release check and check response status

* update action token to execution step scoped variant

* add check for parsed download url

* set IOTA binary version to fixed urls

- avoid CI breaking on releases, where binariese have not yet been published

* bump iota dependencies to `v0.7.3-rc`

---------

Co-authored-by: Sebastian Wolfram <[email protected]>
* rename sui module to iota

* fmt
* chore: add identity and delegation tests

* add permission tests

* review comments

---------

Co-authored-by: Yasir <[email protected]>
* fix identity creation lint

* Update identity_iota_core/packages/iota_identity/sources/identity.move

Co-authored-by: wulfraem <[email protected]>

* Update identity_iota_core/packages/iota_identity/sources/identity.move

Co-authored-by: wulfraem <[email protected]>

---------

Co-authored-by: wulfraem <[email protected]>
… address (#1473)

* add support for tests against devnet

- add `API_ENDPOINT` env variable for tests and examples
- add `IOTA_IDENTITY_FUND_WITH_ACTIVE_ADDRESS` env variable to toggle funding via active address

* update inline function documentation

* replace local api endpoint constants

- now using `IOTA_LOCAL_NETWORK_URL` from `iota` create
* fix DID lookup errors due to failing on single lookup error

* apply review suggestions

- make did resolving's future handling less clunky
* Enhance coin retrieval logic in Iota client

- Introduced a constant `MINIMUM_BALANCE` to define the minimum balance required for transactions.
- Updated `get_coin_for_transaction` method to iterate through paginated coin data, selecting the coin with the highest balance that meets the minimum requirement.
- Improved error handling to provide clearer messages when no suitable coins are found.

This change optimizes the process of selecting coins for transactions, ensuring that only coins with sufficient balance are considered.

* chore: remove unecessary comments

* chore: simplify the coin logic

* chore: review comments

* Update identity_iota_core/src/rebased/client/full_client.rs

Co-authored-by: Enrico Marconi <[email protected]>

* Update minimum balance requirement in Iota client

---------

Co-authored-by: Enrico Marconi <[email protected]>
* add field legacy_id to Move Identity + test

* update Rust code

* identity creation requires IotaDocument instead of bytes
* network name is chain id

* add package metadata for devnet

* Update identity_iota_core/src/rebased/iota/well_known_networks.rs

Co-authored-by: wulfraem <[email protected]>

* remove test that uses wrong identity

* add devnet connection test

---------

Co-authored-by: wulfraem <[email protected]>
* fix formatting issue

* fix fmt and clippy issues
* fix dprint issue and add missing license header

* add missing license header
…etworks (#1482)

* fix did test, add optional network alias

* update tests for client connecting to well known networks
@wulfraem wulfraem changed the title Identity rebased alpha Identity Rebased alpha tracking hub Dec 6, 2024
wulfraem and others added 3 commits December 6, 2024 12:25
- run for feat/ targets
- don't run for epic/ targets (unused atm)
* chore: update readme

* Update README.md

Co-authored-by: Eike Haß <[email protected]>

---------

Co-authored-by: Eike Haß <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Breaking change A change to the API that requires a major release. Part of "Changed" section in changelog Rust Related to the core Rust code. Becomes part of the Rust changelog.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants