Skip to content

Commit da76ed4

Browse files
authored
Merge pull request #130 from Fraunhofer-AISEC/fix/est-fixes
EST fixes and examples overhaul
2 parents 889c65b + 737d855 commit da76ed4

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+226
-681
lines changed

Dockerfile

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,8 @@ WORKDIR "/root"
2323
# Ports to expose
2424
EXPOSE 8080 29292
2525
ENTRYPOINT ["java"]
26-
CMD ["--class-path", "./jars/*", "de.fhg.aisec.ids.TrustedConnector"]
26+
CMD ["--add-exports=java.base/sun.security.x509=ALL-UNNAMED", \
27+
"--add-exports=java.base/sun.security.pkcs=ALL-UNNAMED", \
28+
"--add-exports=java.base/sun.security.pkcs10=ALL-UNNAMED", \
29+
"--class-path", "./jars/*", "de.fhg.aisec.ids.TrustedConnector", \
30+
"--spring.config.location=classpath:application.yml,optional:/root/etc/application.yml"]
Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,6 @@
1-
logging:
2-
level:
3-
root: info
1+
#logging:
2+
# level:
43
# de.fhg.aisec: debug
5-
# Use for IDSCP2 debugging
6-
# de.fhg.aisec.ids.idscp2: trace
7-
# de.fhg.aisec.ids.camel.idscp2: trace
8-
9-
spring:
10-
web:
11-
resources:
12-
static-locations: classpath:/www/
134

145
ids-multipart:
156
daps-bean-name: rootDaps
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
0 Bytes
Binary file not shown.
0 Bytes
Binary file not shown.
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
server.keyStorePassword=password
2-
server.keyStoreResource=etc/consumer-keystore.p12
2+
server.keyStoreResource=etc/server-keystore.p12
33
client.keyStorePassword=password
4-
client.keyStoreResource=etc/provider-keystore.p12
4+
client.keyStoreResource=etc/client-keystore.p12
55
trustStorePassword=password
66
trustStoreResource=etc/truststore.p12
-1.11 KB
Binary file not shown.

examples/src/main/resources/example-getting-started/compose.yaml

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,27 @@
11
version: '3'
22
services:
33

4-
ids-core:
4+
tc-core:
55
image: fraunhoferaisec/trusted-connector-core:${EXAMPLE_TAG:-develop}
66
tty: true
77
stdin_open: true
8-
command: [ "--class-path", "./jars/*", "de.fhg.aisec.ids.TrustedConnector",
9-
"--spring.config.location=/root/etc/application.yml" ]
108
volumes:
119
- /var/run/docker.sock:/var/run/docker.sock
1210
- ../etc/application.yml:/root/etc/application.yml
1311
- ../deploy/allow-all-flows.pl:/root/deploy/allow-all-flows.pl
1412
- ../etc/settings.mapdb:/root/etc/settings.mapdb
15-
- ../etc/consumer-keystore.p12:/root/etc/consumer-keystore.p12
16-
- ../etc/provider-keystore.p12:/root/etc/provider-keystore.p12
13+
- ../etc/server-keystore.p12:/root/etc/server-keystore.p12
14+
- ../etc/client-keystore.p12:/root/etc/client-keystore.p12
1715
- ../etc/truststore.p12:/root/etc/truststore.p12
1816
- ../etc/tls.properties:/root/etc/tls.properties
1917
- ./example-idscp2-localloop.xml:/root/deploy/example-idscp2-localloop.xml
2018
ports:
2119
- "8080:8080"
22-
environment:
23-
TC_DAPS_URL: "https://daps-dev.aisec.fraunhofer.de/v4"
2420
networks:
2521
example-internal:
2622
aliases:
27-
- consumer-core
28-
- provider-core
23+
- tc-core-server
24+
- tc-core-client
2925

3026
networks:
3127
example-internal:

examples/src/main/resources/example-getting-started/example-idscp2-localloop.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@
5252
<simple>Message at $simple{date:now:yyyy-MM-dd HH:mm:ss}</simple>
5353
</setBody>
5454
<log message="Sending message body &quot;${body}&quot;..."/>
55-
<to uri="idscp2client://consumer-core:9292/?sslContextParameters=#clientSslContext" />
55+
<to uri="idscp2client://tc-core-server:9292/?sslContextParameters=#clientSslContext" />
5656
</route>
5757

5858
<route id="receiveTime">

