From 426a9217ebc654b3b6f9a419c94fddd4fcd7b3ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A5vard=20Solberg=20Nyb=C3=B8e?= <40893697+havardnyboe@users.noreply.github.com> Date: Mon, 14 Aug 2023 12:49:40 +0200 Subject: [PATCH 1/2] Update README.md --- README.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 1409922..815cd6e 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,7 @@ # summer-camp-2023 -Backlog for sommercamp 2023 + +This is a monorepo for the technical components for the DigDir summercamp 2023. + +For instructions on how to use the different components see: +- [Backend](./backend) +- [Wallet](./wallet) From 97867c698449a045dd8a8e2c8be370d80bffd85e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A5vard=20Solberg=20Nyb=C3=B8e?= <40893697+havardnyboe@users.noreply.github.com> Date: Mon, 14 Aug 2023 12:54:16 +0200 Subject: [PATCH 2/2] Update README.md Updated formating and code blocks --- backend/README.md | 41 +++++++++++++++++++---------------------- 1 file changed, 19 insertions(+), 22 deletions(-) diff --git a/backend/README.md b/backend/README.md index 0c01a5a..30b2808 100644 --- a/backend/README.md +++ b/backend/README.md @@ -1,40 +1,39 @@ -

Backend for Summerproject 2023

+# Backend for Summerproject 2023 ![Structure](./Resources/Flow.png) -

Installing

+## Installing Clone the repository - ```sh -$ cd .\summer-camp-2023\backend +cd .\summer-camp-2023\backend ``` -install nescecary deppendencies: +Install the nescecary deppendencies: ```sh -$ npm i +npm install ``` -compile: +Compile the project: ```sh -$ npx hardhat compile +npx hardhat compile ``` -start the blockchain local instance: +Start the blockchain local instance: ``` -$ npx hardhat node +npx hardhat node ``` Deploy the smart contracts: ```sh -$ npx hardhat run --network localhost scripts/deploy.js +npx hardhat run --network localhost scripts/deploy.js ``` Start the server: ```sh -$ node scripts/server/index.js +node scripts/server/index.js ``` -

The Blockchain

+## The Blockchain In this repository are the smart contracts based on EIP-712 and EIP-1812 for Structured Data Types and Verifiable Claims respectively, to perform the registration and verification process of Verifiable Credentials on-chain. -

Structure

+### Structure ![Structure](./Resources/structure-backend.png) @@ -42,7 +41,7 @@ In this repository are the smart contracts based on EIP-712 and EIP-1812 for Str The main objective is to have a credential registry for creating Liquor liscence and knowledge test verifiable credentials. There is the CredentialRegistry whose function is to maintain the main registry. However, it is not intended to interact directly with applications. That is why there is a contract that serves as a middleman to be able to register each type of credential, this contract is called ClaimsVerifier, and it is in charge of both registering credential hashes and verifying them by making internal calls to the CredentialRegistry. -

Contracts:

+### Contracts * __CredentialRegistry:__ Master credential registry @@ -54,7 +53,7 @@ That is why there is a contract that serves as a middleman to be able to registe * __ICredentialRegistry:__ Interface that defines the main methods of a CredentialRegistry, as well as the metadata of each credential. -

Security roles

+### Security roles The contracts make use of the OpenZeppelin Access Control System, for which two roles have been defined: @@ -66,13 +65,11 @@ The ISSUER_ROLE should be assigned to any account that is going to register a cr The SIGNER_ROLE should be assigned to any account that is going to sign a credential within the ClaimsVerifier contract. -

Pre-requisites

- -NodeJS > 12.4 - -Etehrs @ 5.7.2 +### Pre-requisites -OpenZeppelin Contracts @ 3.0.0 +- NodeJS > 12.4 +- Etehrs @ 5.7.2 +- OpenZeppelin Contracts @ 3.0.0