X-Git-Url: http://git.cyclocoop.org/?a=blobdiff_plain;f=includes%2Flibs%2FCryptHKDF.php;h=c41aab339c33056a4ac32353a30401defe8cb47b;hb=06b472604535f8bac2a1e2aed0c57c23a9f59917;hp=4c867574182dc8cf1b2dcac5f75c1cf9f8afa520;hpb=dcdb8e463e3b2be121c61c91df13ea36d270a602;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/libs/CryptHKDF.php b/includes/libs/CryptHKDF.php index 4c86757418..c41aab339c 100644 --- a/includes/libs/CryptHKDF.php +++ b/includes/libs/CryptHKDF.php @@ -197,11 +197,11 @@ class CryptHKDF { * From http://eprint.iacr.org/2010/264.pdf: * * The scheme HKDF is specifed as: - * HKDF(XTS, SKM, CTXinfo, L) = K(1) || K(2) || ... || K(t) + * HKDF(XTS, SKM, CTXinfo, L) = K(1) || K(2) || ... || K(t) * where the values K(i) are defined as follows: - * PRK = HMAC(XTS, SKM) - * K(1) = HMAC(PRK, CTXinfo || 0); - * K(i+1) = HMAC(PRK, K(i) || CTXinfo || i), 1 <= i < t; + * PRK = HMAC(XTS, SKM) + * K(1) = HMAC(PRK, CTXinfo || 0); + * K(i+1) = HMAC(PRK, K(i) || CTXinfo || i), 1 <= i < t; * where t = [L/k] and the value K(t) is truncated to its first d = L mod k bits; * the counter i is non-wrapping and of a given fixed size, e.g., a single byte. * Note that the length of the HMAC output is the same as its key length and therefore @@ -217,7 +217,7 @@ class CryptHKDF { * @param string $ikm The input keying material * @param string $salt The salt to add to the ikm, to get the prk * @param string $info Optional context (change the output without affecting - * the randomness properties of the output) + * the randomness properties of the output) * @param int $L Number of bytes to return * @return string Cryptographically secure pseudorandom binary string */