Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
151 changes: 80 additions & 71 deletions Server/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,13 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<goals>
<goal>properties</goal>
</goals>
</execution>
</executions>
<executions>
<execution>
<goals>
<goal>properties</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
Expand Down Expand Up @@ -79,10 +79,10 @@
<configuration>
<target>
<!-- Update the test certificates on every test run to ensure they are not expired -->
<exec executable="sh" osfamily="unix">
<arg value="-c"/>
<arg line="${project.basedir}/src/bin/create_test_certificates.sh"/>
</exec>
<exec executable="sh" osfamily="unix">
<arg value="-c"/>
<arg line="${project.basedir}/src/bin/create_test_certificates.sh"/>
</exec>
<!-- Copy the installer config files to test resources to ensure we test the default config -->
<copy todir="${project.basedir}/src/test/resources/config"
verbose="true">
Expand All @@ -99,16 +99,16 @@
<phase>package</phase>
<configuration>
<target>
<copy todir="${package.assembly.dir}/bin"
<copy todir="${package.assembly.dir}/bin"
verbose="true">
<fileset dir="${project.basedir}/src/bin"/>
</copy>
<echo message="OS Name: ${os.name}"/>
<exec executable="sh" osfamily="unix">
<arg value="-c"/>
<arg line="'chmod uga+x ${package.assembly.dir}/bin/*.sh'"/>
</exec>
<!--Copy config directory to assembly directory -->
<exec executable="sh" osfamily="unix">
<arg value="-c"/>
<arg line="'chmod uga+x ${package.assembly.dir}/bin/*.sh'"/>
</exec>
<!--Copy config directory to assembly directory -->
<copy todir="${package.assembly.dir}/config"
verbose="true">
<fileset dir="${project.basedir}/src/config"/>
Expand All @@ -120,8 +120,8 @@
</copy>
<!--Copy artifact to build lib directory -->
<copy
file="${project.build.directory}/${project.build.finalName}.jar"
todir="${package.assembly.dir}/lib" verbose="true"/>
file="${project.build.directory}/${project.build.finalName}.jar"
todir="${package.assembly.dir}/lib" verbose="true"/>
<!-- Add the help PDF version to the distro -->
<copy file="${help.file.src}"
todir="${package.assembly.dir}" verbose="true"/>
Expand All @@ -138,14 +138,14 @@
<!--
Pre-delete the package otherwise it keeps old files in it
-->
<delete file="${project.basedir}/dist/${project.dist.package.name}"/>
<delete file="${project.basedir}/dist/${project.dist.package.name}"/>
<zip
destfile="${project.basedir}/dist/${project.dist.package.name}"
update="true">
<zipfileset dir="${package.assembly.dir}" encoding="UTF-8"
includes="**/*.sh" filemode="755"/>
<zipfileset dir="${package.assembly.dir}" encoding="UTF-8"
excludes="**/*.sh"/>
destfile="${project.basedir}/dist/${project.dist.package.name}"
update="true">
<zipfileset dir="${package.assembly.dir}" encoding="UTF-8"
includes="**/*.sh" filemode="755"/>
<zipfileset dir="${package.assembly.dir}" encoding="UTF-8"
excludes="**/*.sh"/>

</zip>
</target>
Expand All @@ -160,18 +160,18 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<!-- Configures the content of the created manifest -->
<manifest>
<!-- Adds the classpath to the created manifest -->
<addClasspath>true</addClasspath>
<!-- Specifies that all dependencies of our application are found -->
<!-- Configures the main class of the application -->
<mainClass>org.openas2.app.OpenAS2Server</mainClass>
</manifest>
</archive>
</configuration>
<configuration>
<archive>
<!-- Configures the content of the created manifest -->
<manifest>
<!-- Adds the classpath to the created manifest -->
<addClasspath>true</addClasspath>
<!-- Specifies that all dependencies of our application are found -->
<!-- Configures the main class of the application -->
<mainClass>org.openas2.app.OpenAS2Server</mainClass>
</manifest>
</archive>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
Expand All @@ -188,6 +188,15 @@
</plugins>
</build>
<dependencies>
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>dynamodb</artifactId>
</dependency>
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>dynamodb-enhanced</artifactId>
</dependency>

