Skip to content

Commit

Permalink
docs(coordinator): update readme section
Browse files Browse the repository at this point in the history
  • Loading branch information
0xmad committed May 27, 2024
1 parent ff3e241 commit dace358
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion circuits/ts/__tests__/PrivToPubKey.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { Keypair, PrivKey, PubKey } from "maci-domainobjs";
import { L } from "./utils/constants";
import { circomkitInstance, getSignal } from "./utils/utils";

describe.only("Public key derivation circuit", function test() {
describe("Public key derivation circuit", function test() {
this.timeout(900000);

let circuit: WitnessTester<["privKey"], ["pubKey"]>;
Expand Down
3 changes: 2 additions & 1 deletion coordinator/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@
1. Add `.env` file (see `.env.example`).
2. Generate RSA key pair with `pnpm run generate-keypair`.
3. Download zkey files using `pnpm run download-zkeys:{type}` (only test type is available for now).
4. Make sure you copied RSA public key to your application. This will be needed for encrypting `Authorization` header and coordinator private key for proof generation.
4. Make sure you copied RSA public key to your application. This will be needed for encrypting `Authorization` header and coordinator private key for proof generation. Also it can be accessed through API method `GET v1/proof/publicKey`.
5. Run `pnpm run start` to run the service.
6. All API calls must be called with `Authorization` header, where the value is encrypted with RSA public key you generated before. Header value contains message signature and message digest created by `COORDINATOR_ADDRESS`. The format is `publicEncrypt({signature}:{digest})`.
Make sure you set `COORDINATOR_ADDRESS` env variable and sign any message with this address from your application (see [AccountSignatureGuard](./ts/auth/AccountSignatureGuard.service.ts)).
7. Proofs can be generated with `POST v1/proof/generate` API method (see [dto spec](./ts/proof/dto.ts) and [controller](./ts/app.controller.ts)).
8. [Swagger documentation for API methods](https://maci-coordinator.pse.dev/api)

0 comments on commit dace358

Please sign in to comment.