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

client packages: release stable based on v0.9.20-04 #3109

Merged
merged 4 commits into from
Sep 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion tee-worker/identity/client-api/parachain-api/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

- Update for version [parachain-release v0.9.20-03](https://github.com/litentry/litentry-parachain/releases/tag/v0.9.20-03)
## [0.9.20-4.1] - 2024-09-30

- Update for version [parachain-release v0.9.20-04](https://github.com/litentry/litentry-parachain/releases/tag/v0.9.20-04)

### Added

Expand Down
2 changes: 1 addition & 1 deletion tee-worker/identity/client-api/parachain-api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"main": "dist/src/index.js",
"module": "dist/src/index.js",
"sideEffects": false,
"version": "0.9.20-03-next.0",
"version": "0.9.20-04.1",
"scripts": {
"clean": "rm -rf dist build node_modules",
"update-metadata": "curl -s -H \"Content-Type: application/json\" -d '{\"id\":\"1\", \"jsonrpc\":\"2.0\", \"method\": \"state_getMetadata\", \"params\":[]}' http://localhost:9944 > prepare-build/litentry-parachain-metadata.json",
Expand Down
4 changes: 3 additions & 1 deletion tee-worker/identity/client-api/sidechain-api/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

- Update for version [parachain-release v0.9.20-03](https://github.com/litentry/litentry-parachain/releases/tag/v0.9.20-03)
## [0.9.20-4] - 2024-09-30

- Update for version [parachain-release v0.9.20-04](https://github.com/litentry/litentry-parachain/releases/tag/v0.9.20-04)

## [0.9.19-07] - 2024-08-26

Expand Down
2 changes: 1 addition & 1 deletion tee-worker/identity/client-api/sidechain-api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"main": "dist/src/index.js",
"module": "dist/src/index.js",
"sideEffects": false,
"version": "0.9.20-03-next.0",
"version": "0.9.20-04",
"scripts": {
"clean": "rm -rf dist build node_modules",
"update-metadata": "../../bin/litentry-cli print-sgx-metadata-raw > prepare-build/litentry-sidechain-metadata.json",
Expand Down
201 changes: 3 additions & 198 deletions tee-worker/identity/client-sdk/packages/enclave/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,71 +7,26 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

<<<<<<< HEAD
=======
## [4.3.0] - 2024-09-30

### Changed

- Use `@litentry/[email protected]03.next.0` and `@litentry/[email protected]03.next.0`
- Use `@litentry/[email protected]4.1` and `@litentry/[email protected]4`

### Added

- Support for `Email` Identity

>>>>>>> dev
## [4.2.0] - 2024-08-26

### Changed

<<<<<<< HEAD
- Use `@litentry/[email protected]`
=======
- Use `@litentry/[email protected]`
>>>>>>> dev

## [4.1.0] - 2024-08-06

### Added

<<<<<<< HEAD
- Trusted call requests: add the `request.linkIdentityCallback` method.

### Changed

- Use `@litentry/[email protected]`
- `createLitentryIdentityType`: type can now be created by passing a raw value in hex or `Uint8Array`
- `request.requestBatchVc` now support and optional `signer`.

## [4.0.1] - 2024-07-19

- Use `@litentry/[email protected]` and `@litentry/[email protected]` stable versions.

## [4.0.0] - 2024-07-15

- Migrate to `@litentry/parachain-api` and `@litentry/sidechain-api`.
- Distribute as ES Module
- Targets [parachain-release v0.9.18-10](https://github.com/litentry/litentry-parachain/releases/tag/v0.9.18-10)

## Added

- Export the type `IdGraph` and its type's struct name under `ID_GRAPH_STRUCT`.
- Challenge code now produces a prettified string for utf-8 signing for web3 identities when `options.prettify` is set to `true`.

## Changed

- Migrate to `@litentry/parachain-api` and `@litentry/sidechain-api` por chain types. Deprecates `@litentry/chain-types`.
- Support the new `RequestVcResultOrError` type definition.
- `KeyAesOutput` was renamed to `AesOutput`.
- renamed `global` to `globalThis`
- This library is now distributed as an ESModule

## Removed

- Drop `@litentry/chain-types` from dependencies.

### Fixed

- `request.getIdGraphHash` no longer throws when the user's id_graph is empty.
=======
- Trusted call requests: add the `request.linkIdentityCallback` method.

### Changed
Expand Down Expand Up @@ -110,95 +65,29 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Fixed

- `request.getIdGraphHash` no longer throws when the user's id_graph is empty.
>>>>>>> dev

## [3.2.1] - 2024-06-10

### Added

<<<<<<< HEAD
- Adds a new dependency: `@litentry/chaindata`.
=======
- Adds a new dependency: `@litentry/chaindata`.
>>>>>>> dev

## [3.1.2] - 2024-06-08

### Fixed

<<<<<<< HEAD
- Skip `StfError` validation for verifiable credentials requests. Rely on `RequestVcResultOrError` codec.
=======
- Skip `StfError` validation for verifiable credentials requests. Rely on `RequestVcResultOrError` codec.
>>>>>>> dev

## [3.1.1] - 2024-06-07

### Fixed

<<<<<<< HEAD
- Fix error decoding for single assertions request in `request.requestBatchVc`.
=======
- Fix error decoding for single assertions request in `request.requestBatchVc`.
>>>>>>> dev

## [3.1.0] - 2024-06-03

### Changed

<<<<<<< HEAD
- Upgrade `@polkadot/api*`, `@polkadot/rpc*`, `@polkadot/types*` to 10.9.1, and `@polkadot/util*` to `12.5.1`

### Removed

- Drop unused `@polkadot/keyring` dependency.

## [3.0.0] - 2024-06-03

- Introduce oAuth2 proofs support for Web2 identity validation

### Added

- Config: support `litentry-staging` for the env var `[NX_]PARACHAIN_NETWORK`.
- Config: support the new env var `[NX_]LITENTRY_NETWORK` for setting the network same as `[NX_]PARACHAIN_NETWORK` but higher precedence.
- Config: accept custom WS endpoints on `[NX_]LITENTRY_NETWORK` / `[NX_]PARACHAIN_NETWORK`.

### Changed

- Use `@litentry/[email protected]`
- The type creator `createLitentryValidationDataType` now accepts building oAuth2 proofs for Discord and Twitter.

```ts
// twitter
const twitterOAuth2Proof = createLitentryValidationDataType(
registry,
{
addressOrHandle: 'my_twitter_handle',
type: 'Twitter',
},
{
code: 'my_twitter_code',
state: 'my_twitter_state',
redirectUri: 'http://test-redirect-uri',
}
);

// Discord
const validationData = createLitentryValidationDataType(
registry,
{
addressOrHandle: 'my_discord_handle',
type: 'Discord',
},
{
code: 'my_discord_code',
redirectUri: 'http://test-redirect-uri',
}
);
```

The legacy public message proofs are still supported.
=======
- Upgrade `@polkadot/api*`, `@polkadot/rpc*`, `@polkadot/types*` to 10.9.1, and `@polkadot/util*` to `12.5.1`

### Removed
Expand Down Expand Up @@ -250,42 +139,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
```

The legacy public message proofs are still supported.
>>>>>>> dev

## [2.0.1] - 2024-05-21

### Changed

<<<<<<< HEAD
- When no `PARACHAIN_NETWORK` or `NX_PARACHAIN_NETWORK` is specified, the library will default to the production (`tee-prod`) endpoint rather than to development (`tee-dev`).
=======
- When no `PARACHAIN_NETWORK` or `NX_PARACHAIN_NETWORK` is specified, the library will default to the production (`tee-prod`) endpoint rather than to development (`tee-dev`).
>>>>>>> dev

## [2.0.0] - 2024-05-17

### Removed

<<<<<<< HEAD
- `createLitentryIdentityType` dropped the support deriving the identity type from the provided address. Now both `addressOrHandle` and `type` are required.

```ts
import { createLitentryIdentityType } from '@litentry/enclave';

// from
createLitentryIdentityType(registry, {
address: '5DNx1Kgis2u2SQq7EJrBdnV49PoZCxV3NqER4vV5VqjqZcat',
});

// To
createLitentryIdentityType(registry, {
addressOrHandle: '5DNx1Kgis2u2SQq7EJrBdnV49PoZCxV3NqER4vV5VqjqZcat',
type: 'Substrate',
});
```

consequently, the following methods require a `LitentryIdentity` for the `who` parameter instead of a plain address string: `request.getIdGraph`, `request.linkIdentity`, `request.requestBatchVc`, `request.setIdentityNetworks`, and `request.createChallengeCode`.
=======
- `createLitentryIdentityType` dropped the support deriving the identity type from the provided address. Now both `addressOrHandle` and `type` are required.

```ts
Expand All @@ -304,7 +168,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
```

consequently, the following methods require a `LitentryIdentity` for the `who` parameter instead of a plain address string: `request.getIdGraph`, `request.linkIdentity`, `request.requestBatchVc`, `request.setIdentityNetworks`, and `request.createChallengeCode`.
>>>>>>> dev

## [1.0.4] - 2024-05-16

Expand All @@ -314,53 +177,20 @@ Routinely update

### Changed

<<<<<<< HEAD
- `@litentry/enclave` add support for Solana hex-encoded signatures. It hex string is not provided, it will default to base58 decoding.
=======
- `@litentry/enclave` add support for Solana hex-encoded signatures. It hex string is not provided, it will default to base58 decoding.
>>>>>>> dev

## [1.0.2] - 2024-05-14

### Changed

<<<<<<< HEAD
- `@litentry/chain-types` is now marked as a peerDependency
=======
- `@litentry/chain-types` is now marked as a peerDependency
>>>>>>> dev

## [1.0.1] - 2024-05-08

Routinely update

## [1.0.0] - 2024-04-24

<<<<<<< HEAD
- Initial public version

### Added

- Request methods that mutate the idGraph information will have a common response. The entire idGraph will no longer be returned but the information about the updated identity only.
- `request.getIdGraphHash` Request getter to get idGraph hash with no signature.
- `calculateIdGraphHash`: Helper method to calculate the hash of a given local idGraph.
- `request.requestBatchVC`: Request trusted call to request a batch of VCs.
- `Enclave.send` now supports a third argument to subscribe to the WS streamed responses.
- Payload signature is now beautify by default to look more human.
- Use a different key for encrypting the transmitted package to the Enclave.

### Removed

- `request.requestVc`. Superseded by `request.requestBatchVc`.
- `createEnclaveHttpProxyHandler`. The connection to the Enclave is now done directly via WebSockets.

### Changed

- Migrate from `teerex` to `teebag`.
- Enclave's nonce is now retrieved through the `author_getNextNonce` getter call.
- The connection to the Enclave is now done directly via WebSockets. Setting up an HTTP proxy is no longer necessary nor suggested.
- The payload size of all operations was reduced and fixed to a 32-bytes length.
=======
- Initial public version

### Added
Expand All @@ -384,37 +214,13 @@ Routinely update
- Enclave's nonce is now retrieved through the `author_getNextNonce` getter call.
- The connection to the Enclave is now done directly via WebSockets. Setting up an HTTP proxy is no longer necessary nor suggested.
- The payload size of all operations was reduced and fixed to a 32-bytes length.
>>>>>>> dev

## 2023-12-05

Update to `Litentry-parachain p0.9.17-9170-w0.0.1-100`.

### Added

<<<<<<< HEAD
- `request.getIdGraph`: fetch the user's idGraph from the Enclave Sidechain. It requires user signature.

### Changed

- **Shielding key**: Users no longer need to set a shielding key on-chain. The data for network transportation is now protected by ephemeral shielding keys generated on the fly. Ephemeral shielding keys increase security and enhance the user experience.
- **Direct responses**: Operation responses are no longer gathered from the Parachain but from the Enclave itself.
- `request.linkIdentity`: The method now has a two level encryption: the information is encrypted with a different key that the one used for transportation.
- `request.linkIdentity`: The call argument `data.encryptionNonce` was removed.
- `request.linkIdentity`: The returned `send` callback now returns both the idGraph and the parsed sidechain response in a `WorkerRpcReturnValue` type.
- `request.createChallengeCode`: The call argument `args.shield` was removed. The Challenge code no longer needs encrypted information.
- `request.setIdentityNetworks`: The returned `send` callback now returns the transaction hash `txHash` and the parsed sidechain response in a `WorkerRpcReturnValue` type.
- `request.requestVc`: The returned `send` callback now returns the `vcIndex`, `vcHash` and the VC's contents on `vcPayload`. As well as the parsed sidechain response in a `WorkerRpcReturnValue` type.
- `enclave.getNonce` was moved as a requestor: `request.getEnclaveNonce`.
- `KeyAesOutput` type is no longer part of the Parachain-runtime metadata and thus it can't be found on `@polkadot/types/lookup`. Use `KeyAesOutput` instead from `@litentry/chain-types`
- `enclave.send`: Error thrown during Enclave operations include more information now.
- `createEnclaveHttpProxyHandler`: HTTP errors responses are now only returned if reaching the Enclave or processing the request fails. However, `enclave.send` could still throw an execution error if the intrinsic operation contains errors. For instance, linking an already linked identity will result on a 200 HTTP response from the Enclave's proxy but `enclave.send` will throw an error about `IdentityAlreadyLinked`.

### Removed

- `request.setUserShieldingKey`: It is no longer needed to set the user's shielding key on-chain. See the Shielding Key point on the Changed section for more information.
- `ky-universal` dependency was dropped.
=======
- `request.getIdGraph`: fetch the user's idGraph from the Enclave Sidechain. It requires user signature.

### Changed
Expand All @@ -436,7 +242,6 @@ Update to `Litentry-parachain p0.9.17-9170-w0.0.1-100`.

- `request.setUserShieldingKey`: It is no longer needed to set the user's shielding key on-chain. See the Shielding Key point on the Changed section for more information.
- `ky-universal` dependency was dropped.
>>>>>>> dev

## 2023-11-01

Expand Down
6 changes: 3 additions & 3 deletions tee-worker/identity/client-sdk/packages/enclave/package.json
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
{
"name": "@litentry/enclave",
"description": "This package provides helpers for dApps to interact with the Litentry Protocol Enclave.",
"version": "4.2.0-next.0",
"version": "4.3.0",
"license": "GPL-3.0-or-later",
"dependencies": {},
"devDependencies": {
"@polkadot/rpc-provider": "^10.9.1"
},
"peerDependencies": {
"@litentry/parachain-api": "0.9.20-03-next.0",
"@litentry/sidechain-api": "0.9.20-03-next.0",
"@litentry/parachain-api": "0.9.20-4.1",
"@litentry/sidechain-api": "0.9.20-4",
"@litentry/chaindata": "*",
"@polkadot/api": "^10.9.1",
"@polkadot/types": "^10.9.1",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import {
import { identity, trusted_operations } from '@litentry/parachain-api';

import { createLitentryValidationDataType } from './validation-data';
import { createLitentryIdentityType } from './litentry-identity';

const types = {
...identity.types, // LitentryIdentity is defined here
Expand Down
Loading