Use default server mode in SSLEngineTemplate. Rename the test.

This commit is contained in:
Artur Barashev 2026-06-11 08:32:34 -04:00
parent d4dba5e24f
commit ef273ab937
2 changed files with 4 additions and 11 deletions

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2003, 2025, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2003, 2026, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -139,7 +139,6 @@ public class SSLEngineTemplate extends SSLContextTemplate {
* Configure the server side engine.
*/
protected SSLEngine configureServerEngine(SSLEngine serverEngine) {
serverEngine.setUseClientMode(false);
serverEngine.setNeedClientAuth(true);
// Get/set parameters if needed

View File

@ -21,24 +21,18 @@
* questions.
*/
//
// SunJSSE does not support dynamic system properties, no way to re-use
// system properties in samevm/agentvm mode.
//
/*
* @test
* @bug 4980882 8207250 8237474 8386159
* @summary SSLEngine's client/server mode can't be changed once
* handshaking has begun
* @library /javax/net/ssl/templates
* @run main/othervm EngineEnforceUseClientMode
* @author Brad R. Wetmore
*/
import javax.net.ssl.*;
public class EngineEnforceUseClientMode extends SSLEngineTemplate {
public class EngineTestClientMode extends SSLEngineTemplate {
private static boolean debug = Boolean.getBoolean("test.debug");
@ -161,7 +155,7 @@ public class EngineEnforceUseClientMode extends SSLEngineTemplate {
public static void main(String args[]) throws Exception {
EngineEnforceUseClientMode test = new EngineEnforceUseClientMode();
EngineTestClientMode test = new EngineTestClientMode();
test.createAdditionalSSLEngines();
test.runTest();
@ -174,7 +168,7 @@ public class EngineEnforceUseClientMode extends SSLEngineTemplate {
* **********************************************************
*/
public EngineEnforceUseClientMode() throws Exception {
public EngineTestClientMode() throws Exception {
super();
}