cisco.ise.rest_id_store_info 模块 – 用于 REST Id 存储的信息模块

注意

此模块是 cisco.ise 集合 (版本 2.9.6) 的一部分。

如果您使用的是 ansible 包,您可能已经安装了此集合。它不包含在 ansible-core 中。要检查它是否已安装,请运行 ansible-galaxy collection list

要安装它,请使用:ansible-galaxy collection install cisco.ise。您需要进一步的要求才能使用此模块,有关详细信息,请参阅 要求

要在 playbook 中使用它,请指定:cisco.ise.rest_id_store_info

cisco.ise 1.0.0 中的新增功能

概要

  • 获取所有 REST Id 存储。

  • 按 id 获取 REST Id 存储。

  • 按名称获取 REST Id 存储。

  • 此 API 允许客户端按 ID 获取 REST ID 存储。

  • 此 API 允许客户端按名称获取 REST ID 存储。

  • 此 API 允许客户端获取所有 REST ID 存储。

注意

此模块具有相应的 操作插件

要求

执行此模块的主机需要满足以下要求。

  • ciscoisesdk >= 2.2.3

  • python >= 3.5

参数

参数

注释

filter

列表 / 元素=字符串

筛选查询参数。**简单筛选**应该可以通过筛选查询字符串参数获得。筛选的结构是字段运算符和值的三元组,用点分隔。可以发送多个筛选器。所有筛选条件通用的逻辑运算符默认为 AND,可以通过使用 “filterType=or” 查询字符串参数来更改。

每个资源数据模型描述都应指定属性是否为筛选字段。

“EQ” 运算符描述“等于”。

“NEQ” 运算符描述“不等于”。

“GT” 运算符描述“大于”。

“LT” 运算符描述“小于”。

“STARTSW” 运算符描述“以…开头”。

“NSTARTSW” 运算符描述“不以…开头”。

“ENDSW” 运算符描述“以…结尾”。

“NENDSW” 运算符描述“不以…结尾”。

“CONTAINS” 运算符描述“包含”。

“NCONTAINS” 运算符描述“不包含”。

filterType

字符串

FilterType 查询参数。所有筛选条件通用的逻辑运算符默认为 AND,可以使用此参数进行更改。

id

字符串

Id 路径参数。

ise_debug

布尔值

用于启用调试的 Identity Services Engine SDK 的标志。

选项

  • false ← (默认)

  • true

ise_hostname

字符串 / 必填

Identity Services Engine 主机名。

ise_password

字符串 / 必填

用于身份验证的 Identity Services Engine 密码。

ise_single_request_timeout

整数

在 cisco.ise 3.0.0 中添加

RESTful HTTP 请求的超时时间(以秒为单位)。

默认值: 60

ise_username

字符串 / 必填

用于身份验证的 Identity Services Engine 用户名。

ise_uses_api_gateway

布尔值

在 cisco.ise 1.1.0 中添加

通知 SDK 是否使用 Identity Services Engine 的 API 网关发送请求的标志。

如果为 true,则它使用 ISE 的 API 网关并将请求发送到 https://{{ise_hostname}}。

如果为 false,则它会将请求发送到 https://{{ise_hostname}}:{{port}},其中端口值取决于所使用的服务(ERS、Mnt、UI、PxGrid)。

选项

  • false

  • true ← (默认)

ise_uses_csrf_token

布尔值

在 cisco.ise 3.0.0 中添加

通知 SDK 是否将 CSRF 令牌发送到 ISE 的 ERS API 的标志。

如果为 True,则 SDK 会假定您的 ISE CSRF 检查已启用。

如果为 True,则假定您需要 SDK 为您自动管理 CSRF 令牌。

选项

  • false ← (默认)

  • true

ise_verify

布尔值

启用或禁用 SSL 证书验证的标志。

选项

  • false

  • true ← (默认)

ise_version

字符串

通知 SDK 使用哪个版本的 Identity Services Engine。

默认值: "3.1_Patch_1"

ise_wait_on_rate_limit

布尔值

用于启用自动速率限制处理的 Identity Services Engine SDK 的标志。

选项

  • false

  • true ← (默认)

name

字符串

名称路径参数。

page

整数

Page 查询参数。页码。

size

整数

Size 查询参数。每页返回的对象数。

sortasc

字符串

Sortasc 查询参数。升序排序。

sortdsc

字符串

Sortdsc 查询参数。降序排序。

注意

注意

  • 使用的 SDK 方法为 restid_store.RestidStore.get_rest_id_store_by_id、restid_store.RestidStore.get_rest_id_store_by_name、restid_store.RestidStore.get_rest_id_store_generator,

  • 使用的路径为 get /ers/config/restidstore、get /ers/config/restidstore/name/{name}、get /ers/config/restidstore/{id},

  • 支持 check_mode

  • 该插件在控制节点上运行,不使用任何 ansible 连接插件,而是使用 Cisco ISE SDK 中的嵌入式连接管理器

  • 以 ise_ 开头的参数由 Cisco ISE Python SDK 用于建立连接

示例

- name: Get all REST Id Store
  cisco.ise.rest_id_store_info:
    ise_hostname: "{{ise_hostname}}"
    ise_username: "{{ise_username}}"
    ise_password: "{{ise_password}}"
    ise_verify: "{{ise_verify}}"
    page: 1
    size: 20
    sortasc: string
    sortdsc: string
    filter: []
    filterType: AND
  register: result

- name: Get REST Id Store by id
  cisco.ise.rest_id_store_info:
    ise_hostname: "{{ise_hostname}}"
    ise_username: "{{ise_username}}"
    ise_password: "{{ise_password}}"
    ise_verify: "{{ise_verify}}"
    id: string
  register: result

- name: Get REST Id Store by name
  cisco.ise.rest_id_store_info:
    ise_hostname: "{{ise_hostname}}"
    ise_username: "{{ise_username}}"
    ise_password: "{{ise_password}}"
    ise_verify: "{{ise_verify}}"
    name: string
  register: result

返回值

常见返回值记录在此处,以下是此模块特有的字段

描述

ise_response

字典

一个字典或列表,其中包含 Cisco ISE Python SDK 返回的响应

返回: 总是

示例: {"description": "字符串", "ersRestIDStoreAttributes": {"headers": [{"key": "字符串", "value": "字符串"}], "predefined": "字符串", "rootUrl": "字符串", "usernameSuffix": "字符串"}, "id": "字符串", "link": {"href": "字符串", "rel": "字符串", "type": "字符串"}, "name": "字符串"}

ise_responses

列表 / 元素=字典

在 cisco.ise 1.1.0 中添加

一个字典或列表,其中包含 Cisco ISE Python SDK 返回的响应

返回: 总是

示例: "[\n  {\n    \"id\": \"字符串\",\n    \"name\": \"字符串\",\n    \"description\": \"字符串\",\n    \"ersRestIDStoreAttributes\": {\n      \"usernameSuffix\": \"字符串\",\n      \"rootUrl\": \"字符串\",\n      \"predefined\": \"字符串\",\n      \"headers\": [\n        {\n          \"key\": \"字符串\",\n          \"value\": \"字符串\"\n        }\n      ]\n    },\n    \"link\": {\n      \"rel\": \"字符串\",\n      \"href\": \"字符串\",\n      \"type\": \"字符串\"\n    }\n  }\n]\n"

作者

  • Rafael Campos (@racampos)