cisco.ise.byod_portal 模块 – BYOD 门户的资源模块

注意

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

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

要安装它,请使用:ansible-galaxy collection install cisco.ise。您需要其他要求才能使用此模块,请参阅 要求 获取详细信息。

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

cisco.ise 1.0.0 中的新增功能

概要

  • 管理 BYOD 门户资源的创建、更新和删除操作。

  • 此 API 创建一个 BYOD 门户。

  • 此 API 通过 ID 删除 BYOD 门户。

  • 此 API 允许客户端通过 ID 更新 BYOD 门户。

注意

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

要求

以下是执行此模块的主机所需的条件。

  • ciscoisesdk >= 2.2.3

  • python >= 3.5

参数

参数

注释

customizations

字典

定义 BYOD 可用的所有门户自定义设置。

globalCustomizations

字典

表示门户全局自定义设置。

backgroundImage

字典

BYOD 门户的背景图像。

data

字符串

表示为图像字节数组的 base64 编码字符串。

bannerImage

字典

BYOD 门户的横幅图像。

data

字符串

表示为图像字节数组的 base64 编码字符串。

bannerTitle

字符串

BYOD 门户的横幅标题。

contactText

字符串

BYOD 门户的联系文本。

desktopLogoImage

字典

BYOD 门户的桌面Logo图像。

data

字符串

表示为图像字节数组的 base64 编码字符串。

footerElement

字符串

BYOD 门户的页脚元素。

mobileLogoImage

字典

BYOD 门户的移动Logo图像。

data

字符串

表示为图像字节数组的 base64 编码字符串。

language

字典

此属性仅支持读取操作,它允许以英文显示自定义设置。不支持其他语言。

viewLanguage

字符串

BYOD 门户的查看语言。

pageCustomizations

字典

将整个页面自定义设置表示为一个大型字典。

data

列表 / 元素=字典

字典将在此处作为键值对显示。

key

字符串

BYOD 门户的键。

value

字符串

BYOD 门户的值。

portalTheme

字典

定义门户主题的配置。

id

字符串

门户主题的唯一内部标识符。

name

字符串

门户主题的系统或用户分配的名称。

themeData

字符串

一个 CSS 文件,表示为 Base64 编码的字节数组。

portalTweakSettings

字典

调整设置是对为门户选择的门户主题的自定义。更改门户主题选择后,将覆盖调整设置以匹配主题中的值。用户随后可以更改调整设置。

bannerColor

字符串

十六进制颜色值。

bannerTextColor

字符串

BYOD 门户的横幅文本颜色。

pageBackgroundColor

字符串

BYOD 门户的页面背景颜色。

pageLabelAndTextColor

字符串

BYOD 门户的页面标签和文本颜色。

description

字符串

BYOD 门户的描述。

id

字符串

资源 UUID,更新时必填。

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

字符串

资源名称。

portalTestUrl

字符串

用于显示此门户测试页面的 URL。

portalType

字符串

允许的值 - BYOD、- HOTSPOTGUEST、- MYDEVICE、- SELFREGGUEST、- SPONSOR、- SPONSOREDGUEST。

settings

字典

定义 BYOD 可用的所有设置组。

byodSettings

字典

BYOD 设备欢迎、注册和成功步骤的配置。

byodRegistrationSettings

字典

BYOD门户的byodRegistrationSettings。

endPointIdentityGroupId

字符串

BYOD门户的endPointIdentityGroupId。

showDeviceID

布尔值

ShowDeviceID标志。

选项

  • false

  • true

byodRegistrationSuccessSettings

字典

BYOD门户的byodRegistrationSuccessSettings。

redirectUrl

字符串

重定向的目标URL,在successRedirect = URL时使用。

successRedirect

字符串

身份验证成功后设备应重定向到的位置。允许的值。

byodWelcomeSettings

字典

BYOD端点欢迎步骤配置的配置。

aupDisplay

字符串

AUP的显示方式,可在页面上显示或作为链接显示。仅在includeAup = true时有效。允许的值 - ONPAGE,- ASLINK。

enableBYOD

布尔值

EnableBYOD标志。

选项

  • false

  • true

enableGuestAccess

布尔值

EnableGuestAccess标志。

选项

  • false

  • true

includeAup

布尔值

IncludeAup标志。

选项

  • false

  • true

requireAupAcceptance

布尔值

RequireAupAcceptance标志。

选项

  • false

  • true

requireMDM

