BASE64(1)

πŸ“¦ version 1.053, in alpine 3.24

πŸ’… BASE64(1) β€” the girlboss guide to encoding ✨

okay so real talk, this is a page from the User Contributed Perl Documentation section of the manual, and it's literally just called BASE64(1). yes bestie, base64. the thing that turns your files into alphabet soup. she's iconic, she's useful, let's go πŸŽ€


✨ NAME ✨

base64 β€” encode and decode base64 data πŸ¦‹

like, that's it. that's her whole job. and she does it well.


🌸 SYNOPSIS 🌸

base64 [-dv] [-o FILE] [FILE]

short, sweet, slays every time. let's break the vibe down πŸ’–


🫢 DESCRIPTION 🫢

🧚 the encoding era (default mode)

so when you're encoding β€” which is the default mode, meaning you don't even gotta ask, she just does it β€” a binary file gets read in, and a base64 format file gets created. cute, right? ✨

and if you don't hand her an input file argument at all? or you pass - as the file? she just reads from stdin. no drama, no fuss. 🫢

the base64 output contains 76 characters per line. every line. 76. periodt. πŸ’…

and where does output go by default? stdout. obviously. ✨

πŸ” the decoding era

when you're decoding, the input file is expected to contain only valid base64 characters β€” and those are alphanumeric characters, plus +, plus /, plus =. that's the whole guest list, no plus-ones. πŸ‘‘

spaces are ignored when decoding. so breathe, bestie, whitespace is fine πŸ’–

⚠️ but listen β€” selecting a binary file as input will result in an error. like, it will genuinely not go well for you. this is the vibe check and the binary file is failing it πŸ’€

πŸ’… OPTIONS πŸ’…

the following options are available, and yes, there are only three, she's low-maintenance:

  • -d β€” decode data. literally the uno-reverse of the default mode πŸ”„
  • -o FILE β€” write output to the specified FILE. where you tell her to drop the goods πŸ’Œ
  • -v β€” print version number and exit. she'll tell you who she is, then she's gone πŸ‘‹βœ¨

😭 BUGS 😭

okay so here's the tea, and it's giving "i love her but" β˜•

  • no option exists for wrapping encoded base64 output at different column widths. so you're getting 76 characters per line and that's the whole menu. she said this is the width. πŸŽ€
  • it might be desirable to ignore unrecognised input characters when decoding. key word: might. this version of base64 has no option for relaxing the input validation. strict queen. no exceptions, no mercy, no exceptions-to-the-exceptions πŸ™ˆ
ngl these are real limitations, not vibes-based ones β€” don't go looking for a flag that isn't there πŸ’€

πŸ‘‘ AUTHOR πŸ‘‘

written by Michael Mikonos. thank you for your service, king 🫑✨


Copyright (c) 2023 Michael Mikonos.

this code is licensed under the Artistic License 2. 🎨


okay that's the whole page, you're officially base64 literate, go encode something and feel something πŸ’–βœ¨πŸ¦‹

signing off from perl v5.42.2, dated 2026-02-15, in the BASE64(1) section β€” mwah, ily, see you in the group chat πŸŽ€πŸ’œ

πŸ“¦ where this page comes from