support configurable code lengths

I plan to use this app to support Digits-style authentication. 20 character is simply too long so the first step is to make the code length configurable.