布尔值

RequireMDM标志。

选项

  • false

  • true

requireScrolling

布尔值

要求BYOD设备滚动到AUP底部,仅在includeAup = true时有效。

选项

  • false

  • true

portalSettings

字典

门户的端口、接口、证书和其他基本设置。

allowedInterfaces

列表 / 元素=字符串

门户可在其上访问的接口。允许的值 - eth0,- eth1,- eth2,- eth3,- eth4,- eth5,- bond0,- bond1,- bond2。

alwaysUsedLanguage

字符串

在displayLang = ALWAYSUSE时使用。

certificateGroupTag

字符串

将用于门户的x.509服务器证书的逻辑名称。

displayLang

字符串

允许的值 - USEBROWSERLOCALE,- ALWAYSUSE。

endpointIdentityGroup

字符串

将添加用户设备的端点身份组的唯一ID。仅在热点门户中使用。

fallbackLanguage

字符串

在displayLang = USEBROWSERLOCALE时使用。

httpsPort

整数

允许的接口将监听的端口号。范围从8000到8999。

supportInfoSettings

字典

BYOD门户的supportInfoSettings。

defaultEmptyFieldValue

字符串

为空字段显示的默认值。仅在emptyFieldDisplay = DISPLAYWITHDEFAULTVALUE时有效。

emptyFieldDisplay

字符串

指定如何在支持信息页面上处理空字段。允许的值 - HIDE,- DISPLAYWITHNOVALUE,- DISPLAYWITHDEFAULTVALUE。

includeBrowserUserAgent

布尔值

IncludeBrowserUserAgent标志。

选项

  • false

  • true

includeFailureCode

布尔值

IncludeFailureCode标志。

选项

  • false

  • true

includeIpAddress

布尔值

IncludeIpAddress标志。

选项

  • false

  • true

includeMacAddr

布尔值

IncludeMacAddr标志。

选项

  • false

  • true

includePolicyServer

布尔值

IncludePolicyServer标志。

选项

  • false

  • true

includeSupportInfoPage

布尔值

IncludeSupportInfoPage标志。

选项

  • false

  • true

注释

注意

  • 使用的SDK方法为byod_portal.ByodPortal.create_byod_portal、byod_portal.ByodPortal.delete_byod_portal_by_id、byod_portal.ByodPortal.update_byod_portal_by_id,

  • 使用的路径为post /ers/config/byodportal、delete /ers/config/byodportal/{id}、put /ers/config/byodportal/{id},

  • 不支持check_mode

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

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

示例

- name: Update by id
  cisco.ise.byod_portal:
    ise_hostname: "{{ise_hostname}}"
    ise_username: "{{ise_username}}"
    ise_password: "{{ise_password}}"
    ise_verify: "{{ise_verify}}"
    state: present
    customizations:
      globalCustomizations:
        backgroundImage:
          data: string
        bannerImage:
          data: string
        bannerTitle: string
        contactText: string
        desktopLogoImage:
          data: string
        footerElement: string
        mobileLogoImage:
          data: string
      language:
        viewLanguage: string
      pageCustomizations:
        data:
        - key: string
          value: string
      portalTheme:
        id: string
        name: string
        themeData: string
      portalTweakSettings:
        bannerColor: string
        bannerTextColor: string
        pageBackgroundColor: string
        pageLabelAndTextColor: string
    description: string
    id: string
    name: string
    portalTestUrl: string
    portalType: string
    settings:
      byodSettings:
        byodRegistrationSettings:
          endPointIdentityGroupId: string
          showDeviceID: true
        byodRegistrationSuccessSettings:
          redirectUrl: string
          successRedirect: string
        byodWelcomeSettings:
          aupDisplay: string
          enableBYOD: true
          enableGuestAccess: true
          includeAup: true
          requireAupAcceptance: true
          requireMDM: true
          requireScrolling: true
      portalSettings:
        allowedInterfaces:
        - string
        alwaysUsedLanguage: string
        certificateGroupTag: string
        displayLang: string
        endpointIdentityGroup: string
        fallbackLanguage: string
        httpsPort: 0
      supportInfoSettings:
        defaultEmptyFieldValue: string
        emptyFieldDisplay: string
        includeBrowserUserAgent: true
        includeFailureCode: true
        includeIpAddress: true
        includeMacAddr: true
        includePolicyServer: true
        includeSupportInfoPage: true

