util: io::load accepts base64 encoding without newlines

This commit also renames io::BASE_64 to io::BASE64.

refs #3741

Change-Id: I46286c72d12e685902a72ce8dab4a1385dc0fceb
diff --git a/src/util/io.cpp b/src/util/io.cpp
index 84db1e4..76fe18c 100644
--- a/src/util/io.cpp
+++ b/src/util/io.cpp
@@ -37,8 +37,8 @@
       case NO_ENCODING:
         t::streamSource(is) >> t::streamSink(os);
         break;
-      case BASE_64:
-        t::streamSource(is) >> t::base64Decode() >> t::streamSink(os);
+      case BASE64:
+        t::streamSource(is) >> t::stripSpace("\n") >> t::base64Decode(false) >> t::streamSink(os);
         break;
       case HEX:
         t::streamSource(is) >> t::hexDecode() >> t::streamSink(os);
@@ -69,7 +69,7 @@
       case NO_ENCODING:
         t::bufferSource(block.wire(), block.size()) >> t::streamSink(os);
         break;
-      case BASE_64:
+      case BASE64:
         t::bufferSource(block.wire(), block.size()) >> t::base64Encode() >> t::streamSink(os);
         break;
       case HEX: