Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

Testing with SOAP UI

Testing without a signed key

A normal „serviceCheck“ request for an instance “Cortex” is configured the following way.

Configured instance of Web Service

The related SOAP UI request looks like this.

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:int="http://interfaces.webservice.kgs.software.com/">
   <soapenv:Header/>
   <soapenv:Body>
      <int:ServiceCheck>
         <!--Optional:-->
         <applicationName>Cortex</applicationName>
         <!--Optional:-->
         <username>David</username>
         <!--Optional:-->
         <seckey></seckey>
      </int:ServiceCheck>
   </soapenv:Body>
</soapenv:Envelope>

Testing with signed key

We have developed a small tool, “KGS Security Key generator” which generates a signed text which can be used together with SOAP UI. We will use the instance “Cortex” as our example. The installation package contains both a private keystore and public keystore for testing. The “private” keystore contains a keypair consisting of both private and public key whereas the “public” keystore consists of certificate with public key. In case of testing with SOAP UI, you need the file private (keystore) located at “security_testing/keystore” and public (keystore) located at “security_test-ing/keystore”.

  • Keystore Path (OSGi -> Configuration -> WebService MainConfiguration)

  • Keystore Password (OSGi -> Configuration -> WebService MainConfiguration)

WebService MainConfiguration

  • The password for the “public” keystore is “public” (without quotes). Configure the alias “kgs” which is already present in our test (public) keystore.
    Main -> KGS WebService -> Application Manager

  • Edit the instance “Cortex” and go to the security tab.

Opened “Cortex” configuration

  • Save the configuration. As of now, the instance “Cortex” is ready to receive a signed text (in our case is the Application’s name which is ‘Cortex’)

  • Generate a signed text by starting the “KGS Security Key generator”. Simply, double-click the “generator.jar” located at “security_testing/”. A window will open. Password for the pri-vate keystore is “private” (without quotes). Please enter as shown below.

Screenshot of “KGS Security Key generator”

In this case, the text will be signed by the private key mapped against the alias “kgs” in the private keystore.

  • Click “Generate” and a pop-up window will open displaying the signed text as shown below.

Display of signed text.

  • Copy the text from the “Signed Key (Base64)” window and copy the text within the secKey tag in the SOAP UI window as shown below.

Screenshot of SOAP UI with added seckey

  • In case of “seviceCheck”, the service should be available as shown below.

Screenshot of ServiceCheck result

Testing MTOM with SOAP UI

Please follow the following steps to send an attachment using MTOM;

  • We assume that the MTOM interfaces (located at http://Server-IP-Address:Server-Port/WebApplicationName/ webservice/apiV2?wsdl) have been configured in the SOAP UI

  • Select the “ContentServerDocCreate” interface

  • Configure the tag “imageData” with the following format; <imageData>cid:Name -Of-The-File-With-Extension</imageData>

  • Click on the ‘Plus’ sign as shown below.

Highlighted Plus-button in SOAP UI

  • Locate your attachment and attach it.

  • Click on the ‘Part’ box as shown below.

Highlighted “Part”-column in SOAP UI

  • Select the name of the attachment as shown below.

Selected attachment in SOAP UI

  • At this point, your attachment along with your create request is ready.

  • No labels