examples/src/main/resources/example-ids-multipart-uc/compose.yaml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,16 @@
11
version: '3'
22
services:
33

4-
consumer-core:
4+
tc-core-server:
55
image: fraunhoferaisec/trusted-connector-core:${EXAMPLE_TAG:-develop}
66
tty: true
77
stdin_open: true
8-
command: [ "--class-path", "./jars/*", "de.fhg.aisec.ids.TrustedConnector",
9-
"--spring.config.location=/root/etc/application.yml" ]
108
volumes:
119
- /var/run/docker.sock:/var/run/docker.sock
1210
- ../etc/application.yml:/root/etc/application.yml
1311
- ../deploy/allow-all-flows.pl:/root/deploy/allow-all-flows.pl
1412
- ../etc/settings.mapdb:/root/etc/settings.mapdb
15-
- ../etc/consumer-keystore.p12:/root/etc/keystore.p12
13+
- ../etc/server-keystore.p12:/root/etc/keystore.p12
1614
- ../etc/truststore.p12:/root/etc/truststore.p12
1715
- ./example-multipart-uc-server.xml:/root/deploy/example-multipart-uc-server.xml
1816
- ./make-contract.xml:/root/deploy/make-contract.xml
@@ -23,18 +21,16 @@ services:
2321
profiles:
2422
- server
2523

26-
provider-core:
24+
tc-core-client:
2725
image: fraunhoferaisec/trusted-connector-core:${EXAMPLE_TAG:-develop}
2826
tty: true
2927
stdin_open: true
30-
command: [ "--class-path", "./jars/*", "de.fhg.aisec.ids.TrustedConnector",
31-
"--spring.config.location=/root/etc/application.yml" ]
3228
volumes:
3329
- /var/run/docker.sock:/var/run/docker.sock
3430
- ../etc/application.yml:/root/etc/application.yml
3531
- ../deploy/allow-all-flows.pl:/root/deploy/allow-all-flows.pl
3632
- ../etc/settings2.mapdb:/root/etc/settings.mapdb
37-
- ../etc/provider-keystore.p12:/root/etc/keystore.p12
33+
- ../etc/client-keystore.p12:/root/etc/keystore.p12
3834
- ../etc/truststore.p12:/root/etc/truststore.p12
3935
- ./example-multipart-uc-client.xml:/root/deploy/example-multipart-uc-client.xml
4036
ports:

examples/src/main/resources/example-ids-multipart-uc/example-multipart-uc-client.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
</setProperty>
3333
<process ref="contractRequestCreationProcessor" />
3434
<process ref="idsMultiPartOutputProcessor" />
35-
<to uri="https://consumer-core:28282/usageControl?sslContextParameters=#rootClientSslContext" />
35+
<to uri="https://tc-core-server:28282/usageControl?sslContextParameters=#rootClientSslContext" />
3636
<process ref="idsMultiPartInputProcessor" />
3737
<process ref="idsMessageTypeExtractionProcessor" />
3838
<choice>
@@ -41,7 +41,7 @@
4141
<log message="### Handle ContractResponseMessage ###" />
4242
<process ref="contractResponseProcessor" />
4343
<process ref="idsMultiPartOutputProcessor" />
44-
<to uri="https://consumer-core:28282/usageControl?sslContextParameters=#rootClientSslContext" />
44+
<to uri="https://tc-core-server:28282/usageControl?sslContextParameters=#rootClientSslContext" />
4545
<process ref="idsMultiPartInputProcessor" />
4646
<process ref="idsMessageTypeExtractionProcessor" />
4747
<choice>
@@ -76,7 +76,7 @@
7676
</setProperty>
7777
<process ref="artifactRequestCreationProcessor" />
7878
<process ref="idsMultiPartOutputProcessor" />
79-
<to uri="https://consumer-core:28282/usageControl?sslContextParameters=#rootClientSslContext" />
79+
<to uri="https://tc-core-server:28282/usageControl?sslContextParameters=#rootClientSslContext" />
8080
<process ref="idsMultiPartInputProcessor" />
8181
<process ref="idsMessageTypeExtractionProcessor" />
8282
<choice>

examples/src/main/resources/example-ids-multipart-uc/make-contract.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
<camel:sslContextParameters id="serverSslContext" certAlias="1">
1111
<camel:keyManagers keyPassword="password">
12-
<camel:keyStore resource="etc/provider-keystore.p12" password="password"/>
12+
<camel:keyStore resource="etc/client-keystore.p12" password="password"/>
1313
</camel:keyManagers>
1414
<camel:trustManagers>
1515
<camel:keyStore resource="etc/truststore.p12" password="password"/>

