client certificate invalid keystore format

To access a webservice I need to add a certificate (I get the dialog above in the screenshot).

I have red the documentation on gatling.io and searched this forum, concluding that I need to add this certificate to my computer and then refer it from the gatling.conf togheter with the password like this:

`

 }
  keyStore {
    #type = ""      # Type of SSLContext's KeyManagers store
    file = "/Users/myname/Downloads/Sa_sslMun[KMD2015]_cli.p12"      # Location of SSLContext's KeyManagers store
    password = "I8S3K2SAJHV7SGXMFHNT"  # Password for SSLContext's KeyManagers store
    #algorithm = "" # Algorithm used SSLContext's KeyManagers store
  }
}

`

However, when running the simulation, I get an error:

Simulation magnus.FileUploadSimulation started... Exception in thread "main" java.io.IOException: Invalid keystore format at sun.security.provider.JavaKeyStore.engineLoad(JavaKeyStore.java:650) at sun.security.provider.JavaKeyStore$JKS.engineLoad(JavaKeyStore.java:55) at java.security.KeyStore.load(KeyStore.java:1433) at io.gatling.http.util.SslHelper$$anonfun$newKeyManagers$1.apply(SslHelper.scala:53) at io.gatling.http.util.SslHelper$$anonfun$newKeyManagers$1.apply(SslHelper.scala:50)

Do I need to type in the keystore “type” as well? Given the certificates name is “Sa_sslMun[KMD2015]_cli.p12” what should the type be?

Thanks!


Hi Magnus

This is my config

ssl {
  keyStore {
    type = "pkcs12"
      file = "/etc/ssl/dev-cert.p12"
      password = “password1”
  }
  trustStore {
    type = ""
      file = "/etc/ssl/jssecacerts"
      password = “password2”
  }
}

I know there was an issue with the reading of the cert config in earlier versions of the 2.2.0-SNAPSHOT which has now been fixed.

sbt update

Aidy