Skip to content

Commit

Permalink
Add SHA256withRSA-PSS pair. Add SHA384withECDSA pair. Overhaul hashin…
Browse files Browse the repository at this point in the history
…g and signature algorithms determination logic
  • Loading branch information
J3imip committed Nov 28, 2024
1 parent 0cdf321 commit 42a1717
Show file tree
Hide file tree
Showing 46 changed files with 4,600 additions and 1,872 deletions.
16 changes: 1 addition & 15 deletions config.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,3 @@
vault:
address: "http://127.0.0.1:8200"
mount_path: "secret_data"

network:
eth_rpc:
state_contract:

verifier:
verification_keys_paths:
sha1: "./sha1_verification_key.json"
Expand All @@ -16,18 +8,12 @@ verifier:
multi_acc_max_limit: 30
registration_timeout: 1h

issuer:
base_url: "http://localhost:3002/v1"
did: ""
claim_type: "VotingCredential"
credential_schema: "https://bafybeibbniic63etdbcn5rs5ir5bhelym6ogv46afj35keatzhn2eqnioi.ipfs.w3s.link/VotingCredential.json"

log:
level: debug
disable_sentry: true

db:
url: postgres://voting:voting@localhost:35432/voting?sslmode=disable
url: postgres://ilr:ilr@localhost:5432/ilr?sslmode=disable

listener:
addr: :8000
Expand Down
16 changes: 0 additions & 16 deletions docs/spec/components/schemas/Claim.yaml

This file was deleted.

36 changes: 36 additions & 0 deletions docs/spec/components/schemas/DocumentSod.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
allOf:
- $ref: '#/components/schemas/DocumentSodKey'
- type: object
required:
- attributes
properties:
attributes:
type: object
required:
- hash_algorithm
- signature_algorithm
- signed_attributes
- signature
- encapsulated_content
- pem_file
properties:
hash_algorithm:
type: string
description: The hash algorithm used to hash the content
signature_algorithm:
type: string
description: The signature algorithm used to sign the content
signed_attributes:
type: string
description: The signed attributes, for e.g. 104 bytes-long hex string
signature:
type: string
description: Signature corresponding to the algorithm
encapsulated_content:
type: string
description: The encapsulated content, for e.g. 186 bytes-long hex string
pem_file:
type: string
description: The PEM file containing the public key


Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ properties:
type:
type: string
enum:
- gist_datas
- document-sod
16 changes: 0 additions & 16 deletions docs/spec/components/schemas/GistData.yaml

This file was deleted.

29 changes: 0 additions & 29 deletions docs/spec/components/schemas/GistProof.yaml

This file was deleted.

15 changes: 15 additions & 0 deletions docs/spec/components/schemas/VerifySod.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
allOf:
- $ref: '#/components/schemas/VerifySodKey'
- type: object
required:
- attributes
properties:
attributes:
type: object
properties:
dg1:
type: string
example: 7768792064696420796F75206576656E206465636F6465642069743F
description: The data group 1 of the SOD


Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ properties:
type:
type: string
enum:
- claims
- verify-sod
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
post:
tags:
- Identity
summary: The identity creating
operationId: create-identity
- Verify document SOD
summary: Verify document SOD
operationId: verifyDocumentSod
requestBody:
content:
application/json:
Expand All @@ -13,69 +13,7 @@ post:
properties:
data:
type: object
required:
- id
- document_sod
- zkproof
properties:
id:
type: string
document_sod:
type: object
required:
- signed_attributes
- algorithm
- signature
- pem_file
- encapsulated_content
properties:
signed_attributes:
type: string
algorithm:
type: string
signature:
type: string
pem_file:
type: string
encapsulated_content:
type: string
zkproof:
type: object
required:
- proof
- pub_signals
properties:
proof:
type: object
required:
- pi_a
- pi_b
- pi_c
- protocol
- curve
properties:
pi_a:
type: array
items:
type: string
pi_b:
type: array
items:
type: array
items:
type: string
pi_c:
type: array
items:
type: string
protocol:
type: string
curve:
type: string
pub_signals:
type: array
items:
type: string
$ref: '#/components/schemas/DocumentSod'
responses:
'200':
description: Success
Expand All @@ -86,7 +24,7 @@ post:
properties:
data:
type: object
$ref: '#/components/schemas/Claim'
$ref: '#/components/schemas/VerifySod'
'500':
description: Internal Error
content:
Expand Down

This file was deleted.

Loading

0 comments on commit 42a1717

Please sign in to comment.