第 18 章 Searching and filtering


The ability to instantly find resources is important to safeguard your cluster. Use Red Hat Advanced Cluster Security for Kubernetes search feature to find relevant resources faster. For example, you can use it to find deployments that are exposed to a newly published CVE or find all deployments that have external network exposure.

18.1. Search syntax

A search query is made up of two parts:

  • An attribute that identifies the resource type you want to search for.
  • A search term that finds the matching resource.

For example, to find all violations in the visa-processor deployment, the search query is Deployment:visa-processor. In this search query, Deployment is the attribute and visa-processor is the search term.

注意

You must select an attribute before you can use search terms. However, in some views, such as the Risk view and the Violations view, Red Hat Advanced Cluster Security for Kubernetes automatically applies the relevant attribute based on the search term you enter.

  • You can use multiple attributes in your query. When you use more than one attribute, the results only include the items that match all attributes.

    Example

    When you search for Namespace:frontend CVE:CVE-2018-11776, it returns only those resources which violate CVE-2018-11776 in the frontend namespace.

  • You can use more than one search term with each attribute. When you use more than one search term, the results include all items that match any of the search terms.

    Example

    If you use the search query Namespace: frontend backend, it returns matching results from the namespace frontend or backend.

  • You can combine multiple attribute and search term pairs.

    Example

    The search query Cluster:production Namespace:frontend CVE:CVE-2018-11776 returns all resources which violate CVE-2018-11776 in the frontend namespace in the production cluster.

  • Search terms can be part of a word, in which case Red Hat Advanced Cluster Security for Kubernetes returns all matching results.

    Example

    If you search for Deployment:def, the results include all deployments starting with def.

  • To explicitly search for a specific term, use the search terms inside quotes.

    Example

    When you search for Deployment:"def", the results only include the deployment def.

  • You can also use regular expressions by using r/ before your search term.

    Example

    When you search for Namespace:r/st.*x, the results include matches from namespace stackrox and stix.

  • Use ! to indicate the search terms that you do not want in results.

    Example

    If you search for Namespace:!stackrox, the results include matches from all namespaces except the stackrox namespace.

  • Use the comparison operators >, <, =, >=, or <= to match a specific value or range of values.

    Example

    If you search for CVSS:>=6, the results include all vulnerabilities with Common Vulnerability Scoring System (CVSS) score 6 or higher.

Red Hat logoGithubredditYoutubeTwitter

学习

尝试、购买和销售

社区

關於紅帽

我们提供强化的解决方案,使企业能够更轻松地跨平台和环境(从核心数据中心到网络边缘)工作。

让开源更具包容性

红帽致力于替换我们的代码、文档和 Web 属性中存在问题的语言。欲了解更多详情,请参阅红帽博客.

关于红帽文档

Legal Notice

Theme

© 2026 Red Hat
返回顶部