Skip to main content

TACACS+ Server Profile Models

Models for TACACS+ server profile objects in Strata Cloud Manager, defining TACACS+ server configurations for terminal access controller authentication, authorization, and accounting.

Overview

The TACACS+ Server Profile models support the following key attributes:

  • Profile name and container assignment
  • List of TACACS+ servers with address, port, and shared secret
  • Protocol selection (CHAP or PAP)
  • Timeout and single connection settings

Base Models

TacacsServerProfileBaseModel

The base model contains fields common to all CRUD operations.

FieldTypeRequiredDescription
namestrYesProfile name
serverList[TacacsServer]NoList of TACACS+ servers
protocolTacacsProtocolNoTACACS+ protocol type
timeoutintNoTimeout in seconds (1-30)
use_single_connectionboolNoUse single connection
folderstrNo*Folder in which the resource is defined
snippetstrNo*Snippet in which the resource is defined
devicestrNo*Device in which the resource is defined

* Exactly one of folder, snippet, or device is required.

TacacsServerProfileCreateModel

Inherits from TacacsServerProfileBaseModel and adds container validation ensuring exactly one of folder, snippet, or device is provided.

TacacsServerProfileUpdateModel

Inherits from TacacsServerProfileBaseModel with an additional required field:

FieldTypeRequiredDescription
idUUIDYesThe unique identifier of the profile

TacacsServerProfileResponseModel

Inherits from TacacsServerProfileBaseModel with an additional field:

FieldTypeRequiredDescription
idUUIDYesThe unique identifier of the profile
note

The response model uses extra="ignore" to handle any additional fields returned by the API.

Component Models

TacacsServer

Represents a single TACACS+ server entry.

FieldTypeRequiredDescription
namestrNoServer name
addressstrNoServer address
portintNoServer port number (1-65535)
secretstrNoShared secret

TacacsProtocol

Protocol type enumeration.

ValueDescription
CHAPChallenge-Handshake Authentication Protocol
PAPPassword Authentication Protocol

Usage Examples

Creating a TACACS+ Server Profile

from scm.models.identity.tacacs_server_profiles import (
TacacsServerProfileCreateModel,
TacacsServer,
TacacsProtocol,
)

# Create model instance
profile = TacacsServerProfileCreateModel(
name="corp-tacacs",
folder="Texas",
server=[
TacacsServer(
name="tacacs-primary",
address="10.0.1.50",
port=49,
secret="shared-secret"
)
],
protocol=TacacsProtocol.CHAP,
timeout=5,
use_single_connection=True
)

# Use with SDK
payload = profile.model_dump(exclude_unset=True)
result = client.tacacs_server_profile.create(payload)

Parsing a TACACS+ Server Profile Response

from scm.models.identity.tacacs_server_profiles import (
TacacsServerProfileResponseModel,
)

# Parse API response
response = TacacsServerProfileResponseModel(**api_response)
print(f"Name: {response.name}")
print(f"Protocol: {response.protocol}")
print(f"Timeout: {response.timeout}")
if response.server:
for server in response.server:
print(f" Server: {server.name} ({server.address}:{server.port})")