PeterScott/streql — pull request #3 by appleorange1 (2014-10-29 07:59:44+00:00)
Title: Leak less information if strings are not equal in length

I'm currently packaging streql for Debian (https://lists.debian.org/debian-security/2014/10/msg00063.html) and this issue came up:

If two strings are that are not equal in length are compared, no further equality checking is done, meaning that comparing two strings of different length takes a lot less time than comparing two strings of the same length.

This pull request tries to fix that, by performing an equality check for as many characters as possible in strings of unequal length, thus increasing the time taken to perform the equality check. Some length information is still leaked, but not as obviously.