Path: csiph.com!optima2.xanadu-bbs.net!xanadu-bbs.net!news.glorb.com!usenet.stanford.edu!not-for-mail From: Geir Hauge Newsgroups: gnu.bash.bug Subject: Re: bash displays strange characters after base64 decoding Date: Fri, 7 Aug 2015 15:08:03 +0200 Lines: 28 Approved: bug-bash@gnu.org Message-ID: References: <55C39D51.6010401@posteo.org> NNTP-Posting-Host: lists.gnu.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Trace: usenet.stanford.edu 1438952895 3591 208.118.235.17 (7 Aug 2015 13:08:15 GMT) X-Complaints-To: action@cs.stanford.edu Cc: bug-bash@gnu.org, bash@packages.debian.org To: Valentin Schmidt Envelope-to: bug-bash@gnu.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:content-transfer-encoding :in-reply-to:user-agent; bh=+Rt1ubtKyVcRkQV88H+NI7H7Y4h3fgim0oqEqkz57O0=; b=LQze39xWPiek90tpN4/AaQx3hJ3AicOalGUjv8N3RYn13RQzI1nO2ochS0Bngi2mmK 3IVHeCNwrxC1rYvZ1Ynk1mXjEUpNVaATxYD+DYhTZXJ2lIrITAZ6mkNBRtLhDgEKV3mE hrOqNbbaCHL/HE08k+9hoF22ne1y/HkO4rmk6vIELzK2xcCxycQfFZ1YggTT5DA5B4dQ cnBCMk350msiLyrKyldvcbLlKczXQX4M84AsVhzlEZyX63AviKN0TnVQtr85C7u3kASX HoyDgFzC2mQVKd+NePX0bQqgIAzygkcD0DMIf+Wqe+vIZZkTMZTSpCwFUC2Ww9cxy9vm Gagg== X-Received: by 10.152.42.244 with SMTP id r20mr7424895lal.90.1438952886036; Fri, 07 Aug 2015 06:08:06 -0700 (PDT) Content-Disposition: inline In-Reply-To: <55C39D51.6010401@posteo.org> User-Agent: Mutt/1.5.23 (2014-03-12) X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4010:c03::232 X-BeenThere: bug-bash@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Bug reports for the GNU Bourne Again SHell List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Xref: csiph.com gnu.bash.bug:11300 On Thu, Aug 06, 2015 at 07:45:53PM +0200, Valentin Schmidt wrote: > Bash displays strange characters (including command prompt) (see attached > png file) after the execution of the base64 (GNU coreutils 8.21) command > like described as follows: > base64 -d base64.txt Xterm has some escape sequences that switch between a second character set, where many of the ascii letters become line drawing characters instead. Try the following: printf %b '\e(0' {a..z} '\n' '\e(B' {a..z} '\n' This prints the 26 lowercase ascii letters in the second character set, entered by the sequence ESC ( 0, followed by the same line after switching back, with the sequence ESC ( B. In a Gnome Terminal on Ubuntu I get the following output from the above: ▒␉␌␍␊°±␤␋┘┐┌└┼⎺⎻─⎼⎽├┤┴┬│≤≥ abcdefghijklmnopqrstuvwxyz Sven Mascheck has written a bit about this fun feature here: http://www.in-ulm.de/~mascheck/various/alternate_charset/ -- Geir Hauge