def set_auth_traps_enabled(status=True):
 vname = 'EnableAuthenticationTraps'
 current_status = get_auth_traps_enabled()
 if (bool(status) == current_status):
  _LOG.debug('%s already contains the provided value.', vname)
  return True
 vdata = int(status)
 __salt__['reg.set_value'](_HKEY, _SNMP_KEY, vname, vdata, 'REG_DWORD')
 new_status = get_auth_traps_enabled()
 if (status == new_status):
  _LOG.debug('Setting %s configured successfully: %s', vname, vdata)
  return True
 _LOG.error('Unable to configure %s with value: %s', vname, vdata)
 return False

def set_auth_traps_enabled ( status = True ) : vname = 'EnableAuthenticationTraps' current_status = get_auth_traps_enabled ( ) if ( bool ( status ) == current_status ) : _LOG . debug ( '%s already contains the provided value.' , vname ) return True vdata = int ( status ) __salt__ [ 'reg.set_value' ] ( _HKEY , _SNMP_KEY , vname , vdata , 'REG_DWORD' ) new_status = get_auth_traps_enabled ( ) if ( status == new_status ) : _LOG . debug ( 'Setting %s configured successfully: %s' , vname , vdata ) return True _LOG . error ( 'Unable to configure %s with value: %s' , vname , vdata ) return False
manage the sending of authentication traps .