examples/src/main/resources/example-ids-multipart/compose.yaml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,16 @@
11
version: '3'
22
services:
33

4-
consumer-core:
4+
tc-core-server:
55
image: fraunhoferaisec/trusted-connector-core:${EXAMPLE_TAG:-develop}
66
tty: true
77
stdin_open: true
8-
command: [ "--class-path", "./jars/*", "de.fhg.aisec.ids.TrustedConnector",
9-
"--spring.config.location=/root/etc/application.yml" ]
108
volumes:
119
- /var/run/docker.sock:/var/run/docker.sock
1210
- ../etc/application.yml:/root/etc/application.yml
1311
- ../deploy/allow-all-flows.pl:/root/deploy/allow-all-flows.pl
1412
- ../etc/settings.mapdb:/root/etc/settings.mapdb
15-
- ../etc/consumer-keystore.p12:/root/etc/keystore.p12
13+
- ../etc/server-keystore.p12:/root/etc/keystore.p12
1614
- ../etc/truststore.p12:/root/etc/truststore.p12
1715
- ./example-multipart-server.xml:/root/deploy/example-multipart-server.xml
1816
ports:
@@ -22,18 +20,16 @@ services:
2220
profiles:
2321
- server
2422

25-
provider-core:
23+
tc-core-client:
2624
image: fraunhoferaisec/trusted-connector-core:${EXAMPLE_TAG:-develop}
2725
tty: true
2826
stdin_open: true
29-
command: [ "--class-path", "./jars/*", "de.fhg.aisec.ids.TrustedConnector",
30-
"--spring.config.location=/root/etc/application.yml" ]
3127
volumes:
3228
- /var/run/docker.sock:/var/run/docker.sock
3329
- ../etc/application.yml:/root/etc/application.yml
3430
- ../deploy/allow-all-flows.pl:/root/deploy/allow-all-flows.pl
3531
- ../etc/settings2.mapdb:/root/etc/settings.mapdb
36-
- ../etc/provider-keystore.p12:/root/etc/keystore.p12
32+
- ../etc/client-keystore.p12:/root/etc/keystore.p12
3733
- ../etc/truststore.p12:/root/etc/truststore.p12
3834
- ./example-multipart-client.xml:/root/deploy/example-multipart-client.xml
3935
ports:

examples/src/main/resources/example-ids-multipart/example-multipart-client.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
<from uri="timer://tenSecondsTimer?fixedRate=true&amp;period=10000"/>
2929
<process ref="descriptionRequestCreationProcessor"/>
3030
<process ref="idsMultiPartOutputProcessor"/>
31-
<to uri="https://consumer-core:28282/selfInformation?sslContextParameters=#rootClientSslContext"/>
31+
<to uri="https://tc-core-server:28282/selfInformation?sslContextParameters=#rootClientSslContext"/>
3232
<process ref="idsMultiPartInputProcessor"/>
3333
<log message="Server self-description:\n${body}"/>
3434
</route>

examples/src/main/resources/example-idscp2-uc/compose.yaml

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,40 @@
11
version: '3'
22
services:
33

4-
provider-core:
4+
tc-core-server:
55
image: fraunhoferaisec/trusted-connector-core:${EXAMPLE_TAG:-develop}
66
tty: true
77
stdin_open: true
8-
command: [ "--class-path", "./jars/*", "de.fhg.aisec.ids.TrustedConnector",
9-
"--spring.config.location=/root/etc/application.yml" ]
108
volumes:
119
- /var/run/docker.sock:/var/run/docker.sock
1210
- ../etc/application.yml:/root/etc/application.yml
1311
- ../deploy/allow-all-flows.pl:/root/deploy/allow-all-flows.pl
1412
- ../etc/settings.mapdb:/root/etc/settings.mapdb
15-
- ../etc/provider-keystore.p12:/root/etc/keystore.p12
13+
- ../etc/server-keystore.p12:/root/etc/keystore.p12
1614
- ../etc/truststore.p12:/root/etc/truststore.p12
1715
- ./example-idscp2-server.xml:/root/deploy/example-idscp2-server.xml
1816
- ./make-contract.xml:/root/deploy/make-contract.xml
1917
ports:
2018
- "8080:8080"
21-
environment:
22-
TC_DAPS_URL: "https://daps-dev.aisec.fraunhofer.de/v4"
2319
networks:
2420
- ids-wide
2521
profiles:
2622
- server
2723

28-
consumer-core:
24+
tc-core-client:
2925
image: fraunhoferaisec/trusted-connector-core:${EXAMPLE_TAG:-develop}
3026
tty: true
3127
stdin_open: true
32-
command: [ "--class-path", "./jars/*", "de.fhg.aisec.ids.TrustedConnector",
33-
"--spring.config.location=/root/etc/application.yml" ]
3428
volumes:
3529
- /var/run/docker.sock:/var/run/docker.sock
3630
- ../etc/application.yml:/root/etc/application.yml
3731
- ../deploy/allow-all-flows.pl:/root/deploy/allow-all-flows.pl
3832
- ../etc/settings2.mapdb:/root/etc/settings.mapdb
39-
- ../etc/consumer-keystore.p12:/root/etc/keystore.p12
33+
- ../etc/client-keystore.p12:/root/etc/keystore.p12
4034
- ../etc/truststore.p12:/root/etc/truststore.p12
4135
- ./example-idscp2-client.xml:/root/deploy/example-idscp2-client.xml
4236
ports:
4337
- "8081:8080"
44-
environment:
45-
TC_DAPS_URL: "https://daps-dev.aisec.fraunhofer.de/v4"
4638
networks:
4739
- ids-wide
4840
- provider-internal

examples/src/main/resources/example-idscp2-uc/example-idscp2-client.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,14 +27,14 @@
2727
<constant>https://example.com/some_artifact</constant>
2828
</setProperty>
2929
<process ref="contractRequestCreationProcessor" />
30-
<to uri="idscp2client://provider-core:29292?awaitResponse=true&amp;connectionShareId=ucConnection&amp;sslContextParameters=#clientSslContext&amp;useIdsMessages=true"/>
30+
<to uri="idscp2client://tc-core-server:29292?awaitResponse=true&amp;connectionShareId=ucConnection&amp;sslContextParameters=#clientSslContext&amp;useIdsMessages=true"/>
3131
<process ref="idsMessageTypeExtractionProcessor"/>
3232
<choice>
3333
<when>
3434
<simple>${exchangeProperty.ids-type} == 'ContractResponseMessage'</simple>
3535
<log message="### Handle ContractResponseMessage ###"/>
3636
<process ref="contractResponseProcessor"/>
37-
<to uri="idscp2client://provider-core:29292?awaitResponse=true&amp;connectionShareId=ucConnection&amp;sslContextParameters=#clientSslContext&amp;useIdsMessages=true"/>
37+
<to uri="idscp2client://tc-core-server:29292?awaitResponse=true&amp;connectionShareId=ucConnection&amp;sslContextParameters=#clientSslContext&amp;useIdsMessages=true"/>
3838
<process ref="idsMessageTypeExtractionProcessor"/>
3939
<choice>
4040
<when>
@@ -63,7 +63,7 @@
6363
<constant>https://example.com/some_artifact</constant>
6464
</setProperty>
6565
<process ref="artifactRequestCreationProcessor" />
66-
<to uri="idscp2client://provider-core:29292?awaitResponse=true&amp;connectionShareId=ucConnection&amp;sslContextParameters=#clientSslContext&amp;useIdsMessages=true"/>
66+
<to uri="idscp2client://tc-core-server:29292?awaitResponse=true&amp;connectionShareId=ucConnection&amp;sslContextParameters=#clientSslContext&amp;useIdsMessages=true"/>
6767
<process ref="idsMessageTypeExtractionProcessor"/>
6868
<choice>
6969
<when>

examples/src/main/resources/example-idscp2-uc/make-contract.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
<camel:sslContextParameters id="serverSslContext" certAlias="1">
1111
<camel:keyManagers keyPassword="password">
12-
<camel:keyStore resource="etc/provider-keystore.p12" password="password"/>
12+
<camel:keyStore resource="etc/keystore.p12" password="password"/>
1313
</camel:keyManagers>
1414
<camel:trustManagers>
1515
<camel:keyStore resource="etc/truststore.p12" password="password"/>

examples/src/main/resources/example-idscp2/compose-broadcast.yaml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,37 @@
11
version: '3'
22
services:
33

