Rich Dialog Client Side Libraries

Providing a Custom Certificate

This section shows you how to provide a custom certificate for your Rich Dialog clients.

Note

When a client starts a Rich Dialog for the first time, a security information dialog box pops up showing information about the publisher of Xpert.ivy as well as the publisher's certificate. It may be confusing to the users of your application that a certificate from Xpert.ivy is displayed instead of a certificate of the implementor/vendor of the software they're using. This section shows you how to avoid this situation.

Install a Java Developer Kit (JDK)

Install a Java Developer Kit (JDK) version 1.7. You can download it from http://java.oracle.com

Creating a custom certificate

Use the keytool from the previously installed JDK to create a custom certificate in a Java keystore. You may also want to sign your certificate by a certification authority.

See the JDK keytool documentation for details.

Signing the Rich Dialog client libraries

To sign your custom Rich Dialog client extensions with a custom certificate, proceed as follows:

  1. Configure the following properties:

    keystore.file, keystore.password, keystore.alias and dir.jdk

    in the file

    [Xpert.ivy Designer Installation Directory] / clientlib / build.properties

    Save your changes.

  2. Open the Ant build file

    [Xpert.ivy Designer Installation Directory] / clientlib / build.xml

    in Xpert.ivy Designer.

  3. Open the Outline View (Use the menu Window > Show View > Others... > General > Outline)

  4. In the Outline View select the root entry in the tree. Right click to bring up the context menu and select Run As > Ant Build to run the Ant build script (build.xml). The Console View will show what the Ant build is doing and if there are errors during the build, they will shown in the Console View as well.

  5. If the Ant build was successful then a new directory has been created:

    [Xpert.ivy Designer Installation Directory] / clientlib / customSigned

    This directory now contains the new Rich Dialog client libraries which have been signed with your certificate.

Xpert.ivy Designer will automatically use libraries that are located in this new directory when a Rich Application is started, i.e. the provided client side libraries will automatically be deployed to the client when simulating the next time.

Note

If an error message like jarsigner error: java.lang.RuntimeException: keystore load: DerInputStream.getLength(): lengthTag=109, too big. appears, try setting the property keystore.type accordingly to the type used in the keystore.

Deploying custom signed Rich Dialog client libraries

To use the new custom signed client side extensions with another Xpert.ivy Designer or Server, simply copy the directory

Xpert.ivy Installation Directory / clientlib / customSigned

with all its files to a directory with the same name of another Xpert.ivy Designer or Server Installation Directory.

Restrictions

Warning

Upgrading Xpert.ivy Designer or Server may install a new version of the standard client side libraries. If this is the case you have to resign your custom Rich Dialog client side libraries so that they are compatible with the newer standard client side libraries.

Xpert.ivy Designer will fall back to the standard client side libraries if the custom signed client side library version does not match.

Xpert.ivy Server can only be started if the custom signed client side libraries have exactly the same version as the standard client side libraries.

Warning

All Rich Dialog client libraries located in the clientlib/customSigned directory must be signed by the same certificate. Otherwise the Rich Dialog client will not start because of security restrictions.

Warning

Because of performance optimizations (lazy loading) all client side libraries located in the clientlib/customSigned directory must be signed together. Do not mix new with previously signed libraries, otherwise the lazy loading index will be inconsistent, leading to errors on the client side when executing your application.

Providing custom ULC Widgets

Warning

Development of custom ULC widgets is only permitted with a valid ULC developer license. Licenses and more information about the ULC (Ultra Light Client) framework can be obtained from Canoo.

Licensed ULC developers may contribute their own ULC extensions to an Xpert.ivy installation. This chapter explains how custom ULC widgets can be included by packing them into a Xpert.ivy Rich Dialog Client Extension.

Using custom ULC Widgets

To use a custom ULC Widget the following steps are necessary:

  1. The server side classes of the custom ULC Widget must be located in a Xpert.ivy Project, so that they can be loaded on server side.

  2. The client side classes of the custom ULC Widget must be located in a Xpert.ivy Rich Dialog Client Extension that is installed in the directory clientlib/extensions.

Packing custom ULC Widgets to a Xpert.ivy Rich Dialog Client Extension

To pack custom ULC Widgets to a Xpert.ivy Rich Dialog Client Extension the following steps are necessary:

  1. The client side classes of the custom ULC Widgets must be available in *.jar files.

  2. In the Xpert.ivy Designer Installation Directory / clientlib / extensions directory create a new sub directory with the name of your extension

  3. Create another sub directory called clientLibs inside the previously created extension sub directory. The directory structure now looks like:

    Xpert.ivy Installation Directory / clientlib / extensions / myExtension / clientLibs

    In the example the extension is called myExtension.

  4. Copy the .jar files with the client side classes to the clientLibs sub directory created above.

  5. Now, execute the same steps that are necessary to provide a customer certificate. Instead of using the file Xpert.ivy Designer Installation Directory / clientlib / build.xml use the file Xpert.ivy Designer Installation Directory / clientlib / extensions / build.xml. See section above.

If the Ant build is successful then a new directory was created:

Xpert.ivy Designer Installation Directory / clientlib / extensions / myExtension / signed

It contains the jar files with the custom ULC Widgets signed with your certificate. The build will also create an extension configuration file if no such file is already available:

Xpert.ivy Designer Installation Directory / clientlib / extensions / myExtension / extension.any

It contains information about your Xpert.ivy Rich Dialog Client Extension like title, vendor, homepage, etc.. But also the version of the extension. This version should be increased and the extension rebuilt every time the client side classes of the ULC Widget changes.

Xpert.ivy Designer will automatically use the new created extension for the Rich Dialog clients.

Deploying Xpert.ivy Rich Dialog Client Extensions

To deploy a Xpert.ivy Rich Dialog Client Extension simple copy the extension directory (e.g. myExtension) that contains the extension.any file and the signed directory inclusive the signed jars to the directory clientlib / extensions of another Xpert.ivy Designer or Server Installation.

Note

It is possible to install multiple Xpert.ivy Rich Dialog Client Extensions from different vendors with different certificates.

Restrictions

Warning

All Jar files of one extension must be signed by the same certificate. Otherwise the Rich Dialog client will not start because of security restrictions.

Warning

Because of performance optimizations (lazy loading) all jar files of one extensions must be signed together. Do not mix new with previously signed jar files, otherwise the lazy loading index is inconsistent.

Troubleshooting Java Web Start Cache Problems

Rich Dialog Clients are using a technology called Java Web Start. Java Web Start caches all libraries it downloads from Xpert.ivy. This can cause conflicts if you are developing and do not increase the version of your client side classes if they change or if you changing certificates. The following command line tools can help to solve problems.

Use the following command line to clean the cache of Java Web Start. This will remove all cached libraries from the cache:

javaws -uninstall

Use the following command to inspect the libraries that are cached by Java Web Start:

javaws -viewer