Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Remove base64 encoding of store secrets #33
It turns out that the mystery incompatibility in handling macaroons between Node.js and OCaml from #30, was that the macaroons.js can accept secrets as either utf-8 strings or Buffers, with Buffers being more efficient. The arbiter was minting macaroons with Buffers, which results in distinct signatures than with strings, even if it's the same bytes as the lib's code shows.
Since ocaml-macaroons deals with strings, the past changes switched to string secrets. This inadvertently broke store-json. @Toshbrown remedied this by moving that also to strings in me-box-archive/store-json#6. And since we're modifying that, we took the opportunity to close #32 too. With that change, all is well in the world, and the new ocaml store also doesn't need to base64 decode anything.