Base64 is actually very simple. It's also not an encryption algorithm, so this question probably fits better into Stack Overflow.
The idea behind Base64 is that you want to be able to take any binary data, and convert it into something that can be treated as ASCII text (i.e., letters, numbers and a few special characters). Binary data of course has 256 possible values per byte, but to get to a textual representation, you need to reduce that to no more than about 80 or less possible values. Since 64 is a power of two, that was chosen.
64 values is the equivalent of six bits. Consequently, every three bytes (24 bits) in the original binary translates into four bytes in Base64 (also 24 bits, as four groups of six).
The algorithm is simply:
- take the original binary.
- divide into groups of three bytes
- treat the three bytes as groups of 24 bits.
- divide these 24 bits into four groups of six bits.
- look up the corresponding letter for each six-bit group. This is your output.
You can find the translation table all over the Web, for instance here: http://email.about.com/od/emailbehindthescenes/l/blbase64enctabl.htm
There is one special case: at the very end of the binary data, you may have one or two bytes left over. That is why you will sometimes see = signs at the very end; they indicate padding.
With that in mind, your original text really does not look like Base64. It could be, but it does not look plausible. The long strings of 0's are a giveaway. Reversing the algorithm above, each 0 stands for the number 52 (looked up in the table), or 110100 in binary. So the sequence 0000 would correspond to the bit pattern 110100110100110100110100. Split that along eight-bit boundaries to get the original binary, and you get this:
11010011 01001101 00110100 or in hex D34D34
In in data, seeing long strings of zero values is a lot more plausible than long strings of D34D34. Even less plausible, the data starts with eleven 0's - if this really was a long string of data, one would expect multiples of four.