BOS_ADDKEY(8)
π BOS_ADDKEY π
okay so bestie, welcome to bos_addkey, from the OpenAFS command reference (section 8, admin girlies only β¨). It's the little command that adds a new server encryption key to the KeyFile file. Yes, that KeyFile. Put your seatbelt on, we're going to the key party π
πΈ NAME πΈ
bos_addkey β adds a new server encryption key to the KeyFile file. that's it, that's the whole job description, she's a one-trick pony and she's iconic for it π
β¨ SYNOPSIS β¨
bos addkey -server <machine name> [-key <key>]
-kvno <key version number> [-cell <cell name>]
[-noauth] [-localauth] [-help]
bos addk -s <machine name> [-ke <key>]
-kv <key version number> [-ce <cell name>] [-n]
[-l] [-h]
two forms, same girl π« the long one is her government name, the short one is what you call her in the group chat. every flag's abbreviated twin is right there β -s for -server, -ke for -key, -kv for -kvno, -ce for -cell, -n for -noauth, -l for -localauth, -h for -help. no cap.
π¦ DESCRIPTION π¦
The bos addkey command constructs a server encryption key from the text string you give it, assigns it the key version number you specify with the -kvno argument, and adds it to the /etc/openafs/server/KeyFile file on the machine named by the -server argument. building a key from scratch, naming it, filing it. multitasking queen π
ngl bestie, normally you should be using asetkey add instead of this command β go read asetkey(8) for the details, she explains it way better. The primary use of bos addkey is for cells that are still using the Authentication Server instead of a Kerberos v5 KDC. It may, however, also be useful in unusual circumstances where a key needs to be added based on a known password rather than via a Kerberos v5 keytab. niche? yes. useless? no π«Ά
When you're using bos addkey with an AFS cell that uses the Authentication Server, be sure to use the kas setpassword or kas setkey command to add the same key to the "afs" entry in the Authentication Database. two places, same key, don't leave her twin hanging π
π¨ Do not use the -key argument, bestie. it literally echoes the password string visibly on the screen. everyone in the room, everyone on the scrollback, everyone who ever does a screen share. If you omit the argument, the BOS Server prompts for the string and does not echo it visibly:
Input key:
Retype input key:
see? polite. discreet. the moment.
The BOS Server prohibits reuse of any key version number already listed in the /etc/openafs/server/KeyFile file. this is not being annoying for fun, it's so that users who still have tickets sealed with the current key are not prevented from communicating with a server process just because someone overwrote the current key with a new one. Use the bos listkeys command to display the key version numbers in the /etc/openafs/server/KeyFile file. check before you wreck π
π CAUTIONS π
okay this is the part where I hold your hand, because it's real.
In the unusual case of using bos addkey to add a key with a known password matching a password used to generate Kerberos v5 keys, the key in the Kerberos v5 KDC database must have only the DES encryption type and must use "afs3" salt, not the default Kerberos v5 salt. Otherwise, the key generated by bos addkey will not match the key generated by the Kerberos v5 KDC. and then nothing works and you're sad. π
This command can only add keys to the KeyFile; these keys must be DES keys. The stronger keys used by the rxkad-k5 extension are stored in the KeyFileExt, which is not supported by this command. she literally cannot, don't ask her to π
As such, the use of this command is disrecommended; use asetkey(8) instead to benefit from the increased security of the rxkad-k5 extension. I'm not saying it, the manpage is saying it, and honestly? she's right. periodt.
π OPTIONS π
-server <machine name>β Indicates the server machine on which to change the/etc/openafs/server/KeyFilefile. Identify the machine by IP address or its host name (either fully-qualified or abbreviated unambiguously). For details, seebos(8).
In cells that use the Update Server to distribute the contents of the /etc/openafs/server directory, it is conventional to specify only the system control machine as a value for the -server argument. Otherwise, repeat the command for each file server machine. For further discussion, see bos(8).
-key <key>β Specifies a character string just like a password; the BOS Server calls a DES conversion function to encode it into a form appropriate for use as an encryption key. Omit this argument to have the BOS Server prompt for the string instead. (and please omit it, see the dramatic warning above π)-kvno <key version number>β Defines the new key's key version number. It must be an integer in the range from 0 (zero) through 255. For the sake of simplicity, use the number one higher than the current highest key version number; use thebos listkeyscommand to display key version numbers.-cell <cell name>β Names the cell in which to run the command. Do not combine this argument with the-localauthflag. For more details, seebos(8).-noauthβ Assigns the unprivileged identity"anonymous"to the issuer. Do not combine this flag with the-localauthflag. For more details, seebos(8).-localauthβ Constructs a server ticket using a key from the local/etc/openafs/server/KeyFileor/etc/openafs/server/KeyFileExtfile. Theboscommand interpreter presents the ticket to the BOS Server during mutual authentication. Do not combine this flag with the-cellor-noauthoptions. For more details, seebos(8).-helpβ Prints the online help for this command. All other valid options are ignored. she said what she said π
π OUTPUT π
If the strings typed at the "Input key" and "Retype input key" prompts do not match, the following message appears, and the command exits without adding a new key:
Input key mismatch
typo protection, we love to see it π«Ά
β EXAMPLES β
The following command adds a new server encryption key with key version number 14 to the KeyFile file kept on the machine "fs1.example.com" (the system control machine). The issuer omits the -key argument, as recommended, and provides the password at the prompts.
% bos addkey -server fs1.example.com -kvno 14
Input key:
Retype input key:
look at her. no password on the command line, no leaks, just vibes and a -kvno 14 β¨
π PRIVILEGE REQUIRED π
The issuer must be listed in the /etc/openafs/server/UserList file on the machine named by the -server argument, or must be logged onto a server machine as the local superuser "root" if the -localauth flag is included. pick your lane bestie, both work π
π¦ SEE ALSO π¦
KeyFile(5), KeyFileExt(5), UserList(5), asetkey(8), bos(8), bos_listkeys(8), bos_removekey(8)
go read asetkey(8) fr fr, she's the one you actually want πΈ
π COPYRIGHT π
IBM Corporation 2000. <http://www.ibm.com/> All Rights Reserved.
This documentation is covered by the IBM Public License Version 1.0. It was converted from HTML to POD by software written by Chas Williams and Russ Allbery, based on work by Alf Wachsmann and Elizabeth Cassell.
and that's the whole page π brought to you by OpenAFS, dated 2026-07-27 β go add that key, but maybe use asetkey instead, ily, bye πβ¨
π¦ where this page comes from
- ubuntu stonking: openafs-client 1.8.16.1-1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms