waft.cf_dashboard.zero_trust.models.device_profile.device_profile_model module

class waft.cf_dashboard.zero_trust.models.device_profile.device_profile_model.DeviceProfileModel(dash_client: CfDashboardClient, settings_profile: SettingsPolicy, account_id: str)

Bases: object

Object used to manage and interact with Device Profiles

add_fallback_domains(fallback_domains: list[FallbackDomainParam])

Add Local Domain Fallback(s) to the device profile to route DNS queries to resolvers locally connected to the device. Domains added to the Local Domain Fallback list bypass Cloudflare’s filtering and logging.

Parameters:

fallback_domains (list[FallbackDomainParam]) – Fallback domain definition(s), defined as a domain suffix with optional description and/or list of DNS server IPs

allow_mode_switch() None

Allow users enrolled in device profile to change WARP client mode

allow_updates() None

Users enrolled in device profile will receive notifications when a new version of the WARP client is available

allow_user_to_leave_org() None

Devices enrolled in device profile are allowed to leave the organization

captive_portal_delay(delay_mins: int) None

Amount of minutes that WARP will turn off for when a captive portal is detected for devices enrolled in device profile

Args: delay_mins: Number of minutes for which the WARP client will be disabled when a captive portal is detected

delete() None

Delete Device Profile

disable() None

Disable Device Profile

disable_auto_fallback() None

If the dns_server field of a fallback domain is not present, the client WILL NOT fall back to a best guess of the default/system DNS resolvers

disallow_mode_switch() None

Disallow users enrolled in device profile to change WARP client mode

disallow_updates() None

Users enrolled in device profile will not receive notifications when a new version of the WARP client is available

disallow_user_to_leave_org() None

Devices enrolled in device profile are not allowed to leave the organization

edit(**kwargs) None

Base method for editing device profile

enable() None

Enable Device Profile

enable_auto_fallback() None

If the dns_server field of a fallback domain is not present, the client WILL fall back to a best guess of the default/system DNS resolvers

exclude(excludes: Iterable[str | IPv4Address | IPv6Address])

Sets IPs and/or domains to exclude from the WARP tunnel for the device profile

Parameters:

excludes (Iterable) – Iterable IPs and/or domains to exclude from the WARP tunnel

exclude_office_ips() None

Add Microsoft office IPs to split tunnel exclusions

include(includes: Iterable[str | IPv4Address | IPv6Address])

Sets IPs and/or domains to include in the WARP tunnel for the device profile

Parameters:

includes (Iterable) – Iterable IPs and/or domains to include in the WARP tunnel

include_office_ips() None

Do not add Microsoft office IPs to split tunnel exclusions

lock_switch() None

Lock WARP switch for all clients with this device profile applied

remove_fallback_domains(domains: list[str])

Remove Local Domain Fallback(s) from the device profile.

Parameters:

domains (list[str]) – Domain suffixes

reset_fallback_domains()

Restore default Local Domain Fallback(s) to the device profile

reset_split_tunnel()

Restore default split tunnel entries to the device profile

set_auto_connect(auto_connect_time: int) None

Set autoconnect time in minutes for devices enrolled in device profile.

Args: auto_connect_time: Time in minutes after which the WARP client will automatically connect

set_description(description: str) None

Set the description of the Device Profile

Args: description: Description to set for device profile

set_match_value(match_string: str) None

Set new wirefilter expression to filter devices

Args: match_string: Wirefilter expression to use to filter devices for applying Device Profile

set_precedence(precedence_value: float) None

Set the precedence value for the device profile order

Args: precedence_value: Float value to use to determine device profile order

set_service_mode(service_mode: DashboardWarpModes) None

Set service mode for WARP client via the device profile

Args: service_mode: DashboardWarpModes enum member

set_support_url(support_url: str) None

Sets support URL for device profile

Args: support_url: URL to direct to when support link in client is clicked

set_tunnel_protocol(tunnel_protocol: WarpProtocols) None

Sets tunnel protocol for device profile

Args: tunnel_protocol: string representing tunnel protocol

unlock_switch() None

Unlock WARP switch for all clients with this device profile applied