code: private boolean setUnauthenticatedSubjectIfNeeded(Subject invokedSubject, Subject receivedSubject) {
          if ((invokedSubject == null) && (receivedSubject == null)) {
              // create the unauthenticated subject and set as the invocation subject
              subjectManager.setInvocationSubject(unauthenticatedSubjectServiceRef.getService().getUnauthenticatedSubject());
              return true;
          }
          return false;
      }
docs: If invoked and received cred are null, then set the unauthenticated subject.
  
  @param invokedSubject
  @param receivedSubject
  @return {@code true} if the unauthenticated subject was set, {@code false} otherwise.