About the Octal to Base64 Converter
Octal byte values turn up in old dumps, in C string escapes, in Python source and in the output of tools that predate the general move to hexadecimal. Getting them into a modern payload usually means one hop through Base64, and that is all this converter does.
Values may be separated by spaces, commas, semicolons, pipes or line breaks. Backslashes and 0o prefixes are treated as separators too, so a C escape sequence such as \123\150\151 is read correctly without any editing. A single unbroken run whose length divides by three is sliced into triplets automatically, which handles output that arrived with no separators at all.
Two checks protect the result. A token containing a digit 8 or 9 is rejected by name, because those digits do not exist in octal and their presence almost always means the values were decimal. A token whose value exceeds 255 is rejected as well, with the decimal equivalent shown, since a byte cannot hold it. Neither case is silently truncated.
The URL-safe checkbox produces the alphabet used by tokens and path segments, and the wrap widths give the block layout expected in PEM files and MIME bodies. Read the values back out with Base64 to Octal, or compare bases side by side in Number Base Converter.
How to use
- Paste octal values separated by spaces, commas, backslashes or line breaks.
- Check the status line for the number of values that were read.
- Tick URL-safe alphabet or set a wrap width if the destination requires it.
- Copy the Base64 result.
Common questions
- Why was my value rejected as too large?
- Anything above 377 octal is more than 255 decimal, which will not fit in a byte. The error shows the decimal value so you can spot the mistake.
- Do I need to pad values to three digits?
- No. A value such as 40 is read as 32 decimal, exactly the same as 040.
- Can I paste a C string escape directly?
- Yes. Backslashes act as separators, so a run of escape sequences converts without any cleanup.
- What if my numbers were actually decimal?
- Any 8 or 9 will trigger an error. If there is none, the values will convert but produce the wrong bytes, so check the source before trusting the result.