Testing with SOAP UITesting without a signed keyA normal „serviceCheck“ request for an instance “Cortex” is configured the following way. | Configured instance of Web Service | |
---|
| Image Added | |
The related SOAP UI request looks like this. Code Block |
---|
| <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 keyWe 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”. | WebService MainConfiguration | |
---|
| Image Added | |
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 | |
---|
| Image Added | |
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” | |
---|
| Image Added | |
In this case, the text will be signed by the private key mapped against the alias “kgs” in the private keystore. | Display of signed text. | |
---|
| Image Added | |
| Screenshot of SOAP UI with added seckey | |
---|
| Image Added | |
| Screenshot of ServiceCheck result | |
---|
| Image Added | |
Testing MTOM with SOAP UIPlease 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 | |
---|
| Image Added | |
| Highlighted “Part”-column in SOAP UI | |
---|
| Image Added | |
| Selected attachment in SOAP UI | |
---|
| Image Added | |
|