diff options
Diffstat (limited to 'pysnmp/proto/secmod/rfc3414/auth')
-rw-r--r-- | pysnmp/proto/secmod/rfc3414/auth/base.py | 3 | ||||
-rw-r--r-- | pysnmp/proto/secmod/rfc3414/auth/hmacmd5.py | 3 | ||||
-rw-r--r-- | pysnmp/proto/secmod/rfc3414/auth/hmacsha.py | 3 |
3 files changed, 9 insertions, 0 deletions
diff --git a/pysnmp/proto/secmod/rfc3414/auth/base.py b/pysnmp/proto/secmod/rfc3414/auth/base.py index e412adea..133416b8 100644 --- a/pysnmp/proto/secmod/rfc3414/auth/base.py +++ b/pysnmp/proto/secmod/rfc3414/auth/base.py @@ -15,6 +15,9 @@ class AbstractAuthenticationService(object): def localizeKey(self, authKey, snmpEngineID): raise error.ProtocolError(errind.noAuthentication) + + def getTagLen(self): + raise error.ProtocolError(errind.noAuthentication) # 7.2.4.1 def authenticateOutgoingMsg(self, authKey, wholeMsg): diff --git a/pysnmp/proto/secmod/rfc3414/auth/hmacmd5.py b/pysnmp/proto/secmod/rfc3414/auth/hmacmd5.py index 35a95b32..13b27e10 100644 --- a/pysnmp/proto/secmod/rfc3414/auth/hmacmd5.py +++ b/pysnmp/proto/secmod/rfc3414/auth/hmacmd5.py @@ -32,6 +32,9 @@ class HmacMd5(base.AbstractAuthenticationService): def localizeKey(self, authKey, snmpEngineID): return localkey.localizeKeyMD5(authKey, snmpEngineID) + def getTagLen(self): + return 12 + # 6.3.1 def authenticateOutgoingMsg(self, authKey, wholeMsg): # Here we expect calling secmod to indicate where the digest diff --git a/pysnmp/proto/secmod/rfc3414/auth/hmacsha.py b/pysnmp/proto/secmod/rfc3414/auth/hmacsha.py index 5bc3c457..16cb2149 100644 --- a/pysnmp/proto/secmod/rfc3414/auth/hmacsha.py +++ b/pysnmp/proto/secmod/rfc3414/auth/hmacsha.py @@ -32,6 +32,9 @@ class HmacSha(base.AbstractAuthenticationService): def localizeKey(self, authKey, snmpEngineID): return localkey.localizeKeySHA(authKey, snmpEngineID) + def getTagLen(self): + return 12 + # 7.3.1 def authenticateOutgoingMsg(self, authKey, wholeMsg): # 7.3.1.1 |