|
There's a subtle flaw in your design here. You're selectively discarding data with meaning and those decisions can be seen and you are not being strict enough with your rules about reuse of data. Although the user doesn't have to use the first possible index according to this scheme, chances are they would (and you did in your example) The short form of the problem is where you say "No offset can be used more than once." where you actually want "No offset can be used unless it is higher than all previously used offsets". Consider an assassin and their controller using this scheme for designating targets. Garry is first, the controller sends 10, 13, 16, 19, 22 = garry
The security services intercept this and notice that garry is killed.They now know that 0-9 != g, 11-12 != a, 14-15 != r, 17-18 != r, 19-21 != y They suspect that either andi or rory is the next target, the controller orders Andy killed and sends: 0, 15, 17, 27 = andi
The security services can then infer that the person to be killed is matched by the regex: ^[^g][^r][^r].$
andi matches, rory doesn't.It's much better to treat your random characters as numbers to add to the your data mod 256 (in your ASCII 256 example), and also set rules like fixed message length and scheduled messages that can be 'no-op'. |