2016-09-18 105 views
0

當使用基於WebNMS java的SNMP API與SNMPv3進行通信時,我在使用SHA-DES組合時遇到以下錯誤。所有其他組合(MD5-DES,noAuthNoPriv等)工作正常。WebNMS - SHA-DES上的SNMPv3不起作用

Digest Failed : RemoteHost = 10.121.32.163 : RemotePort = 5000 : UserName = batty

returning : -1could not send a wrongDigests report PDU Failed to authenticate the SecurityParameters for user batty authKey length has to be 20

的WebNMS低級API錯誤說以下有關該錯誤:

If an SNMPv3 message is send to an SNMPv3 agent, it checks whether the authParams is correct. In case if the authParams is incorrect, it sends this error to the originator. The agent developed using WebNMS SNMP API will automatically send the report PDU on receiving the SNMP message. If the authParams of the message is wrong, this error is sent to the originator.

AuthProtocol: SHA Context Name, ContextEngineID are not specified.

但我覈實,所有這些信息是正確的。

任何遇到此問題的人?如何去解決這個問題?

回答

0

這是USMUtils.password_to_key API中的一個錯誤。當priv協議(AES-128和DES)與auth協議SHA一起使用時,它返回長度爲16的auth密鑰。

使用已棄用的password_to_key來解決問題。

Deprecated. This method cannot be used to generate localized privacy key if the privacy protocol is other than CBC_DES and CFB_AES_128.