tdl-xoa-driver 1.0.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- tdl_xoa_driver-1.0.0.dist-info/LICENSE +202 -0
- tdl_xoa_driver-1.0.0.dist-info/METADATA +177 -0
- tdl_xoa_driver-1.0.0.dist-info/RECORD +325 -0
- tdl_xoa_driver-1.0.0.dist-info/WHEEL +5 -0
- tdl_xoa_driver-1.0.0.dist-info/top_level.txt +1 -0
- xoa_driver/__init__.py +2 -0
- xoa_driver/enums.py +399 -0
- xoa_driver/exceptions.py +77 -0
- xoa_driver/functions/__init__.py +0 -0
- xoa_driver/functions/anlt.py +744 -0
- xoa_driver/functions/anlt_ll_debug.py +429 -0
- xoa_driver/functions/cli.py +581 -0
- xoa_driver/functions/exceptions.py +72 -0
- xoa_driver/functions/headers.py +608 -0
- xoa_driver/functions/mgmt.py +515 -0
- xoa_driver/functions/tools.py +256 -0
- xoa_driver/hlfuncs.py +18 -0
- xoa_driver/internals/__init__.py +0 -0
- xoa_driver/internals/commands/__init__.py +31 -0
- xoa_driver/internals/commands/c_commands.py +2041 -0
- xoa_driver/internals/commands/enums.py +3289 -0
- xoa_driver/internals/commands/m4_commands.py +700 -0
- xoa_driver/internals/commands/m4e_commands.py +107 -0
- xoa_driver/internals/commands/m_commands.py +1875 -0
- xoa_driver/internals/commands/p4_commands.py +2221 -0
- xoa_driver/internals/commands/p4e_commands.py +160 -0
- xoa_driver/internals/commands/p4g_commands.py +7253 -0
- xoa_driver/internals/commands/p_commands.py +6000 -0
- xoa_driver/internals/commands/pc_commands.py +335 -0
- xoa_driver/internals/commands/pd_commands.py +355 -0
- xoa_driver/internals/commands/pe_commands.py +1018 -0
- xoa_driver/internals/commands/pec_commands.py +265 -0
- xoa_driver/internals/commands/ped_commands.py +1034 -0
- xoa_driver/internals/commands/pef_commands.py +2216 -0
- xoa_driver/internals/commands/pf_commands.py +379 -0
- xoa_driver/internals/commands/pl1_commands.py +1588 -0
- xoa_driver/internals/commands/pl_commands.py +178 -0
- xoa_driver/internals/commands/pm_commands.py +256 -0
- xoa_driver/internals/commands/pp_commands.py +2341 -0
- xoa_driver/internals/commands/pr_commands.py +812 -0
- xoa_driver/internals/commands/ps_commands.py +2311 -0
- xoa_driver/internals/commands/pt_commands.py +370 -0
- xoa_driver/internals/commands/px_commands.py +303 -0
- xoa_driver/internals/commands/subtypes.py +86 -0
- xoa_driver/internals/core/__init__.py +0 -0
- xoa_driver/internals/core/builders.py +39 -0
- xoa_driver/internals/core/exceptions.py +69 -0
- xoa_driver/internals/core/funcs.py +81 -0
- xoa_driver/internals/core/funcs.pyi +1072 -0
- xoa_driver/internals/core/interfaces.py +47 -0
- xoa_driver/internals/core/token.py +44 -0
- xoa_driver/internals/core/transporter/__init__.py +0 -0
- xoa_driver/internals/core/transporter/_processor.py +83 -0
- xoa_driver/internals/core/transporter/_publisher.py +101 -0
- xoa_driver/internals/core/transporter/_request_id_counter.py +28 -0
- xoa_driver/internals/core/transporter/_stream.py +99 -0
- xoa_driver/internals/core/transporter/_typings.py +43 -0
- xoa_driver/internals/core/transporter/exceptions.py +44 -0
- xoa_driver/internals/core/transporter/handler.py +127 -0
- xoa_driver/internals/core/transporter/logger/__init__.py +10 -0
- xoa_driver/internals/core/transporter/logger/__logger.py +94 -0
- xoa_driver/internals/core/transporter/logger/__state_off.py +32 -0
- xoa_driver/internals/core/transporter/logger/__state_on_default.py +70 -0
- xoa_driver/internals/core/transporter/logger/__state_on_loguru.py +51 -0
- xoa_driver/internals/core/transporter/logger/__state_on_user.py +48 -0
- xoa_driver/internals/core/transporter/protocol/__init__.py +0 -0
- xoa_driver/internals/core/transporter/protocol/_constants.py +77 -0
- xoa_driver/internals/core/transporter/protocol/_utils.py +59 -0
- xoa_driver/internals/core/transporter/protocol/exceptions.py +271 -0
- xoa_driver/internals/core/transporter/protocol/payload/__init__.py +70 -0
- xoa_driver/internals/core/transporter/protocol/payload/base_struct.py +283 -0
- xoa_driver/internals/core/transporter/protocol/payload/descriptor.py +119 -0
- xoa_driver/internals/core/transporter/protocol/payload/exceptions.py +20 -0
- xoa_driver/internals/core/transporter/protocol/payload/field.py +296 -0
- xoa_driver/internals/core/transporter/protocol/payload/types.py +173 -0
- xoa_driver/internals/core/transporter/protocol/payload/utils.py +53 -0
- xoa_driver/internals/core/transporter/protocol/struct_header.py +123 -0
- xoa_driver/internals/core/transporter/protocol/struct_request.py +65 -0
- xoa_driver/internals/core/transporter/protocol/struct_response.py +89 -0
- xoa_driver/internals/core/transporter/registry.py +43 -0
- xoa_driver/internals/exceptions/__init__.py +9 -0
- xoa_driver/internals/exceptions/modules.py +13 -0
- xoa_driver/internals/exceptions/testers.py +21 -0
- xoa_driver/internals/hli_v1/__init__.py +0 -0
- xoa_driver/internals/hli_v1/indices/__init__.py +0 -0
- xoa_driver/internals/hli_v1/indices/base_index.py +39 -0
- xoa_driver/internals/hli_v1/indices/connection_group/__init__.py +0 -0
- xoa_driver/internals/hli_v1/indices/connection_group/cg.py +186 -0
- xoa_driver/internals/hli_v1/indices/connection_group/histogram.py +78 -0
- xoa_driver/internals/hli_v1/indices/connection_group/l2.py +94 -0
- xoa_driver/internals/hli_v1/indices/connection_group/l3.py +130 -0
- xoa_driver/internals/hli_v1/indices/connection_group/raw.py +200 -0
- xoa_driver/internals/hli_v1/indices/connection_group/replay.py +109 -0
- xoa_driver/internals/hli_v1/indices/connection_group/tcp.py +314 -0
- xoa_driver/internals/hli_v1/indices/connection_group/tls.py +198 -0
- xoa_driver/internals/hli_v1/indices/connection_group/udp.py +133 -0
- xoa_driver/internals/hli_v1/indices/connection_group/user_state.py +28 -0
- xoa_driver/internals/hli_v1/indices/filter/__init__.py +0 -0
- xoa_driver/internals/hli_v1/indices/filter/base_filter.py +65 -0
- xoa_driver/internals/hli_v1/indices/filter/genuine_filter.py +20 -0
- xoa_driver/internals/hli_v1/indices/length_term.py +49 -0
- xoa_driver/internals/hli_v1/indices/macsecscs/__init__.py +0 -0
- xoa_driver/internals/hli_v1/indices/macsecscs/base_macsecsc.py +224 -0
- xoa_driver/internals/hli_v1/indices/macsecscs/genuine_macsecsc.py +72 -0
- xoa_driver/internals/hli_v1/indices/match_term.py +64 -0
- xoa_driver/internals/hli_v1/indices/port_dataset.py +72 -0
- xoa_driver/internals/hli_v1/indices/streams/__init__.py +0 -0
- xoa_driver/internals/hli_v1/indices/streams/base_stream.py +405 -0
- xoa_driver/internals/hli_v1/indices/streams/genuine_stream.py +64 -0
- xoa_driver/internals/hli_v1/modules/__init__.py +0 -0
- xoa_driver/internals/hli_v1/modules/__interfaces.py +21 -0
- xoa_driver/internals/hli_v1/modules/base_module.py +138 -0
- xoa_driver/internals/hli_v1/modules/module_chimera.py +366 -0
- xoa_driver/internals/hli_v1/modules/module_l23ve.py +73 -0
- xoa_driver/internals/hli_v1/modules/module_l47.py +397 -0
- xoa_driver/internals/hli_v1/modules/module_l47ve.py +9 -0
- xoa_driver/internals/hli_v1/modules/modules_l23/__init__.py +0 -0
- xoa_driver/internals/hli_v1/modules/modules_l23/family_combi.py +83 -0
- xoa_driver/internals/hli_v1/modules/modules_l23/family_d.py +75 -0
- xoa_driver/internals/hli_v1/modules/modules_l23/family_e.py +85 -0
- xoa_driver/internals/hli_v1/modules/modules_l23/family_f.py +145 -0
- xoa_driver/internals/hli_v1/modules/modules_l23/family_g.py +84 -0
- xoa_driver/internals/hli_v1/modules/modules_l23/family_h.py +40 -0
- xoa_driver/internals/hli_v1/modules/modules_l23/family_i.py +25 -0
- xoa_driver/internals/hli_v1/modules/modules_l23/family_j.py +25 -0
- xoa_driver/internals/hli_v1/modules/modules_l23/family_k.py +39 -0
- xoa_driver/internals/hli_v1/modules/modules_l23/family_l.py +55 -0
- xoa_driver/internals/hli_v1/modules/modules_l23/family_l1.py +800 -0
- xoa_driver/internals/hli_v1/modules/modules_l23/family_m.py +25 -0
- xoa_driver/internals/hli_v1/modules/modules_l23/family_n.py +40 -0
- xoa_driver/internals/hli_v1/modules/modules_l23/module_l23_base.py +383 -0
- xoa_driver/internals/hli_v1/ports/__init__.py +0 -0
- xoa_driver/internals/hli_v1/ports/base_port.py +125 -0
- xoa_driver/internals/hli_v1/ports/port_l23/__init__.py +0 -0
- xoa_driver/internals/hli_v1/ports/port_l23/bases/__init__.py +0 -0
- xoa_driver/internals/hli_v1/ports/port_l23/bases/port_capture.py +70 -0
- xoa_driver/internals/hli_v1/ports/port_l23/bases/port_l23.py +527 -0
- xoa_driver/internals/hli_v1/ports/port_l23/bases/port_l23_genuine.py +229 -0
- xoa_driver/internals/hli_v1/ports/port_l23/bases/port_reception_statistics.py +231 -0
- xoa_driver/internals/hli_v1/ports/port_l23/bases/port_transceiver.py +117 -0
- xoa_driver/internals/hli_v1/ports/port_l23/bases/port_transmission_statistics.py +131 -0
- xoa_driver/internals/hli_v1/ports/port_l23/chimera/__init__.py +0 -0
- xoa_driver/internals/hli_v1/ports/port_l23/chimera/filter_definition/__init__.py +0 -0
- xoa_driver/internals/hli_v1/ports/port_l23/chimera/filter_definition/_utils.py +15 -0
- xoa_driver/internals/hli_v1/ports/port_l23/chimera/filter_definition/general.py +396 -0
- xoa_driver/internals/hli_v1/ports/port_l23/chimera/filter_definition/shadow.py +104 -0
- xoa_driver/internals/hli_v1/ports/port_l23/chimera/filter_definition/working.py +36 -0
- xoa_driver/internals/hli_v1/ports/port_l23/chimera/pe_custom_distribution.py +125 -0
- xoa_driver/internals/hli_v1/ports/port_l23/chimera/pe_distribution.py +174 -0
- xoa_driver/internals/hli_v1/ports/port_l23/chimera/port_chimera.py +119 -0
- xoa_driver/internals/hli_v1/ports/port_l23/chimera/port_emulation.py +244 -0
- xoa_driver/internals/hli_v1/ports/port_l23/chimera/reception_statistics.py +24 -0
- xoa_driver/internals/hli_v1/ports/port_l23/chimera/transmission_statistics.py +24 -0
- xoa_driver/internals/hli_v1/ports/port_l23/family_combi.py +37 -0
- xoa_driver/internals/hli_v1/ports/port_l23/family_d.py +51 -0
- xoa_driver/internals/hli_v1/ports/port_l23/family_e.py +107 -0
- xoa_driver/internals/hli_v1/ports/port_l23/family_f.py +151 -0
- xoa_driver/internals/hli_v1/ports/port_l23/family_g.py +77 -0
- xoa_driver/internals/hli_v1/ports/port_l23/family_h.py +67 -0
- xoa_driver/internals/hli_v1/ports/port_l23/family_i.py +84 -0
- xoa_driver/internals/hli_v1/ports/port_l23/family_j.py +68 -0
- xoa_driver/internals/hli_v1/ports/port_l23/family_k.py +73 -0
- xoa_driver/internals/hli_v1/ports/port_l23/family_l.py +82 -0
- xoa_driver/internals/hli_v1/ports/port_l23/family_l1.py +166 -0
- xoa_driver/internals/hli_v1/ports/port_l23/family_m.py +29 -0
- xoa_driver/internals/hli_v1/ports/port_l23/fault_jkl.py +24 -0
- xoa_driver/internals/hli_v1/ports/port_l23/freya_l1.py +722 -0
- xoa_driver/internals/hli_v1/ports/port_l23/pcs_pma_ghijkl.py +369 -0
- xoa_driver/internals/hli_v1/ports/port_l23/pcs_pma_ijkl_chimera.py +60 -0
- xoa_driver/internals/hli_v1/ports/port_l23/pcs_pma_l.py +78 -0
- xoa_driver/internals/hli_v1/ports/port_l23/port_l23ve.py +101 -0
- xoa_driver/internals/hli_v1/ports/port_l47/__init__.py +0 -0
- xoa_driver/internals/hli_v1/ports/port_l47/counters.py +174 -0
- xoa_driver/internals/hli_v1/ports/port_l47/main.py +228 -0
- xoa_driver/internals/hli_v1/ports/port_l47/packet_engine.py +31 -0
- xoa_driver/internals/hli_v1/revisions.py +11 -0
- xoa_driver/internals/hli_v1/testers/__init__.py +0 -0
- xoa_driver/internals/hli_v1/testers/_base_tester.py +259 -0
- xoa_driver/internals/hli_v1/testers/genuine/__init__.py +0 -0
- xoa_driver/internals/hli_v1/testers/genuine/l_23/__init__.py +0 -0
- xoa_driver/internals/hli_v1/testers/genuine/l_23/health.py +16 -0
- xoa_driver/internals/hli_v1/testers/genuine/l_23/rest_api.py +38 -0
- xoa_driver/internals/hli_v1/testers/genuine/l_23/time_keeper.py +57 -0
- xoa_driver/internals/hli_v1/testers/genuine/l_23/upload_file.py +29 -0
- xoa_driver/internals/hli_v1/testers/genuine/management_interface.py +42 -0
- xoa_driver/internals/hli_v1/testers/l23_tester.py +196 -0
- xoa_driver/internals/hli_v1/testers/l23ve_tester.py +114 -0
- xoa_driver/internals/hli_v1/testers/l47_tester.py +106 -0
- xoa_driver/internals/hli_v1/testers/l47ve_tester.py +54 -0
- xoa_driver/internals/hli_v2/__init__.py +0 -0
- xoa_driver/internals/hli_v2/indices/__init__.py +0 -0
- xoa_driver/internals/hli_v2/indices/base_index.py +39 -0
- xoa_driver/internals/hli_v2/indices/connection_group/__init__.py +0 -0
- xoa_driver/internals/hli_v2/indices/connection_group/cg.py +115 -0
- xoa_driver/internals/hli_v2/indices/connection_group/histogram.py +59 -0
- xoa_driver/internals/hli_v2/indices/connection_group/l2.py +71 -0
- xoa_driver/internals/hli_v2/indices/connection_group/l3.py +96 -0
- xoa_driver/internals/hli_v2/indices/connection_group/raw.py +148 -0
- xoa_driver/internals/hli_v2/indices/connection_group/replay.py +89 -0
- xoa_driver/internals/hli_v2/indices/connection_group/tcp.py +261 -0
- xoa_driver/internals/hli_v2/indices/connection_group/tls.py +166 -0
- xoa_driver/internals/hli_v2/indices/connection_group/udp.py +112 -0
- xoa_driver/internals/hli_v2/indices/connection_group/user_state.py +25 -0
- xoa_driver/internals/hli_v2/indices/filter/__init__.py +0 -0
- xoa_driver/internals/hli_v2/indices/filter/base_filter.py +50 -0
- xoa_driver/internals/hli_v2/indices/filter/genuine_filter.py +17 -0
- xoa_driver/internals/hli_v2/indices/length_term.py +44 -0
- xoa_driver/internals/hli_v2/indices/match_term.py +49 -0
- xoa_driver/internals/hli_v2/indices/port_dataset.py +53 -0
- xoa_driver/internals/hli_v2/indices/streams/__init__.py +0 -0
- xoa_driver/internals/hli_v2/indices/streams/base_stream.py +234 -0
- xoa_driver/internals/hli_v2/indices/streams/genuine_stream.py +32 -0
- xoa_driver/internals/hli_v2/modules/__init__.py +0 -0
- xoa_driver/internals/hli_v2/modules/__interfaces.py +21 -0
- xoa_driver/internals/hli_v2/modules/base_module.py +125 -0
- xoa_driver/internals/hli_v2/modules/module_chimera.py +358 -0
- xoa_driver/internals/hli_v2/modules/module_l23ve.py +58 -0
- xoa_driver/internals/hli_v2/modules/module_l47.py +230 -0
- xoa_driver/internals/hli_v2/modules/module_l47ve.py +8 -0
- xoa_driver/internals/hli_v2/modules/modules_l23/__init__.py +0 -0
- xoa_driver/internals/hli_v2/modules/modules_l23/family_combi.py +73 -0
- xoa_driver/internals/hli_v2/modules/modules_l23/family_d.py +75 -0
- xoa_driver/internals/hli_v2/modules/modules_l23/family_e.py +85 -0
- xoa_driver/internals/hli_v2/modules/modules_l23/family_f.py +144 -0
- xoa_driver/internals/hli_v2/modules/modules_l23/family_g.py +84 -0
- xoa_driver/internals/hli_v2/modules/modules_l23/family_h.py +40 -0
- xoa_driver/internals/hli_v2/modules/modules_l23/family_i.py +25 -0
- xoa_driver/internals/hli_v2/modules/modules_l23/family_j.py +25 -0
- xoa_driver/internals/hli_v2/modules/modules_l23/family_k.py +39 -0
- xoa_driver/internals/hli_v2/modules/modules_l23/family_l.py +55 -0
- xoa_driver/internals/hli_v2/modules/modules_l23/family_l1.py +797 -0
- xoa_driver/internals/hli_v2/modules/modules_l23/family_m.py +25 -0
- xoa_driver/internals/hli_v2/modules/modules_l23/family_n.py +40 -0
- xoa_driver/internals/hli_v2/modules/modules_l23/module_l23_base.py +339 -0
- xoa_driver/internals/hli_v2/ports/__init__.py +0 -0
- xoa_driver/internals/hli_v2/ports/base_port.py +105 -0
- xoa_driver/internals/hli_v2/ports/port_l23/__init__.py +0 -0
- xoa_driver/internals/hli_v2/ports/port_l23/bases/__init__.py +0 -0
- xoa_driver/internals/hli_v2/ports/port_l23/bases/port_capture.py +64 -0
- xoa_driver/internals/hli_v2/ports/port_l23/bases/port_l23.py +441 -0
- xoa_driver/internals/hli_v2/ports/port_l23/bases/port_l23_genuine.py +172 -0
- xoa_driver/internals/hli_v2/ports/port_l23/bases/port_reception_statistics.py +156 -0
- xoa_driver/internals/hli_v2/ports/port_l23/bases/port_transceiver.py +117 -0
- xoa_driver/internals/hli_v2/ports/port_l23/bases/port_transmission_statistics.py +59 -0
- xoa_driver/internals/hli_v2/ports/port_l23/chimera/__init__.py +0 -0
- xoa_driver/internals/hli_v2/ports/port_l23/chimera/filter_definition/__init__.py +0 -0
- xoa_driver/internals/hli_v2/ports/port_l23/chimera/filter_definition/_utils.py +15 -0
- xoa_driver/internals/hli_v2/ports/port_l23/chimera/filter_definition/general.py +340 -0
- xoa_driver/internals/hli_v2/ports/port_l23/chimera/filter_definition/shadow.py +99 -0
- xoa_driver/internals/hli_v2/ports/port_l23/chimera/filter_definition/working.py +36 -0
- xoa_driver/internals/hli_v2/ports/port_l23/chimera/pe_custom_distribution.py +116 -0
- xoa_driver/internals/hli_v2/ports/port_l23/chimera/pe_distribution.py +102 -0
- xoa_driver/internals/hli_v2/ports/port_l23/chimera/port_chimera.py +113 -0
- xoa_driver/internals/hli_v2/ports/port_l23/chimera/port_emulation.py +420 -0
- xoa_driver/internals/hli_v2/ports/port_l23/chimera/reception_statistics.py +22 -0
- xoa_driver/internals/hli_v2/ports/port_l23/chimera/transmission_statistics.py +22 -0
- xoa_driver/internals/hli_v2/ports/port_l23/family_combi.py +36 -0
- xoa_driver/internals/hli_v2/ports/port_l23/family_d.py +49 -0
- xoa_driver/internals/hli_v2/ports/port_l23/family_e.py +96 -0
- xoa_driver/internals/hli_v2/ports/port_l23/family_f.py +144 -0
- xoa_driver/internals/hli_v2/ports/port_l23/family_g.py +77 -0
- xoa_driver/internals/hli_v2/ports/port_l23/family_h.py +60 -0
- xoa_driver/internals/hli_v2/ports/port_l23/family_i.py +66 -0
- xoa_driver/internals/hli_v2/ports/port_l23/family_j.py +53 -0
- xoa_driver/internals/hli_v2/ports/port_l23/family_k.py +58 -0
- xoa_driver/internals/hli_v2/ports/port_l23/family_l.py +67 -0
- xoa_driver/internals/hli_v2/ports/port_l23/family_l1.py +149 -0
- xoa_driver/internals/hli_v2/ports/port_l23/family_m.py +28 -0
- xoa_driver/internals/hli_v2/ports/port_l23/fault_jkl.py +22 -0
- xoa_driver/internals/hli_v2/ports/port_l23/pcs_pma_ghijkl.py +342 -0
- xoa_driver/internals/hli_v2/ports/port_l23/pcs_pma_ijkl_chimera.py +50 -0
- xoa_driver/internals/hli_v2/ports/port_l23/pcs_pma_l.py +65 -0
- xoa_driver/internals/hli_v2/ports/port_l23/port_l23ve.py +81 -0
- xoa_driver/internals/hli_v2/ports/port_l47/__init__.py +0 -0
- xoa_driver/internals/hli_v2/ports/port_l47/counters.py +146 -0
- xoa_driver/internals/hli_v2/ports/port_l47/main.py +137 -0
- xoa_driver/internals/hli_v2/ports/port_l47/packet_engine.py +20 -0
- xoa_driver/internals/hli_v2/revisions.py +11 -0
- xoa_driver/internals/hli_v2/testers/__init__.py +0 -0
- xoa_driver/internals/hli_v2/testers/_base_tester.py +207 -0
- xoa_driver/internals/hli_v2/testers/genuine/__init__.py +0 -0
- xoa_driver/internals/hli_v2/testers/genuine/l_23/__init__.py +0 -0
- xoa_driver/internals/hli_v2/testers/genuine/l_23/health.py +16 -0
- xoa_driver/internals/hli_v2/testers/genuine/l_23/rest_api.py +34 -0
- xoa_driver/internals/hli_v2/testers/genuine/l_23/time_keeper.py +50 -0
- xoa_driver/internals/hli_v2/testers/genuine/l_23/upload_file.py +26 -0
- xoa_driver/internals/hli_v2/testers/genuine/management_interface.py +38 -0
- xoa_driver/internals/hli_v2/testers/l23_tester.py +159 -0
- xoa_driver/internals/hli_v2/testers/l23ve_tester.py +98 -0
- xoa_driver/internals/hli_v2/testers/l47_tester.py +95 -0
- xoa_driver/internals/hli_v2/testers/l47ve_tester.py +50 -0
- xoa_driver/internals/state_storage/__init__.py +0 -0
- xoa_driver/internals/state_storage/_speed_detector.py +121 -0
- xoa_driver/internals/state_storage/modules_state.py +128 -0
- xoa_driver/internals/state_storage/ports_state.py +154 -0
- xoa_driver/internals/state_storage/testers_state.py +104 -0
- xoa_driver/internals/utils/__init__.py +0 -0
- xoa_driver/internals/utils/attributes.py +33 -0
- xoa_driver/internals/utils/cap_id.py +63 -0
- xoa_driver/internals/utils/con_traffic_light.py +88 -0
- xoa_driver/internals/utils/indices/__init__.py +0 -0
- xoa_driver/internals/utils/indices/_interfaces.py +26 -0
- xoa_driver/internals/utils/indices/header_modifier_manager.py +56 -0
- xoa_driver/internals/utils/indices/index_manager.py +95 -0
- xoa_driver/internals/utils/indices/observer.py +17 -0
- xoa_driver/internals/utils/kind.py +19 -0
- xoa_driver/internals/utils/managers/__init__.py +0 -0
- xoa_driver/internals/utils/managers/abc.py +44 -0
- xoa_driver/internals/utils/managers/exceptions.py +22 -0
- xoa_driver/internals/utils/managers/modules_manager.py +118 -0
- xoa_driver/internals/utils/managers/ports_manager.py +116 -0
- xoa_driver/internals/utils/rev_tool.py +21 -0
- xoa_driver/internals/utils/session.py +117 -0
- xoa_driver/internals/warn.py +32 -0
- xoa_driver/lli.py +15 -0
- xoa_driver/misc.py +57 -0
- xoa_driver/modules.py +448 -0
- xoa_driver/ports.py +332 -0
- xoa_driver/testers.py +37 -0
- xoa_driver/utils.py +12 -0
- xoa_driver/v2/__init__.py +11 -0
- xoa_driver/v2/misc.py +77 -0
- xoa_driver/v2/modules.py +308 -0
- xoa_driver/v2/ports.py +232 -0
- xoa_driver/v2/testers.py +24 -0
|
@@ -0,0 +1,314 @@
|
|
|
1
|
+
from typing import TYPE_CHECKING
|
|
2
|
+
if TYPE_CHECKING:
|
|
3
|
+
from xoa_driver.internals.core import interfaces as itf
|
|
4
|
+
from xoa_driver.internals.commands import (
|
|
5
|
+
P4G_CLEAR_POST_STAT,
|
|
6
|
+
P4G_TCP_RTT_VALUE,
|
|
7
|
+
P4G_TCP_STATE_CURRENT,
|
|
8
|
+
P4G_TCP_STATE_TOTAL,
|
|
9
|
+
P4G_TCP_STATE_RATE,
|
|
10
|
+
P4G_TCP_RX_PAYLOAD_COUNTERS,
|
|
11
|
+
P4G_TCP_TX_PAYLOAD_COUNTERS,
|
|
12
|
+
P4G_TCP_RETRANSMIT_COUNTERS,
|
|
13
|
+
P4G_TCP_ERROR_COUNTERS,
|
|
14
|
+
P4G_TCP_MSS_TYPE,
|
|
15
|
+
P4G_TCP_MSS_MINMAX,
|
|
16
|
+
P4G_TCP_MSS_VALUE,
|
|
17
|
+
P4G_TCP_WINDOW_SIZE,
|
|
18
|
+
P4G_TCP_DUP_THRES,
|
|
19
|
+
P4G_TCP_SYN_RTO,
|
|
20
|
+
P4G_TCP_RTO,
|
|
21
|
+
P4G_TCP_CONGESTION_MODE,
|
|
22
|
+
P4G_TCP_WINDOW_SCALING,
|
|
23
|
+
P4G_TCP_RTO_MINMAX,
|
|
24
|
+
P4G_TCP_RTO_PROLONGED_MODE,
|
|
25
|
+
P4G_TCP_ICWND_CALC_METHOD,
|
|
26
|
+
P4G_TCP_ISSTHRESH,
|
|
27
|
+
P4G_TCP_ACK_FREQUENCY,
|
|
28
|
+
P4G_TCP_ACK_TIMEOUT,
|
|
29
|
+
P4G_TCP_ESTABLISH_HIST,
|
|
30
|
+
P4G_TCP_CLOSE_HIST,
|
|
31
|
+
P4G_TCP_RX_TOTAL_BYTES_HIST,
|
|
32
|
+
P4G_TCP_RX_GOOD_BYTES_HIST,
|
|
33
|
+
P4G_TCP_TX_TOTAL_BYTES_HIST,
|
|
34
|
+
P4G_TCP_TX_GOOD_BYTES_HIST,
|
|
35
|
+
P4G_TCP_RX_PACKET_COUNTERS,
|
|
36
|
+
P4G_TCP_TX_PACKET_COUNTERS,
|
|
37
|
+
)
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
class GAckTcp:
|
|
41
|
+
"""TCP ACK configuration"""
|
|
42
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
43
|
+
self.duplicate_thresholds = P4G_TCP_DUP_THRES(conn, module_id, port_id, group_idx)
|
|
44
|
+
"""
|
|
45
|
+
|
|
46
|
+
:type: P4G_TCP_DUP_THRES
|
|
47
|
+
"""
|
|
48
|
+
self.frequency = P4G_TCP_ACK_FREQUENCY(conn, module_id, port_id, group_idx)
|
|
49
|
+
"""
|
|
50
|
+
|
|
51
|
+
:type: P4G_TCP_ACK_FREQUENCY
|
|
52
|
+
"""
|
|
53
|
+
self.timeout = P4G_TCP_ACK_TIMEOUT(conn, module_id, port_id, group_idx)
|
|
54
|
+
"""
|
|
55
|
+
|
|
56
|
+
:type: P4G_TCP_ACK_TIMEOUT
|
|
57
|
+
"""
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
class GRetransmissionTimeoutTcp:
|
|
61
|
+
"""TCP Retransmission Timeout configuration"""
|
|
62
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
63
|
+
self.syn_value = P4G_TCP_SYN_RTO(conn, module_id, port_id, group_idx)
|
|
64
|
+
"""
|
|
65
|
+
|
|
66
|
+
:type: P4G_TCP_SYN_RTO
|
|
67
|
+
"""
|
|
68
|
+
self.value = P4G_TCP_RTO(conn, module_id, port_id, group_idx)
|
|
69
|
+
"""
|
|
70
|
+
|
|
71
|
+
:type: P4G_TCP_RTO
|
|
72
|
+
"""
|
|
73
|
+
self.range_limits = P4G_TCP_RTO_MINMAX(conn, module_id, port_id, group_idx)
|
|
74
|
+
"""
|
|
75
|
+
|
|
76
|
+
:type: P4G_TCP_RTO_MINMAX
|
|
77
|
+
"""
|
|
78
|
+
self.prolonged_mode = P4G_TCP_RTO_PROLONGED_MODE(conn, module_id, port_id, group_idx)
|
|
79
|
+
"""
|
|
80
|
+
|
|
81
|
+
:type: P4G_TCP_RTO_PROLONGED_MODE
|
|
82
|
+
"""
|
|
83
|
+
|
|
84
|
+
|
|
85
|
+
class GStateCountersTcp:
|
|
86
|
+
"""TCP State counters"""
|
|
87
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
88
|
+
self.current = P4G_TCP_STATE_CURRENT(conn, module_id, port_id, group_idx)
|
|
89
|
+
"""
|
|
90
|
+
|
|
91
|
+
:type: P4G_TCP_STATE_CURRENT
|
|
92
|
+
"""
|
|
93
|
+
self.total = P4G_TCP_STATE_TOTAL(conn, module_id, port_id, group_idx)
|
|
94
|
+
"""
|
|
95
|
+
|
|
96
|
+
:type: P4G_TCP_STATE_TOTAL
|
|
97
|
+
"""
|
|
98
|
+
self.rate = P4G_TCP_STATE_RATE(conn, module_id, port_id, group_idx)
|
|
99
|
+
"""
|
|
100
|
+
|
|
101
|
+
:type: P4G_TCP_STATE_RATE
|
|
102
|
+
"""
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
class GMaxSegmentSize:
|
|
106
|
+
"""TCP Max Segment Size Configuration"""
|
|
107
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
108
|
+
self.type = P4G_TCP_MSS_TYPE(conn, module_id, port_id, group_idx)
|
|
109
|
+
"""
|
|
110
|
+
|
|
111
|
+
:type: P4G_TCP_MSS_TYPE
|
|
112
|
+
"""
|
|
113
|
+
self.range_limits = P4G_TCP_MSS_MINMAX(conn, module_id, port_id, group_idx)
|
|
114
|
+
"""
|
|
115
|
+
|
|
116
|
+
:type: P4G_TCP_MSS_MINMAX
|
|
117
|
+
"""
|
|
118
|
+
self.fixed_value = P4G_TCP_MSS_VALUE(conn, module_id, port_id, group_idx)
|
|
119
|
+
"""
|
|
120
|
+
|
|
121
|
+
:type: P4G_TCP_MSS_VALUE
|
|
122
|
+
"""
|
|
123
|
+
|
|
124
|
+
|
|
125
|
+
class GPacketCountersTcp:
|
|
126
|
+
"""TCP Packet Counters"""
|
|
127
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
128
|
+
self.rx = P4G_TCP_RX_PACKET_COUNTERS(conn, module_id, port_id, group_idx)
|
|
129
|
+
"""
|
|
130
|
+
|
|
131
|
+
:type: P4G_TCP_RX_PACKET_COUNTERS
|
|
132
|
+
"""
|
|
133
|
+
self.tx = P4G_TCP_TX_PACKET_COUNTERS(conn, module_id, port_id, group_idx)
|
|
134
|
+
"""
|
|
135
|
+
|
|
136
|
+
:type: P4G_TCP_TX_PACKET_COUNTERS
|
|
137
|
+
"""
|
|
138
|
+
|
|
139
|
+
|
|
140
|
+
class GPayloadCountersTcp:
|
|
141
|
+
"""TCP Payload Counters"""
|
|
142
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
143
|
+
self.rx = P4G_TCP_RX_PAYLOAD_COUNTERS(conn, module_id, port_id, group_idx)
|
|
144
|
+
"""
|
|
145
|
+
|
|
146
|
+
:type: P4G_TCP_RX_PAYLOAD_COUNTERS
|
|
147
|
+
"""
|
|
148
|
+
self.tx = P4G_TCP_TX_PAYLOAD_COUNTERS(conn, module_id, port_id, group_idx)
|
|
149
|
+
"""
|
|
150
|
+
|
|
151
|
+
:type: P4G_TCP_TX_PAYLOAD_COUNTERS
|
|
152
|
+
"""
|
|
153
|
+
|
|
154
|
+
|
|
155
|
+
class GCountersTcp:
|
|
156
|
+
"""TCP counters"""
|
|
157
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
158
|
+
self.retransmission = P4G_TCP_RETRANSMIT_COUNTERS(conn, module_id, port_id, group_idx)
|
|
159
|
+
"""
|
|
160
|
+
|
|
161
|
+
:type: P4G_TCP_RETRANSMIT_COUNTERS
|
|
162
|
+
"""
|
|
163
|
+
self.error = P4G_TCP_ERROR_COUNTERS(conn, module_id, port_id, group_idx)
|
|
164
|
+
"""
|
|
165
|
+
|
|
166
|
+
:type: P4G_TCP_ERROR_COUNTERS
|
|
167
|
+
"""
|
|
168
|
+
self.packet = GPacketCountersTcp(conn, module_id, port_id, group_idx)
|
|
169
|
+
"""Packet counters"""
|
|
170
|
+
self.payload = GPayloadCountersTcp(conn, module_id, port_id, group_idx)
|
|
171
|
+
"""Payload counters"""
|
|
172
|
+
self.state = GStateCountersTcp(conn, module_id, port_id, group_idx)
|
|
173
|
+
"""State counters"""
|
|
174
|
+
|
|
175
|
+
|
|
176
|
+
class GRxHistogramTcp:
|
|
177
|
+
"""TCP RX Histogram"""
|
|
178
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
179
|
+
self.total_bytes = P4G_TCP_RX_TOTAL_BYTES_HIST(conn, module_id, port_id, group_idx)
|
|
180
|
+
"""
|
|
181
|
+
|
|
182
|
+
:type: P4G_TCP_RX_TOTAL_BYTES_HIST
|
|
183
|
+
"""
|
|
184
|
+
self.good_bytes = P4G_TCP_RX_GOOD_BYTES_HIST(conn, module_id, port_id, group_idx)
|
|
185
|
+
"""
|
|
186
|
+
|
|
187
|
+
:type: P4G_TCP_RX_GOOD_BYTES_HIST
|
|
188
|
+
"""
|
|
189
|
+
|
|
190
|
+
|
|
191
|
+
class GTxHistogramTcp:
|
|
192
|
+
"""TCP TX Histogram"""
|
|
193
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
194
|
+
self.total_bytes = P4G_TCP_TX_TOTAL_BYTES_HIST(conn, module_id, port_id, group_idx)
|
|
195
|
+
"""
|
|
196
|
+
|
|
197
|
+
:type: P4G_TCP_TX_TOTAL_BYTES_HIST
|
|
198
|
+
"""
|
|
199
|
+
self.good_bytes = P4G_TCP_TX_GOOD_BYTES_HIST(conn, module_id, port_id, group_idx)
|
|
200
|
+
"""
|
|
201
|
+
|
|
202
|
+
:type: P4G_TCP_TX_GOOD_BYTES_HIST
|
|
203
|
+
"""
|
|
204
|
+
|
|
205
|
+
|
|
206
|
+
class GConnHistogramTcp:
|
|
207
|
+
"""TCP Connection Histogram"""
|
|
208
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
209
|
+
self.establish_times = P4G_TCP_ESTABLISH_HIST(conn, module_id, port_id, group_idx)
|
|
210
|
+
"""
|
|
211
|
+
|
|
212
|
+
:type: P4G_TCP_ESTABLISH_HIST
|
|
213
|
+
"""
|
|
214
|
+
self.close_times = P4G_TCP_CLOSE_HIST(conn, module_id, port_id, group_idx)
|
|
215
|
+
"""
|
|
216
|
+
|
|
217
|
+
:type: P4G_TCP_CLOSE_HIST
|
|
218
|
+
"""
|
|
219
|
+
|
|
220
|
+
|
|
221
|
+
class GHistogramTcp:
|
|
222
|
+
"""TCP histogram"""
|
|
223
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
224
|
+
self.connection = GConnHistogramTcp(conn, module_id, port_id, group_idx)
|
|
225
|
+
"""TCP Connection Histogram"""
|
|
226
|
+
self.rx = GRxHistogramTcp(conn, module_id, port_id, group_idx)
|
|
227
|
+
"""TCP RX Histogram"""
|
|
228
|
+
self.tx = GTxHistogramTcp(conn, module_id, port_id, group_idx)
|
|
229
|
+
"""TCP TX Histogram"""
|
|
230
|
+
|
|
231
|
+
|
|
232
|
+
class GReceiverWindowTcp:
|
|
233
|
+
"""TCP RWND Configuration"""
|
|
234
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
235
|
+
self.size = P4G_TCP_WINDOW_SIZE(conn, module_id, port_id, group_idx)
|
|
236
|
+
"""
|
|
237
|
+
|
|
238
|
+
:type: P4G_TCP_WINDOW_SIZE
|
|
239
|
+
"""
|
|
240
|
+
self.scaling = P4G_TCP_WINDOW_SCALING(conn, module_id, port_id, group_idx)
|
|
241
|
+
"""
|
|
242
|
+
|
|
243
|
+
:type: P4G_TCP_WINDOW_SCALING
|
|
244
|
+
"""
|
|
245
|
+
|
|
246
|
+
|
|
247
|
+
class GCongestionWindowTcp:
|
|
248
|
+
"""TCP CWND Configuration"""
|
|
249
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
250
|
+
self.congestion_mode = P4G_TCP_CONGESTION_MODE(conn, module_id, port_id, group_idx)
|
|
251
|
+
"""
|
|
252
|
+
|
|
253
|
+
:type: P4G_TCP_CONGESTION_MODE
|
|
254
|
+
"""
|
|
255
|
+
self.icwnd_calc_method = P4G_TCP_ICWND_CALC_METHOD(conn, module_id, port_id, group_idx)
|
|
256
|
+
"""
|
|
257
|
+
|
|
258
|
+
:type: P4G_TCP_ICWND_CALC_METHOD
|
|
259
|
+
"""
|
|
260
|
+
|
|
261
|
+
|
|
262
|
+
class GTcp:
|
|
263
|
+
"""TCP Stack Configuration"""
|
|
264
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
265
|
+
self.clear_post_test_statistics = P4G_CLEAR_POST_STAT(conn, module_id, port_id, group_idx)
|
|
266
|
+
"""
|
|
267
|
+
|
|
268
|
+
:type: P4G_CLEAR_POST_STAT
|
|
269
|
+
"""
|
|
270
|
+
self.rtt_value = P4G_TCP_RTT_VALUE(conn, module_id, port_id, group_idx)
|
|
271
|
+
"""
|
|
272
|
+
|
|
273
|
+
:type: P4G_TCP_RTT_VALUE
|
|
274
|
+
"""
|
|
275
|
+
self.iss_treshold = P4G_TCP_ISSTHRESH(conn, module_id, port_id, group_idx)
|
|
276
|
+
"""
|
|
277
|
+
|
|
278
|
+
:type: P4G_TCP_ISSTHRESH
|
|
279
|
+
"""
|
|
280
|
+
self.mss = GMaxSegmentSize(conn, module_id, port_id, group_idx)
|
|
281
|
+
"""Max segment size config
|
|
282
|
+
|
|
283
|
+
:type: GMaxSegmentSize
|
|
284
|
+
"""
|
|
285
|
+
self.rto = GRetransmissionTimeoutTcp(conn, module_id, port_id, group_idx)
|
|
286
|
+
"""Retransmission timeout config
|
|
287
|
+
|
|
288
|
+
:type: GRetransmissionTimeoutTcp
|
|
289
|
+
"""
|
|
290
|
+
self.ack = GAckTcp(conn, module_id, port_id, group_idx)
|
|
291
|
+
"""ACK config
|
|
292
|
+
|
|
293
|
+
:type: GAckTcp
|
|
294
|
+
"""
|
|
295
|
+
self.rwnd = GReceiverWindowTcp(conn, module_id, port_id, group_idx)
|
|
296
|
+
"""RWND config
|
|
297
|
+
|
|
298
|
+
:type: GReceiverWindowTcp
|
|
299
|
+
"""
|
|
300
|
+
self.cwnd = GCongestionWindowTcp(conn, module_id, port_id, group_idx)
|
|
301
|
+
"""CWND config
|
|
302
|
+
|
|
303
|
+
:type: GCongestionWindowTcp
|
|
304
|
+
"""
|
|
305
|
+
self.counters = GCountersTcp(conn, module_id, port_id, group_idx)
|
|
306
|
+
"""Counters.
|
|
307
|
+
|
|
308
|
+
:type: GCountersTcp
|
|
309
|
+
"""
|
|
310
|
+
self.histogram = GHistogramTcp(conn, module_id, port_id, group_idx)
|
|
311
|
+
"""Histogram.
|
|
312
|
+
|
|
313
|
+
:type: GHistogramTcp
|
|
314
|
+
"""
|
|
@@ -0,0 +1,198 @@
|
|
|
1
|
+
from typing import TYPE_CHECKING
|
|
2
|
+
if TYPE_CHECKING:
|
|
3
|
+
from xoa_driver.internals.core import interfaces as itf
|
|
4
|
+
from xoa_driver.internals.commands import (
|
|
5
|
+
P4G_TLS_ENABLE,
|
|
6
|
+
P4G_TLS_CIPHER_SUITES,
|
|
7
|
+
P4G_TLS_MAX_RECORD_SIZE,
|
|
8
|
+
P4G_TLS_CERTIFICATE_FILENAME,
|
|
9
|
+
P4G_TLS_PRIVATE_KEY_FILENAME,
|
|
10
|
+
P4G_TLS_DHPARAMS_FILENAME,
|
|
11
|
+
P4G_TLS_CLOSE_NOTIFY,
|
|
12
|
+
P4G_TLS_ALERT_WARNING_COUNTERS,
|
|
13
|
+
P4G_TLS_ALERT_FATAL_COUNTERS,
|
|
14
|
+
P4G_TLS_STATE_CURRENT,
|
|
15
|
+
P4G_TLS_STATE_TOTAL,
|
|
16
|
+
P4G_TLS_STATE_RATE,
|
|
17
|
+
P4G_TLS_RX_PAYLOAD_COUNTERS,
|
|
18
|
+
P4G_TLS_TX_PAYLOAD_COUNTERS,
|
|
19
|
+
P4G_TLS_RX_PAYLOAD_BYTES_HIST,
|
|
20
|
+
P4G_TLS_TX_PAYLOAD_BYTES_HIST,
|
|
21
|
+
P4G_TLS_HANDSHAKE_HIST,
|
|
22
|
+
P4G_TLS_SERVER_NAME,
|
|
23
|
+
P4G_TLS_PROTOCOL_VER,
|
|
24
|
+
P4G_TLS_MIN_REQ_PROTOCOL_VER,
|
|
25
|
+
)
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
class GCountersTlsState:
|
|
29
|
+
"""TLS state counters"""
|
|
30
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
31
|
+
self.current = P4G_TLS_STATE_CURRENT(conn, module_id, port_id, group_idx)
|
|
32
|
+
"""
|
|
33
|
+
|
|
34
|
+
:type: P4G_TLS_STATE_CURRENT
|
|
35
|
+
"""
|
|
36
|
+
self.total = P4G_TLS_STATE_TOTAL(conn, module_id, port_id, group_idx)
|
|
37
|
+
"""
|
|
38
|
+
|
|
39
|
+
:type: P4G_TLS_STATE_TOTAL
|
|
40
|
+
"""
|
|
41
|
+
self.rate = P4G_TLS_STATE_RATE(conn, module_id, port_id, group_idx)
|
|
42
|
+
"""
|
|
43
|
+
|
|
44
|
+
:type: P4G_TLS_STATE_RATE
|
|
45
|
+
"""
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
class GCountersTlsAlert:
|
|
49
|
+
"""TLS alert counters"""
|
|
50
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
51
|
+
self.warning = P4G_TLS_ALERT_WARNING_COUNTERS(conn, module_id, port_id, group_idx)
|
|
52
|
+
"""
|
|
53
|
+
|
|
54
|
+
:type: P4G_TLS_ALERT_WARNING_COUNTERS
|
|
55
|
+
"""
|
|
56
|
+
self.fatal = P4G_TLS_ALERT_FATAL_COUNTERS(conn, module_id, port_id, group_idx)
|
|
57
|
+
"""
|
|
58
|
+
|
|
59
|
+
:type: P4G_TLS_ALERT_FATAL_COUNTERS
|
|
60
|
+
"""
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
class GCountersTlsPayload:
|
|
64
|
+
"""TLS payload counters"""
|
|
65
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
66
|
+
self.rx = P4G_TLS_RX_PAYLOAD_COUNTERS(conn, module_id, port_id, group_idx)
|
|
67
|
+
"""
|
|
68
|
+
|
|
69
|
+
:type: P4G_TLS_RX_PAYLOAD_COUNTERS
|
|
70
|
+
"""
|
|
71
|
+
self.tx = P4G_TLS_TX_PAYLOAD_COUNTERS(conn, module_id, port_id, group_idx)
|
|
72
|
+
"""
|
|
73
|
+
|
|
74
|
+
:type: P4G_TLS_TX_PAYLOAD_COUNTERS
|
|
75
|
+
"""
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
class GCountersTls:
|
|
79
|
+
"""TLS counters"""
|
|
80
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
81
|
+
self.alert = GCountersTlsAlert(conn, module_id, port_id, group_idx)
|
|
82
|
+
"""TLS alert counters"""
|
|
83
|
+
self.payload = GCountersTlsPayload(conn, module_id, port_id, group_idx)
|
|
84
|
+
"""TLS payload counters"""
|
|
85
|
+
self.state = GCountersTlsState(conn, module_id, port_id, group_idx)
|
|
86
|
+
"""TLS state counters"""
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
class GHistogramTlsPayload:
|
|
90
|
+
"""TLS payload histogram"""
|
|
91
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
92
|
+
self.rx_bytes = P4G_TLS_RX_PAYLOAD_BYTES_HIST(conn, module_id, port_id, group_idx)
|
|
93
|
+
"""
|
|
94
|
+
|
|
95
|
+
:type: P4G_TLS_RX_PAYLOAD_BYTES_HIST
|
|
96
|
+
"""
|
|
97
|
+
self.tx_bytes = P4G_TLS_TX_PAYLOAD_BYTES_HIST(conn, module_id, port_id, group_idx)
|
|
98
|
+
"""
|
|
99
|
+
|
|
100
|
+
:type: P4G_TLS_TX_PAYLOAD_BYTES_HIST
|
|
101
|
+
"""
|
|
102
|
+
|
|
103
|
+
|
|
104
|
+
class GHistogramTls:
|
|
105
|
+
"""TLS histogram"""
|
|
106
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
107
|
+
self.handshake = P4G_TLS_HANDSHAKE_HIST(conn, module_id, port_id, group_idx)
|
|
108
|
+
"""
|
|
109
|
+
|
|
110
|
+
:type: P4G_TLS_HANDSHAKE_HIST
|
|
111
|
+
"""
|
|
112
|
+
self.payload = GHistogramTlsPayload(conn, module_id, port_id, group_idx)
|
|
113
|
+
"""TLS payload histogram"""
|
|
114
|
+
|
|
115
|
+
|
|
116
|
+
class GProtocolTls:
|
|
117
|
+
"""TLS protocol version"""
|
|
118
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
119
|
+
self.version = P4G_TLS_PROTOCOL_VER(conn, module_id, port_id, group_idx)
|
|
120
|
+
"""
|
|
121
|
+
|
|
122
|
+
:type: P4G_TLS_PROTOCOL_VER
|
|
123
|
+
"""
|
|
124
|
+
self.min_required_version = P4G_TLS_MIN_REQ_PROTOCOL_VER(conn, module_id, port_id, group_idx)
|
|
125
|
+
"""
|
|
126
|
+
|
|
127
|
+
:type: P4G_TLS_MIN_REQ_PROTOCOL_VER
|
|
128
|
+
"""
|
|
129
|
+
|
|
130
|
+
|
|
131
|
+
class GFileTls:
|
|
132
|
+
"""TLS certificate and key files"""
|
|
133
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
134
|
+
self.certificate_path = P4G_TLS_CERTIFICATE_FILENAME(conn, module_id, port_id, group_idx)
|
|
135
|
+
"""
|
|
136
|
+
|
|
137
|
+
:type: P4G_TLS_CERTIFICATE_FILENAME
|
|
138
|
+
"""
|
|
139
|
+
self.private_key_path = P4G_TLS_PRIVATE_KEY_FILENAME(conn, module_id, port_id, group_idx)
|
|
140
|
+
"""
|
|
141
|
+
|
|
142
|
+
:type: P4G_TLS_PRIVATE_KEY_FILENAME
|
|
143
|
+
"""
|
|
144
|
+
self.dhparams_path = P4G_TLS_DHPARAMS_FILENAME(conn, module_id, port_id, group_idx)
|
|
145
|
+
"""
|
|
146
|
+
|
|
147
|
+
:type: P4G_TLS_DHPARAMS_FILENAME
|
|
148
|
+
"""
|
|
149
|
+
|
|
150
|
+
|
|
151
|
+
class GTls:
|
|
152
|
+
"""TLS configuration"""
|
|
153
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
154
|
+
self.enable = P4G_TLS_ENABLE(conn, module_id, port_id, group_idx)
|
|
155
|
+
"""
|
|
156
|
+
|
|
157
|
+
:type: P4G_TLS_ENABLE
|
|
158
|
+
"""
|
|
159
|
+
self.server_name = P4G_TLS_SERVER_NAME(conn, module_id, port_id, group_idx)
|
|
160
|
+
"""
|
|
161
|
+
|
|
162
|
+
:type: P4G_TLS_SERVER_NAME
|
|
163
|
+
"""
|
|
164
|
+
self.close_notify = P4G_TLS_CLOSE_NOTIFY(conn, module_id, port_id, group_idx)
|
|
165
|
+
"""
|
|
166
|
+
|
|
167
|
+
:type: P4G_TLS_CLOSE_NOTIFY
|
|
168
|
+
"""
|
|
169
|
+
self.cipher_suites = P4G_TLS_CIPHER_SUITES(conn, module_id, port_id, group_idx)
|
|
170
|
+
"""
|
|
171
|
+
|
|
172
|
+
:type: P4G_TLS_CIPHER_SUITES
|
|
173
|
+
"""
|
|
174
|
+
self.max_record_size = P4G_TLS_MAX_RECORD_SIZE(conn, module_id, port_id, group_idx)
|
|
175
|
+
"""
|
|
176
|
+
|
|
177
|
+
:type: P4G_TLS_MAX_RECORD_SIZE
|
|
178
|
+
"""
|
|
179
|
+
self.file = GFileTls(conn, module_id, port_id, group_idx)
|
|
180
|
+
"""Cert and key file
|
|
181
|
+
|
|
182
|
+
:type: GFileTls
|
|
183
|
+
"""
|
|
184
|
+
self.protocol = GProtocolTls(conn, module_id, port_id, group_idx)
|
|
185
|
+
"""Protocol version
|
|
186
|
+
|
|
187
|
+
:type: GProtocolTls
|
|
188
|
+
"""
|
|
189
|
+
self.counters = GCountersTls(conn, module_id, port_id, group_idx)
|
|
190
|
+
"""Counters
|
|
191
|
+
|
|
192
|
+
:type: GCountersTls
|
|
193
|
+
"""
|
|
194
|
+
self.histogram = GHistogramTls(conn, module_id, port_id, group_idx)
|
|
195
|
+
"""Histogram
|
|
196
|
+
|
|
197
|
+
:type: GHistogramTls
|
|
198
|
+
"""
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
from typing import TYPE_CHECKING
|
|
2
|
+
if TYPE_CHECKING:
|
|
3
|
+
from xoa_driver.internals.core import interfaces as itf
|
|
4
|
+
from xoa_driver.internals.commands import (
|
|
5
|
+
P4G_UDP_PACKET_SIZE_TYPE,
|
|
6
|
+
P4G_UDP_PACKET_SIZE_MINMAX,
|
|
7
|
+
P4G_UDP_PACKET_SIZE_VALUE,
|
|
8
|
+
P4G_UDP_STATE_CURRENT,
|
|
9
|
+
P4G_UDP_STATE_TOTAL,
|
|
10
|
+
P4G_UDP_STATE_RATE,
|
|
11
|
+
P4G_UDP_RX_PAYLOAD_COUNTERS,
|
|
12
|
+
P4G_UDP_TX_PAYLOAD_COUNTERS,
|
|
13
|
+
P4G_UDP_RX_BYTES_HIST,
|
|
14
|
+
P4G_UDP_TX_BYTES_HIST,
|
|
15
|
+
P4G_UDP_RX_PACKET_COUNTERS,
|
|
16
|
+
P4G_UDP_TX_PACKET_COUNTERS,
|
|
17
|
+
)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
class GHistogramUdp:
|
|
21
|
+
"""UDP histogram"""
|
|
22
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
23
|
+
self.rx_bytes = P4G_UDP_RX_BYTES_HIST(conn, module_id, port_id, group_idx)
|
|
24
|
+
"""
|
|
25
|
+
|
|
26
|
+
:type: P4G_UDP_RX_BYTES_HIST
|
|
27
|
+
"""
|
|
28
|
+
self.tx_bytes = P4G_UDP_TX_BYTES_HIST(conn, module_id, port_id, group_idx)
|
|
29
|
+
"""
|
|
30
|
+
|
|
31
|
+
:type: P4G_UDP_TX_BYTES_HIST
|
|
32
|
+
"""
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
class GPayloadCountersUdp:
|
|
36
|
+
"""UDP payload counters"""
|
|
37
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
38
|
+
self.rx = P4G_UDP_RX_PAYLOAD_COUNTERS(conn, module_id, port_id, group_idx)
|
|
39
|
+
"""
|
|
40
|
+
|
|
41
|
+
:type: P4G_UDP_RX_PAYLOAD_COUNTERS
|
|
42
|
+
"""
|
|
43
|
+
self.tx = P4G_UDP_TX_PAYLOAD_COUNTERS(conn, module_id, port_id, group_idx)
|
|
44
|
+
"""
|
|
45
|
+
|
|
46
|
+
:type: P4G_UDP_TX_PAYLOAD_COUNTERS
|
|
47
|
+
"""
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
class GPacketCountersUdp:
|
|
51
|
+
"""UDP packet counters"""
|
|
52
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
53
|
+
self.rx = P4G_UDP_RX_PACKET_COUNTERS(conn, module_id, port_id, group_idx)
|
|
54
|
+
"""
|
|
55
|
+
|
|
56
|
+
:type: P4G_UDP_RX_PACKET_COUNTERS
|
|
57
|
+
"""
|
|
58
|
+
self.tx = P4G_UDP_TX_PACKET_COUNTERS(conn, module_id, port_id, group_idx)
|
|
59
|
+
"""
|
|
60
|
+
|
|
61
|
+
:type: P4G_UDP_TX_PACKET_COUNTERS
|
|
62
|
+
"""
|
|
63
|
+
|
|
64
|
+
|
|
65
|
+
class GCountersUdp:
|
|
66
|
+
"""UDP counters"""
|
|
67
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
68
|
+
self.payload = GPayloadCountersUdp(conn, module_id, port_id, group_idx)
|
|
69
|
+
"""UDP payload counters"""
|
|
70
|
+
self.packet = GPacketCountersUdp(conn, module_id, port_id, group_idx)
|
|
71
|
+
"""UDP packet counters"""
|
|
72
|
+
self.state = GStateCountersUdp(conn, module_id, port_id, group_idx)
|
|
73
|
+
"""UDP state counters"""
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
class GPacketSizeUdp:
|
|
77
|
+
"""UDP packet size"""
|
|
78
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
79
|
+
self.type = P4G_UDP_PACKET_SIZE_TYPE(conn, module_id, port_id, group_idx)
|
|
80
|
+
"""
|
|
81
|
+
|
|
82
|
+
:type: P4G_UDP_PACKET_SIZE_TYPE
|
|
83
|
+
"""
|
|
84
|
+
self.range_limits = P4G_UDP_PACKET_SIZE_MINMAX(conn, module_id, port_id, group_idx)
|
|
85
|
+
"""
|
|
86
|
+
|
|
87
|
+
:type: P4G_UDP_PACKET_SIZE_MINMAX
|
|
88
|
+
"""
|
|
89
|
+
self.value = P4G_UDP_PACKET_SIZE_VALUE(conn, module_id, port_id, group_idx)
|
|
90
|
+
"""
|
|
91
|
+
|
|
92
|
+
:type: P4G_UDP_PACKET_SIZE_VALUE
|
|
93
|
+
"""
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
class GStateCountersUdp:
|
|
97
|
+
"""UDP state counters"""
|
|
98
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
99
|
+
self.current = P4G_UDP_STATE_CURRENT(conn, module_id, port_id, group_idx)
|
|
100
|
+
"""
|
|
101
|
+
|
|
102
|
+
:type: P4G_UDP_STATE_CURRENT
|
|
103
|
+
"""
|
|
104
|
+
self.total = P4G_UDP_STATE_TOTAL(conn, module_id, port_id, group_idx)
|
|
105
|
+
"""
|
|
106
|
+
|
|
107
|
+
:type: P4G_UDP_STATE_TOTAL
|
|
108
|
+
"""
|
|
109
|
+
self.rate = P4G_UDP_STATE_RATE(conn, module_id, port_id, group_idx)
|
|
110
|
+
"""
|
|
111
|
+
|
|
112
|
+
:type: P4G_UDP_STATE_RATE
|
|
113
|
+
"""
|
|
114
|
+
|
|
115
|
+
|
|
116
|
+
class GUdp:
|
|
117
|
+
"""UDP configuration"""
|
|
118
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
119
|
+
self.packet_size = GPacketSizeUdp(conn, module_id, port_id, group_idx)
|
|
120
|
+
"""UDP packet size
|
|
121
|
+
|
|
122
|
+
:type: GPacketSizeUdp
|
|
123
|
+
"""
|
|
124
|
+
self.counters = GCountersUdp(conn, module_id, port_id, group_idx)
|
|
125
|
+
"""UDP counters
|
|
126
|
+
|
|
127
|
+
:type: GCountersUdp
|
|
128
|
+
"""
|
|
129
|
+
self.histogram = GHistogramUdp(conn, module_id, port_id, group_idx)
|
|
130
|
+
"""UDP histogram
|
|
131
|
+
|
|
132
|
+
:type: GHistogramUdp
|
|
133
|
+
"""
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
from typing import TYPE_CHECKING
|
|
2
|
+
if TYPE_CHECKING:
|
|
3
|
+
from xoa_driver.internals.core import interfaces as itf
|
|
4
|
+
from xoa_driver.internals.commands import (
|
|
5
|
+
P4G_USER_STATE_CURRENT,
|
|
6
|
+
P4G_USER_STATE_TOTAL,
|
|
7
|
+
P4G_USER_STATE_RATE,
|
|
8
|
+
)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
class GUserState:
|
|
12
|
+
"""User state counters"""
|
|
13
|
+
def __init__(self, conn: "itf.IConnection", module_id: int, port_id: int, group_idx: int) -> None:
|
|
14
|
+
self.current = P4G_USER_STATE_CURRENT(conn, module_id, port_id, group_idx)
|
|
15
|
+
"""
|
|
16
|
+
|
|
17
|
+
:type: P4G_USER_STATE_CURRENT
|
|
18
|
+
"""
|
|
19
|
+
self.total = P4G_USER_STATE_TOTAL(conn, module_id, port_id, group_idx)
|
|
20
|
+
"""
|
|
21
|
+
|
|
22
|
+
:type: P4G_USER_STATE_TOTAL
|
|
23
|
+
"""
|
|
24
|
+
self.rate = P4G_USER_STATE_RATE(conn, module_id, port_id, group_idx)
|
|
25
|
+
"""
|
|
26
|
+
|
|
27
|
+
:type: P4G_USER_STATE_RATE
|
|
28
|
+
"""
|
|
File without changes
|