encode_keychange(1)
π NAME π
encode_keychange β she produces the KeyChange string for SNMPv3. That's it, that's the job, and she does it flawlessly β¨ (also hi, this is a Net-SNMP situation, just so you know what you're getting into π«Ά)
πΈ SYNOPSIS πΈ
encode_keychange -t md5|sha1 [OPTIONS]
π¦ DESCRIPTION π¦
okay so bestie, listen up π
encode_keychange produces a KeyChange string using the old and new passphrases, exactly as described in Section 5 of RFC 2274 "User-based Security Model (USM) for version 3 of the Simple Network Management Protocol (SNMPv3)". And the -t option? It is mandatory β not optional, not a vibe, not a maybe. It specifies the hash transform type to use. No -t, no KeyChange. Periodt. π₯
The transform is used to do three (3) iconic things:
- convert passphrase to master key for a given user (
Ku), - convert master key to the localized key (
Kul), - and to hash the old
Kulwith the random bits.
Three jobs, one transform, she's booked and busy π
π where the passphrases come from π
Passphrases are obtained by examining a number of sources until success β in this exact order, no skipping the queue:
- command line options (see
-Nand-Ooptions below); - the file
$HOME/.snmp/passphrase.ekwhich should only contain two lines with old and new passphrase; - standard input -or- user input from the terminal.
Note that the file "should only contain two lines with old and new passphrase" β two lines. Old, then new. That's the whole file. Don't get creative in there π
π OPTIONS π
-E [0x]<engineID>β the EngineID used forKulgeneration. Here's the tea:<engineID>is interpreted as a hex string when preceded by0x, otherwise it is treated as a text string. And if you don't specify an<engineID>at all? It gets constructed from the first IP address for the local host. Automatic, no input needed π«-fβ forces passphrases to be read from standard input. Bossy, but sometimes you need that.-hβ displays the help message. The classic. The comfort flag π«Ά-N "<new_passphrase>"β the passphrase used to generate the newKu. (New = the one you're moving to, babe.)-O "<old_passphrase>"β the passphrase used to generate the oldKu. (Old = where you're coming from. Character development.)-Pβ turns off the prompt for passphrases when getting data from standard input. Shy girl mode activated π§-vβ be verbose. Tell me everything, I'm listening π-Vβ echo passphrases to terminal. Careful with this one β your passphrases end up right there on the screen, for everyone to see π
π SEE ALSO π
The localized key method is defined in RFC 2274, Sections 2.6 and A.2, and originally documented in
U. Blumenthal, N. C. Hien, B. Wijnen, "Key Derivation for Network
Management Applications", IEEE Network Magazine, April/May issue,
1997.
and that's the whole page, bestie π this was encode_keychange(1) from Net-SNMP, version V5.9.5.2, dated 16 Nov 2006 β go forth and derive your keys, you absolute main character ππ
π¦ where this page comes from
- alpine 3.23: net-snmp-doc 5.9.5.2-r0 Β· Net-SNMP
- alpine 3.24: net-snmp-doc 5.9.5.2-r0 Β· Net-SNMP
- arch rolling: net-snmp 5.9.5.2-2 Β· BSD
- fedora 44: net-snmp-utils 1:5.9.5.2-4.fc44 Β· MIT-CMU AND BSD-3-Clause AND MIT
- nixos 26.05: net-snmp 5.9.5.2
- nixpkgs unstable: net-snmp 5.9.5.2
- ubuntu stonking: snmp 5.9.5.2+dfsg-2.1ubuntu5
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms