Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
12 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
[Initialization of library](./intialization.md) requires several properties of [signer](../api/classes/modules_signer.SignerService.md): | ||
|
||
- The signer meets [EIP-191: Signed Data Standard](https://eips.ethereum.org/EIPS/eip-191) | ||
- Public key. This is legacy parameter, which was used to initialized DID document | ||
|
||
These properties are not directly exposed by all signers, such as Metamask, and thus are determined in runtime by sending test sign request. | ||
In order to improve user expirience when library is used in browser it tries to get these parameters from local storage. | ||
In order to implement application specific session management the library doesn't modify storage and relies on the application to set `isEthSigner` and `PublicKey` local storage variables on login. | ||
For example to disable session application will not set properties. | ||
If properties are not in local storage then signer initialization will be completed on login to ssi-hub. | ||
Initialization is postponed in order to prevent double signing when user is not logged in ssi-hub. |
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