Skip to content

Commit db59047

Browse files
authored
#314: configure dev Nuts node with policy, explain NUTS_URL config (#316)
1 parent 42a7398 commit db59047

File tree

3 files changed

+152
-2
lines changed

3 files changed

+152
-2
lines changed

config/nuts.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
1-
url: http://localhost:8080
1+
url: http://localhost:8080/nuts
22

33
didmethods:
44
- web
55
auth:
66
contractvalidators:
7-
- dummy
7+
- dummy
8+
9+
policy:
10+
directory: "/app/config/policy"

config/policy/policy.json

Lines changed: 144 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,144 @@
1+
{
2+
"eOverdracht-sender": {
3+
"organization": {
4+
"format": {
5+
"ldp_vc": {
6+
"proof_type": [
7+
"JsonWebSignature2020"
8+
]
9+
},
10+
"jwt_vc": {
11+
"alg": [
12+
"PS256"
13+
]
14+
},
15+
"jwt_vp": {
16+
"alg": [
17+
"ES256"
18+
]
19+
}
20+
},
21+
"id": "pd_any_care_organization",
22+
"name": "Care organization",
23+
"purpose": "Finding a care organization",
24+
"input_descriptors": [
25+
{
26+
"id": "id_uzicert_uracredential",
27+
"name": "Care organization identity from fake UZI-server certificate",
28+
"purpose": "Finding a care organization for authorizing access to medical metadata.",
29+
"constraints": {
30+
"fields": [
31+
{
32+
"path": ["$.type"],
33+
"filter": {
34+
"type": "string",
35+
"const": "X509Credential"
36+
}
37+
},
38+
{
39+
"id": "organization_id",
40+
"path": ["$.credentialSubject[0].id", "$.credentialSubject.id"],
41+
"filter": {
42+
"type": "string",
43+
"pattern": "^did:web:"
44+
}
45+
},
46+
{
47+
"id": "organization_name",
48+
"path": [
49+
"$.credentialSubject[0].subject.O",
50+
"$.credentialSubject.subject.O"
51+
],
52+
"filter": {
53+
"type": "string"
54+
}
55+
},
56+
{
57+
"id": "organization_ura",
58+
"path": [
59+
"$.credentialSubject[0].san.otherName",
60+
"$.credentialSubject.san.otherName"
61+
],
62+
"filter": {
63+
"type": "string",
64+
"pattern": "^[0-9.]+-\\d+-\\d+-S-(\\d+)-00\\.000-\\d+$"
65+
}
66+
}
67+
]
68+
}
69+
}
70+
]
71+
}
72+
},
73+
"eOverdracht-receiver": {
74+
"organization": {
75+
"format": {
76+
"ldp_vc": {
77+
"proof_type": [
78+
"JsonWebSignature2020"
79+
]
80+
},
81+
"jwt_vc": {
82+
"alg": [
83+
"PS256"
84+
]
85+
},
86+
"jwt_vp": {
87+
"alg": [
88+
"ES256"
89+
]
90+
}
91+
},
92+
"id": "pd_any_care_organization",
93+
"name": "Care organization",
94+
"purpose": "Finding a care organization",
95+
"input_descriptors": [
96+
{
97+
"id": "id_uzicert_uracredential",
98+
"name": "Care organization identity from fake UZI-server certificate",
99+
"purpose": "Finding a care organization for authorizing access to medical metadata.",
100+
"constraints": {
101+
"fields": [
102+
{
103+
"path": ["$.type"],
104+
"filter": {
105+
"type": "string",
106+
"const": "X509Credential"
107+
}
108+
},
109+
{
110+
"id": "organization_id",
111+
"path": ["$.credentialSubject[0].id", "$.credentialSubject.id"],
112+
"filter": {
113+
"type": "string",
114+
"pattern": "^did:web:"
115+
}
116+
},
117+
{
118+
"id": "organization_name",
119+
"path": [
120+
"$.credentialSubject[0].subject.O",
121+
"$.credentialSubject.subject.O"
122+
],
123+
"filter": {
124+
"type": "string"
125+
}
126+
},
127+
{
128+
"id": "organization_ura",
129+
"path": [
130+
"$.credentialSubject[0].san.otherName",
131+
"$.credentialSubject.san.otherName"
132+
],
133+
"filter": {
134+
"type": "string",
135+
"pattern": "^[0-9.]+-\\d+-\\d+-S-(\\d+)-00\\.000-\\d+$"
136+
}
137+
}
138+
]
139+
}
140+
}
141+
]
142+
}
143+
}
144+
}

docs/DEPLOYMENT.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,9 @@ or wants to have the Nuts node deployed separately, the Knooppunt can use that N
106106
107107
Use [`nuts.enabled`](./CONFIGURATION.md) to configure the embedded or existing Nuts node.
108108
109+
Note that you MUST configure the `url` (or `NUTS_URL`) property in the Nuts configuration to point to the **publicly accessible** base URL of the Knooppunt (the URL under which other Nuts nodes and clients can reach it). This is the URL the Nuts node advertises externally.
110+
The Knooppunt runs the embedded Nuts node on `/nuts`, so if the Knooppunt is publicly reachable at `https://knooppunt.example.com/`, the Nuts node URL must be `https://knooppunt.example.com/nuts` (not an internal-only address such as `http://knooppunt:8080/nuts`).
111+
109112
### Tracing
110113
111114
The Knooppunt supports distributed tracing using OpenTelemetry. Traces can be sent to any OTLP-compatible collector (e.g. Jaeger, Grafana Tempo, or a vendor's existing observability platform).

0 commit comments

Comments
 (0)