Ascertain key length