Skip to content
Merged
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
18 changes: 9 additions & 9 deletions RELEASE-NOTES.md
Original file line number Diff line number Diff line change
@@ -1,24 +1,28 @@
# OpenAS2 Server
# Version 4.5.1
# Version 4.5.2
# RELEASE NOTES
-----
The OpenAS2 project is pleased to announce the release of OpenAS2 4.5.1
The OpenAS2 project is pleased to announce the release of OpenAS2 4.5.2

The release download file is: OpenAS2Server-4.5.1.zip
The release download file is: OpenAS2Server-4.5.2.zip

The zip file contains a PDF document (OpenAS2HowTo.pdf) providing information on installing and using the application.
## NOTE: Testing covers Java 11 to 21.
## Java 8 is NO LONGER SUPPORTED.

Version 4.5.1 - 2025-06-04
Version 4.5.2 - 2025-06-12

This is a bugfix release.

1. Fix dynamic content-type functionality.
1. Fix database connection setup for healthcheck module.

##Upgrade Notes
See the openAS2HowTo appendix for the general process on upgrading OpenAS2.

Below are some specific things to focus on depending on which version you are upgrading from.

**You must review all notes for the relevant intermediate versions from your version to this release version.**

### Upgrading to 4.0 or newer from any older version:
1. Ensure you implement all logging that you had configured for ealrier versions using the logback configuration or replace with another framework that works with SLF4J facade. See the OpenAS2HowTo.pdf logging section for more details.
2. The property for email configuration in the config.xml changed:
Expand Down Expand Up @@ -47,10 +51,6 @@ This is a bugfix release.
5. Run this command: java -cp ../lib/\* org.openas2.upgrades.MigratePollingModuleConfig config.xml partnerships.xml
6. A backup will be created of the original file (with .00 extension|) that can be removed if the conversion is successful.

Below are some specific things to focus on depending on which version you are upgrading from.

**You must review all notes for the relevant intermediate versions from your version to this release version.**

### If upgrading from versions older than 2.12.0:
1. If you are using the DB tracking module with the default H2 database then you will need to follow the DB upgrade steps "Appendix: Updating database structure" defined in the OpenAS2HowTo.pdf to ensure you do not lose your existing data because the new H2 version has issues with old databases.
2. A change to the way the private key is looked up in the receiver handler means that if you have duplicated a certificate in the keystore, some partnerships may start to fail. This fix may fix other strange certificate issues when receiving messages. To fix partnership failures that occur after the upgrade, find the duplicates and remove them making sure the one you leave behind is the one with the correct private key. Alternatively, use the **use_new_certificate_lookup_mode** attribute at partnership level set to **false** and the old mechanism will be used but this is not advised as a long term solution as it will eventually be removed in a future version.
Expand Down
2 changes: 1 addition & 1 deletion Server/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<!-- DO NOT CHANGE THIS "groupId" WITHOUT CHANGING XMLSession.getManifestAttributes.MANIFEST_VENDOR_ID_ATTRIB -->
<groupId>net.sf.openas2</groupId>
<artifactId>OpenAS2</artifactId>
<version>4.5.1</version>
<version>4.5.2</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,9 +97,7 @@ protected CompositeParameters createParser() {
}

