Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v3_usm.go: add privacy passphrase in extendKeyBlumenthal cacheKey call #425

Merged
merged 1 commit into from
Jan 23, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions v3_usm.go
Original file line number Diff line number Diff line change
Expand Up @@ -493,12 +493,12 @@ func extendKeyReeder(authProtocol SnmpV3AuthProtocol, password string, engineID
// https://tools.ietf.org/html/draft-blumenthal-aes-usm-04#page-7
// Not many vendors use this algorithm.
// Previously implemented in the net-snmp and pysnmp libraries.
// Not tested
// TODO: Not tested
func extendKeyBlumenthal(authProtocol SnmpV3AuthProtocol, password string, engineID string) ([]byte, error) {
var key []byte
var err error

key, err = hMAC(authProtocol.HashType(), cacheKey(authProtocol, ""), password, engineID)
key, err = hMAC(authProtocol.HashType(), cacheKey(authProtocol, password), password, engineID)

if err != nil {
return nil, err
Expand Down