[PATCH 0/2] lib/base64: decode fixes

Josh Law posted 2 patches 1 week, 2 days ago
There is a newer version of this series
lib/base64.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
[PATCH 0/2] lib/base64: decode fixes
Posted by Josh Law 1 week, 2 days ago
Two small fixes for lib/base64.c:

1. base64_decode() writes a decoded byte to the output buffer before
   validating the input in the trailing-bytes path. Move the validity
   checks before any writes so dst is untouched on invalid input.

2. The @padding kernel-doc for base64_decode() was copy-pasted from
   base64_encode() and describes the wrong direction.

Josh Law (2):
  lib/base64: validate before writing in decode tail path
  lib/base64: fix copy-pasted @padding doc in base64_decode()

 lib/base64.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

-- 
2.34.1