o nnh@sbddlmZddlZddlmZddlmZddlm Z ddl m Z e Z iZ ddZd d ZdS) ) annotationsN) constants)to_bytes)paramiko)DisplaycCszt|WStyYnwt|dd}d}ztj|ddgtjtjd}|\}}d|vs3d|vr5d }Wn tyAd }Ynw|t|<|S) Nsurrogate_or_strict)errorsTz-oControlPersist)stdoutstderrsBad configuration optionsUsage:F)_HAS_CONTROLPERSISTKeyErrorr subprocessPopenPIPE communicateOSError)ssh_executable b_ssh_exechas_cpcmdouterrrF/usr/local/lib/python3.10/dist-packages/ansible/utils/ssh_functions.pycheck_for_controlpersist"s$     rcCs@tjdkrtjdddtdstdurdt_dSdt_dSdS)Nsmartz]The 'smart' option for connections is deprecated. Set the connection plugin directly instead.z2.20)versionsshr)CDEFAULT_TRANSPORTdisplay deprecatedrrrrrrset_default_transport7s   r#) __future__rransiblerr+ansible.module_utils.common.text.convertersr$ansible.module_utils.compat.paramikoransible.utils.displayrr!r rr#rrrrs