Description of problem: Installer must escape '\' used as path delimiter on windows for all post-install actions, because '\' is omitted. Version-Release number of selected component (if applicable): EAP 6.2.0.ER7 How reproducible: Always Steps to Reproduce: 1. Run gui installer. Use default options to get onto Post-intall configuration screen. 2. Choose to "Enable SSL security". 3. On SSL screen enter some password and location of keystore (eg. W:\pkremens\installer\ssl.keystore) 4. Finish the installation and observe server configuration files (eg.standalone.xml) Actual results: command in batch: /core-service=management/security-realm=ManagementRealm/server-identity=ssl:add(keystore-path=W:\pkremens\installer\ssl.keystore,keystore-password="password") content of standalone.xml file: <ssl> <keystore keystore-password="password" path="W:pkremensinstallerssl.keystore"/> </ssl> Server failt to start. Expected results: command in batch: /core-service=management/security-realm=ManagementRealm/server-identity=ssl:add(keystore-path=W:\\pkremens\\installer\\ssl.keystore,keystore-password="password") content of standalone.xml file: <ssl> <keystore keystore-password="password" path="W:pkremens\\installer\\ssl.keystore"/> </ssl> Additional info: - see BZ1024381 - windows paths with '\' as delimiter are not used correctly. '\' is omited - we should fix this in all post-install actions entering some path (Install password vault, Enable SSL security, and Add a security-domain)
I've added the necessary extra escape characters to the Installer's CLI commands so that windows paths are inserted into the batch command and the config xmls with the proper escaped backslashes like so: "C:\\fcanas\\vault\\keystore.jks" Note: The above works, but then final Installationlog file will show the command with extra escape characters, which unfortunately means that it is no longer reproducible by the user int he CLI (unless he removes the extra \'s). This is due to the way the CLI returns info (through the stdout rather then as a return value) and how we capture that info in order to log it. Will try to find a way to display the correct path in the log, but it may require some more modifications to izpack that I didn't want to make so close to the release. http://git.app.eng.bos.redhat.com/jbossas-installer.git/commit/?h=eap-6.2&id=6f2523e64391df17316ce30035d5b58a4b10830d
I see things like: "W:\\\\\\\\tmp\\\\\\\\pkremens\\\\\\\\ssl.keystore" in xml files and CLI log. Although it is working, we should definitely spend some time trying to find cleaner solution for 6.3 (agree with avoiding more complicated modifications to izpack now). Please fix also commands using Keystore and Truststore URL during JSSE configuration, the rest seems to be fine.
Please note that all of this is a side effect of the JBoss CLI API, unfortunately.
I have added similar path escaping to the JSSE keystore and truststore URL elements. Note that the JSSE properties are parsed differently by the CLI, so the actual number of escape characters required in the installer is halved. This has the unfortunate side effect of creating more inconsistency in the Installationlog file: For SSL that path appears like this: c:\\\\\\\\myfolder\\\\\\\\myfile.jks For JSSE the path appears like this: c:\\\\myfolder\\\\myfile.jks Even though the path appears like this in the actual xmls for *both*: c:\\myfolder\\myfile.jks For 6.3 we'll come up with some other workaround to replace the paths shown in the logs with the third version so it's consistent with the xml files.
One more note: Made a few changes in order to preserve spaces in the paths: (ie. c:\my folder\keystore.jks) This again changes what we see in the Installationlogs, but it is now more consistent. All paths will have the same number of escape chars.
I am aware that CLI is villain here, we were complaining about this (BZ1024381), but we didn't succeeded so far :/.
There is one more thing that need to be fixed. You've accidentally removed double quotes from vault configuration command on KEYSTORE_URL and KEYSTORE_FILE_DIR attribute values. Command looks like: ...("KEYSTORE_URL" => /home/pkremens/jbossqe-eap-tests-installer/src/test/resources/vault/vault.keystore), ... ("ENC_FILE_DIR" => /home/pkremens/jbossqe-eap-tests-installer/target/eap/)]) This is throwing Vault Reader Exception -> installation fails http://git.app.eng.bos.redhat.com/jbossas-installer.git/commit/?h=eap-6.2&id=6f2523e64391df17316ce30035d5b58a4b10830d
I actually re-added the quotes yesterday (see comment 5) because the CLI wasn't preserving spaces in the path otherwise. The vault installation succeeds with the command: /core-service=vault:add(vault-options=[("KEYSTORE_URL" => "/home/yyz/fcanas/vault/keystore.jks"), ("KEYSTORE_PASSWORD" => "MASK-1KXfR4wmalv87Emab3wgdL"), ("KEYSTORE_ALIAS" => "myvault"), ("SALT" => "12345678"), ("ITERATION_COUNT" => "44"), ("ENC_FILE_DIR" => "/home/yyz/fcanas/EAP-6.2.0/")]) The batch executed successfully {"outcome" => "success"} This update will be in the re-spin and/or CR3.
Verified on EAP 6.2.0.CR3 installer.