Provide data - Web service

Integration module Provide data

1. Provide web service




A new web service can by created via the Web service menu / New web service. This option is only available if Web service under Provide data is selected. So that self-created web services can be consumed, the settings of the provided web service must be configured accordingly. In each configuration dialog, you can reach the corresponding Intrexx Help by pressing F1 or by clicking on the "Help" button.

2. Permissions

To configure web services, the portal permission Register web services and permission for the Tools module are required.

3. HTTPS certification

In the following it is assumed that the relevant certificates as well keystore and truststore are already present. Make sure that both keystore and truststore have the file type Java Keystore (file ending jks).

3.1 AXIS2 configuration

To setup a transport using HTTPS, modifications to the Axis2 configuration file need to be carried out. Switch to the portal directory /internal/webservice/provider/axis2/conf/ to do that and open the file "axis2.xml" in your preferred text editor. Now search for the following entry:
<!-- ================================================= -->
<!-- Non-blocking http/s Transport Listener  -->
<!-- the non blocking http transport based on HttpCore + NIO extensions -->
<transportReceiver class="de.uplanet.lucy.server.webservice.provider.axis2.transport.nhttp.HttpCore NIOListener" name="http">
	<parameter locked="false" name="port">WS_PORT</parameter>
	<parameter locked="false" name="non-blocking">true</parameter>
	<parameter locked="false" name="hostname">HOST_NAME</parameter>
</transportReceiver>
Beneath this entry is another "<transportreceiver>" element that is currently commented out. Remove the comment tags to activate the entry.
<!-- the non blocking https transport based on HttpCore + SSL-NIO extensions -->
<transportReceiver class="de.uplanet.lucy.server.webservice.provider.axis2.transport.nhttp.HttpCore
NIOSSLListener" name="https">
	<parameter locked="false" name="port">SSL_WS_PORT</parameter>
	<parameter locked="false" name="non-blocking">true</parameter>
	<parameter locked="false" name="keystore">
		<KeyStore>
			<Location>KEYSTORE.jks</Location>
			<Type>JKS</Type>
			<Password>KEYSTORE_PASSWORD</Password>
			<KeyPassword>KEY_PASSWORD</KeyPassword>
		</KeyStore>
	</parameter>
	<parameter locked="false" name="truststore">
		<TrustStore>
			<Location>TRUSTSTORE.jks</Location> 
			<Type>JKS</Type>
			<Password>TRUSTSTORE_PASSWORD</Password>
		</TrustStore>
	</parameter>
	<parameter name="SSLVerifyClient">require</parameter>
<!--supports optional|require or defaults to none -->
</transportReceiver>
The following values need to be filled in correctly:

ParameterDescription
SSL_WS_PORTPort that can be used to call up the HTTPS Web service. It should be noted that this port is different to the port for unsecured Web service calls.
KEYSTORE.jksPath to the Keystore in the format JKS. The path must be entered relevant to the portal directory \internal\webservice\provider\
KEYSTORE_PASSWORDPassword for the stated Keystore.
KEY_PASSWORDPassword for the used key.
TRUSTSTORE.jksPath to the Truststore in the format JKS. The path must be entered relevant to the portal directory \internal\webservice\provider\
TRUSTSTORE_PASSWORDPassword for the stated Truststore.

Once the values have been entered correctly, the next entry to search for is:
<transportSender class="org.apache.axis2.transport.http.CommonsHTTPTransportSender" name="https">
	<parameter name="PROTOCOL">HTTP/1.1</parameter>
	<parameter name="Transfer-Encoding">chunked</parameter>
</transportSender>
Beneath this entry is another "<transportsender>" element that is currently commented out. Remove the comment tags to activate the entry.
<!-- the non-blocking https transport sender based on HttpCore + NIO SSL extensions-->
<transportSender name="https" class="de.uplanet.lucy.server.webservice.provider.axis2.transport.nhttp.Http
CoreNIOSSLSender">
<parameter name="non-blocking" locked="false">true</parameter>
<parameter name="keystore" locked="false">
	<KeyStore>
		<Location>KEYSTORE.jks</Location>
		<Type>JKS</Type>
		<Password>KEYSTORE_PASSWORD</Password>
		<KeyPassword>KEY_PASSWORD</KeyPassword>
	</KeyStore>
</parameter>
<parameter locked="false" name="truststore">
	<TrustStore>
		<Location>TRUSTSTORE.jks</Location>
		<Type>JKS</Type>
		<Password>TRUSTSTORE_PASSWORD</Password>
	</TrustStore>
</parameter>
<parameter name="HostnameVerifier">DefaultAndLocalhost</parameter>
	;<!--supports Strict|AllowAll|DefaultAndLocalhost or the default if none specified-->
</transportSender>
The following values need to be filled in correctly:

ParameterDescription
KEYSTORE.jksPath to the Keystore in the format JKS. The path must be entered relevant to the portal directory \internal\webservice\provider\
KEYSTORE_PASSWORDPassword for the stated Keystore.
KEY_PASSWORDPassword for the used key.
TRUSTSTORE.jksPath to the Truststore in the format JKS. The path must be entered relevant to the portal directory \internal\webservice\provider\
TRUSTSTORE_PASSWORDPassword for the stated Truststore.

Save the file and then restart the portal service. Afterwards, call up the WSDL file in the browser to test the HTTPS authentication. When doing this, make sure that the entries are correct, i.e. the port and https instead of http. If the URL has been correctly entered, the applied certificate must be accepted. Subsequently, the WSDL file will be shown in the browser.

More information

General
Consume web service
Export / Import