protected void persist(Message msg, Map<String, String> map) {
Connection conn = null;
try {
conn = dbHandler.getConnection();
try (Connection conn = dbHandler.getConnection()) {
Statement s = conn.createStatement();
String msgIdField = FIELDS.MSG_ID;
ResultSet rs = s.executeQuery(
Expand Down Expand Up @@ -180,26 +178,15 @@ protected void persist(Message msg, Map<String, String> map) {
msg.setLogMsg("Failed to persist a tracking event: " + org.openas2.util.Logging.getExceptionMsg(e)
+ " ::: Data map: " + map);
logger.error(msg.getLogMsg(), e);
} finally {
if (conn != null) {
try {
conn.close();
} catch (SQLException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
}

}

public ArrayList<HashMap<String, String>> listMessages() {

Connection conn = null;
ArrayList<HashMap<String, String>> rows = new ArrayList<HashMap<String, String>>();

try {
conn = dbHandler.getConnection();
try (Connection conn = dbHandler.getConnection()) {
Statement s = conn.createStatement();
ResultSet rs = s.executeQuery("SELECT " + FIELDS.MSG_ID
+ ",CREATE_DT,SENDER_ID,RECEIVER_ID,MSG_ID,FILE_NAME,ENCRYPTION_ALGORITHM,SIGNATURE_ALGORITHM,MDN_MODE,STATE FROM "
Expand All @@ -216,24 +203,14 @@ public ArrayList<HashMap<String, String>> listMessages() {
}
} catch (Exception e) {
e.printStackTrace();
} finally {
if (conn != null) {
try {
conn.close();
} catch (SQLException e) {
e.printStackTrace();
}
}
}
return rows;
}

public HashMap<String, String> showMessage(String msg_id) {

Connection conn = null;
HashMap<String, String> row = new HashMap<String, String>();
try {
conn = dbHandler.getConnection();
try (Connection conn = dbHandler.getConnection()) {
PreparedStatement s = conn
.prepareStatement("SELECT * FROM " + tableName + " WHERE " + FIELDS.MSG_ID + " = ?");
s.setString(1, msg_id);
Expand All @@ -248,23 +225,13 @@ public HashMap<String, String> showMessage(String msg_id) {
}
} catch (Exception e) {
e.printStackTrace();
} finally {
if (conn != null) {
try {
conn.close();
} catch (SQLException e) {
e.printStackTrace();
}
}
}
return row;
}

public ArrayList<HashMap<String, String>> getDataCharts(HashMap<String, String> map) {
Connection conn = null;
ArrayList<HashMap<String, String>> rows = new ArrayList<HashMap<String, String>>();
try {
conn = dbHandler.getConnection();
try (Connection conn = dbHandler.getConnection()) {
Statement s = conn.createStatement();
ResultSet rs = s.executeQuery("SELECT " + FIELDS.MSG_ID + ",STATE,STATUS,CREATE_DT FROM " + tableName
+ " WHERE CREATE_DT BETWEEN CAST('" + map.get("startDate").toString()
Expand All @@ -282,14 +249,6 @@ public ArrayList<HashMap<String, String>> getDataCharts(HashMap<String, String>
}
} catch (Exception e) {
e.printStackTrace();
} finally {
if (conn != null) {
try {
conn.close();
} catch (SQLException e) {
e.printStackTrace();
}
}
}
return rows;
}
Expand Down Expand Up @@ -370,21 +329,13 @@ public void stop() {

@Override
public boolean healthcheck(List<String> failures) {
Connection conn = null;
try {
try (Connection conn = dbHandler.getConnection()) {
Statement s = conn.createStatement();
s.executeQuery("SELECT COUNT(*) FROM " + tableName);
} catch (Exception e) {
failures.add(this.getClass().getSimpleName() + " - Failed to check DB tracking module connection to DB: "
+ e.getMessage() + " :: Connect String: " + jdbcConnectString);
return false;
} finally {
if (conn != null) {
try {
conn.close();
} catch (Exception e) {
}
}
}
return true;
}
Expand Down
20 changes: 12 additions & 8 deletions changes.txt
Original file line number Diff line number Diff line change
@@ -1,42 +1,46 @@
**IMPORTANT NOTE**: Please review upgrade notes in the RELEASE-NOTES.md if you are upgrading

Version 4.5.1 - 2025-06-04
Version 4.5.2 - 2025-06-12

This is a bugfix release.
1. Fix database connection setup for healthcheck module.

Version 4.5.1 - 2025-06-04

1. Fix dynamic content-type functionality.
This is a bugfix release.

1. Fix dynamic content-type functionality.

Version 4.5.0 - 2025-05-18

This is an enhancement release.

1. Add configuration paramerter "resend_on_ssl_exception" to enter into a resend loop when an SSL exception occurs connecting to a partner.
1. Add configuration paramerter "resend_on_ssl_exception" to enter into a resend loop when an SSL exception occurs connecting to a partner.

Version 4.4.0 - 2025-05-10

This is an enhancement release.

1. Log the file size of the file being processed in the AS2 vmessage builder.
1. Log the file size of the file being processed in the AS2 vmessage builder.

Version 4.3.0 - 2025-04-20

This is an enhancement release.

1. Support retaining the original file name as received into the OpenAS2 server before processing so that it can be referenced in dynamic variables.
1. Support retaining the original file name as received into the OpenAS2 server before processing so that it can be referenced in dynamic variables.

Version 4.2.0 - 2025-03-29

This is an enhancement release.

1. Support AS2 systems that do not set the "Content-Transfer-Encoding" mime body part header on the outer mime body part but instead pass it as an HTTP header.
1. Support AS2 systems that do not set the "Content-Transfer-Encoding" mime body part header on the outer mime body part but instead pass it as an HTTP header.

Version 4.1.1 - 2025-03-19

This is a bugfix release.

1. Fix the proxy support implementation.
2. Fix handling of file cleanup when resend loop is entered.
1. Fix the proxy support implementation.
2. Fix handling of file cleanup when resend loop is entered.

Version 4.1.0 - 2024-12-04

Expand Down
4 changes: 2 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>net.sf.openas2</groupId>
<artifactId>OpenAS2</artifactId>
<version>4.5.1</version>
<version>4.5.2</version>
<name>OpenAS2</name>
<packaging>pom</packaging>

Expand Down Expand Up @@ -108,7 +108,7 @@
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter</artifactId>
<version>5.13.0</version>
<version>5.13.1</version>
<scope>test</scope>
</dependency>
<!-- https://mvnrepository.com/artifact/org.mockito/mockito-core -->
Expand Down