# Object names are based on pyATS/Genie parser (boolean values are left out)
Value INTERFACE (\S+)
Value VERSION (\d+)
Value GROUP_NUMBER (\d+)
Value PRIORITY (\d+)
Value HSRP_ROUTER_STATE (\w+(\(\w+\s+\w+\))?)
Value CONFIGURED_PRIORITY (\d+)
Value PREEMPT (.*)
Value LOWER_FWD_TRESHOLD (\d+)
Value UPPER_FWD_TRESHOLD (\d+)
# Value TIMERS_HELLO_MSEC_FLAG
# Value TIMERS_HOLD_MSEC_FLAG
Value TIMERS_HELLO_SEC (\d+)
Value TIMERS_HOLD_SEC (\d+)
Value PRIMARY_IPV4_ADDRESS (\S+)
# Value VIRTUAL_IP_LEARN
Value SECONDARY_IPV4_ADDRESS (\S+)
Value ACTIVE_ROUTER (\S+)
Value ACTIVE_EXPIRE (\d+\.\d+)
Value ACTIVE_IP_ADDRESS (\S+)
Value ACTIVE_PRIORITY (\d+)
Value STANDBY_ROUTER (\S+)
Value STANDBY_EXPIRE (\d+\.\d+)
Value STANDBY_IP_ADDRESS (\S+)
Value STANDBY_PRIORITY (\d+)
Value AUTHENTICATION (\S+)
Value VIRTUAL_MAC_ADDRESS (\S+)
Value VIRTUAL_MAC_ADDRESS_STATUS (.*)
Value NUM_STATE_CHANGES (\d+)
Value LAST_STATE_CHANGE (\S+)
Value SESSION_NAME (\S+)

Start
  ^${INTERFACE}\s+-\s+Group\s${GROUP_NUMBER}\s+\(HSRP-V${VERSION}\)\s\(IPv[46]\)\s*$$
  ^\s+Local\s+state\s+is\s+${HSRP_ROUTER_STATE},\s+priority\s+${PRIORITY}\s+\(Cfged\s+${CONFIGURED_PRIORITY}\),\s+${PREEMPT}\s*$$  
  ^\s+.*lower:\s+${LOWER_FWD_TRESHOLD}\s+upper:\s+${UPPER_FWD_TRESHOLD}\s*$$
  ^\s+Preemption\s+Delay.*$$
  ^\s+Hellotime\s+${TIMERS_HELLO_SEC}.*holdtime\s+${TIMERS_HOLD_SEC}.*$$
  ^\s+Next\s+hello\s+sent.*$$
  ^\s+Virtual\s+IP\s+address\s+is\s+${PRIMARY_IPV4_ADDRESS}\s+.*$$
  ^\s+Secondary\s+Virtual\s+IP\s+address\s+is\s+${SECONDARY_IPV4_ADDRESS}\s*$$
  ^\s+Active\s+router\s+is\s+${ACTIVE_ROUTER}\s*$$
  ^\s+Active\s+router\s+is\s+${ACTIVE_IP_ADDRESS}\s?,\s+priority\s+${ACTIVE_PRIORITY}\s+expires\s+in\s+${ACTIVE_EXPIRE}.*$$
  ^\s+Standby\s+router\s+is\s+${STANDBY_ROUTER}\s*$$
  ^\s+Standby\s+router\s+is\s+${STANDBY_IP_ADDRESS}\s?,\s+priority\s+${STANDBY_PRIORITY}\s+expires\s+in\s+${STANDBY_EXPIRE}.*$$
  # catch clear text authetication:
  ^\s+Authentication\stext\s+.*$$
  ^\s+Authentication\s+${AUTHENTICATION},.*$$
  ^\s+Virtual\s+mac\s+address\s+is\s+${VIRTUAL_MAC_ADDRESS}\s+\(${VIRTUAL_MAC_ADDRESS_STATUS}\)\s*$$
  ^\s+${NUM_STATE_CHANGES}\s+state\s+changes,\s+last\s+state\s+change\s+${LAST_STATE_CHANGE}\s*$$
  ^\s+IP\s+redundancy\s+name\s+is\s+${SESSION_NAME}\s.*$$
  ^\s+Secondary\s+VIP.*$$
  # Catch secondary VIPs:
  ^\s+\d+\.\d+\.\d+\.\d+$$
  # Record data when empty line is found
  ^\s*$$ -> Record
  ^. -> Error
