diff --git a/lib/installer-exclude/lcrypto-jdk16-143.jar b/lib/installer-exclude/lcrypto-jdk16-143.jar index 3f5f9ddb5..5b983d367 100755 Binary files a/lib/installer-exclude/lcrypto-jdk16-143.jar and b/lib/installer-exclude/lcrypto-jdk16-143.jar differ diff --git a/lib/installer-exclude/zrtp4j-light.jar b/lib/installer-exclude/zrtp4j-light.jar index 9874ae930..5aa586bdb 100755 Binary files a/lib/installer-exclude/zrtp4j-light.jar and b/lib/installer-exclude/zrtp4j-light.jar differ diff --git a/src/net/java/sip/communicator/impl/media/transform/zrtp/ZRTPTransformEngine.java b/src/net/java/sip/communicator/impl/media/transform/zrtp/ZRTPTransformEngine.java index 005ef0021..e4c6ab372 100644 --- a/src/net/java/sip/communicator/impl/media/transform/zrtp/ZRTPTransformEngine.java +++ b/src/net/java/sip/communicator/impl/media/transform/zrtp/ZRTPTransformEngine.java @@ -348,16 +348,43 @@ public PacketTransformer getRTPTransformer() return this; } + /** + * Engine initialization method. + * Calling this for engine initialization and start it with auto-sensing + * and a given configuration setting. + * + * @param zidFilename The ZID file name + * @param config The configuration data + * @return true if initialization fails, false if succeeds + */ + public boolean initialize(String zidFilename, ZrtpConfigure config) { + return initialize(zidFilename, true, config); + } + + /** + * Engine initialization method. + * Calling this for engine initialization and start it with defined + * auto-sensing and a default configuration setting. + * + * @param zidFilename The ZID file name + * @param autoEnable If true start with auto-sensing mode. + * @return true if initialization fails, false if succeeds + */ + public boolean initialize(String zidFilename, boolean autoEnable) { + return initialize(zidFilename, autoEnable, null); + } + /** * Default engine initialization method. - * Calling this for engine initialization and start it with auto-sensing. + * + * Calling this for engine initialization and start it with auto-sensing + * and default configuration setting. * * @param zidFilename The ZID file name * @return true if initialization fails, false if succeeds */ - public synchronized boolean initialize(String zidFilename) - { - return initialize(zidFilename, true); + public boolean initialize(String zidFilename) { + return initialize(zidFilename, true, null); } /** @@ -370,8 +397,8 @@ public synchronized boolean initialize(String zidFilename) * disable it. * @return true if initialization fails, false if succeeds */ - public synchronized boolean initialize(String zidFilename, - boolean autoEnable) + public synchronized boolean initialize(String zidFilename, + boolean autoEnable, ZrtpConfigure config) { // Get a reference to the FileAccessService BundleContext bc = MediaActivator.getBundleContext(); @@ -429,8 +456,12 @@ public synchronized boolean initialize(String zidFilename, return false; } } + if (config == null) { + config = new ZrtpConfigure(); + config.setStandardConfig(); + } - zrtpEngine = new ZRtp(zf.getZid(), this, clientIdString); + zrtpEngine = new ZRtp(zf.getZid(), this, clientIdString, config); if (timeoutProvider == null) { @@ -948,25 +979,25 @@ public void requestGoSecure() } /** - * Sets the srtps secret data (chapter 3.2.1 in the ZRTP specification) + * Sets the auxilliary secret data * - * @param data The srtps secret data + * @param data The auxilliary secret data */ - public void setSrtpsSecret(byte[] data) + public void setAuxSecret(byte[] data) { if (zrtpEngine != null) - zrtpEngine.setSrtpsSecret(data); + zrtpEngine.setAuxSecret(data); } + /** - * Sets the other secret data (chapter 3.2.1 in the ZRTP specification) + * Sets the PBX secret data * - * @param data The other secret data + * @param data The PBX secret data */ - public void setOtherSecret(byte[] data) - { + public void setPbxSecret(byte[] data) { if (zrtpEngine != null) - zrtpEngine.setOtherSecret(data); + zrtpEngine.setPbxSecret(data); } /**