Refactor the two padding schemes into two Codecs, similar to encoding/base64