Skip to content

Commit

Permalink
[WFLY-10735] IIOP: make POA use only SSL connections if cleartext soc…
Browse files Browse the repository at this point in the history
…ket binding is not configured
  • Loading branch information
tadamski committed Aug 10, 2018
1 parent 883115e commit 02258d9
Showing 1 changed file with 6 additions and 6 deletions.
Expand Up @@ -89,7 +89,7 @@ public class CorbaPOAService implements Service<POA> {


private final ThreadPolicyValue threadPolicyValue; private final ThreadPolicyValue threadPolicyValue;


private final boolean sslRequired; private final boolean sslOnly;


/** /**
* <p> * <p>
Expand All @@ -101,8 +101,8 @@ public class CorbaPOAService implements Service<POA> {
* @param bindingName the JNDI context name where the created {@code POA} will be bound. If null, the JNDI binding * @param bindingName the JNDI context name where the created {@code POA} will be bound. If null, the JNDI binding
* won't be performed. * won't be performed.
*/ */
public CorbaPOAService(String poaName, String bindingName, boolean sslRequired) { public CorbaPOAService(String poaName, String bindingName, boolean sslOnly) {
this(poaName, bindingName, sslRequired, null, null, null, null, null, null, null); this(poaName, bindingName, sslOnly, null, null, null, null, null, null, null);
} }


/** /**
Expand All @@ -128,13 +128,13 @@ public CorbaPOAService(String poaName, String bindingName, boolean sslRequired)
* @param threadPolicyValue the {@code ThreadPolicyValue} that will be associated with the created {@code POA}. Can * @param threadPolicyValue the {@code ThreadPolicyValue} that will be associated with the created {@code POA}. Can
* be null. * be null.
*/ */
public CorbaPOAService(String poaName, String bindingName, boolean sslRequired, IdAssignmentPolicyValue idAssignmentPolicyValue, public CorbaPOAService(String poaName, String bindingName, boolean sslOnly, IdAssignmentPolicyValue idAssignmentPolicyValue,
IdUniquenessPolicyValue idUniquenessPolicyValue, ImplicitActivationPolicyValue implicitActivationPolicyValue, IdUniquenessPolicyValue idUniquenessPolicyValue, ImplicitActivationPolicyValue implicitActivationPolicyValue,
LifespanPolicyValue lifespanPolicyValue, RequestProcessingPolicyValue requestProcessingPolicyValue, LifespanPolicyValue lifespanPolicyValue, RequestProcessingPolicyValue requestProcessingPolicyValue,
ServantRetentionPolicyValue servantRetentionPolicyValue, ThreadPolicyValue threadPolicyValue) { ServantRetentionPolicyValue servantRetentionPolicyValue, ThreadPolicyValue threadPolicyValue) {
this.poaName = poaName; this.poaName = poaName;
this.bindingName = bindingName; this.bindingName = bindingName;
this.sslRequired = sslRequired; this.sslOnly = sslOnly;
this.idAssignmentPolicyValue = idAssignmentPolicyValue; this.idAssignmentPolicyValue = idAssignmentPolicyValue;
this.idUniquenessPolicyValue = idUniquenessPolicyValue; this.idUniquenessPolicyValue = idUniquenessPolicyValue;
this.implicitActivationPolicyValue = implicitActivationPolicyValue; this.implicitActivationPolicyValue = implicitActivationPolicyValue;
Expand Down Expand Up @@ -222,7 +222,7 @@ public Injector<POA> getParentPOAInjector() {
*/ */
private Policy[] createPolicies(POA poa) { private Policy[] createPolicies(POA poa) {
List<Policy> policies = new ArrayList<Policy>(); List<Policy> policies = new ArrayList<Policy>();
if(this.sslRequired) if(this.sslOnly)
policies.add(ZeroPortPolicy.getPolicy()); policies.add(ZeroPortPolicy.getPolicy());
if (this.idAssignmentPolicyValue != null) if (this.idAssignmentPolicyValue != null)
policies.add(poa.create_id_assignment_policy(this.idAssignmentPolicyValue)); policies.add(poa.create_id_assignment_policy(this.idAssignmentPolicyValue));
Expand Down

0 comments on commit 02258d9

Please sign in to comment.