Technical Tip: SNMP message authentication or checking failed
| Description | This article describes what is the meaning of 'the message authentication or checking failed (asn.1 parse error) in SNMP version 3 polling found in FortiGate's system event log. |
| Scope | FortiGate. |
| Solution | To debug the process of SNMP internally over the FortiGate, run the following commands:
diagnose debug application snmpd -1 diagnose debug console timestamp enable diagnose debug enable
Further check the error:
ASN.1 in the message means that Abstract Syntax Notation One data structure, and the parsing process log failure from FortiGate's system event log is shown as an example below: date=2024-09-03 time=10:04:02 id=7410231810229010996 itime="2024-09-03 10:04:02" euid=3 epid=3 dsteuid=3 dstepid=3 logver=700159346 logid=0100029021 type="event" subtype="system" level="warning" srcip=XXXX dstip=XXXX msg="Message authentication or checking failed (ASN.1 parse error)." logdesc="SNMP query failed" user="5GFGTuS3rN1CKV" version="SNMP_v3" srcport=6372 dstport=161 eventtime=1725329042733320693 tz="+0800" devid="XXXXX" vd="root" dtime="2024-09-03 10:04:02" itime_t=1725329042 devname="XXXXX"
One example of SNMP daemon debug is shown below:
snmpd: <msg> 225 bytes X.X.X.X:27628 -> X.X.X.X:161 (itf 4.4) . .
The 'recv' is a message from the SNMP manager. The error number will be variable due to how the SNMP manager responds to FortiGate. It is required to check the configuration settings related to SNMP authentication, to ensure the SNMP message format, due to the ASN.1 standard, is correct, and verify the shared secret keys if using SNMP version 3 authentication and encryption. It is also required to work with the SNMP manager to figure out errors.
Related articles: |