- name: Delete by id
  cisco.ise.byod_portal:
    ise_hostname: "{{ise_hostname}}"
    ise_username: "{{ise_username}}"
    ise_password: "{{ise_password}}"
    ise_verify: "{{ise_verify}}"
    state: absent
    id: string

- name: Create
  cisco.ise.byod_portal:
    ise_hostname: "{{ise_hostname}}"
    ise_username: "{{ise_username}}"
    ise_password: "{{ise_password}}"
    ise_verify: "{{ise_verify}}"
    state: present
    customizations:
      globalCustomizations:
        backgroundImage:
          data: string
        bannerImage:
          data: string
        bannerTitle: string
        contactText: string
        desktopLogoImage:
          data: string
        footerElement: string
        mobileLogoImage:
          data: string
      language:
        viewLanguage: string
      pageCustomizations:
        data:
        - key: string
          value: string
      portalTheme:
        id: string
        name: string
        themeData: string
      portalTweakSettings:
        bannerColor: string
        bannerTextColor: string
        pageBackgroundColor: string
        pageLabelAndTextColor: string
    description: string
    id: string
    name: string
    portalTestUrl: string
    portalType: string
    settings:
      byodSettings:
        byodRegistrationSettings:
          endPointIdentityGroupId: string
          showDeviceID: true
        byodRegistrationSuccessSettings:
          redirectUrl: string
          successRedirect: string
        byodWelcomeSettings:
          aupDisplay: string
          enableBYOD: true
          enableGuestAccess: true
          includeAup: true
          requireAupAcceptance: true
          requireMDM: true
          requireScrolling: true
      portalSettings:
        allowedInterfaces:
        - string
        alwaysUsedLanguage: string
        certificateGroupTag: string
        displayLang: string
        endpointIdentityGroup: string
        fallbackLanguage: string
        httpsPort: 0
      supportInfoSettings:
        defaultEmptyFieldValue: string
        emptyFieldDisplay: string
        includeBrowserUserAgent: true
        includeFailureCode: true
        includeIpAddress: true
        includeMacAddr: true
        includePolicyServer: true
        includeSupportInfoPage: true

返回值

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

描述

ise_response

字典

包含Cisco ISE Python SDK返回的响应的字典或列表

返回:始终

示例:{"customizations": {"globalCustomizations": {"backgroundImage": {"data": "string"}, "bannerImage": {"data": "string"}, "bannerTitle": "string", "contactText": "string", "desktopLogoImage": {"data": "string"}, "footerElement": "string", "mobileLogoImage": {"data": "string"}}, "language": {"viewLanguage": "string"}, "pageCustomizations": {"data": [{"key": "string", "value": "string"}]}, "portalTheme": {"id": "string", "name": "string", "themeData": "string"}, "portalTweakSettings": {"bannerColor": "string", "bannerTextColor": "string", "pageBackgroundColor": "string", "pageLabelAndTextColor": "string"}}, "description": "string", "id": "string", "link": {"href": "string", "rel": "string", "type": "string"}, "name": "string", "portalTestUrl": "string", "portalType": "string", "settings": {"byodSettings": {"byodRegistrationSettings": {"endPointIdentityGroupId": "string", "showDeviceID": true}, "byodRegistrationSuccessSettings": {"redirectUrl": "string", "successRedirect": "string"}, "byodWelcomeSettings": {"aupDisplay": "string", "enableBYOD": true, "enableGuestAccess": true, "includeAup": true, "requireAupAcceptance": true, "requireMDM": true, "requireScrolling": true}}, "portalSettings": {"allowedInterfaces": ["string"], "alwaysUsedLanguage": "string", "certificateGroupTag": "string", "displayLang": "string", "endpointIdentityGroup": "string", "fallbackLanguage": "string", "httpsPort": 0}, "supportInfoSettings": {"defaultEmptyFieldValue": "string", "emptyFieldDisplay": "string", "includeBrowserUserAgent": true, "includeFailureCode": true, "includeIpAddress": true, "includeMacAddr": true, "includePolicyServer": true, "includeSupportInfoPage": true}}}

ise_update_response

字典

在 cisco.ise 1.1.0 中添加

包含Cisco ISE Python SDK返回的响应的字典或列表

返回:始终

示例:{"UpdatedFieldsList": {"field": "string", "newValue": "string", "oldValue": "string", "updatedField": [{"field": "string", "newValue": "string", "oldValue": "string"}]}}

作者

  • Rafael Campos (@racampos)