ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/gvpe/src/connection.C
(Generate patch)

Comparing gvpe/src/connection.C (file contents):
Revision 1.105 by root, Fri Jul 19 18:22:54 2013 UTC vs.
Revision 1.106 by root, Fri Jul 19 21:01:16 2013 UTC

180} 180}
181 181
182static void 182static void
183auth_hash (const auth_data &auth, const ecdh_key &b, auth_mac &mac) 183auth_hash (const auth_data &auth, const ecdh_key &b, auth_mac &mac)
184{ 184{
185 hkdf kdf (&auth.ecdh, sizeof (auth.ecdh), AUTH_DIGEST ()); // use remote ecdh b as salt 185 hkdf kdf (b, sizeof b, AUTH_DIGEST ()); // use response ecdh b as salt
186 kdf.extract (&auth.rsa, sizeof (auth.rsa)); 186 kdf.extract (&auth.rsa, sizeof (auth.rsa));
187 kdf.extract_done (); 187 kdf.extract_done ();
188 kdf.expand (mac, sizeof mac, b, sizeof b); // use response ecdh b as info 188 kdf.expand (mac, sizeof mac, auth.ecdh, sizeof (auth.ecdh)); // use challenge ecdh b as info
189} 189}
190 190
191void 191void
192connection::generate_auth_data () 192connection::generate_auth_data ()
193{ 193{

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines