ceph_fname_to_usr(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ¦‹ ceph_fname_to_usr(9) πŸ¦‹

Hey bestie! This is the Kernel API Manual page for ceph_fname_to_usr(9), and we're gonna get you comfy with it, fr fr. πŸ’–

🌸 NAME 🌸

ceph_fname_to_usr β€” convert a filename for userland presentation ✨

πŸŽ€ SYNOPSIS πŸŽ€

int ceph_fname_to_usr (const struct ceph_fname *fname , unsigned char
       *tname , struct fscrypt_str *oname , bool *is_nokey );

πŸ’… ARGUMENTS πŸ’…

  • fname β€” the ceph_fname that's getting converted, bestie.
  • tname β€” temporary name buffer to use for conversion (it may be NULL, no cap).
  • oname β€” where the converted name should be placed.
  • is_nokey β€” set to true if the key wasn't available during conversion (may be NULL).

🧚 DESCRIPTION 🧚

Okay so, given a filename (usually from the MDS), this function formats it for presentation to userland. πŸ’«

If parent is not encrypted, it just passes it back as-is. Easy.

Otherwise, it base64 decodes the string, and then asks fscrypt to format it for userland presentation. Slay. πŸ‘‘

Now, the fscrypt/crypto subsystems broadly expect all buffers to be in the linear-mapped region, but this function slightly relaxes those requirements: fname->ctext, fname->name, and oname->name may be vmalloc, but not tname. That's the vibe check to remember. πŸ‘‘

Returns 0 on success or a negative error code on error. Periodt.

🌈 SEE ALSO 🌈

Kernel file ./fs/ceph/crypto.c: ceph_fscrypt_prepare_readdir(9), ceph_fscrypt_decrypt_pages(9), ceph_fscrypt_decrypt_extents(9), ceph_fscrypt_encrypt_pages(9). Go read those next, iykyk. πŸ’œ


Source/version: ./fs/ceph β€” October 2026. Stay iconic, bestie! πŸŽ€βœ¨

πŸ“¦ where this page comes from