Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
ソースコードのソースコードを読みたい
Search
tosio
February 09, 2024
370
0
Share
ソースコードのソースコードを読みたい
テテミート #7 2023/2/9
tosio
February 09, 2024
More Decks by tosio
See All by tosio
Gmailに届け
tosiooooooo
0
130
断頭台の大魔族がつながりレシピをお勧めしてくれるLINEbot
tosiooooooo
0
1.1k
Featured
See All Featured
Designing Experiences People Love
moore
143
24k
How to Think Like a Performance Engineer
csswizardry
28
2.5k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
133
19k
Lightning talk: Run Django tests with GitHub Actions
sabderemane
0
160
Learning to Love Humans: Emotional Interface Design
aarron
275
41k
Unsuck your backbone
ammeep
672
58k
HU Berlin: Industrial-Strength Natural Language Processing with spaCy and Prodigy
inesmontani
PRO
0
310
Hiding What from Whom? A Critical Review of the History of Programming languages for Music
tomoyanonymous
2
660
Measuring & Analyzing Core Web Vitals
bluesmoon
9
800
Making Projects Easy
brettharned
120
6.6k
We Have a Design System, Now What?
morganepeng
55
8.1k
BBQ
matthewcrist
89
10k
Transcript
ソースコードの ソースコードを読みたい Medley.inc Yuji Tamai
ソースコードという日本酒を買った
隠しメッセージ!
隠しメッセージ読んでみたい・・・ けど、写経はあまりに大変そう・・・ OCRでなんとかならんかな
ChatGPT4が使えると評判のBing Copilotでやってみた
全然ダメだった
AWS Rekognition使ってみた もっとダメだった
他に画像からテキスト起こすやつないかな・・・ Googleドライブでいけるらしい
Googleドライブに画像あげてGoogleドキュメントで開くだけ
結構いい感じ!
console.log(String.fromCodePoint([!![]+!![]+!![]+!![]+!![]+!![]+, [],+!![],+!![].].join("")),String.fromCodePoint([+!!,+!!],~~[]].join(""),String.fromCode ("")),String.fromCodePoint([+!![],+!![],!![]+!![]+!![]+!![],].join(""),String.fromCode []+!![]+!![]+!![]+!![]+!![]+!![],].join("")),String.fromCodePoint([+!![],+!![], ([+!![],+!![],+!![]+!![]+!![]+!![]+!![]+!![]+!![],].join("")),String.fromCode ("")),String.fromCodePoint([!![]+!![]+!![]+!![]+!![]+!![]+!![]+!![]+ ("")),String.fromCodePoint([+!![],+!![],+!![]+!![]+!![]+!![]+!![]+!![],].join(String.fromCode [],].join("")),String.fromCodePoint([+!![],+!![],+""[],].join("")),String.fromCode ("")),String.fromCodePoint([+!![],+!![],+!![]+!![]+!![]+!![]+!![],].join("")),String.fromCode ("")),)console.log(String.fromCodePoint([!![]+!![]+!![]+!![]+!![]
("")),String.fromCodePoint([+!![],+!![],+!![] なにこれ?
「+!![]」って何? JavaScriptでは、`+!![]`は次のように解釈されます: 1. `[]`は空の配列を表します。 2. `!`は論理否定演算子で、オペランドをブール値に変換し、その逆を返します。したがって、 `![]`は`false`を返します(なぜなら、空の配列は真と評価されます)。 3. 2つ目の`!`は、先ほどの`false`を再度否定し、`true`を返します。したがって、`!![]`は`true`を 返します。
4. 最後に、`+`は単項プラス演算子で、オペランドを数値に変換します。ブール値の`true`は数 値の`1`に変換されます。 したがって、`+!![]`は`1`を返します。このようなテクニックは、 JavaScriptの型変換の特性を利用したもので、しばしば難読化や圧縮のために使用されます。 🙂
試しに一部出してみた console.log(String.fromCodePoint([+!![],+!![],!![]+!![]+!![]+!![]+!![],].join(""))); => s console.log(String.fromCodePoint([1,1,1+1+1+1+1,].join(""))); console.log(String.fromCodePoint([1,1,5,].join(""))); => s
なぜ「s」が出るの? `String.fromCodePoint([1,1,5].join(""))`が"s"になる理由は、`String.fromCodePoint`メ ソッドがUnicodeのコードポイントを文字列に変換するからです。 まず、`[1,1,5].join("")`は配列の要素を連結して`"115"`という文字列を作ります。 次に、`String.fromCodePoint("115")`は、`"115"`を数値に変換し、その数値に対応する Unicodeの文字を返します。 Unicodeのコードポイント`115`は、小文字の`s`に対応しています。 したがって、`String.fromCodePoint([1,1,5].join(""))`は`s`を返します。🙂
そして隠しメッセージとは!!! 絶賛解析中です!!! 登壇に間に合いませんでした
曲面の文字列の解析大変 • Googleドキュメントでも文字起こし精度は7〜8割くらい • 元の文字が”[+!![],+!![],+!![]+!![]+!![]+!![]+!![]+!![]+!![],]”みたいなのばっかりだ から、より間違えられやすい • 曲面を3箇所から撮影してうまくつなぎ合わせればいけるかなと思ったけど、1 枚目の時点で面倒で途中で挫折 •
パノラマ撮影機能を使って結構いい感じに1枚の画像にできたけど、それでも 間違い探しが大変 • 間違え正すくらいなら、全部手で打った方が多分早い
解析完了したら 口頭で お知らせします!!! また何かのイベントでお会いしましょう
ご清聴ありがとうございました