[Ksummit-discuss] Fwd: [TECH TOPIC] QR encoded oops for the kernel

Johannes Berg johannes at sipsolutions.net
Wed May 14 08:20:52 UTC 2014


On Tue, 2014-05-13 at 13:18 -0700, josh at joshtriplett.org wrote:

> > Base32 does sound good until you realize that it requires roughly 20%
> > more space than Base64 does. We would need some calculations to
> > decide if we were to go down this path.
> 
> QR has several encoding modes; it doesn't matter that base32 uses more
> space in terms of characters, because QR itself has an alphanumeric
> encoding mode that only uses 5.5 bits per character to encode 45
> possible alphanumeric/symbol characters.  base64 wastes far more
> relative to bytes (6 versus 8 bits) than base32 wastes relative to QR
> alphanumeric (5 versus 5.5 bits).

This subthread is kinda going on a tangent now, but ...

The valid characters seem to be

0-9A-Z $%*+-./:

so you'll need to be careful to not use a ? for URL parameters [1],
otherwise the QR encoder will likely have to pick binary/byte encoding.

Since you really wouldn't want to use % due to URL-encoding
difficulties, and $ and space also seem a bit questionable, you could
still extend the encoding alphabet to at least base36 (0-9A-Z) and even
add +-./: without much difficulty to get to base41.

johannes

[1] i.e. the previously suggested https://oops.kernel.org/?qr=... will
not work




More information about the Ksummit-discuss mailing list