You are on page 1of 1

ANEW

57
VARIABLE
S"
:\CREATE
\\ Bin-to-Ascii
3Bin-to-4Ascii
Encode-a-Line
Encode-the-File
BASE64ENCODE
Ascii-to-Bin
4Ascii-to-3Bin
Decode-a-Line
Decode-the-File
BASE64DECODE
CONSTANT
File-Span
Bin-to-Ascii
3Bin-to-4Ascii
ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="
Encode-a-Line
*Encode-the-File
*******************************************************************
Ascii-to-Bin
4Ascii-to-3Bin
Decode-a-Line
Decode-the-File
*************************
CREATE
Base64-Alphabet
(MARKER
363
3Bin-to-4Ascii
Write-Ascii-Line
WHILE
CLIPBOARD
2DROP
Inverse-Base64-Alphabet
;:COUNT
dup
0\2dup
DROP
PAD
BEGIN
UNTIL
CR
--BASE64--
//http://www.oac.uci.edu/indiv/ehood/MIME/1521/rfc1521ToC.html
arbitrary
humanly
simple,
percent
virtually
(PEM)
Aeliminates
character,
function.)
US
represented
popular
utility
PostScript,
fulfill
left
concatenating
treated
translated
must
first.
That
bit
low-order
Each
printable
is
representable,
particular
"-").
Value
The
lines
other
decoding
those
indicate
or
circumstances.
Special
available
encoding
When
group,
number
performed
an
arise:
multiple
will
padding,
bits;
characters
final
followed
Because
that
in
Any
ignored
illegal
as
Care
if
has
line
base64
be
canonicalization
NOTE:
encapsulation
multipart
the
GET-UNENCODED-FILE
PUT-ENCODED-LINE
Get-Unencoded-File
Put-Encoded-Line
Variable
Write
SALT
END
+LOOP
Encode
Write-Ascii-Line
Needs
GET-ENCODED-LINE
PUT-DECODED-FILE
Get-Encoded-Line
Put-Decoded-File
Repack
Convert
Save-Ascii-Line-Length
PAD
?DO
Base64-Alphabet
Inverse-Base64-Alphabet
AND
Pad
Pick
Initialize
Encode
Discard
Save
Reset
Decode
65-character
Clipboard-Buffer
TYPE
Inverse-Base64-Alphabet
65
COUNT
Bin-to-Ascii
21CASE
PAD
ENDCASE
0dup
LOOP
16
Append-Char
2dup
File-Span
0=
1+
Get-Encoded-Line
CLIP
CLIPBOARD
represented
ASCII,
output
placed
Table
10
11
12
13
14
15
16
even
integral
transit).
"====="
base64
done
8+File-Span
0Save-Ascii-Line-Length
Base64
encoding
in
9876543210encapsulation
output
occurrence
number
characters
not
)base64
OF
?DO
Ascii-to-Bin
;(C!
\\
tostr)
is,
6-bit
fewer
be
the
must
breaks
Clipboard-Buffer
0INITIALIZATION
input
>R
Get-Unencoded-File
(RSHIFT
File-Span
applications,
This
Table
QPONMLKJHGFEDCBAEncoding
of
characters
in
here,
quantum
unit
There
#Bytes-at-a-Time
Clipboard-Buffer
I6-bit
INITIALIZATION
Base64-Alphabet
up
18
12
[char]
ENDOF
COUNT
your
>R
OUTFILE
EMIT
THEN
length
zero
of
(1)
encoding.
dup
CR
a6;DO
the
File-Span
)str
BASE64DECODE
DROP
7-bit
1-
PAD.
flag)
5.2.
readable.
but
larger
encodings,
and
right,
as
apresumed
processing
an
it
in
sequence
been
directly
BASE64ENCODE
Base64-Alphabet
16
R>
-2
(-1
7-bit
encoded
the
Decode-a-Line
is+dup
the
1,
no
software.
aTable
quantum
of
(2)
by
end
for
binary
830SALT
RSHIFT
;given
COUNT
empty
//
sequences
identical
and
strings
bit
characters.
in
message
at
6-bit
using
be
encoding
;entities
str
Split-Next-Line
Content-Transfer-Encoding
"=",
4subset
into
bit
first
group
significance
stream
transmission
than
the
integral
followed
is
of
base64-encoded
encoding.
#Bytes-at-a-Time
with
R@
bytes
LSHIFT
OR
file.
PAD
len)
definitions
4Ascii-to-3Bin
adapted
identically
do
portability
below,
1:
more
bits
number
24
the
one
must
is
binary
Put-Encoded-Line
output
;record.
!C@
(line.
mail
process
concatenated
first
taken
converted
=the
(of
Ascii
PAD
for
Base64
3all
in
of
used
No
octets
boundaries
;SWAP
C!
--
@len)
10
(encoded
str
\\
than
"*"
subset
per
anot
stream
and
The
1,
final
bits;
of
outside
no
C+!
;)PAD
[char]
DROP
@line.
encoded
is
base85
a8-bit
Value
24
groups.
final
"="
nthe
two
Bin-to-Ascii
input
Encode-a-Line
-1
line
file
ascii
str
--
24-bit
to
byte,
the
output
than
not
end
is
are
final
encoding
such
of
be
The
by
step
length
(=)@at
18
12
R>
Append-Char
3later.
has
characters
must
of
single
boundaries
(encoded
line
rejection
any
need
65
0--
>R
6(R>
len)
The
mechanism
printable
used
such
share
bit
are
the
Base64
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
input
of
only
is
because
nCOUNT
as
3MOVE
Append-Char
buffer.
=.Encode-the-File
IF
ascii
to
str
4--
)0=
//
of*/
to
as
from
be
used
In
always
'='
multiple
by
padding
data
characters
converted
(the
nul
aR>
str
--
LSHIFT
;OR
len
Content-Transfer-Encoding
4represents
first
found
of
added
quantum
here,
transmitted
important
--
as
)ALLOT
OR
.MOD
IF
to
ofDecode-the-File
the
input
via
The
hgfedcbaZYXWVUTSREncoding
76
performed
octets,
unit
output
'='
assurance
use
applied
in
.str
addr
7-bit
time.
for
Ascii
)6-bit
=+--
IF
octets
the
defined
encoding
meet.
encoded
ordered
in
and
selected
set
base64
breaks,
quantum
two
of
to
#Bytes-at-a-Time
PLACE
)1+
for:
str
DROP
--
len
str'
data
unencoded
in
as
requirements
input
string.
to
error,
the
character.
for
.encoder
)of
I7-bit
bytes.
>R
BASE64ENCODE
len
binary.
=(C@
--
Put-Decoded-File
BASE64DECODE
\\
BASE64
RFC
US-ASCII
these
digit
as
characters
bits
Padding
has
some
within
str
dup
C@
)--
important
6-bit
character
Alphabet
input
characters
data.
the
canonical
worry
len
--
+256
C!
.later.
str'
str
IF
NIP
2DROP
one
signify
all
byte,
excludes
SMTP
bytes)
in
completed
(on
of
"="
no
)the
len
;--
>R
R>
3flag
groups.
an
might
data
character.
padding
MIN
Ascii.
.(C@
--
13
to
)binary
are
1421,
for
character.
in
defined
of
will
been
;.len
+LOOP
//
in)6-bit
group
stream
Table
data,
are
only
encoded
base64
proper
directly
into
implementations.
hyphen
--
Ascii.
ALLOT
65
str)
str+1)(
str+2)(
;.)str+3
flag
OR
len
1-
used
versions
encoding
properties,
characters.
with
eighth
index
and
about
the
final
of
padding
in
.thing
binary
(Inverse-Base64-Alphabet
REPEAT
more
and
the
specified
24-bit
groups,
These
so
(e.g.,
Value
if
4encoding
is
rather
about
base64-encoded
./STRING
)THEN
EXIT
a\\
consistently
embedded
and
being
at
was
The
)more
str
FILL
str+3)
>R
EXIT
data.
RFC
is
must
available
characters
encoding
be
reached
the
flag
--
THEN
form
awith
as
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
other
fewer
right)
the
exactly
possible,
CRLF
)pieces.
decoding
in
property
subset
is
These
referenced
1each.
characters
the
Since
at
form.
)xxx)(
is**************************
used,
special
encoding,
will
so
into
in
which
appropriate
at
unit
three
amay
alphabet
same
octets
to
characters
len
)(binary.
THEN
1421.
bit
characters,
to
yxwvutsrqponmlkjiEncoding
must
output
base64
)quoting
line.
R:
THEN
Privacy
binary
groups
formed
".",
be
encoded.
following
characters,
the
multiple
to
)than
str+1)(
str+2)(
str+3)(
str+4
str+4)
//
designed
that
one
(The
of
used
each
most-significant-bit
on.
this
the
end
sequences
2note
/SPLIT
2DROP
\R:
This
white
than
input
be
more
x)
;xx)
clear
as
24
be
will
an
represented
to
all
of
(without
applies
text
+In
enabling
ISO
are
EBCDIC.
and
Proceeding
All
abe
input
16
characters
end
Wil
The
change:
universally
CR,
end
of
taken
for
in
(ALLOT
\\
need
algorithms
extra
processing
that
by
part
bits
of
alphabet.
the
array
document
warning
form
encoded
with
will
however,
encoding,
particular,
)is
bbb)(
only
encoding
transport
of
by
ignored
24
base64
bits;
are
)apparent
;(str
Enhanced
646,
also
thus
be
by
with
line
other
space
an
the
is
of
amaterial
parts
R:
Baden
base64
text.
the
which
LF)
Value
(pad)
of
line
that
are
end)
tolen)
input
high-order
under
Abits
cases
is
prior
//
not
it
of
are
identified
input
an
no
be
the
as
to
prior
b)
bb)
bbb)
about
65th
bit
of
51
52
53
54
55
56
57
58
59
60
61
62
63
afull
data
or
truncation
three.
R:
represent
6base64
including
Other
uuencode
do
and
breaks
exactly
here,
used
is\\
Level
than
probably
message
body.
input
integral
output
"="
two
evidence
be
any
breaks
this
of1997-11-17
be
bits
from
then
is
64
index
(e.g.,
=/+9876543210zEncoding
in
by
are
(3)
data,
)when
isto
not
bits
When
stream
some
can
+such
are
Mail
is
that
33may
text
in
C!the
2to8 *\\
or
is
//

You might also like