diff options
Diffstat (limited to 'java/test/IceSSL/configuration/ServerI.java')
-rw-r--r-- | java/test/IceSSL/configuration/ServerI.java | 72 |
1 files changed, 36 insertions, 36 deletions
diff --git a/java/test/IceSSL/configuration/ServerI.java b/java/test/IceSSL/configuration/ServerI.java index 40bf174f3d5..b796971e131 100644 --- a/java/test/IceSSL/configuration/ServerI.java +++ b/java/test/IceSSL/configuration/ServerI.java @@ -11,67 +11,67 @@ class ServerI extends Test._ServerDisp { ServerI(Ice.Communicator communicator) { - _communicator = communicator; + _communicator = communicator; } public void noCert(Ice.Current current) { - try - { - IceSSL.ConnectionInfo info = IceSSL.Util.getConnectionInfo(current.con); - test(info.certs == null); - } - catch(IceSSL.ConnectionInvalidException ex) - { - test(false); - } + try + { + IceSSL.ConnectionInfo info = IceSSL.Util.getConnectionInfo(current.con); + test(info.certs == null); + } + catch(IceSSL.ConnectionInvalidException ex) + { + test(false); + } } public void checkCert(String subjectDN, String issuerDN, Ice.Current current) { - try - { - IceSSL.ConnectionInfo info = IceSSL.Util.getConnectionInfo(current.con); - java.security.cert.X509Certificate cert = (java.security.cert.X509Certificate)info.certs[0]; - test(info.certs.length == 2 && - cert.getSubjectDN().toString().equals(subjectDN) && - cert.getIssuerDN().toString().equals(issuerDN)); - } - catch(IceSSL.ConnectionInvalidException ex) - { - test(false); - } + try + { + IceSSL.ConnectionInfo info = IceSSL.Util.getConnectionInfo(current.con); + java.security.cert.X509Certificate cert = (java.security.cert.X509Certificate)info.certs[0]; + test(info.certs.length == 2 && + cert.getSubjectDN().toString().equals(subjectDN) && + cert.getIssuerDN().toString().equals(issuerDN)); + } + catch(IceSSL.ConnectionInvalidException ex) + { + test(false); + } } public void checkCipher(String cipher, Ice.Current current) { - try - { - IceSSL.ConnectionInfo info = IceSSL.Util.getConnectionInfo(current.con); - test(info.cipher.indexOf(cipher) >= 0); - } - catch(IceSSL.ConnectionInvalidException ex) - { - test(false); - } + try + { + IceSSL.ConnectionInfo info = IceSSL.Util.getConnectionInfo(current.con); + test(info.cipher.indexOf(cipher) >= 0); + } + catch(IceSSL.ConnectionInvalidException ex) + { + test(false); + } } public void destroy() { - _communicator.destroy(); + _communicator.destroy(); } private static void test(boolean b) { - if(!b) - { - throw new RuntimeException(); - } + if(!b) + { + throw new RuntimeException(); + } } private Ice.Communicator _communicator; |