Conversation
Add three new pyaoscx resource modules for AAA configuration:
- AaaServerGroup (system/aaa_server_groups): manage AAA server groups
indexed by group_name with a configurable group_type.
- RadiusServer (system/vrfs/{vrf}/radius_servers): manage RADIUS servers,
VRF-nested with the compound index address,port,port_type and support
for the server_group binding (REST v10.16).
- TacacsServer (system/vrfs/{vrf}/tacacs_servers): manage TACACS+ servers,
VRF-nested with the compound index address,tcp_port and group membership.
All three classes are registered in the api module-name table and use a
PUT-based update. Includes the v10.16 REST version module (required for the
RADIUS server_group binding) and 17 offline unit tests in tests/test_aaa.py.
Signed-off-by: ed6869 <ed6869@mail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds three new resource modules to manage the AAA server family on AOS-CX
devices, plus the v10.16 REST version module they rely on.
pyaoscx/aaa_server_group.py—AaaServerGroup(system/aaa_server_groups,index
group_name, attributegroup_type).pyaoscx/radius_server.py—RadiusServer(
system/vrfs/{vrf}/radius_servers, VRF-nested, compound indexaddress,port,port_type). Supports theserver_groupbinding(
{group_uri: priority}, several groups allowed), the write-onlypasskeyand the usual RADIUS scalars (auth_type, accounting_udp_port, retries,
timeout, tls_initial_connection_timeout, msg_authenticator_check,
tracking_*, port_access).
pyaoscx/tacacs_server.py—TacacsServer(
system/vrfs/{vrf}/tacacs_servers, VRF-nested, compound indexaddress,tcp_port). Supportsgroupmembership, the write-onlypasskeyand the TACACS+ scalars (auth_type, timeout, tracking_enable,
default_group_priority, user_group_priority).
All three classes are registered in
pyaoscx/api.pyand use a PUT-basedupdate(). This change also adds thepyaoscx/rest/v10_16/API version module(required for the RADIUS
server_groupdict binding) and 17 offline unit testsin
tests/test_aaa.py.Fixes #70
Testing
black --line-length 79 --checkandflake8clean on all new files.pytest tests/test_aaa.py— 17/17 passing.read-back / idempotent update / delete for all three resources, including a
multi-group
server_groupbinding that reproduces a productionClearPass-style RADIUS profile. No production resources were modified.
Note on contribution target
CONTRIBUTING.mdmentions adevelopmentbranch, but the repository onlyexposes
master, so this PR targetsmaster. Happy to retarget if adevelopmentbranch is created.Companion collection PR: aruba/aoscx-ansible-collection#158