code: def nonwhitelisted_allowed_principals(self, whitelist=None):
          
  
          if not whitelist:
              return []
  
          nonwhitelisted = []
          for statement in self.statements:
              if statement.non_whitelisted_principals(whitelist) and statement.effect == "Allow":
                  nonwhitelisted.append(statement)
  
          return nonwhitelisted
docs: Find non whitelisted allowed principals.