<dependency>
<groupId>org.dom4j</groupId>
<artifactId>dom4j</artifactId>
Expand All @@ -212,26 +221,26 @@
<groupId>commons-cli</groupId>
<artifactId>commons-cli</artifactId>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</dependency>
<dependency>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</dependency>
<dependency>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
</dependency>
<dependency>
<groupId>com.sun.mail</groupId>
<artifactId>jakarta.mail</artifactId>
</dependency>
<dependency>
<dependency>
<groupId>com.h2database</groupId>
<artifactId>h2</artifactId>
</dependency>
<dependency>
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP</artifactId>
</dependency>
<dependency>
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP</artifactId>
</dependency>
<dependency>
<groupId>org.bouncycastle</groupId>
<artifactId>bcpg-jdk18on</artifactId>
Expand All @@ -258,31 +267,31 @@
<artifactId>jackson-databind</artifactId>
<type>jar</type>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.module</groupId>
<artifactId>jackson-module-jaxb-annotations</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.module</groupId>
<artifactId>jackson-module-jaxb-annotations</artifactId>
</dependency>
<dependency>
<groupId>org.glassfish.jersey.media</groupId>
<artifactId>jersey-media-json-jackson</artifactId>
<type>jar</type>
</dependency>
<dependency>
<groupId>org.glassfish.jersey.inject</groupId>
<artifactId>jersey-hk2</artifactId>
<dependency>
<groupId>org.glassfish.jersey.inject</groupId>
<artifactId>jersey-hk2</artifactId>
</dependency>
<!-- Removed JavaEE APIs removed from Java 9+ -->
<dependency>
<groupId>jakarta.xml.bind</groupId>
<artifactId>jakarta.xml.bind-api</artifactId>
</dependency>
<dependency>
<groupId>jakarta.ws.rs</groupId>
<artifactId>jakarta.ws.rs-api</artifactId>
</dependency>
<dependency>
<groupId>jakarta.annotation</groupId>
<artifactId>jakarta.annotation-api</artifactId>
<dependency>
<groupId>jakarta.ws.rs</groupId>
<artifactId>jakarta.ws.rs-api</artifactId>
</dependency>
<dependency>
<groupId>jakarta.annotation</groupId>
<artifactId>jakarta.annotation-api</artifactId>
</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
Expand All @@ -294,15 +303,15 @@
<artifactId>hamcrest</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-junit-jupiter</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-junit-jupiter</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<scope>test</scope>
</dependency>
</dependency>
</dependencies>
</project>
Binary file modified Server/src/config/as2_certs.p12
Binary file not shown.
11 changes: 10 additions & 1 deletion Server/src/config/config.xml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
module.AS2SenderModule.readtimeout="60000"
module.MDNSenderModule.enabled="true"
module.DbTrackingModule.enabled="true"
module.DynamoDbTrackingModule.enabled="false"
module.MDNFileModule.enabled="true"
module.MDNFileModule.filename="$properties.storageBaseDir$/$mdn.msg.sender.as2_id$-$mdn.msg.receiver.as2_id$/mdn/$date.yyyy-MM-dd$/$mdn.msg.headers.message-id$"
module.MDNFileModule.tempdir="$properties.storageBaseDir$/temp"
Expand Down Expand Up @@ -74,6 +75,9 @@
msg_tracking.tcp_server_start="true"
msg_tracking.tcp_server_port="9092"
msg_tracking.tcp_server_password="openas2"
msg_tracking.aws_region="us-east-1"
msg_tracking.dynamodb_table_name="as2db-dev"
msg_tracking.consistent_read="true"
reject_unsigned_messages="false"
pollerConfigBase.outboxdir="$properties.storageBaseDir$/outbox/$partnership.receiver.as2_id$"
pollerConfigBase.errordir="$properties.storageBaseDir$/outbox/error/$date.YYYY$-$date.MM$-$date.dd$/$partnership.receiver.as2_id$"
Expand Down Expand Up @@ -109,7 +113,7 @@
ssl_protocol="TLS"
ssl_keystore="$properties.ssl_keystore$"
ssl_keystore_password="$properties.ssl_keystore_password$"
userid="$properties.restapi.command.processor.userid$"
userid="$properties.restapi.command.processor.userid$"
password="$properties.restapi.command.processor.password$" />
</commandProcessors>
<processor classname="org.openas2.processor.DefaultProcessor"
Expand Down Expand Up @@ -150,6 +154,11 @@
tcp_server_start="$properties.msg_tracking.tcp_server_start$"
tcp_server_port="$properties.msg_tracking.tcp_server_port$"
tcp_server_password="$properties.msg_tracking.tcp_server_password$"/>
<module enabled="$properties.module.DynamoDBTrackingModule.enabled$"
classname="org.openas2.processor.msgtracking.DynamoDBTrackingModule"
aws_region="$properties.msg_tracking.aws_region$"
table_name="$properties.msg_tracking.dynamodb_table_name$"
consistent_read="$properties.msg_tracking.consistent_read$"/>
<module enabled="$properties.module.MDNFileModule.enabled$"
classname="org.openas2.processor.storage.MDNFileModule"
filename="$properties.module.MDNFileModule.filename$"
Expand Down
2 changes: 1 addition & 1 deletion Server/src/main/java/org/openas2/BaseComponent.java
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public int getParameterInt(String key, boolean required, int defaultValue) throw

public Map<String, String> getParameters() {
if (parameters == null) {
parameters = new HashMap<String, String>();
parameters = new HashMap<>();
}

return parameters;
Expand Down
Loading