GNU bug report logs - #38299
A bug while trying to decode a non encode base64

Previous Next

Package: coreutils;

Reported by: vardhaman narasagoudar <vardhamanbn <at> gmail.com>

Date: Wed, 20 Nov 2019 13:25:01 UTC

Severity: normal

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: vardhaman narasagoudar <vardhamanbn <at> gmail.com>
Subject: bug#38299: closed (Re: bug#38299: A bug while trying to decode a
 non encode base64)
Date: Wed, 20 Nov 2019 19:22:02 +0000
[Message part 1 (text/plain, inline)]
Your bug report

#38299: A bug while trying to decode a non encode base64

which was filed against the coreutils package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to 38299 <at> debbugs.gnu.org.

-- 
38299: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=38299
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Paul Eggert <eggert <at> cs.ucla.edu>
To: Martin Schulte <gnu <at> schrader-schulte.de>, 38299-done <at> debbugs.gnu.org
Cc: vijay.chaos <at> gmail.com, vardhaman narasagoudar <vardhamanbn <at> gmail.com>
Subject: Re: bug#38299: A bug while trying to decode a non encode base64
Date: Wed, 20 Nov 2019 11:21:39 -0800
On 11/20/19 6:22 AM, Martin Schulte wrote:
> vardhamanbn1 is a valid encoding

Thanks for explaining; closing the bug report.

[Message part 3 (message/rfc822, inline)]
From: vardhaman narasagoudar <vardhamanbn <at> gmail.com>
To: bug-coreutils <at> gnu.org
Cc: vijay.chaos <at> gmail.com
Subject: A bug while trying to decode a non encode base64
Date: Wed, 20 Nov 2019 16:46:45 +0530
[Message part 4 (text/plain, inline)]
Hi Team,

Looks like there is a bug while trying to decode a non-encode base64 for 12
characters (or multiple of 12) , the return code is always 0.

e.g:-

1) When trying to decode a encoded value
[vardhaman <at> oc6085028360 ~]$ echo  'Nzc3Nzk5Cg==' | base64 --decode
777799
[vardhaman <at> oc6085028360 ~]$ echo $?
0

2)   A sample when trying to decode a non-encode value
[vardhaman <at> oc6085028360 ~]$ echo  '777799' | base64 --decode
����base64: invalid input
[vardhaman <at> oc6085028360 ~]$ echo $?
1


3) Now trying to decode a non-encoded value of 12characters
[vardhaman <at> oc6085028360 ~]$ echo  'vardhamanbn1' | base64 --decode
��݅�����[vardhaman <at> oc6085028360 ~]$ echo $?
0

The point 3 should return code as 1 , as invalid input

I feel this bug is present in all version , anywhere sharing the current
version where I tested

vardhaman <at> oc6085028360 ~]$ base64 --version
base64 (GNU coreutils) 8.22
Copyright (C) 2013 Free Software Foundation, Inc.



-- 
Thanks & Regards
Vardhaman B.N
9945840928
[Message part 5 (text/html, inline)]

This bug report was last modified 5 years and 241 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.