This commit is contained in:
Moxie Marlinspike 2013-12-04 20:09:44 -08:00
parent 842df1ac39
commit 3c3028c8e3

View File

@ -58,7 +58,7 @@ public class HKDF {
private SecretKeySpec deriveMacKey(byte[] okm) { private SecretKeySpec deriveMacKey(byte[] okm) {
byte[] macKey = new byte[32]; byte[] macKey = new byte[32];
System.arraycopy(okm, MAC_KEYS_OFFSET, macKey, 0, macKey.length); System.arraycopy(okm, MAC_KEYS_OFFSET, macKey, 0, macKey.length);
return new SecretKeySpec(macKey, "HmacSHA1"); return new SecretKeySpec(macKey, "HmacSHA256");
} }
private byte[] extract(byte[] salt, byte[] inputKeyMaterial) { private byte[] extract(byte[] salt, byte[] inputKeyMaterial) {