@@ -3436,12 +3436,12 @@ public Void call() throws Exception {
34363436 public void testAutoSNIProperty () throws Exception {
34373437 System .out .print ("\t Testing autoSNI property" );
34383438
3439- /* Save original Security property value */
3440- String originalProp = Security .getProperty ("wolfjsse.autoSNI" );
3439+ /* Save original System property value */
3440+ String originalProp = System .getProperty ("wolfjsse.autoSNI" );
34413441
34423442 try {
34433443 /* Test with autoSNI enabled */
3444- Security .setProperty ("wolfjsse.autoSNI" , "true" );
3444+ System .setProperty ("wolfjsse.autoSNI" , "true" );
34453445
34463446 /* Create new CTX */
34473447 this .ctx = tf .createSSLContext ("TLS" , ctxProvider );
@@ -3490,7 +3490,7 @@ public void testAutoSNIProperty() throws Exception {
34903490 }
34913491
34923492 /* Test with autoSNI disabled */
3493- Security .setProperty ("wolfjsse.autoSNI" , "false" );
3493+ System .setProperty ("wolfjsse.autoSNI" , "false" );
34943494
34953495 ss = (SSLServerSocket )ctx .getServerSocketFactory ()
34963496 .createServerSocket (0 );
@@ -3524,9 +3524,9 @@ public void testAutoSNIProperty() throws Exception {
35243524 } finally {
35253525 /* Restore original property value */
35263526 if (originalProp != null ) {
3527- Security .setProperty ("wolfjsse.autoSNI" , originalProp );
3527+ System .setProperty ("wolfjsse.autoSNI" , originalProp );
35283528 } else {
3529- Security .setProperty ("wolfjsse.autoSNI" , "true" );
3529+ System .setProperty ("wolfjsse.autoSNI" , "true" );
35303530 }
35313531 }
35323532 }
0 commit comments