4-
# The core platform, mounts docker control socket and route definition into the image
5-
provider-core:
4+
tc-core-server:
65
image: fraunhoferaisec/trusted-connector-core:${EXAMPLE_TAG:-develop}
76
tty: true
87
stdin_open: true
98
volumes:
109
- /var/run/docker.sock:/var/run/docker.sock
10+
- ../etc/application.yml:/root/etc/application.yml
1111
- ../deploy/allow-all-flows.pl:/root/deploy/allow-all-flows.pl
1212
- ../etc/settings.mapdb:/root/etc/settings.mapdb
13-
- ../etc/provider-keystore.p12:/root/etc/provider-keystore.p12
13+
- ../etc/consumer-keystore.p12:/root/etc/keystore.p12
1414
- ../etc/truststore.p12:/root/etc/truststore.p12
15-
- ./example-idscp2-server-broadcast.xml:/root/deploy/example-idscp2-server.xml
15+
- ./example-idscp2-server-broadcast.xml:/root/deploy/example-idscp2-server-broadcast.xml
1616
ports:
1717
- "8080:8080"
1818
networks:
1919
- ids-wide
2020
profiles:
2121
- server
2222

23-
# The core platform, mounts docker control socket and route definition into the image
24-
consumer-core:
23+
tc-core-client:
2524
image: fraunhoferaisec/trusted-connector-core:${EXAMPLE_TAG:-develop}
2625
tty: true
2726
stdin_open: true
2827
volumes:
2928
- /var/run/docker.sock:/var/run/docker.sock
29+
- ../etc/application.yml:/root/etc/application.yml
3030
- ../deploy/allow-all-flows.pl:/root/deploy/allow-all-flows.pl
3131
- ../etc/settings2.mapdb:/root/etc/settings.mapdb
32-
- ../etc/consumer-keystore.p12:/root/etc/consumer-keystore.p12
32+
- ../etc/provider-keystore.p12:/root/etc/keystore.p12
3333
- ../etc/truststore.p12:/root/etc/truststore.p12
34-
- ./example-idscp2-client-broadcast.xml:/root/deploy/example-idscp2-client.xml
34+
- ./example-idscp2-client-broadcast.xml:/root/deploy/example-idscp2-client-broadcast.xml
3535
ports:
3636
- "8081:8080"
3737
networks:

examples/src/main/resources/example-idscp2/compose.yaml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,16 @@
11
version: '3'
22
services:
33

4-
consumer-core:
4+
tc-core-server:
55
image: fraunhoferaisec/trusted-connector-core:${EXAMPLE_TAG:-develop}
66
tty: true
77
stdin_open: true
8-
command: [ "--class-path", "./jars/*", "de.fhg.aisec.ids.TrustedConnector",
9-
"--spring.config.location=/root/etc/application.yml" ]
108
volumes:
119
- /var/run/docker.sock:/var/run/docker.sock
1210
- ../etc/application.yml:/root/etc/application.yml
1311
- ../deploy/allow-all-flows.pl:/root/deploy/allow-all-flows.pl
1412
- ../etc/settings.mapdb:/root/etc/settings.mapdb
15-
- ../etc/consumer-keystore.p12:/root/etc/keystore.p12
13+
- ../etc/server-keystore.p12:/root/etc/keystore.p12
1614
- ../etc/truststore.p12:/root/etc/truststore.p12
1715
- ./example-idscp2-server.xml:/root/deploy/example-idscp2-server.xml
1816
ports:
@@ -22,18 +20,16 @@ services:
2220
profiles:
2321
- server
2422

25-
provider-core:
23+
tc-core-client:
2624
image: fraunhoferaisec/trusted-connector-core:${EXAMPLE_TAG:-develop}
2725
tty: true
2826
stdin_open: true
29-
command: [ "--class-path", "./jars/*", "de.fhg.aisec.ids.TrustedConnector",
30-
"--spring.config.location=/root/etc/application.yml" ]
3127
volumes:
3228
- /var/run/docker.sock:/var/run/docker.sock
3329
- ../etc/application.yml:/root/etc/application.yml
3430
- ../deploy/allow-all-flows.pl:/root/deploy/allow-all-flows.pl
3531
- ../etc/settings2.mapdb:/root/etc/settings.mapdb
36-
- ../etc/provider-keystore.p12:/root/etc/keystore.p12
32+
- ../etc/client-keystore.p12:/root/etc/keystore.p12
3733
- ../etc/truststore.p12:/root/etc/truststore.p12
3834
- ./example-idscp2-client.xml:/root/deploy/example-idscp2-client.xml
3935
ports:

0 commit comments

Comments
 (0)