as2 ingress connector

AS2Gateway Ingress Connector

Version: 17.07

Supported Since: 17.01

What is AS2Gateway Ingress Connector?

AS2Gateway Ingress connector can be used to receive AS2 messages from a remote AS2 service. The processing AS2 messages by AS2Gateway Ingress connector is done according to the RFC 4130 written by Drummond & Moberg.

Note: This functionality of this connector is almost similar to AS2 Ingress Connector's functionality. However although the AS2 Ingress Connector is limited to single station, single partner setup AS2Gateway Ingress Connector has eliminated that limitation by providing support for maintaining multiple AS2 trading stations and AS2 trading partners.

Therefore if you are a organization who requires only one trading station and one trading partner please refer to AS2 Ingress Connector as it is comparatively easier to configure.

Sample Use Case

Prerequisite

In order to use the AS2Gateway Egress Connector you must first select the "AS2 Connector" dependency from the connector list when you are creating an empty Ultra project. If you have already created a project, you can add the "AS2 Connector" dependency via Component Registry. From Tools menu, select Ultra Studio → Component Registry and from the Connectors list, select the "AS2 Connector" dependency.

As a prerequisite to use the AS2Gateway Egress Connector it is required to prepare a resource configuration which contains required AS2 trading station/partner information.

1. Preparing the AS2 Trading information resource

To create a resource with required information, you should open the project.xpml file in Design mode. Then select AS2 Trading under Custom Templates menu. This will open a list of input parameter where you need to enter the relevant information in input fields inorder to configure the AS2 Trading information resource.

as2gateway project resource
Resource Parameters

* marked fields are mandatory

The AS2Gateway Ingress Connector uses the HTTP as the underlying transport protocol which makes it inherit the properties of HTTP Ingress Connector. Therefore it is possible to view and customize those HTTP transport specific properties defined under the Transport Configuration category. To understand them please refer to NIO HTTP Ingress Connector reference.

Resource ID *

Identifier for the resource to identify within the XML configuration of project.xpml

Station AS2 ID *

AS2 Identifier of the trading station

User Email ID *

Email address of the user

Station Keystore Type

Type of the Identity Keystore that will be used for AS2 message signing and encrypting (S/MIME), possible values are "JKS" and "PKCS12"

Station Keystore Path *

Path of the Identity Keystore which stores the certificate that will be used for AS2 message signing and encryption (S/MIME)

Station Keystore Password *

Password of the Identity Keystore which stores the certificate that will be used for AS2 message signing and encryption (S/MIME)

Station Certificate Alias *

Alias of the certificate that will be used for AS2 message signing and encrypting (S/MIME)

Key Password *

Key password of the certificate that will be used for AS2 message signing and encrypting (S/MIME)

Station Truststore Type

Type of the Trust Keystore that will be used storing the trading partner’s (S/MIME) certificates, possible values are "JKS" and "PKCS12"

Truststore Path*

Path of the Trust Keystore that will be used for storing the trading partner’s (S/MIME) certificates

Truststore Password*

Password of the Trust Keystore that will be used storing the trading partner’s (S/MIME) certificates

Organization ID*

Unique integer identifier to recognize the organization

Partner AS2 ID *

AS2 Identifier of the trading partner

Partner URL *

AS2 Message receiving URL of the trading partner

Station Async MDN URL*

HTTP URL of the trading station which will be receiving Asynchronous MDNs

Partner Certificate Alias*

Alias of the certificate that will be used for processing AS2 messages from partner

Sign AS2 Message*

Sign AS2 Message for partner

Encrypt AS2 Message*

Encrypt AS2 Message for partner

Compress Message Before

Compress the message payload before starting the AS2 processing

Compress Message After

Compress the message payload after starting the AS2 processing

AS2 Message Encrypt Algorithm

Algorithm to be used in AS2 message encryption process

AS2 Message Sign Algorithm

Algorithm to be used in AS2 message signing process

AS2 Message Signature Encrypt Algorithm

Algorithm to be used in AS2 message signature encryption process

Request MDN

For the sent AS2 messages request a Message Disposition Notification (MDN) from the receiving trading partners

Request MDN Signed

Request for the MDN sending party to send a signed MDN

Request Async MDN

Request the MDN sending party to send a asynchronous MDN to the defined Async MDN URL endpoint

Message Subject

Subject of the AS2 Message

2. Receiving an invoice from trading partner over AS2

Following scenario is almost similar to the sample scenario that we have discussed under AS2 Ingress Connector. The only difference is now there are multiple AS2 trading stations and multiple trading partners for AS2Gateway. Here the received invoice file will be store into a local directory and send an Message Disposition Notification (MDN) to the trading partner. The MDN is the response to the trading partner which contains the processing status of the received AS2 message. The MDN can be sent as the response to the received AS2 message (sync MDN) or else it will be sent as a new AS2 message (Async MDN) to the trading partner. It will be decided on the preference of the trading partner which will be included in the receiving AS2 message.

as2 ingress flow

For the above scenario it is required to have four elements for the AS2 message flow configuration of the UltraESB. The first element is a AS2Gateway Ingress Connector which is responsible for receiving the AS2 message, parsing it to extract the invoice file, set the extracted invoice as a attachment of the message and finally preparing the response for the message and add it as the response message payload. The second element is a Attachment Saver element which is responsible for saving the invoice file into a user defined local directory. The third element is a AS2MDNCreator which will evaluate requested format of MDN. If the remote trading party has requested a synchronous MDN then it will invoke the response message which will contain the MDN message through its Sync MDN Requested out port. If the remote trading party has requested for a asynchronous MDN then the AS2MDNCreator will forward the response message to the final element of the flow, which is an NIOHttpDynamicURLEgressConnector. It will send the MDN in a new HTTP request.

In-order to understand the functionality of Attachment Saver element please refer to the reference resources.

For this sample use case, configuration of the Attachment Saver element is as follows.