Live data from Hacker News

Decoding the obfuscated bash script on a Uniqlo t-shirt

tris.sherliker.net

131–140 of 253 posts

Re: Decoding the obfuscated bash script on a Uniqlo t-shirt

#131
The font is Roboto Mono, not Consolas.

There's something else a lot stranger going on, though. It is a proper monospace font, but the typesetting on the shirt is not. There's some kerning going on (I noticed it especially in the 'Iy' pair), and also it appears that narrower characters such as 'i' take less horizontal space. If I had to guess, I would say that it was set with a tool such as "optical kerning" in InDesign.

Re: Decoding the obfuscated bash script on a Uniqlo t-shirt

#132
post #98

Earlier quoted context omitted.

You may want to retract that bet: https://news.ycombinator.com/item?id=48830846

Yeah, I read that later. My bet is against manual OCR with various engines + finding mistakes later using an LLM.

I'd rather find the mistakes with my human brain. Keeps me limber. I might even accidentally learn something.

Re: Decoding the obfuscated bash script on a Uniqlo t-shirt

#133

"Uniqlo x Akamai sells another design of shirt in the same range which is plainly incomplete" Imagine having to return a t-shirt because that malfunction! — I don't understand why are you returning this, was the size wrong or you didn't like it? — No, there is a syntax error at line 37 that makes it impossible to run, and I'm concerned people on the street may think I promote unsafe bash scripting.

Worked on my torso

Re: Decoding the obfuscated bash script on a Uniqlo t-shirt

#135
post #124
post #76

Earlier quoted context omitted.

I watched that whole video link - thank you for that - and he doesn't really say. In fact, he spends much more time on the beige color harkening to computer case plastics of the 80s & 90s. The AI not handling the output relates to the final base64 output on the T-shirt (which other comments in this thread mention manually keying in or TFA discusses in the context of OCR). So, that is just not relevant to the question…

You mention someone else's Python version. Did you note that the prototype in the video was... Python? All the smells you pointed out, just look like a Python dev approaching bash without fully understanding it.

Yeah. The Flask web-page prototype was indeed in Python. (The prequel shirt was Go.)

{ Also, it was my own Py version which I mostly did in case anyone wanted to actually run the thing after such interest was expressed on this thread. :-) }

I already said regular devs and LLMs can both gen copy-pasta. That said, being "mostly" a Python dev, asking some LLM to translate to bash for him seems even more likely to me. Only he or those close to him knows for sure. You & I cannot settle it here conclusively (as also said).

I also noted from the video that the ♥s (hearts) worked on whatever version of bash he tested with though it failed for me (which is why I wrote that Python). And his terminal title bar is switching between `tput` and `bc` and such meaning that what he was demoing was not some Python script. ¯\_(ツ)_/¯

EDIT: Ah..another resolution of the hearts is to not run in an LC_ALL=C environment. Oops! `LC_ALL=en_US.UTF-8 bash ..` fixed it. Oh well, I think the Python script is nicer in almost every way. E.g., you could |head -n60 and send it to a line printer/dot matrix reminiscent of the 1980s computers he shows in the video, although your printer driver would have to strip the color escapes with a `sed` or maybe https://github.com/c-blake/bu/blob/main/noc.nim. ;-)

Re: Decoding the obfuscated bash script on a Uniqlo t-shirt

#136
post #124

Earlier quoted context omitted.

You mention someone else's Python version. Did you note that the prototype in the video was... Python? All the smells you pointed out, just look like a Python dev approaching bash without fully understanding it.

> All the smells you pointed out, just look like a Python dev approaching bash without fully understanding it. also, referring to Linux as "the language of the internet" when bash isn't particularly suited for internet tasks also smell like "excited windows Python dev"...

FWIW, his screens looked a lot like OSX to me (which tracks with graphic design users in my experience).

Anyway, he seems like a very nice fellow and I wish him and almost all T-shirt designers well. That bash script just gave me a lot of pause. (And even that seems possibly downstream of him being nice and doing it himself to spare his team from what he called a "FrankenProject".)

Re: Decoding the obfuscated bash script on a Uniqlo t-shirt

#138
Neat. My only critique of the script is that I would have added a

  sleep 0.1 
in the loop so that as this prints in a terminal it is actually readable; any modern terminal will scroll so fast you can't see the message in flight.

Slowing it to a 10hz refresh makes it look great.

Re: Decoding the obfuscated bash script on a Uniqlo t-shirt

#139
Huh! I was sure the copy-text-from-image feature in MacOS would handle this flawlessly. But the best run I managed produced the following:

    base64: stdin: (null): error decoding base64 input stream
    #!/bin/bash
    
    # Congratulations! You found thu eastur ugg!#B��O��
    # おめでとう��M�ぇM�す!隣C��わM�サ�#ライ����見でM�������!O��
    
    # Define thu tuxt to anima|e
    text="♥PEACE♥FOR♥ALOB��PEACE♵FOR♵ALL♵PEACE♥FOR♥ALL♥PEACE♥FOR♥ALL♥PEACE♵FOR♵ALL♥"
    
    # Get termb�al dmmensions
    cols=$(tput cols)
    linus=$(tput lines)

Re: Decoding the obfuscated bash script on a Uniqlo t-shirt

#140

Neat. My only critique of the script is that I would have added a sleep 0.1 in the loop so that as this prints in a terminal it is actually readable; any modern terminal will scroll so fast you can't see the message in flight. Slowing it to a 10hz refresh makes it look great.

Maybe you can sew a patch into it?
Post reply on HN