TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

The Catch 22 of Base64: Attacker Dilemma from a Defender Point of View

15 pointsby WhiteSource1about 7 years ago

4 comments

zrmabout 7 years ago
&gt; based on the assumption that legitimate users have no practical need to do multiple encoding of the same text.<p>Things can legitimately be encoded multiple times because encapsulation is a thing and multiple independent stages may each be configured to accept possibly binary input and produce base64 output.<p>You also don&#x27;t need to re-encode something an unreasonable number of times to get &quot;Vm0wd&quot;, all you have to do is start with &quot;Vm0&quot; and base64 encode it twice. &quot;Vm0&quot; only has 24 bits of entropy which means it will regularly occur at random in legitimate data.<p>And then nobody can figure out why &quot;Vm0-Edge-West&quot; isn&#x27;t working.
benchaneyabout 7 years ago
I&#x27;m not really sure what the threat model is here. If the attacker can control what encoding scheme you use, surely you have much more serious problems than the possibility of wasting space.
评论 #16969783 未加载
loup-vaillantabout 7 years ago
&gt; <i>While Base64 encoding is very useful to transfer binary data over the web</i><p>This part I cannot fathom. The era of 7-bit bytes is over. What can possibly justify the need for a &quot;printable characters&quot; encoding now? Something stupid like putting data in a JSON string? What&#x27;s the next step, base-64 encode the JSON containing that string and put it in an XML tag?
评论 #16969770 未加载
评论 #16969818 未加载
boneitisabout 7 years ago
To really crank up the pedant-O-meter, wouldn&#x27;t it be accurate to instead describe the output growth in point #1 as polynomial, even sub-quadratic?
评论 #16975020 未加载
评论 #16969488 未加载
评论 #16969397 未加载
评论 #16969496 未加载