e5b582b990
Related: #1958073
40 lines
1.8 KiB
Diff
40 lines
1.8 KiB
Diff
This patch is required because net-smp is not build with DES support,
|
|
so usmDESPrivProtocol is not available.
|
|
|
|
diff -ur pegasus.orig/src/Pegasus/Handler/snmpIndicationHandler/snmpDeliverTrap_netsnmp.cpp pegasus/src/Pegasus/Handler/snmpIndicationHandler/snmpDeliverTrap_netsnmp.cpp
|
|
--- pegasus.orig/src/Pegasus/Handler/snmpIndicationHandler/snmpDeliverTrap_netsnmp.cpp 2021-06-16 11:22:58.855254567 +0200
|
|
+++ pegasus/src/Pegasus/Handler/snmpIndicationHandler/snmpDeliverTrap_netsnmp.cpp 2021-06-16 11:37:33.012733834 +0200
|
|
@@ -247,6 +247,16 @@
|
|
#ifdef PEGASUS_ENABLE_NET_SNMPV3
|
|
case _SNMPv3_TRAP:
|
|
{
|
|
+ if(snmpSecPrivProto == 1)
|
|
+ {
|
|
+ //DES is no longer supported.
|
|
+ PEG_METHOD_EXIT();
|
|
+ throw PEGASUS_CIM_EXCEPTION_L(CIM_ERR_NOT_SUPPORTED,
|
|
+ MessageLoaderParms(
|
|
+ _MSG_VERSION_NOT_SUPPORTED_KEY,
|
|
+ _MSG_VERSION_NOT_SUPPORTED));
|
|
+ }
|
|
+
|
|
snmpSession.version = SNMP_VERSION_3;
|
|
CString securityNameCStr = securityName.getCString();
|
|
size_t securityNameLen = strlen(securityNameCStr);
|
|
@@ -321,14 +331,7 @@
|
|
|
|
SNMP_FREE(snmpSession.securityPrivProto);
|
|
//Privacy
|
|
- if(snmpSecPrivProto == 1) //DES
|
|
- {
|
|
- snmpSession.securityPrivProto = snmp_duplicate_objid(
|
|
- usmDESPrivProtocol,
|
|
- USM_PRIV_PROTO_DES_LEN);
|
|
- snmpSession.securityPrivProtoLen = USM_PRIV_PROTO_DES_LEN;
|
|
- }
|
|
- else if(snmpSecPrivProto == 2) // AES
|
|
+ if(snmpSecPrivProto == 2) // AES
|
|
{
|
|
snmpSession.securityPrivProto = snmp_duplicate_objid(
|
|
usmAESPrivProtocol,
|