]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
WPS: Add more debug info for DH keys
authorJouni Malinen <jouni.malinen@atheros.com>
Sun, 18 Jul 2010 03:23:55 +0000 (20:23 -0700)
committerJouni Malinen <j@w1.fi>
Sun, 18 Jul 2010 03:23:55 +0000 (20:23 -0700)
src/wps/wps_attr_build.c
src/wps/wps_common.c

index 9da556addd05d271aed9de7feddcad9a981b0964..9b345f11b5162591a53c7dc5ad38014dad236271 100644 (file)
@@ -47,6 +47,8 @@ int wps_build_public_key(struct wps_data *wps, struct wpabuf *msg)
                wpabuf_free(pubkey);
                return -1;
        }
+       wpa_hexdump_buf_key(MSG_DEBUG, "WPS: DH Private Key", wps->dh_privkey);
+       wpa_hexdump_buf(MSG_DEBUG, "WPS: DH Public Key", pubkey);
 
        wpabuf_put_be16(msg, ATTR_PUBLIC_KEY);
        wpabuf_put_be16(msg, wpabuf_len(pubkey));
index 6ef14dbbe7da5192c8429201a1d07e0031f36508..f7cb7b832bbde8202f09e0084f033abbe20679eb 100644 (file)
@@ -81,6 +81,8 @@ int wps_derive_keys(struct wps_data *wps)
                return -1;
        }
 
+       wpa_hexdump_buf_key(MSG_DEBUG, "WPS: DH Private Key", wps->dh_privkey);
+       wpa_hexdump_buf(MSG_DEBUG, "WPS: DH Public Key", pubkey);
        dh_shared = dh5_derive_shared(wps->dh_ctx, pubkey, wps->dh_privkey);
        dh5_free(wps->dh_ctx);
        wps->dh_ctx = NULL;