public HashInfo(int keySize, Func<byte[], HashAlgorithm> hash) { KeySize = keySize; HashAlgorithm = key => (hash(key.Take(KeySize / 8))); } }