docs: private ConsumerSessionImpl findConsumerSession(long id) throws SINotAuthorizedException
      {
          if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
              SibTr.entry(tc, "findConsumerSession", Long.valueOf(id));
  
          ConsumerSessionImpl sessionInternal = _messageProcessor.getConsumer(id);
  
          if (sessionInternal != null)
          {
              // Check if this is the right Consumer.
              if (sessionInternal.getIdInternal() == id)
              {
                  if (sessionInternal.getConnectionInternal() != this)
                  {
                      // Defect 346001. Check that the subjects match, but only if bus security is enabled
                      if (_isBusSecure)
                      {
                          // get the bus security interface in order to make audit calls
                          AuthUtils sibAuthUtils = _messageProcessor.getAuthorisationUtils();
  
                          // get the name of the destination the consumer is connected to (used for auditing)
                          String destinationName = sessionInternal.getDestinationAddress().getDestinationName();
  
                          // Check that the subjects match.
                          Subject connsSubject = ((ConnectionImpl) sessionInternal.getConnectionInternal()).getSecuritySubject();
  
                          if (connsSubject != null)
                          {
                              boolean subjectsDiffer = false;
  
                              // Check null subject
                              if (_subject == null)
                              {
                                  subjectsDiffer = true;
                                  if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
                                      SibTr.debug(tc, "Subjects differ - base subject is null");
                              }
  
                              // Check for privileged SIBServerSubject
                              if (!subjectsDiffer && isSIBServerSubject())
                              {
                                  // Connected user is privileged SIBServerSubject, check that the
                                  // bifurcated session has same degree of privilege
                                  if (!_messageProcessor.getAuthorisationUtils().isSIBServerSubject(connsSubject))
                                  {
                                      subjectsDiffer = true;
                                      if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
                                          SibTr.debug(tc, "Subjects differ - base subject is privileged");
                                  }
                              }
  
                              if (!subjectsDiffer)
                              {
                                  // Compare the resolved string userids
                                  String resolvedConnUserid = _messageProcessor.getAuthorisationUtils().getUserName(connsSubject);
                                  String resolvedUserid = _messageProcessor.getAuthorisationUtils().getUserName(_subject);
  
                                  // NB Sib.security, ensures that resolved Userids are non-null                                 
                                  if (!resolvedConnUserid.equals(resolvedUserid))
                                  {
                                      subjectsDiffer = true;
                                      if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
                                          SibTr.debug(tc, "Subjects differ by userid - base " +
                                                          resolvedUserid + ", connected " +
                                                          resolvedConnUserid);
                                  }
                              }
  
                              // Throw exception
                              if (subjectsDiffer)
                              {
                                  // audit the authorization failure
                                  sibAuthUtils.createBifurcatedConsumerSessionAuthorizationFailed(connsSubject, destinationName, id);
  
                                  if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
                                      SibTr.exit(tc, "findConsumerSession", "SINotAuthorizedException - not same");
                                  throw new SINotAuthorizedException(
                                                  nls.getFormattedMessage(
                                                                          "CREATE_BIFURCATED_CONSUMER_ERROR_CWSIP0094",
                                                                          new Object[] { Long.valueOf(id),
                                                                                        _messageProcessor.getMessagingEngineName() },
                                                                          null));
                              }
                          }
                          else if (_subject != null)
                          {
                              // audit the authorization failure  
                              sibAuthUtils.createBifurcatedConsumerSessionAuthorizationFailed(connsSubject, destinationName, id);
  
                              if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
                                  SibTr.exit(tc, "findConsumerSession", "SINotAuthorizedException - null");
  
                              throw new SINotAuthorizedException(
                                              nls.getFormattedMessage(
                                                                      "CREATE_BIFURCATED_CONSUMER_ERROR_CWSIP0094",
                                                                      new Object[] { Long.valueOf(id),
                                                                                    _messageProcessor.getMessagingEngineName() },
                                                                      null));
                          }
                      }
                  }
              }
          }
  
          if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
              SibTr.exit(tc, "findConsumerSession", sessionInternal);
          return sessionInternal;
      }