rpms/xsupplicant/FC-3 xsupplicant-1.2.1-docsfix.patch, NONE, 1.1 xsupplicant-1.2.1-gcc4-cleanups.patch, NONE, 1.1 .cvsignore, 1.2, 1.3 sources, 1.2, 1.3 xsupplicant.spec, 1.1, 1.2

Tom Callaway (spot) fedora-extras-commits at redhat.com
Sun Sep 4 13:17:41 UTC 2005


Author: spot

Update of /cvs/extras/rpms/xsupplicant/FC-3
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv30591/FC-3

Modified Files:
	.cvsignore sources xsupplicant.spec 
Added Files:
	xsupplicant-1.2.1-docsfix.patch 
	xsupplicant-1.2.1-gcc4-cleanups.patch 
Log Message:

Bump to 1.2.1, fix a LOT of signed/unsigned mistakes in the code.


xsupplicant-1.2.1-docsfix.patch:

--- NEW FILE xsupplicant-1.2.1-docsfix.patch ---
--- xsupplicant-1.2.1/doc/builddocs.sh.BAD	2005-09-03 08:20:54.000000000 -0500
+++ xsupplicant-1.2.1/doc/builddocs.sh	2005-09-03 08:22:29.000000000 -0500
@@ -4,7 +4,7 @@
 # best option is just to require users of this script to define
 # the variable on their own?  not quite sure, I guess that's why
 # it's hard coded for now...
-JADE_PUB=/usr/share/doc/openjade-1.3/pubtext
+JADE_PUB=/usr/share/doc/openjade-*/pubtext
 SGML_CATALOG_FILES=/usr/sgml-tools/dtd/catalog:/etc/sgml/catalog:/usr/share/doc/openjade-1.3.2/catalog:/home/chris/t/docbook-dsssl-1.97/catalog
 
 mkdir -p html
@@ -33,7 +33,7 @@
 
 # create the txt docs
 echo -n "Building the TXT docs..."
-lynx -dump -nolist html/Open1x-UserGuide.html > txt/Open1x-UserGuide.txt
+links -dump html/Open1x-UserGuide.html > txt/Open1x-UserGuide.txt
 if [ $? -ne 0 ]
 then
     echo "Error!  Build failed!"

xsupplicant-1.2.1-gcc4-cleanups.patch:

--- NEW FILE xsupplicant-1.2.1-gcc4-cleanups.patch ---
--- xsupplicant-1.2.1/src/cardif/linux/cardif_hostap_driver.c.BAD	2005-09-03 17:50:21.000000000 -0500
+++ xsupplicant-1.2.1/src/cardif/linux/cardif_hostap_driver.c	2005-09-03 17:50:50.000000000 -0500
@@ -326,7 +326,7 @@
   debug_printf(DEBUG_NORMAL, "alg=%s  key_idx=%d set_tx=%d seq_len=%d key_len=%d\n", alg_name, key_idx, set_tx, seq_len, key_len);
 
   debug_printf(DEBUG_NORMAL, "KeyRSC = ");
-  debug_hex_printf(DEBUG_NORMAL, seq, seq_len);
+  debug_hex_printf(DEBUG_NORMAL, (u_char *) seq, seq_len);
 
   if (seq_len > 8)
     {
@@ -350,7 +350,7 @@
 
   memset(param->sta_addr, 0xff, ETH_ALEN);
 
-  strncpy(param->u.crypt.alg, alg_name, HOSTAP_CRYPT_ALG_NAME_LEN);
+  strncpy((char *) param->u.crypt.alg, alg_name, HOSTAP_CRYPT_ALG_NAME_LEN);
   param->u.crypt.flags = set_tx ? HOSTAP_CRYPT_FLAG_SET_TX_KEY : 0;
   param->u.crypt.idx = key_idx;
   memcpy(param->u.crypt.seq, seq, seq_len);
--- xsupplicant-1.2.1/src/cardif/linux/cardif_linux_wext.c.BAD	2005-09-03 17:51:02.000000000 -0500
+++ xsupplicant-1.2.1/src/cardif/linux/cardif_linux_wext.c	2005-09-03 17:53:08.000000000 -0500
@@ -119,10 +119,10 @@
 
   // We set the key index to 0x80, to force key 0 to be set to all 0s,
   // and to have key 0 be set as the default transmit key.
-  cardif_set_wep_key(thisint, (char *)&zerokey, keylen, 0x80);
-  cardif_set_wep_key(thisint, (char *)&zerokey, keylen, 0x01);
-  cardif_set_wep_key(thisint, (char *)&zerokey, keylen, 0x02);
-  cardif_set_wep_key(thisint, (char *)&zerokey, keylen, 0x03);
+  cardif_set_wep_key(thisint, (u_char *)&zerokey, keylen, 0x80);
+  cardif_set_wep_key(thisint, (u_char *)&zerokey, keylen, 0x01);
+  cardif_set_wep_key(thisint, (u_char *)&zerokey, keylen, 0x02);
+  cardif_set_wep_key(thisint, (u_char *)&zerokey, keylen, 0x03);
 }
 
 /**************************************************************
@@ -947,10 +947,10 @@
 
   if (config_ssid_get_ssid_abilities() & RSN_IE)
     {
-      cardif_linux_wext_get_wpa2_ie(intdata, wpaie, &len);
+      cardif_linux_wext_get_wpa2_ie(intdata, (char *) wpaie, &len);
     } else if (config_ssid_get_ssid_abilities() & WPA_IE)
       {
-	cardif_linux_wext_get_wpa_ie(intdata, wpaie, &len);
+	cardif_linux_wext_get_wpa_ie(intdata, (char *) wpaie, &len);
       }
 
   if (len > 0)
@@ -965,11 +965,11 @@
   intdata->flags |= DONTSCAN;
   cardif_linux_wext_set_ssid(intdata, newssid);
 
-  bssid = config_ssid_get_mac();
+  bssid = (char *) config_ssid_get_mac();
   if (bssid != NULL)
     {
       debug_printf(DEBUG_INT, "Dest. BSSID : ");
-      debug_hex_printf(DEBUG_INT, bssid, 6);
+      debug_hex_printf(DEBUG_INT, (u_char *) bssid, 6);
     }
 
   //  cardif_linux_wext_set_bssid(intdata, bssid);
--- xsupplicant-1.2.1/src/cardif/linux/cardif_ipw_driver.c.BAD	2005-09-03 17:54:57.000000000 -0500
+++ xsupplicant-1.2.1/src/cardif/linux/cardif_ipw_driver.c	2005-09-03 17:57:23.000000000 -0500
@@ -240,7 +240,7 @@
   wpa2_gen_ie(intdata, iedata, ielen);
 
   debug_printf(DEBUG_INT, "Setting WPA2 IE : ");
-  debug_hex_printf(DEBUG_INT, iedata, *ielen);
+  debug_hex_printf(DEBUG_INT, (u_char *) iedata, *ielen);
   debug_printf(DEBUG_INT, "\n");
 
   return XENONE;
@@ -372,7 +372,7 @@
   param = (struct ipw_param *) buf;
   param->cmd = IPW_CMD_SET_ENCRYPTION;
   memset(param->sta_addr, 0xff, 6);
-  strncpy(param->u.crypt.alg, alg_name, IPW_CRYPT_ALG_NAME_LEN);
+  strncpy((char *) param->u.crypt.alg, alg_name, IPW_CRYPT_ALG_NAME_LEN);
   param->u.crypt.set_tx = set_tx ? 1 : 0;
   param->u.crypt.idx = key_idx;
   memcpy(param->u.crypt.seq, seq, seq_len);
@@ -422,7 +422,7 @@
 {
   int ret;
 
-  ret = ipw_mlme(intdata->intName, intdata->source_mac, 
+  ret = ipw_mlme(intdata->intName, (u8 *) intdata->source_mac, 
 		     IPW_MLME_STA_DISASSOC, reason_code);
 
   if (ret <0) return ret;
@@ -458,16 +458,16 @@
 
   if (config_ssid_get_ssid_abilities() & RSN_IE)
     {
-      cardif_ipw_driver_get_wpa2_ie(intdata, wpaie, &len);
+      cardif_ipw_driver_get_wpa2_ie(intdata, (char *) wpaie, &len);
     } else if (config_ssid_get_ssid_abilities() & WPA_IE)
       {
-	cardif_ipw_driver_get_wpa_ie(intdata, wpaie, &len);
+	cardif_ipw_driver_get_wpa_ie(intdata, (char *) wpaie, &len);
       }
 
   // Length needs to be > 0 in order to indicate that we have an IE to set.
   if ((len < 255) && (len >= 0))
     {
-      if (cardif_ipw_driver_set_wpa_ie(intdata->intName, wpaie, len) < 0)
+      if (cardif_ipw_driver_set_wpa_ie(intdata->intName, (char *) wpaie, len) < 0)
 	{
 	  debug_printf(DEBUG_NORMAL, "Couldn't set WPA/RSN IE on device %s!\n",
 		       intdata->intName);
--- xsupplicant-1.2.1/src/cardif/linux/cardif_linux_rtnetlink.c.BAD	2005-09-03 17:43:05.000000000 -0500
+++ xsupplicant-1.2.1/src/cardif/linux/cardif_linux_rtnetlink.c	2005-09-03 17:49:49.000000000 -0500
@@ -269,13 +269,13 @@
 	      memcpy(&custom, &tptr[12], (iwe->len - 12));
 	      debug_printf(DEBUG_INT, "(Custom) Value : %s\n", custom);
 
-	      if (strncmp("wpa_ie=", custom, 7) == 0)
+	      if (strncmp("wpa_ie=", (char *) custom, 7) == 0)
 		{
 		  SET_FLAG(flags, WPA_IE);
 		  debug_printf(DEBUG_INT, "AP appears to support WPA!\n");
-		  temp = (char *)malloc((iwe->len - 12)/2);
-		  process_hex(&custom[7], (iwe->len - 12-7), temp);
-		  wpa_parse_ie(temp);
+		  temp = (u_char *)malloc((iwe->len - 12)/2);
+		  process_hex((char *) &custom[7], (iwe->len - 12-7), (char *) temp);
+		  wpa_parse_ie((char *) temp);
 		  
 		  temp_wpa = temp;
 		  temp_wpa_len = ((iwe->len - 12)/2);
@@ -285,13 +285,13 @@
 		  temp = NULL;
 		}
 
-	      if (strncmp("rsn_ie=", custom, 7) == 0)
+	      if (strncmp("rsn_ie=", (char *) custom, 7) == 0)
 		{
 		  SET_FLAG(flags, RSN_IE);
 		  debug_printf(DEBUG_INT, "AP appears to support WPA2/802.11i!\n");
-		  temp = (char *)malloc((iwe->len - 12)/2);
-		  process_hex(&custom[7], (iwe->len - 12-7), temp);
-		  wpa2_parse_ie(temp);
+		  temp = (u_char *)malloc((iwe->len - 12)/2);
+		  process_hex((char *) &custom[7], (iwe->len - 12-7), (char *) temp);
+		  wpa2_parse_ie((char *) temp);
 		  
 		  temp_rsn = temp;
 		  temp_rsn_len = ((iwe->len - 12)/2);
@@ -381,10 +381,10 @@
 			   "but the WPA_IE or RSN_IE flag(s) aren't set!?!\n");
 	    }
 
-	  if (strcmp(essid, intdata->cur_essid) == 0)
+	  if (strcmp((char *) essid, intdata->cur_essid) == 0)
 	    {
 	      debug_printf(DEBUG_INT, "Adding this SSID data!\n");
-	      config_ssids_add(essid, flags, wpa_ie, wpa_ie_len, rsn_ie, 
+	      config_ssids_add((char *) essid, flags, wpa_ie, wpa_ie_len, rsn_ie, 
 			       rsn_ie_len, freq, stale_mac);
 	    }
 	  
@@ -440,10 +440,10 @@
 	}      
     }
 
-  if (strcmp(essid, intdata->cur_essid) == 0)
+  if (strcmp((char *) essid, intdata->cur_essid) == 0)
     {
       debug_printf(DEBUG_INT, "Adding this SSID data!\n");
-      config_ssids_add(essid, flags, wpa_ie, wpa_ie_len, rsn_ie, 
+      config_ssids_add((char *) essid, flags, wpa_ie, wpa_ie_len, rsn_ie, 
 		       rsn_ie_len, freq, mac);
     }
   
@@ -490,8 +490,8 @@
 
   // Then harvest the data.
   debug_printf(DEBUG_INT, "Reaping data. (Size : %d)\n", iwr.u.data.length);
-  cardif_linux_rtnetlink_reap(idata, (char *)buffer, 
-			      ((char *)buffer + iwr.u.data.length));
+  cardif_linux_rtnetlink_reap(idata, (u_char *)buffer, 
+			      ((u_char *)buffer + iwr.u.data.length));
 
   UNSET_FLAG(idata->flags, SCANNING);
 
@@ -519,7 +519,7 @@
     }
 
   remain = recvfrom(rtnl_sock, buf, sizeof(buf), MSG_DONTWAIT,
-			(struct sockaddr *)&rtnl_data, &rtnl_data_size);
+			(struct sockaddr *)&rtnl_data, (u_int *) &rtnl_data_size);
   if (remain >= 0)
     {
       // We need a pointer to the buffer to work with.
@@ -927,7 +927,7 @@
 	case SIOCGIWAP:
 	  memcpy(mac, iwe->u.ap_addr.sa_data, 6);
 	  debug_printf(DEBUG_INT, "AP MAC : ");
-	  debug_hex_printf(DEBUG_INT, mac, 6);
+	  debug_hex_printf(DEBUG_INT, (u_char *) mac, 6);
 	  if (cardif_linux_rtnetlink_validate(idata, (u_char *)&mac) == 1)
 	    {
 	      // We have changed to associated mode.  Populate the destination
@@ -987,7 +987,7 @@
 	  memcpy(buf, custom, iwe->u.data.length);
 	  buf[iwe->u.data.length] = '\0';
 	  debug_printf(DEBUG_NORMAL, "Custom Data : \n");
-	  debug_hex_dump(DEBUG_NORMAL, buf, iwe->u.data.length);
+	  debug_hex_dump(DEBUG_NORMAL, (u_char *) buf, iwe->u.data.length);
 	  cardif_linux_rtnetlink_check_custom(idata, buf);
 	  break;
 
--- xsupplicant-1.2.1/src/cardif/linux/cardif_ndiswrapper_driver.c.BAD	2005-09-03 17:53:21.000000000 -0500
+++ xsupplicant-1.2.1/src/cardif/linux/cardif_ndiswrapper_driver.c	2005-09-03 17:54:27.000000000 -0500
@@ -202,11 +202,11 @@
   wpa_key.addr = addr;
   wpa_key.key_index = key_idx;
   wpa_key.set_tx = set_tx;
-  wpa_key.seq = seq;
+  wpa_key.seq = (u_char *) seq;
   wpa_key.seq_len = seq_len;
   debug_printf(DEBUG_NORMAL, "SEQ : ");
-  debug_hex_printf(DEBUG_NORMAL, seq, seq_len);
-  wpa_key.key = key;
+  debug_hex_printf(DEBUG_NORMAL, (u_char *) seq, seq_len);
+  wpa_key.key = (u_char *) key;
   wpa_key.key_len = key_len;
 
   debug_printf(DEBUG_INT, "Setting key.. alg=%d idx=%d tx=%d seqlen=%d "
@@ -304,11 +304,11 @@
   bzero(&wpa_inf, sizeof(wpa_inf));
   
   memcpy(buf, ssid, strlen(ssid));
-  wpa_inf.bssid = (char *)config_ssid_get_mac();
-  wpa_inf.ssid = (char *)&buf;
+  wpa_inf.bssid = (u_char *)config_ssid_get_mac();
+  wpa_inf.ssid = (u_char *)&buf;
   wpa_inf.ssid_len = strlen(ssid);
   wpa_inf.freq = config_ssid_get_freq();
-  wpa_inf.wpa_ie = (char *)&wpaie;
+  wpa_inf.wpa_ie = (u_char *)&wpaie;
   wpa_inf.wpa_ie_len = ielen;   
 
   wpa_inf.pairwise_suite = network_data->wpa_pairwise_crypt; 
--- xsupplicant-1.2.1/src/cardif/linux/linux_core.c.BAD	2005-09-03 17:39:55.000000000 -0500
+++ xsupplicant-1.2.1/src/cardif/linux/linux_core.c	2005-09-03 17:42:28.000000000 -0500
@@ -116,11 +116,11 @@
 	{
 	  if (wepdata->key[keyidx] != NULL)
 	    {
-	      klen = strlen(wepdata->key[keyidx]);
+	      klen = strlen((char *) wepdata->key[keyidx]);
 	      if (((klen/2) == 5) || ((klen/2) == 13))
 		{
 		  // We have a valid length key.  So, convert it, and set it.
-		  process_hex(wepdata->key[keyidx], klen, key);
+		  process_hex((char *) wepdata->key[keyidx], klen, key);
 
 		  // Calculate the proper key index.
 		  t = keyidx-1;
@@ -130,9 +130,9 @@
 		      debug_printf(DEBUG_INT, "Setting TX key! [%d]\n",
 				   wepdata->tx_key);
 		      t |= 0x80;
-		      cardif_set_wep_key(intcur, key, (klen/2), t);
+		      cardif_set_wep_key(intcur, (u_char *) key, (klen/2), t);
 		    } else {
-		      cardif_set_wep_key(intcur, key, (klen/2), t);
+		      cardif_set_wep_key(intcur, (u_char *) key, (klen/2), t);
 		    }
 		}
 	    }
--- xsupplicant-1.2.1/src/cardif/linux/cardif_linux.c.BAD	2005-09-03 17:37:20.000000000 -0500
+++ xsupplicant-1.2.1/src/cardif/linux/cardif_linux.c	2005-09-03 17:39:29.000000000 -0500
@@ -78,7 +78,7 @@
   cardif_GetBSSID(intdata, curbssid);
 
   debug_printf(DEBUG_INT, "Current BSSID is ");
-  debug_hex_printf(DEBUG_INT, curbssid, 6);
+  debug_hex_printf(DEBUG_INT, (u_char *) curbssid, 6);
 
   memset(newmac, 0x00, 6);
   if (memcmp(newmac, curbssid, 6) == 0)
@@ -463,7 +463,7 @@
 {
   if (wireless == NULL) return -1;
 
-  return wireless->set_tkip_key(thisint, addr, keyidx, settx, seq, seqlen,
+  return wireless->set_tkip_key(thisint, (u_char *) addr, keyidx, settx, seq, seqlen,
 				key, keylen);
 }
 
@@ -478,7 +478,7 @@
 {
   if (wireless == NULL) return -1;
 
-  return wireless->set_ccmp_key(thisint, addr, keyidx, settx, seq, seqlen,
+  return wireless->set_ccmp_key(thisint, (u_char *) addr, keyidx, settx, seq, seqlen,
 				key, keylen);
 }
 
@@ -746,7 +746,7 @@
     {
       // Since we now know this frame is for us, record the address it
       // came from.
-      snmp_dot1xSuppLastEapolFrameSource((char *)&resultframe[6]);
+      snmp_dot1xSuppLastEapolFrameSource((u_char *)&resultframe[6]);
 
       resultsize = newsize;
 
--- xsupplicant-1.2.1/src/psk.c.BAD	2005-09-03 09:24:53.000000000 -0500
+++ xsupplicant-1.2.1/src/psk.c	2005-09-03 09:25:15.000000000 -0500
@@ -50,7 +50,7 @@
   // OpenSSL takes the parameters in a different order than what is
   // defined in F.8.2, so even though it looks wrong, this is correct. ;)
   HMAC(EVP_sha1(), password, strlen(password), digest, ssidlength+4, 
-       digest1, &k);
+       digest1, (u_int *) &k);
 
   /* output = U1 */
   memcpy(output, digest1, SHA_DIGEST_LENGTH);
@@ -59,7 +59,7 @@
     {
       /* Un = PRF(P, Un-1) */
       HMAC(EVP_sha1(), password, strlen(password), digest1, SHA_DIGEST_LENGTH, 
-	   digest, &k);
+	   digest, (u_int *) &k);
       memcpy(digest1, digest, k);
 
       /* output = output xor Un */
--- xsupplicant-1.2.1/src/mic.c.BAD	2005-09-03 09:24:01.000000000 -0500
+++ xsupplicant-1.2.1/src/mic.c	2005-09-03 09:24:43.000000000 -0500
@@ -44,14 +44,14 @@
     {
     case 1:
       // Do an MD5 HMAC
-      HMAC(EVP_md5(), key, keylen, datain, insize, mic, &i);
+      HMAC(EVP_md5(), key, keylen, (u_char *) datain, insize, (u_char *) mic, (u_int *) &i);
       break;
 
     case 2:
       // Do an SHA1 HMAC  
       // Since the HMAC will be 20 bytes, and we only need 16, we must use
       // a temporary variable.
-      HMAC(EVP_sha1(), key, keylen, datain, insize, (char *)&sha_hmac, &i);
+      HMAC(EVP_sha1(), key, keylen, (u_char *) datain, insize, (u_char *)&sha_hmac, (u_int *) &i);
       memcpy(mic, &sha_hmac, 16);
       break;
     }
--- xsupplicant-1.2.1/src/config.h.BAD	2005-09-03 08:39:44.000000000 -0500
+++ xsupplicant-1.2.1/src/config.h	2005-09-03 08:39:53.000000000 -0500
@@ -341,6 +341,7 @@
 char config_get_association();
 char *config_get_logfile();
 int config_get_ipc_gid();
+int config_get_stale_key_timeout();
 char config_get_destination();
 char *config_get_log_facility();
 void config_set_forced_profile(char *);
--- xsupplicant-1.2.1/src/eap.c.BAD	2005-09-03 08:34:21.000000000 -0500
+++ xsupplicant-1.2.1/src/eap.c	2005-09-03 08:38:27.000000000 -0500
@@ -191,9 +191,9 @@
 
   switch (eap_request_auth(network_data->activemethod,
 			   network_data->methods, 
-			   &thisint->recvframe[OFFSET_TO_EAP],
+			   (char *) &thisint->recvframe[OFFSET_TO_EAP],
 			   thisint->recv_size, 
-			   &thisint->sendframe[OFFSET_TO_EAP], &eapsize))
+			   (char *) &thisint->sendframe[OFFSET_TO_EAP], &eapsize))
     {
     case XINNERSUCCESS:
       // We got a LEAP success, so we need to tell the state machine to
@@ -231,7 +231,7 @@
       if ((eapolver < 1) || (eapolver > MAX_EAPOL_VER))
 	eapolver = snmp_get_dot1xSuppLastEapolFrameVersion();
 
-      eapol_build_header(EAP_PACKET, eapsize, eapolver, thisint->sendframe);
+      eapol_build_header(EAP_PACKET, eapsize, eapolver, (char *) thisint->sendframe);
       thisint->send_size = eapsize+OFFSET_TO_EAP;
       return XENONE;
     }
@@ -284,7 +284,7 @@
 
   eap_request_id(network_data->identity,
 		 eapdata->eap_identifier,
-		 &thisint->sendframe[OFFSET_TO_EAP], &eapsize);
+		 (char *) &thisint->sendframe[OFFSET_TO_EAP], &eapsize);
 
   eapolver = network_data->force_eapol_ver;
 
@@ -295,7 +295,7 @@
   if ((eapolver < 1) || (eapolver > MAX_EAPOL_VER))
     eapolver = snmp_get_dot1xSuppLastEapolFrameVersion();
 
-  eapol_build_header(EAP_PACKET, eapsize, eapolver, thisint->sendframe);
+  eapol_build_header(EAP_PACKET, eapsize, eapolver, (char *) thisint->sendframe);
   thisint->send_size = eapsize+OFFSET_TO_EAP;
 
   return XENONE;
@@ -379,7 +379,7 @@
   // We need to determine how long the string that we were returned is.
   // So, take the EAP length value, and subtract 5 to account for the EAP
   // header.
-  strncpy(&myval[0], &inframe[OFFSET_TO_DATA], (ntohs(myeap->eap_length)-5));
+  strncpy(&myval[0], (char *) &inframe[OFFSET_TO_DATA], (ntohs(myeap->eap_length)-5));
 
   debug_printf(DEBUG_NORMAL, "EAP Notification : %s\n", &myval[0]);
   bzero(thisint->recvframe, thisint->recv_size);
@@ -814,8 +814,8 @@
   if ((pwd_needed != 1) || (activemethod->tempPwd != NULL))
     {
       switch ((*eaphandlers[eapmethod].eap_auth_handlers)(activemethod, 
-						      tosendframe, eapinsize, 
-						  &outframe[sizeof(struct eap_header)], 
+						      (u_char *) tosendframe, eapinsize, 
+						  (u_char *) &outframe[sizeof(struct eap_header)], 
 						  eapsize))
 	{
 	case XINNERSUCCESS:
@@ -962,9 +962,9 @@
 
   (*eaphandlers[eapmethod].eap_auth_get_keys)(thisint);
 
-  thisint->statemachine->PMK = thisint->keyingMaterial;
+  thisint->statemachine->PMK = (char *) thisint->keyingMaterial;
   debug_printf(DEBUG_INT, "PMK Keys (%d) :\n", thisint->keyingLength);
-  debug_hex_dump(DEBUG_INT, thisint->statemachine->PMK, thisint->keyingLength);
+  debug_hex_dump(DEBUG_INT, (u_char *) thisint->statemachine->PMK, thisint->keyingLength);
 
   debug_printf(DEBUG_INT, "WEP Keys (%d) :\n", thisint->keyingLength);
   debug_hex_dump(DEBUG_INT, thisint->keyingMaterial, thisint->keyingLength);
--- xsupplicant-1.2.1/src/eapol_key_type2.c.BAD	2005-09-03 09:34:10.000000000 -0500
+++ xsupplicant-1.2.1/src/eapol_key_type2.c	2005-09-03 16:32:47.000000000 -0500
@@ -172,7 +172,7 @@
 	case 2:
 	  // XXX BROKEN!  FIX!
 	  bzero(key, 16);
-	  aes_unwrap(&intdata->statemachine->PTK[16], (keylen-8)/8, keypayload,
+	  aes_unwrap((u_char *) &intdata->statemachine->PTK[16], (keylen-8)/8, keypayload,
 		     key);
 	  break;
 	  
@@ -238,12 +238,12 @@
     }
 
   debug_printf(DEBUG_INT, "PMK : ");
-  debug_hex_printf(DEBUG_INT, intdata->statemachine->PMK, 32);
-  wpa_PRF(intdata->statemachine->PMK, 32, "Pairwise key expansion", 22,
-	  (char *)&prfdata, 76, retval, 64);
+  debug_hex_printf(DEBUG_INT, (u_char *) intdata->statemachine->PMK, 32);
+  wpa_PRF((u_char *) intdata->statemachine->PMK, 32, (u_char *) "Pairwise key expansion", 22,
+	  (u_char *)&prfdata, 76, (u_char *) retval, 64);
 
   debug_printf(DEBUG_INT, "PTK : ");
-  debug_hex_printf(DEBUG_INT, retval, 64);
+  debug_hex_printf(DEBUG_INT, (u_char *) retval, 64);
 
   return retval;
 }
@@ -310,10 +310,10 @@
     eapolver = snmp_get_dot1xSuppLastEapolFrameVersion();
 
   eapol_build_header(EAPOL_KEY, (intdata->send_size-OFFSET_TO_EAPOL-4), 
-		     eapolver, intdata->sendframe); 
+		     eapolver, (char *) intdata->sendframe); 
   
   memcpy(key, intdata->statemachine->PTK, 16);
-  mic_wpa_populate(intdata->sendframe, intdata->send_size+4, key, 16);
+  mic_wpa_populate((char *) intdata->sendframe, intdata->send_size+4, key, 16);
 
   cardif_sendframe(intdata);
   intdata->statemachine->eapolEap = FALSE;
@@ -394,7 +394,7 @@
       bzero(rc4_ek, 32);
       memcpy(rc4_ek, inkeydata->key_iv, 16);
       memcpy(&rc4_ek[16], &intdata->statemachine->PTK[16], 16);
-      rc4_skip(rc4_ek, 32, 256, keydata, value16);
+      rc4_skip((u_char *) rc4_ek, 32, 256, keydata, value16);
 
       debug_printf(DEBUG_INT, "Decrypted data : (%d)\n", value16);
       debug_hex_dump(DEBUG_INT, keydata, value16);
@@ -410,17 +410,17 @@
       wpa_common_swap_rx_tx_mic(keydata);
 
       debug_printf(DEBUG_INT, "Setting GTK with index of %d\n", keyindex);
-      cardif_set_tkip_key(intdata, allfs, keyindex, FALSE, inkeydata->key_rsc,
-			  6, keydata, value16);
+      cardif_set_tkip_key(intdata, (char *) allfs, keyindex, FALSE, (char *) inkeydata->key_rsc,
+			  6, (char *) keydata, value16);
       break;
 
     case 2:
       // First, decrypt the GTK
       bzero(key, 16);
-      aes_unwrap(&intdata->statemachine->PTK[16], (value16-8)/8, keydata,
-		 key);
+      aes_unwrap((u_char *) &intdata->statemachine->PTK[16], (value16-8)/8, keydata,
+		 (u_char *) key);
 
-      cardif_set_ccmp_key(intdata, NULL, keyindex, FALSE, inkeydata->key_rsc,
+      cardif_set_ccmp_key(intdata, NULL, keyindex, FALSE, (char *) inkeydata->key_rsc,
      			  6, key, (value16-8));
       break;
     }
@@ -446,13 +446,13 @@
     eapolver = snmp_get_dot1xSuppLastEapolFrameVersion();
 
   eapol_build_header(EAPOL_KEY, (intdata->send_size-OFFSET_TO_EAPOL-4), 
-		     eapolver, intdata->sendframe); 
+		     eapolver, (char *) intdata->sendframe); 
   
   memcpy(key, intdata->statemachine->PTK, 16);
-  mic_wpa_populate(intdata->sendframe, intdata->send_size+4, key, 16);
+  mic_wpa_populate((char *) intdata->sendframe, intdata->send_size+4, key, 16);
 
   // Dump what we built.
-  eapol_key_type2_dump(intdata, intdata->sendframe);
+  eapol_key_type2_dump(intdata, (char *) intdata->sendframe);
 
   if (network_data->methods->method_num == WPA_PSK)
     {
@@ -560,13 +560,13 @@
     eapolver = snmp_get_dot1xSuppLastEapolFrameVersion();
 
   eapol_build_header(EAPOL_KEY, (intdata->send_size-OFFSET_TO_EAPOL-4), 
-		     eapolver, intdata->sendframe);
+		     eapolver, (char *) intdata->sendframe);
 
   memcpy(key, intdata->statemachine->PTK, 16);
-  mic_wpa_populate(intdata->sendframe, intdata->send_size+4, key, 16);
+  mic_wpa_populate((char *) intdata->sendframe, intdata->send_size+4, key, 16);
 
   // Dump what we built.
-  eapol_key_type2_dump(intdata, intdata->sendframe);
+  eapol_key_type2_dump(intdata, (char *) intdata->sendframe);
 }
 
 /********************************************************
@@ -596,7 +596,7 @@
   memcpy(iedata, indata, len);
 
   debug_printf(DEBUG_INT, "Got an IE of : \n");
-  debug_hex_dump(DEBUG_INT, iedata, len);
+  debug_hex_dump(DEBUG_INT, (u_char *) iedata, len);
 
   // XXX Todo : Verify the IE against the IE we have from the AP.
 
@@ -869,20 +869,20 @@
     eapolver = snmp_get_dot1xSuppLastEapolFrameVersion();
 
   eapol_build_header(EAPOL_KEY, (intdata->send_size-OFFSET_TO_EAPOL-4), 
-		     eapolver, intdata->sendframe); 
+		     eapolver, (char *) intdata->sendframe); 
 
   memcpy(key, intdata->statemachine->PTK, 16);
-  mic_wpa_populate(intdata->sendframe, intdata->send_size+4, key, 16);  
+  mic_wpa_populate((char *) intdata->sendframe, intdata->send_size+4, key, 16);  
 
   // Dump what we built.
-  eapol_key_type2_dump(intdata, intdata->sendframe);
+  eapol_key_type2_dump(intdata, (char *) intdata->sendframe);
 
   // Get TK1
   value16 = ntohs(inkeydata->key_length);
   memcpy(key, (char *)&intdata->statemachine->PTK[32], value16);
   
   debug_printf(DEBUG_INT, "TK1 : ");
-  debug_hex_printf(DEBUG_INT, key, value16);
+  debug_hex_printf(DEBUG_INT, (u_char *) key, value16);
   
   cardif_sendframe(intdata);
   intdata->statemachine->eapolEap = FALSE;
@@ -902,12 +902,12 @@
 	  bzero(rc4_ek, 32);
 	  memcpy(rc4_ek, inkeydata->key_iv, 16);
 	  memcpy(&rc4_ek[16], &intdata->statemachine->PTK[16], 16);
-	  rc4_skip(rc4_ek, 32, 256, keydata, keylen);
+	  rc4_skip((u_char *) rc4_ek, 32, 256, keydata, keylen);
 	  break;
 	  
 	case 2:
 	  aesval = (uint8_t *)malloc(keylen);
-	  if (aes_unwrap(&intdata->statemachine->PTK[16], (keylen-8)/8, keydata,
+	  if (aes_unwrap((u_char *) &intdata->statemachine->PTK[16], (keylen-8)/8, keydata,
 		     aesval))
 	    {
 	      debug_printf(DEBUG_NORMAL, "Failed AES unwrap!\n");
@@ -943,13 +943,13 @@
 	    {
 	    case 1:
 	      wpa_common_swap_rx_tx_mic(gtk);
-	      cardif_set_tkip_key(intdata, allfs, keyindex, txkey, 
-				  inkeydata->key_rsc, RSC_LEN, gtk, value16);
+	      cardif_set_tkip_key(intdata, (char*) allfs, keyindex, txkey, 
+				  (char *) inkeydata->key_rsc, RSC_LEN, (char *) gtk, value16);
 	      break;
 	      
 	    case 2:
-	      cardif_set_ccmp_key(intdata, allfs, keyindex, txkey, 
-				  inkeydata->key_rsc, RSC_LEN, gtk, value16);
+	      cardif_set_ccmp_key(intdata, (char *) allfs, keyindex, txkey, 
+				  (char *) inkeydata->key_rsc, RSC_LEN, (char *) gtk, value16);
 	      break;
 	    }
 	  
@@ -973,15 +973,15 @@
     case 1:
       // We need to swap the TX/RX MIC values since we are the supplicant.  
       // (Thanks to Jouni Malinen for pointing this out!)
-      wpa_common_swap_rx_tx_mic(key);
+      wpa_common_swap_rx_tx_mic((u_char *) key);
 
       cardif_set_tkip_key(intdata, intdata->dest_mac, 0, TRUE, 
-			  inkeydata->key_rsc, RSC_LEN, key, value16);
+			  (char *) inkeydata->key_rsc, RSC_LEN, key, value16);
       break;
 
     case 2:
       cardif_set_ccmp_key(intdata, intdata->dest_mac, 0, TRUE, 
-			  inkeydata->key_rsc, RSC_LEN, key, value16);
+			  (char *) inkeydata->key_rsc, RSC_LEN, key, value16);
       break;
     }
 }
@@ -1008,7 +1008,7 @@
 
   if (keyflags & WPA2_KEY_MIC_FLAG)
     {
-      if (mic_wpa_validate(intdata->recvframe, intdata->recv_size, 
+      if (mic_wpa_validate((char *) intdata->recvframe, intdata->recv_size, 
 			   intdata->statemachine->PTK, 16) == FALSE)
 	{
 	  intdata->statemachine->MICVerified = TRUE;
@@ -1058,7 +1058,7 @@
 	eapolver = snmp_get_dot1xSuppLastEapolFrameVersion();
 
       eapol_build_header(EAPOL_KEY, (intdata->recv_size-OFFSET_TO_EAPOL-4), 
-			 eapolver, intdata->recvframe);
+			 eapolver, (char *) intdata->recvframe);
       cardif_sendframe(intdata);
       intdata->statemachine->eapolEap = FALSE;
     }      
@@ -1127,8 +1127,8 @@
 		}
 
 	      // We have an ASCII password, so calculate it.
-	      if (psk_wpa_pbkdf2(psk->key, intdata->cur_essid, 
-				 strlen(intdata->cur_essid), (char *)&tpmk) 
+	      if (psk_wpa_pbkdf2(psk->key, (u_char *) intdata->cur_essid, 
+				 strlen(intdata->cur_essid), (u_char *)&tpmk) 
 		  == TRUE)
 		{
 		  intdata->statemachine->PMK = (char *)malloc(32);
@@ -1168,7 +1168,7 @@
 	}
     } 
 
-  eapol_key_type2_dump(intdata, inframe);
+  eapol_key_type2_dump(intdata, (char *) inframe);
 
   eapol_key_type2_determine_key(intdata);
 
--- xsupplicant-1.2.1/src/eap_types/otp/eapotp.c.BAD	2005-09-03 17:26:09.000000000 -0500
+++ xsupplicant-1.2.1/src/eap_types/otp/eapotp.c	2005-09-03 17:26:47.000000000 -0500
@@ -123,7 +123,7 @@
   /*  debug_printf(DEBUG_NORMAL, "Response : ");
       gets(&resp); */
 
-  strcpy(outframe, resp);
+  strcpy((char *) outframe, resp);
   *outsize = strlen(resp);
 
   return *outsize;
--- xsupplicant-1.2.1/src/eap_types/tls/tls_funcs.c.BAD	2005-09-03 16:38:06.000000000 -0500
+++ xsupplicant-1.2.1/src/eap_types/tls/tls_funcs.c	2005-09-03 16:42:46.000000000 -0500
@@ -445,7 +445,7 @@
     }
 
   debug_printf(DEBUG_AUTHTYPES, "Packet in (%d) :\n", insize);
-  debug_hex_dump(DEBUG_AUTHTYPES, inframe, insize);
+  debug_hex_dump(DEBUG_AUTHTYPES, (u_char *) inframe, insize);
 
   // First, make sure we don't have any errors.
   err = ERR_get_error();
@@ -563,7 +563,7 @@
 	  
 	  if ((mytls_vars->resuming != 1) || (mytls_vars->quickResponse != TRUE))
 	    {
-	      if (((*dophase2)(thisint, tlsptr, (insize-tlsindex), outframe, 
+	      if (((*dophase2)(thisint, (u_char *) tlsptr, (insize-tlsindex), outframe, 
 			       outsize)) != XENONE)
 		{
 		  debug_printf(DEBUG_NORMAL, "Phase 2 failure!\n");
@@ -578,7 +578,7 @@
 		}
 	    }	  
 	} else {
-	  rtnVal = tls_funcs_parse(thisint, tlsptr, (insize-tlsindex), outframe, outsize, chunksize);
+	  rtnVal = tls_funcs_parse(thisint, (u_char *) tlsptr, (insize-tlsindex), outframe, outsize, chunksize);
 	  if (rtnVal < 0)
 	    {
 	      debug_printf(DEBUG_NORMAL, "Couldn't parse TLS data.\n");
@@ -642,7 +642,7 @@
 
 	      if ((mytls_vars->resuming != 1) || (mytls_vars->quickResponse != TRUE))
 		{
-		  if ((*dophase2)(thisint, tlsptr, (insize-tlsindex), 
+		  if ((*dophase2)(thisint, (u_char *) tlsptr, (insize-tlsindex), 
 				  outframe, outsize) != XENONE)
 		    {
 		      debug_printf(DEBUG_NORMAL, "Phase 2 Failure.\n");
@@ -1083,32 +1083,32 @@
   /* P_MD5 */
   hash = EVP_md5();
   /* Initialize A_MD5 */
-  HMAC(hash, S1, L_S1, P_seed, P_seed_len, A_MD5, &hashed_len);
+  HMAC(hash, S1, L_S1, P_seed, P_seed_len, A_MD5, (u_int *) &hashed_len);
 
   for (i = 0; i < MD5_iterations; i++) {
     HMAC_Init(&ctx, S1, L_S1, hash);
     HMAC_Update(&ctx, A_MD5, MD5_DIGEST_LENGTH);
     HMAC_Update(&ctx, P_seed, P_seed_len);
-    HMAC_Final(&ctx, P_MD5_buf + i*(MD5_DIGEST_LENGTH), &hashed_len);
+    HMAC_Final(&ctx, P_MD5_buf + i*(MD5_DIGEST_LENGTH), (u_int *) &hashed_len);
     HMAC_cleanup(&ctx);
     HMAC(hash, S1, L_S1, A_MD5, MD5_DIGEST_LENGTH,
-	 A_MD5, &hashed_len);
+	 A_MD5, (u_int *) &hashed_len);
   }
     
 
   /* do P_SHA1 */
   hash = EVP_sha1();
   /* Initialize A_SHA1 */
-  HMAC(hash, S2, L_S2, P_seed, P_seed_len, A_SHA1, &hashed_len);
+  HMAC(hash, S2, L_S2, P_seed, P_seed_len, A_SHA1, (u_int *) &hashed_len);
 
   for (i = 0; i < SHA1_iterations; i++) {
     HMAC_Init(&ctx, S2, L_S2, hash);
     HMAC_Update(&ctx, A_SHA1, SHA_DIGEST_LENGTH);
     HMAC_Update(&ctx, P_seed, P_seed_len);
-    HMAC_Final(&ctx, P_SHA1_buf + i*(SHA_DIGEST_LENGTH), &hashed_len);
+    HMAC_Final(&ctx, P_SHA1_buf + i*(SHA_DIGEST_LENGTH), (u_int *) &hashed_len);
     HMAC_cleanup(&ctx);
     HMAC(hash, S2, L_S2, A_SHA1, SHA_DIGEST_LENGTH,
-	 A_SHA1, &hashed_len);
+	 A_SHA1, (u_int *) &hashed_len);
   }
   /* XOR Them for the answer */
   for (i = 0; i < outlen; i++) {
--- xsupplicant-1.2.1/src/eap_types/tls/tls_crypt.c.BAD	2005-09-03 16:58:16.000000000 -0500
+++ xsupplicant-1.2.1/src/eap_types/tls/tls_crypt.c	2005-09-03 16:58:35.000000000 -0500
@@ -72,7 +72,7 @@
   memcpy(p, mytls_vars->ssl->s3->server_random, SSL3_RANDOM_SIZE);
   tls_funcs_PRF(SSL_get_session(mytls_vars->ssl)->master_key, 
 		SSL_get_session(mytls_vars->ssl)->master_key_length,
-		sesskey, sesskeylen, seed, 
+		(u_char *) sesskey, sesskeylen, seed, 
 		SSL3_RANDOM_SIZE * 2, retblock, 
 		TLS_SESSION_KEY_SIZE);
 
--- xsupplicant-1.2.1/src/eap_types/tls/eaptls.c.BAD	2005-09-03 16:33:36.000000000 -0500
+++ xsupplicant-1.2.1/src/eap_types/tls/eaptls.c	2005-09-03 16:36:48.000000000 -0500
@@ -192,7 +192,7 @@
   // Make sure we have something to process...
   if (dataoffs == NULL) return XENONE;
   
-  retVal=tls_funcs_decode_packet(thisint, dataoffs, insize, outframe, outsize, 
+  retVal=tls_funcs_decode_packet(thisint, (char *) dataoffs, insize, (char *) outframe, outsize, 
 				 NULL, userdata->chunk_size);
 
   return retVal;
@@ -222,7 +222,7 @@
       free(thisint->keyingMaterial);
     }
 
-  thisint->keyingMaterial = tls_funcs_gen_keyblock(network_data->activemethod);
+  thisint->keyingMaterial = (u_char *) tls_funcs_gen_keyblock(network_data->activemethod);
   thisint->keyingLength = 32;
   
   if (thisint->keyingMaterial == NULL) return -1;
--- xsupplicant-1.2.1/src/eap_types/peap/eappeap.c.BAD	2005-09-03 17:16:00.000000000 -0500
+++ xsupplicant-1.2.1/src/eap_types/peap/eappeap.c	2005-09-03 17:16:47.000000000 -0500
@@ -239,7 +239,7 @@
   set_peap_version(p2d, peap_version);  // Tell PEAP what version we want to use.
   dataoffs[0] = ((uint8_t)dataoffs[0] & 0xfc);  // Mask out the version bits.
   
-  if (tls_funcs_decode_packet(thisint, dataoffs, insize,  outframe, outsize, 
+  if (tls_funcs_decode_packet(thisint, (char *) dataoffs, insize, (char *) outframe, outsize, 
 			  (phase2_call)peap_do_phase2, 
 			      userdata->chunk_size) != XENONE)
     {
@@ -335,7 +335,7 @@
     {
       free(thisint->keyingMaterial);
     }
-  thisint->keyingMaterial = tls_funcs_gen_keyblock(network_data->activemethod);
+  thisint->keyingMaterial = (u_char *) tls_funcs_gen_keyblock(network_data->activemethod);
   thisint->keyingLength = 32;
 
   if (thisint->keyingMaterial == NULL) return -1;
--- xsupplicant-1.2.1/src/eap_types/peap/peap_phase2.c.BAD	2005-09-03 17:17:38.000000000 -0500
+++ xsupplicant-1.2.1/src/eap_types/peap/peap_phase2.c	2005-09-03 17:21:23.000000000 -0500
@@ -160,7 +160,7 @@
   switch ((uint8_t)eapvalue)
     {
     case EAP_REQUEST:
-      eap_request_id(thisint->eapdata->identity, eapid, out, out_size); 
+      eap_request_id(thisint->eapdata->identity, eapid, (char *) out, out_size); 
       break;
 
     case EAP_SUCCESS:
@@ -192,7 +192,7 @@
 	  return;
 	}
       eap_request_auth(thisint->activemethod, thisint->eapdata->eap_conf_data,
-		       in, in_size, out, out_size);
+		       (char *) in, in_size, (char *) out, out_size);
       break;
     }
   free(new_frame);
@@ -249,7 +249,7 @@
 
   if (eframe != 1) 
     {
-      peap_pad_frame(in, in_size, padded_frame, &padded_size);
+      peap_pad_frame(in, in_size, (u_char *) padded_frame, &padded_size);
     }
 
   new_frame = (char *)malloc(1024);
@@ -259,12 +259,12 @@
       return;
     }
  
-  do_peap_version1(thisint, padded_frame, padded_size, new_frame, 
+  do_peap_version1(thisint, (u_char *) padded_frame, padded_size, (u_char *) new_frame, 
 		   &new_frame_size);
   free(padded_frame);
   if (eframe !=1) 
     {
-      peap_unpad_frame(new_frame, new_frame_size, out, out_size);
+      peap_unpad_frame((u_char *) new_frame, new_frame_size, out, out_size);
     } else {
       memcpy(out, new_frame, new_frame_size);
       *out_size = new_frame_size;
@@ -330,14 +330,14 @@
   p2d->eapdata->identity = peapconf->identity;
   p2d->eapdata->ias_quirk = peapconf->ias_quirk;
 
-  decr_data = (char *)malloc(1550);
+  decr_data = (u_char *)malloc(1550);
   if (decr_data == NULL) 
     {
       debug_printf(DEBUG_NORMAL, "Couldn't allocate memory for decryption buffer!\n");
       return XEMALLOC;
     }
 
-  encr_data = (char *)malloc(1550);
+  encr_data = (u_char *)malloc(1550);
   if (encr_data == NULL) 
     {
       debug_printf(DEBUG_NORMAL, "Couldn't allocate memory for encryption buffer!\n");
--- xsupplicant-1.2.1/src/eap_types/mschapv2/eapmschapv2.c.BAD	2005-09-03 17:09:07.000000000 -0500
+++ xsupplicant-1.2.1/src/eap_types/mschapv2/eapmschapv2.c	2005-09-03 17:15:29.000000000 -0500
@@ -153,13 +153,13 @@
 	  myvars->AuthenticatorChallenge = NULL;
 	}
 
-      myvars->AuthenticatorChallenge = (u_char *)malloc(16);
+      myvars->AuthenticatorChallenge = (char *)malloc(16);
       if (myvars->AuthenticatorChallenge == NULL) return XEMALLOC;
 
       memcpy(myvars->AuthenticatorChallenge, &challenge->Challenge, 16);
       
       debug_printf(DEBUG_AUTHTYPES, "Authenticator Challenge : ");
-      debug_hex_printf(DEBUG_AUTHTYPES, myvars->AuthenticatorChallenge, 16);
+      debug_hex_printf(DEBUG_AUTHTYPES, (u_char *) myvars->AuthenticatorChallenge, 16);
 
       if (myvars->PeerChallenge != NULL)
 	{
@@ -168,13 +168,13 @@
 	}
 
       // Ignore the RADIUS host, we probably don't care.
-      myvars->PeerChallenge = (u_char *)malloc(16);
+      myvars->PeerChallenge = (char *)malloc(16);
       if (myvars->PeerChallenge == NULL) return XEMALLOC;
 
-      RAND_bytes(myvars->PeerChallenge, 16);
+      RAND_bytes((u_char *) myvars->PeerChallenge, 16);
 
       debug_printf(DEBUG_AUTHTYPES, "Generated PeerChallenge : ");
-      debug_hex_printf(DEBUG_AUTHTYPES, myvars->PeerChallenge,16);
+      debug_hex_printf(DEBUG_AUTHTYPES, (u_char *) myvars->PeerChallenge,16);
 
       if (myvars->NtResponse != NULL)
 	{
@@ -182,14 +182,14 @@
 	  myvars->NtResponse = NULL;
 	}
 
-      myvars->NtResponse = (u_char *)malloc(24);
+      myvars->NtResponse = (char *)malloc(24);
       if (myvars->NtResponse == NULL) return XEMALLOC;
 
       GenerateNTResponse(myvars->AuthenticatorChallenge, myvars->PeerChallenge,
 			 username, userdata->password, myvars->NtResponse);
 
       debug_printf(DEBUG_AUTHTYPES, "myvars->NtResponse = ");
-      debug_hex_printf(DEBUG_AUTHTYPES, myvars->NtResponse, 24);
+      debug_hex_printf(DEBUG_AUTHTYPES, (u_char *) myvars->NtResponse, 24);
 
       response->OpCode = MS_CHAPV2_RESPONSE;
       response->MS_CHAPv2_ID = challenge->MS_CHAPv2_ID;
@@ -219,7 +219,7 @@
       CheckAuthenticatorResponse(userdata->password, 
 				 myvars->NtResponse, myvars->PeerChallenge,
 				 myvars->AuthenticatorChallenge,
-				 username, (u_char *)&recv[0], &respOk);
+				 username, (char *)&recv[0], &respOk);
 
       if (respOk == 1)
 	{
@@ -227,15 +227,15 @@
 	  outframe[0] = MS_CHAPV2_SUCCESS;
 	  
 	  // We were successful, so generate keying material.
-	  NtPasswordHash(userdata->password, (u_char *)&NtHash);
-	  HashNtPasswordHash((u_char *)&NtHash, (u_char *)&NtHashHash);
-	  GetMasterKey((u_char *)&NtHashHash, myvars->NtResponse, (u_char *)&MasterKey);
+	  NtPasswordHash(userdata->password, (char *)&NtHash);
+	  HashNtPasswordHash((char *)&NtHash, (char *)&NtHashHash);
+	  GetMasterKey((char *)&NtHashHash, myvars->NtResponse, (char *)&MasterKey);
 	  
 	  // Now, get the send key.
-	  GetAsymetricStartKey((u_char *)&MasterKey, (u_char *)&mppeSend, 16, TRUE, FALSE);
+	  GetAsymetricStartKey((char *)&MasterKey, (char *)&mppeSend, 16, TRUE, FALSE);
 
 	  // And the recv key.
-	  GetAsymetricStartKey((u_char *)&MasterKey, (u_char *)&mppeRecv, 16, FALSE, FALSE);
+	  GetAsymetricStartKey((char *)&MasterKey, (char *)&mppeRecv, 16, FALSE, FALSE);
 
 	  // Finally, populate our myvars->keyingMaterial.
 	  if (myvars->keyingMaterial != NULL)
@@ -243,7 +243,7 @@
 	      free(myvars->keyingMaterial);
 	      myvars->keyingMaterial = NULL;
 	    }
-	  myvars->keyingMaterial = (u_char *)malloc(64);  // 32 bytes each.
+	  myvars->keyingMaterial = (char *)malloc(64);  // 32 bytes each.
 	  if (myvars->keyingMaterial == NULL) return XEMALLOC;
 
 	  bzero(myvars->keyingMaterial, 64);
@@ -294,7 +294,7 @@
       free(thisint->keyingMaterial);
     }
 
-  thisint->keyingMaterial = (char *)malloc(64);
+  thisint->keyingMaterial = (u_char *)malloc(64);
   if (thisint->keyingMaterial == NULL) return -1;
 
   memcpy(thisint->keyingMaterial, myconf->keyingMaterial, 64);
--- xsupplicant-1.2.1/src/eap_types/mschapv2/mschapv2.c.BAD	2005-09-03 17:01:58.000000000 -0500
+++ xsupplicant-1.2.1/src/eap_types/mschapv2/mschapv2.c	2005-09-03 17:04:49.000000000 -0500
@@ -46,7 +46,7 @@
   EVP_DigestUpdate(&cntx, PeerChallenge, 16);
   EVP_DigestUpdate(&cntx, AuthenticatorChallenge, 16);
   EVP_DigestUpdate(&cntx, UserName, strlen(UserName));
-  EVP_DigestFinal(&cntx, (char *)&Digest, &retLen);
+  EVP_DigestFinal(&cntx, (u_char *)&Digest, (u_int *) &retLen);
 
   memcpy(Challenge, Digest, 8);
 }
@@ -96,7 +96,7 @@
 
   EVP_DigestInit(&cntx, EVP_md4());
   EVP_DigestUpdate(&cntx, uniPassword, len);
-  EVP_DigestFinal(&cntx, (char *)&retVal, (int *)&i);
+  EVP_DigestFinal(&cntx, (u_char *)&retVal, (u_int *)&i);
   memcpy(PasswordHash, &retVal, 16);
   free(uniPassword);
 }
@@ -114,7 +114,7 @@
 
   EVP_DigestInit(&cntx, EVP_md4());
   EVP_DigestUpdate(&cntx, PasswordHash, 16);
-  EVP_DigestFinal(&cntx, PasswordHashHash, &i);
+  EVP_DigestFinal(&cntx, (u_char *) PasswordHashHash, (u_int *) &i);
 }
 
 // Shamelessly take from the hostap code written by Jouni Malinen
@@ -231,7 +231,7 @@
   EVP_DigestUpdate(&context, &PasswordHashHash, 16);
   EVP_DigestUpdate(&context, NTResponse, 24);
   EVP_DigestUpdate(&context, Magic1, 39);
-  EVP_DigestFinal(&context, (char *)&Digest, &Digest_len);
+  EVP_DigestFinal(&context, (u_char *)&Digest, (u_int *) &Digest_len);
 
   ChallengeHash(PeerChallenge, AuthenticatorChallenge, UserName, Challenge);
 
@@ -239,7 +239,7 @@
   EVP_DigestUpdate(&context, &Digest, 20);
   EVP_DigestUpdate(&context, &Challenge, 8);
   EVP_DigestUpdate(&context, Magic2, 41);
-  EVP_DigestFinal(&context, (char *)&Digest, &Digest_len);
+  EVP_DigestFinal(&context, (u_char *)&Digest, (u_int *) &Digest_len);
 
   memcpy(AuthenticatorResponse, &Digest, Digest_len);
 }
@@ -287,12 +287,12 @@
       return;
     }
 
-  des_encrypt(Challenge, PasswordHash, Response);
-  des_encrypt(Challenge, PasswordHash + 7, Response+8);
+  des_encrypt((uint8_t *) Challenge, (uint8_t *) PasswordHash, (uint8_t *) Response);
+  des_encrypt((uint8_t *) Challenge, (uint8_t *) PasswordHash + 7, (uint8_t *) Response+8);
   zpwd[0] = PasswordHash[14];
   zpwd[1] = PasswordHash[15];
   memset(zpwd + 2, 0, 5);
-  des_encrypt(Challenge, zpwd, Response+16);
+  des_encrypt((uint8_t *) Challenge, zpwd, (uint8_t *) Response+16);
 }
 
 void NtChallengeResponse(char *Challenge, char *Password, char *Response)
@@ -323,18 +323,18 @@
   
   ChallengeHash(PeerChallenge, AuthenticatorChallenge, UserName, (char *)&Challenge);
   debug_printf(DEBUG_AUTHTYPES, "PeerChallenge : ");
-  debug_hex_printf(DEBUG_AUTHTYPES, PeerChallenge, 8);
+  debug_hex_printf(DEBUG_AUTHTYPES, (u_char *) PeerChallenge, 8);
   debug_printf(DEBUG_AUTHTYPES, "AuthenticatorChallenge : ");
-  debug_hex_printf(DEBUG_AUTHTYPES, AuthenticatorChallenge, 8);
+  debug_hex_printf(DEBUG_AUTHTYPES, (u_char *) AuthenticatorChallenge, 8);
   debug_printf(DEBUG_AUTHTYPES, "Username : %s\n",UserName);
   debug_printf(DEBUG_AUTHTYPES, "Challenge : ");
-  debug_hex_printf(DEBUG_AUTHTYPES, Challenge, 8);
+  debug_hex_printf(DEBUG_AUTHTYPES, (u_char *) Challenge, 8);
   NtPasswordHash(Password, (char *)&PasswordHash);
   debug_printf(DEBUG_AUTHTYPES, "PasswordHash : ");
-  debug_hex_printf(DEBUG_AUTHTYPES, PasswordHash, 16);
+  debug_hex_printf(DEBUG_AUTHTYPES, (u_char *) PasswordHash, 16);
   ChallengeResponse(Challenge, (char *)&PasswordHash, Response);
   debug_printf(DEBUG_AUTHTYPES, "Response : ");
-  debug_hex_printf(DEBUG_AUTHTYPES, Response, 24);
+  debug_hex_printf(DEBUG_AUTHTYPES, (u_char *) Response, 24);
 }
 
 void GetMasterKey(char *PasswordHashHash, char *NTResponse, char *MasterKey)
@@ -360,7 +360,7 @@
   EVP_DigestUpdate(&cntx, PasswordHashHash, 16);
   EVP_DigestUpdate(&cntx, NTResponse, 24);
   EVP_DigestUpdate(&cntx, (char *)&Magic1, 27);
-  EVP_DigestFinal(&cntx, (char *)&Digest, &retLen);
+  EVP_DigestFinal(&cntx, (u_char *)&Digest, (u_int *) &retLen);
 
   memcpy(MasterKey, &Digest, 16);
 }
@@ -386,7 +386,7 @@
   EVP_DigestUpdate(&cntx, APR, 24);
   EVP_DigestUpdate(&cntx, PC, 8);
   EVP_DigestUpdate(&cntx, PR, 24); 
-  EVP_DigestFinal(&cntx, (char *)&Digest, &retLen);
+  EVP_DigestFinal(&cntx, (u_char *)&Digest, (u_int *) &retLen);
   
   memcpy(MasterKey, &Digest, 16);
   
@@ -461,7 +461,7 @@
   EVP_DigestUpdate(&cntx, SHSpad1, 40);
   EVP_DigestUpdate(&cntx, (char *)&Magic, 84);
   EVP_DigestUpdate(&cntx, SHSpad2, 40);
-  EVP_DigestFinal(&cntx, (char *)&Digest, &retLen);
+  EVP_DigestFinal(&cntx, (u_char *)&Digest, (u_int *)&retLen);
 
   memcpy(SessionKey, &Digest, SessionKeyLength);
 }
--- xsupplicant-1.2.1/src/eap_types/ttls/eapttls.c.BAD	2005-09-03 16:43:18.000000000 -0500
+++ xsupplicant-1.2.1/src/eap_types/ttls/eapttls.c	2005-09-03 16:44:20.000000000 -0500
@@ -215,7 +215,7 @@
   // Make sure we have a valid packet to process.
   if (dataoffs == NULL) return XENONE;
   
-  result=tls_funcs_decode_packet(thisint, dataoffs, insize,  outframe, outsize,
+  result=tls_funcs_decode_packet(thisint, (char *) dataoffs, insize, (char *) outframe, outsize,
 				 (phase2_call)ttls_do_phase2, userdata->chunk_size);
 
   if (result != 0)
@@ -250,7 +250,7 @@
       free(thisint->keyingMaterial);
     }
   
-  thisint->keyingMaterial = tls_funcs_gen_keyblock(network_data->activemethod);
+  thisint->keyingMaterial = (u_char *) tls_funcs_gen_keyblock(network_data->activemethod);
   thisint->keyingLength = 32;
 
   if (thisint->keyingMaterial == NULL) return -1;
--- xsupplicant-1.2.1/src/eap_types/ttls/ttlsphase2.c.BAD	2005-09-03 16:45:26.000000000 -0500
+++ xsupplicant-1.2.1/src/eap_types/ttls/ttlsphase2.c	2005-09-03 16:57:41.000000000 -0500
@@ -184,7 +184,7 @@
   username_size = strlen(username);
 
   // Send the Username AVP
-  build_avp(USER_NAME_AVP, 0, MANDITORY_FLAG, username, username_size, out_data, &avp_out_size);
+  build_avp(USER_NAME_AVP, 0, MANDITORY_FLAG, (uint8_t *) username, username_size, (uint8_t *) out_data, &avp_out_size);
 
   avp_offset = avp_out_size;
 
@@ -200,7 +200,7 @@
   id = challenge[16];
 
   // Send the MS-CHAP AVP
-  build_avp(MS_CHAP_CHALLENGE, MS_VENDOR_ATTR, (MANDITORY_FLAG | VENDOR_FLAG), (char *)&mschap_challenge, 16, &out_data[avp_offset], &avp_out_size);
+  build_avp(MS_CHAP_CHALLENGE, MS_VENDOR_ATTR, (MANDITORY_FLAG | VENDOR_FLAG), (uint8_t *) &mschap_challenge, 16, (uint8_t *) &out_data[avp_offset], &avp_out_size);
 
   avp_offset+=avp_out_size;
 
@@ -217,7 +217,7 @@
   memcpy(&mschap_answer[2], &mschap_challenge, 16);
   memcpy(&mschap_answer[26], &mschap_result, 24);
 
-  build_avp(MS_CHAP2_RESPONSE, MS_VENDOR_ATTR, (MANDITORY_FLAG | VENDOR_FLAG), (char *)&mschap_answer, 50, &out_data[avp_offset], &avp_out_size);
+  build_avp(MS_CHAP2_RESPONSE, MS_VENDOR_ATTR, (MANDITORY_FLAG | VENDOR_FLAG), (uint8_t *) &mschap_answer, 50, (uint8_t *) &out_data[avp_offset], &avp_out_size);
   avp_offset+=avp_out_size;
   *out_size = avp_offset;
 }
@@ -283,7 +283,7 @@
   username_size = strlen(username);
 
   // Send the Username AVP
-  build_avp(USER_NAME_AVP, 0, MANDITORY_FLAG, username, username_size, out_data, &avp_out_size);
+  build_avp(USER_NAME_AVP, 0, MANDITORY_FLAG, (uint8_t *) username, username_size, (uint8_t *) out_data, &avp_out_size);
 
   avp_offset = avp_out_size;
 
@@ -299,7 +299,7 @@
   id = challenge[8];
 
   // Send the MS-CHAP AVP
-  build_avp(MS_CHAP_CHALLENGE, MS_VENDOR_ATTR, (MANDITORY_FLAG | VENDOR_FLAG), (char *)&mschap_challenge, 8, &out_data[avp_offset], &avp_out_size);
+  build_avp(MS_CHAP_CHALLENGE, MS_VENDOR_ATTR, (MANDITORY_FLAG | VENDOR_FLAG), (uint8_t *) &mschap_challenge, 8, (uint8_t *) &out_data[avp_offset], &avp_out_size);
 
   avp_offset+=avp_out_size;
 
@@ -313,7 +313,7 @@
   mschap_answer[1] = 1; // Use NT Style Passwords.
   memcpy((char *)&mschap_answer[26], (char *)&mschap_result, 24);
 
-  build_avp(MS_CHAP_RESPONSE, MS_VENDOR_ATTR, (MANDITORY_FLAG | VENDOR_FLAG), (char *)&mschap_answer, 50, &out_data[avp_offset], &avp_out_size);
+  build_avp(MS_CHAP_RESPONSE, MS_VENDOR_ATTR, (MANDITORY_FLAG | VENDOR_FLAG), (uint8_t *) &mschap_answer, 50, (uint8_t *) &out_data[avp_offset], &avp_out_size);
   avp_offset+=avp_out_size;
 
   *out_size = avp_offset;
@@ -386,12 +386,12 @@
       username = phase2data->username;
     }
   username_size = strlen(username);
-  build_avp(USER_NAME_AVP, 0, MANDITORY_FLAG, username, username_size, out_data, &avp_out_size);
+  build_avp(USER_NAME_AVP, 0, MANDITORY_FLAG, (uint8_t *) username, username_size, (uint8_t *) out_data, &avp_out_size);
 
   avp_offset = avp_out_size;
 
   // Get the implicit challenge.
-  challenge = implicit_challenge(thisint);
+  challenge = (u_char *) implicit_challenge(thisint);
   if (challenge == NULL)
     {
       debug_printf(DEBUG_NORMAL, "Invalid implicit challenge in ttls_do_chap()!\n");
@@ -409,9 +409,9 @@
       return;
     }
 
-  user_passwd = phase2data->password;
+  user_passwd = (u_char *) phase2data->password;
 
-  tohash = (char *)malloc(1+16+strlen(user_passwd));
+  tohash = (u_char *)malloc(1+16+strlen((char *) user_passwd));
   if (tohash == NULL)
     {
       debug_printf(DEBUG_NORMAL, "Error with malloc of \"tohash\" in ttls_do_chap().\n");
@@ -419,13 +419,13 @@
     }
 
   tohash[0] = session_id;
-  memcpy(&tohash[1], user_passwd, strlen(user_passwd));
-  memcpy(&tohash[1+strlen(user_passwd)], &chap_challenge, 16);
-  hashlen = 1+strlen(user_passwd)+16;
+  memcpy(&tohash[1], user_passwd, strlen((char *) user_passwd));
+  memcpy(&tohash[1+strlen((char *) user_passwd)], &chap_challenge, 16);
+  hashlen = 1+strlen((char *) user_passwd)+16;
 
   EVP_DigestInit(ctx, EVP_md5());
   EVP_DigestUpdate(ctx, tohash, hashlen);
-  EVP_DigestFinal(ctx, (char *)&chap_hash[1], (int *)&md5_length);
+  EVP_DigestFinal(ctx, (u_char *)&chap_hash[1], (u_int *)&md5_length);
   
   if (md5_length != 16)  // We didn't get back a valid hash!
     {
@@ -433,11 +433,11 @@
     }
   chap_hash[0]=session_id;
 
-  build_avp(CHAP_PASSWORD_AVP, 0, MANDITORY_FLAG, chap_hash, 17, &out_data[avp_offset], &avp_out_size);
+  build_avp(CHAP_PASSWORD_AVP, 0, MANDITORY_FLAG, chap_hash, 17, (uint8_t *) &out_data[avp_offset], &avp_out_size);
 
   avp_offset += avp_out_size;
 
-  build_avp(CHAP_CHALLENGE_AVP, 0, MANDITORY_FLAG, (char *)&chap_challenge, 16, &out_data[avp_offset], &avp_out_size);
+  build_avp(CHAP_CHALLENGE_AVP, 0, MANDITORY_FLAG, (uint8_t *) &chap_challenge, 16, (uint8_t *) &out_data[avp_offset], &avp_out_size);
 
   if (tohash != NULL)
     {
@@ -518,8 +518,8 @@
 
   avp_offset = 0;
 
-  build_avp(USER_NAME_AVP, 0, MANDITORY_FLAG, username, 
-	    strlen(username), out_data, &avp_out_size);
+  build_avp(USER_NAME_AVP, 0, MANDITORY_FLAG, (uint8_t *) username, 
+	    strlen(username), (uint8_t *) out_data, &avp_out_size);
 
   avp_offset += avp_out_size;
 
@@ -537,7 +537,7 @@
   bzero(tempbuf, passwd_size);
   memcpy(tempbuf, phase2data->password, strlen(phase2data->password));
 
-  build_avp(USER_PASSWORD_AVP, 0, MANDITORY_FLAG, tempbuf, passwd_size, &out_data[avp_offset], &avp_out_size);
+  build_avp(USER_PASSWORD_AVP, 0, MANDITORY_FLAG, (uint8_t *) tempbuf, passwd_size, (uint8_t *) &out_data[avp_offset], &avp_out_size);
 
   *out_size = avp_offset + avp_out_size;
   
@@ -548,7 +548,7 @@
     }
 
   debug_printf(DEBUG_AUTHTYPES, "Returning from do_pap :\n");
-  debug_hex_dump(DEBUG_AUTHTYPES, out_data, *out_size);
+  debug_hex_dump(DEBUG_AUTHTYPES, (u_char *) out_data, *out_size);
 }
 
 // We don't do anything with the "in" stuff for now..
@@ -567,7 +567,7 @@
     }
 
   debug_printf(DEBUG_AUTHTYPES, "Encrypted Inner (%d) : \n", in_size);
-  debug_hex_dump(DEBUG_AUTHTYPES, in, in_size);
+  debug_hex_dump(DEBUG_AUTHTYPES, (u_char *) in, in_size);
 
   userdata = (struct config_eap_ttls *)thisint->eap_conf_data;
 
@@ -597,10 +597,10 @@
   if ((in_size > 0) && (in[0] != 0x14))
     {
       // We have something to decrypt!
-      tls_crypt_decrypt(thisint, in, in_size, decr_data, &decrsize);
+      tls_crypt_decrypt(thisint, (u_char *) in, in_size, (u_char *) decr_data, &decrsize);
 
       debug_printf(DEBUG_AUTHTYPES, "Decrypted Inner (%d) : \n", in_size);
-      debug_hex_dump(DEBUG_AUTHTYPES, decr_data, decrsize);
+      debug_hex_dump(DEBUG_AUTHTYPES, (u_char *) decr_data, decrsize);
 
       if (decr_data[0] == 0x00)
 	{
@@ -638,11 +638,11 @@
       return XENONE;
     }
 
-  tls_crypt_encrypt_nolen(thisint, toencout, toencsize, out, out_size);
+  tls_crypt_encrypt_nolen(thisint, (u_char *) toencout, toencsize, (u_char *) out, out_size);
   free(toencout);
 
   debug_printf(DEBUG_AUTHTYPES, "Returning from (TTLS) do_phase2 : \n");
-  debug_hex_dump(DEBUG_AUTHTYPES, out, *out_size);
+  debug_hex_dump(DEBUG_AUTHTYPES, (u_char *) out, *out_size);
   return XENONE;
 }
 
--- xsupplicant-1.2.1/src/eap_types/leap/eapleap.c.BAD	2005-09-03 17:22:01.000000000 -0500
+++ xsupplicant-1.2.1/src/eap_types/leap/eapleap.c	2005-09-03 17:25:57.000000000 -0500
@@ -50,7 +50,7 @@
         unicodePass[2 * i + 1] = 0;
     }
     /* Encrypt plain text password to a 16-byte MD4 hash */
-    md4_calc(MD4Hash, unicodePass, passLen * 2);
+    md4_calc(MD4Hash, (u_char *) unicodePass, passLen * 2);
 }
 
 void leap_mschap(char * password, char * response) {
@@ -64,7 +64,7 @@
 
     ntPwdHash(MD4Hash, password);
     md4_calc(MD4HashHash, MD4Hash, 16);
-    ChallengeResponse(leapchallenges->apc, MD4HashHash, response);
+    ChallengeResponse((char *) leapchallenges->apc, (char *) MD4HashHash, response);
 }
 
 
@@ -199,7 +199,7 @@
 
   // LEAP shouldn't be used as an inner type, so we should be able to get
   // away with this.
-  data = dataoffs-5;
+  data = (char *) dataoffs-5;
   eapheader = (struct eap_header *)data;
 
   switch (eapheader->eap_code) {
@@ -279,7 +279,7 @@
     memset(chall_response, 0x0, 8);
     NtChallengeResponse((char *)leaprequest->randval, userdata->password, (char *)&chall_response);
 
-    GenerateNTResponse((char *)leapchallenges->pr, (char *)leapchallenges->pc, username, userdata->password, chall_response);
+    GenerateNTResponse((char *)leapchallenges->pr, (char *)leapchallenges->pc, username, userdata->password, (char *) chall_response);
 
     // store Access Point Challenge
     memcpy((uint8_t *)leapchallenges->apc, (char *)chall_response, 8);
@@ -337,7 +337,7 @@
 
     leapresponse = (struct leap_responses *)dataoffs;
 
-    challenge_response_got =  (char *)malloc(leapresponse->count+1);
+    challenge_response_got =  (u_char *)malloc(leapresponse->count+1);
     if (!challenge_response_got) {
       debug_printf(DEBUG_NORMAL, "(EAP-LEAP) challenge_response_got is NULL after malloc!\n");
     }
@@ -350,7 +350,7 @@
     memset(challenge_response_expected, 0x0, 24);
 
     // Calculate the 24 bytes MS-CHAP Challenge Response
-    leap_mschap(userdata->password, challenge_response_expected);
+    leap_mschap(userdata->password, (char *) challenge_response_expected);
 
     if (memcmp(challenge_response_got, challenge_response_expected, 24) == 0) {
       debug_printf(DEBUG_AUTHTYPES, "(EAP-LEAP) AP ChallengeResponse got is valid.\n");
@@ -386,7 +386,7 @@
     debug_printf(DEBUG_AUTHTYPES, "(EAP-LEAP) leapchallenges->apr : ");
     debug_hex_printf(DEBUG_AUTHTYPES, (uint8_t *)leapchallenges->apr, 24);
 
-    GetMasterLEAPKey((char *)MD4HashHash, leapchallenges->apc, leapchallenges->apr, leapchallenges->pc, leapchallenges->pr, (char *)&MasterKey);
+    GetMasterLEAPKey((char *)MD4HashHash, (char *) leapchallenges->apc, (char *) leapchallenges->apr, (char *) leapchallenges->pc, (char *) leapchallenges->pr, (char *)&MasterKey);
     debug_printf(DEBUG_AUTHTYPES, "MasterLEAPKey : ");
     debug_hex_printf(DEBUG_AUTHTYPES, (unsigned char *)&MasterKey, 16);
 
@@ -444,7 +444,7 @@
   mydata = (struct leap_data *)network_data->activemethod->eap_data;
 
   // Right now, we don't return anything from LEAP.
-  thisint->keyingMaterial = mydata->keyingMaterial;
+  thisint->keyingMaterial = (u_char *) mydata->keyingMaterial;
   thisint->keyingLength = 16;  // We only use 16 bytes for this keying material!
 
   return 0;
--- xsupplicant-1.2.1/src/wpa_common.c.BAD	2005-09-03 08:42:16.000000000 -0500
+++ xsupplicant-1.2.1/src/wpa_common.c	2005-09-03 08:42:30.000000000 -0500
@@ -201,7 +201,7 @@
       // This is a little different than the reference implementation, 
       // because OpenSSL takes parameters in a different order.
       HMAC(EVP_sha1(), key, key_len, input, total_len, &output[currentindex],
-	   &k);
+	   (u_int *) &k);
       currentindex += 20;
       input[total_len-1]++;
     }
--- xsupplicant-1.2.1/src/eapol_key_type1.c.BAD	2005-09-03 08:40:11.000000000 -0500
+++ xsupplicant-1.2.1/src/eapol_key_type1.c	2005-09-03 08:41:54.000000000 -0500
@@ -107,7 +107,7 @@
   if (calchmac == NULL) return XEMALLOC;
 
   HMAC(EVP_md5(), thisint->keyingMaterial+32, 
-       thisint->keyingLength, framecpy, framesize, calchmac, &outlen);
+       thisint->keyingLength, (u_char *) framecpy, framesize, (u_char *) calchmac, (u_int *) &outlen);
 
   // Now, we need to compare the calculated HMAC to the one sent to us.
   keydata = (struct key_packet *)&inframe[4];
--- xsupplicant-1.2.1/src/eapol.c.BAD	2005-09-03 08:30:37.000000000 -0500
+++ xsupplicant-1.2.1/src/eapol.c	2005-09-03 08:30:45.000000000 -0500
@@ -122,7 +122,7 @@
       // an EAP request that is valid.  If we don't have any config informtion,
       // we should just bail here, and not return an error.
 
-      inframe = (u_char *)&workint->recvframe;
+      inframe = (char *)&workint->recvframe;
 
       temp = (struct eapol_header *)&inframe[OFFSET_PAST_MAC];
 
--- xsupplicant-1.2.1/src/statemachine.c.BAD	2005-09-03 08:32:13.000000000 -0500
+++ xsupplicant-1.2.1/src/statemachine.c	2005-09-03 08:33:13.000000000 -0500
@@ -619,7 +619,7 @@
 	} 
     }
 
-  eapol_build_header(EAPOL_LOGOFF, 0, eapolver, thisint->sendframe);
+  eapol_build_header(EAPOL_LOGOFF, 0, eapolver, (char *) thisint->sendframe);
   thisint->send_size = OFFSET_TO_EAP;
 
   snmp_dot1xSuppEapolLogoffFramesTx();
@@ -664,7 +664,7 @@
     }
   
   eapol_build_header(EAPOL_START, 0, network_data->force_eapol_ver,
-		     thisint->sendframe);
+		     (char *) thisint->sendframe);
   thisint->send_size = OFFSET_TO_EAP;
 
   snmp_dot1xSuppEapolStartFramesTx();
--- xsupplicant-1.2.1/src/config_ssid.c.BAD	2005-09-03 08:30:08.000000000 -0500
+++ xsupplicant-1.2.1/src/config_ssid.c	2005-09-03 08:30:24.000000000 -0500
@@ -151,7 +151,7 @@
 
   if (wpa_ie != NULL)
     {
-      cur->wpa_ie = (char *)malloc(wpa_ie_len);
+      cur->wpa_ie = (unsigned char *)malloc(wpa_ie_len);
       if (cur->wpa_ie == NULL)
 	{
 	  debug_printf(DEBUG_NORMAL, "Couldn't allocate memory for wpa_ie! "
@@ -168,7 +168,7 @@
 
   if (rsn_ie != NULL)
     {
-      cur->rsn_ie = (char *)malloc(rsn_ie_len);
+      cur->rsn_ie = (unsigned char *)malloc(rsn_ie_len);
       if (cur->rsn_ie == NULL)
 	{
 	  debug_printf(DEBUG_NORMAL, "Couldn't allocate memory for rsn_ie! "
--- xsupplicant-1.2.1/src/xsup_ipc.c.BAD	2005-09-03 17:27:32.000000000 -0500
+++ xsupplicant-1.2.1/src/xsup_ipc.c	2005-09-03 17:29:17.000000000 -0500
@@ -144,7 +144,7 @@
     }
 
   debug_printf(DEBUG_INT, "(IPC) Sending : \n");
-  debug_hex_dump(DEBUG_INT, tosend, tolen);
+  debug_hex_dump(DEBUG_INT, (u_char *) tosend, tolen);
 
   err = send(skfd, tosend, tolen, 0);
   if (err < 0)
@@ -194,7 +194,7 @@
       *outsize = 0;
     } else {
       debug_printf(DEBUG_INT, "(IPC) Got : \n");
-      debug_hex_dump(DEBUG_INT, outbuf, readStat);
+      debug_hex_dump(DEBUG_INT, (u_char *) outbuf, readStat);
       // Verify that the packet we got is valid.
       
       *outsize = readStat;
@@ -355,7 +355,7 @@
 	  debug_printf(DEBUG_NORMAL, "Error getting working interface "
 		       "dumping current packet: \n");
 
-	  debug_hex_dump(DEBUG_NORMAL, buffer, bufsize);
+	  debug_hex_dump(DEBUG_NORMAL, (u_char *) buffer, bufsize);
 
 	  debug_printf(DEBUG_NORMAL, "Ignoring remaining parts of packet!\n");
 	  bufptr = bufsize+1;
@@ -419,7 +419,7 @@
 	    {
 	      // We got a request for a new IPC client connection.
 	      debug_printf(DEBUG_INT, "Got a request to connect a new client.\n");
-	      newsock = accept(ipc_sock, (struct sockaddr *)&sa, &len);
+	      newsock = accept(ipc_sock, (struct sockaddr *)&sa, (u_int *) &len);
 	      if (newsock <= 0)
 		{
 		  debug_printf(DEBUG_NORMAL, "Got a request for a new IPC client "
@@ -514,7 +514,7 @@
       ipc_callout_request_password(intidx, &bufptr, (char *)&packet[0], 512, 
 				   eapType, challenge);
       debug_printf(DEBUG_AUTHTYPES, "Sending : \n");
-      debug_hex_dump(DEBUG_AUTHTYPES, packet, bufptr);
+      debug_hex_dump(DEBUG_AUTHTYPES, (u_char *) packet, bufptr);
 
       xsup_ipc_send_all((char *)&packet, bufptr);
       
--- xsupplicant-1.2.1/src/eapol_key_type254.c.BAD	2005-09-03 09:05:02.000000000 -0500
+++ xsupplicant-1.2.1/src/eapol_key_type254.c	2005-09-03 09:21:09.000000000 -0500
@@ -192,12 +192,12 @@
     }
 
   debug_printf(DEBUG_INT, "PMK : ");
-  debug_hex_printf(DEBUG_INT, intdata->statemachine->PMK, 32);
-  wpa_PRF(intdata->statemachine->PMK, 32, "Pairwise key expansion", 22,
-	  (char *)&prfdata, 76, retval, 64);
+  debug_hex_printf(DEBUG_INT, (u_char *) intdata->statemachine->PMK, 32);
+  wpa_PRF((u_char *) intdata->statemachine->PMK, 32, (u_char *) "Pairwise key expansion", 22,
+	  (u_char *)&prfdata, 76, (u_char *) retval, 64);
 
   debug_printf(DEBUG_INT, "PTK : ");
-  debug_hex_printf(DEBUG_INT, retval, 64);
+  debug_hex_printf(DEBUG_INT, (u_char *) retval, 64);
 
   return retval;
 }
@@ -264,10 +264,10 @@
     eapolver = snmp_get_dot1xSuppLastEapolFrameVersion();
 
   eapol_build_header(EAPOL_KEY, (intdata->send_size-OFFSET_TO_EAPOL-4), 
-		     eapolver, intdata->sendframe); 
+		     eapolver, (char *) intdata->sendframe); 
   
   memcpy(key, intdata->statemachine->PTK, 16);
-  mic_wpa_populate(intdata->sendframe, intdata->send_size+4, key, 16);
+  mic_wpa_populate((char *) intdata->sendframe, intdata->send_size+4, key, 16);
 
   cardif_sendframe(intdata);
   intdata->statemachine->eapolEap = FALSE;
@@ -351,21 +351,21 @@
       bzero(rc4_ek, 32);
       memcpy(rc4_ek, inkeydata->key_iv, 16);
       memcpy(&rc4_ek[16], &intdata->statemachine->PTK[16], 16);
-      rc4_skip(rc4_ek, 32, 256, keydata, value16);
+      rc4_skip((u_char *) rc4_ek, 32, 256, keydata, value16);
       
       wpa_common_swap_rx_tx_mic(keydata);
-      cardif_set_tkip_key(intdata, allfs, keyindex, FALSE, inkeydata->key_rsc,
-			  6, keydata, value16);
+      cardif_set_tkip_key(intdata, (char *) allfs, keyindex, FALSE, (char *) inkeydata->key_rsc,
+			  6, (char *) keydata, value16);
       break;
 
     case 2:
       // First, decrypt the GTK
       bzero(key, 16);
-      aes_unwrap(&intdata->statemachine->PTK[16], (value16-8)/8, keydata,
-		 key);
+      aes_unwrap((u_char *) &intdata->statemachine->PTK[16], (value16-8)/8, keydata,
+		 (u_char *) key);
 
       wpa_common_swap_rx_tx_mic(keydata);
-      cardif_set_ccmp_key(intdata, NULL, keyindex, FALSE, inkeydata->key_rsc,
+      cardif_set_ccmp_key(intdata, NULL, keyindex, FALSE, (char *) inkeydata->key_rsc,
      			  6, key, (value16-8));
       break;
     }
@@ -391,13 +391,13 @@
     eapolver = snmp_get_dot1xSuppLastEapolFrameVersion();
 
   eapol_build_header(EAPOL_KEY, (intdata->send_size-OFFSET_TO_EAPOL-4), 
-		     eapolver, intdata->sendframe); 
+		     eapolver, (char *) intdata->sendframe); 
   
   memcpy(key, intdata->statemachine->PTK, 16);
-  mic_wpa_populate(intdata->sendframe, intdata->send_size+4, key, 16);
+  mic_wpa_populate((char *) intdata->sendframe, intdata->send_size+4, key, 16);
 
   // Dump what we built.
-  eapol_key_type254_dump(intdata->sendframe);
+  eapol_key_type254_dump((char *) intdata->sendframe);
 
   if (network_data->methods->method_num == WPA_PSK)
     {
@@ -504,13 +504,13 @@
     eapolver = snmp_get_dot1xSuppLastEapolFrameVersion();
 
   eapol_build_header(EAPOL_KEY, (intdata->send_size-OFFSET_TO_EAPOL-4), 
-		     eapolver, intdata->sendframe);
+		     eapolver, (char *) intdata->sendframe);
 
   memcpy(key, intdata->statemachine->PTK, 16);
-  mic_wpa_populate(intdata->sendframe, intdata->send_size+4, key, 16);
+  mic_wpa_populate((char *) intdata->sendframe, intdata->send_size+4, key, 16);
 
   // Dump what we built.
-  eapol_key_type254_dump(intdata->sendframe);
+  eapol_key_type254_dump((char *) intdata->sendframe);
 }
 
 /********************************************************
@@ -586,20 +586,20 @@
     eapolver = snmp_get_dot1xSuppLastEapolFrameVersion();
 
   eapol_build_header(EAPOL_KEY, (intdata->send_size-OFFSET_TO_EAPOL-4), 
-		     eapolver, intdata->sendframe); 
+		     eapolver, (char *) intdata->sendframe); 
 
   memcpy(key, intdata->statemachine->PTK, 16);
-  mic_wpa_populate(intdata->sendframe, intdata->send_size+4, key, 16);  
+  mic_wpa_populate((char *) intdata->sendframe, intdata->send_size+4, key, 16);  
 
   // Dump what we built.
-  eapol_key_type254_dump(intdata->sendframe);
+  eapol_key_type254_dump((char *) intdata->sendframe);
 
   // Get TK1
   value16 = ntohs(inkeydata->key_length);
   memcpy(key, (char *)&intdata->statemachine->PTK[32], value16);
   
   debug_printf(DEBUG_INT, "TK1 : ");
-  debug_hex_printf(DEBUG_INT, key, value16);
+  debug_hex_printf(DEBUG_INT, (u_char *) key, value16);
   
   cardif_sendframe(intdata);
   intdata->statemachine->eapolEap = FALSE;
@@ -612,14 +612,14 @@
     case 1:
       // We need to swap the TX/RX MIC values since we are the supplicant.  
       // (Thanks to Jouni Malinen for pointing this out!)
-      wpa_common_swap_rx_tx_mic(key);
+      wpa_common_swap_rx_tx_mic((u_char *) key);
       cardif_set_tkip_key(intdata, intdata->dest_mac, keyindex, TRUE, 
-			  inkeydata->key_rsc, 6, key, value16);
+			  (char *) inkeydata->key_rsc, 6, key, value16);
       break;
 
     case 2:
       cardif_set_ccmp_key(intdata, intdata->dest_mac, keyindex, TRUE, 
-			  inkeydata->key_rsc, 6, key, value16);
+			  (char *) inkeydata->key_rsc, 6, key, value16);
       break;
     }
 }
@@ -646,7 +646,7 @@
 
   if (keyflags & WPA_KEY_MIC_FLAG)
     {
-      if (mic_wpa_validate(intdata->recvframe, intdata->recv_size, 
+      if (mic_wpa_validate((char *) intdata->recvframe, intdata->recv_size, 
 			   intdata->statemachine->PTK, 16) == FALSE)
 	{
 	  intdata->statemachine->MICVerified = TRUE;
@@ -688,7 +688,7 @@
 	eapolver = snmp_get_dot1xSuppLastEapolFrameVersion();
 
       eapol_build_header(EAPOL_KEY, (intdata->recv_size-OFFSET_TO_EAPOL-4), 
-			 eapolver, intdata->recvframe);
+			 eapolver, (char *) intdata->recvframe);
       cardif_sendframe(intdata);
       intdata->statemachine->eapolEap = FALSE;
     }      
@@ -757,8 +757,8 @@
 		}
 
 	      // We have an ASCII password, so calculate it.
-	      if (psk_wpa_pbkdf2(psk->key, intdata->cur_essid, 
-				 strlen(intdata->cur_essid), (char *)&tpmk) 
+	      if (psk_wpa_pbkdf2(psk->key, (u_char *) intdata->cur_essid, 
+				 strlen(intdata->cur_essid), (u_char *)&tpmk) 
 		  == TRUE)
 		{
 		  intdata->statemachine->PMK = (char *)malloc(32);
@@ -798,7 +798,7 @@
 	}
     } 
 
-  eapol_key_type254_dump(inframe);
+  eapol_key_type254_dump((char *) inframe);
 
   eapol_key_type254_determine_key(intdata);
 
--- xsupplicant-1.2.1/src/config_grammar.y.BAD	2005-09-03 17:31:51.000000000 -0500
+++ xsupplicant-1.2.1/src/config_grammar.y	2005-09-03 17:34:56.000000000 -0500
@@ -829,8 +829,9 @@
 			    }
 			    else {
 			      int tmp_dst_mac[CONFIG_MAC_LEN];
+			      int retval;
 			      SET_FLAG(tmp_network->flags, CONFIG_NET_DEST_MAC);
-			      sscanf($3, "%2x:%2x:%2x:%2x:%2x:%2x", 
+			      retval = sscanf($3, "%2x:%2x:%2x:%2x:%2x:%2x", 
 				     &tmp_dst_mac[0], 
 				     &tmp_dst_mac[1], 
 				     &tmp_dst_mac[2], 
@@ -1035,25 +1036,25 @@
                         set_current_static_wep();
                         parameter_debug("Static Key 1 : %s\n", $3);
 			if (!tmp_static_wep->key[1])
-			  tmp_static_wep->key[1] = $3;
+			  tmp_static_wep->key[1] = (u_char *) $3;
                       }
                     | TK_STATIC_KEY2 '=' TK_QUOTED_STR {
 		        set_current_static_wep();
 		        parameter_debug("Static Key 2 : %s\n", $3);
 		        if (!tmp_static_wep->key[2])
-			  tmp_static_wep->key[2] = $3;
+			  tmp_static_wep->key[2] = (u_char *) $3;
 		    }
                     | TK_STATIC_KEY3 '=' TK_QUOTED_STR {
 		        set_current_static_wep();
                         parameter_debug("Static Key 3 : %s\n", $3);
                         if (!tmp_static_wep->key[3])
-                          tmp_static_wep->key[3] = $3;
+                          tmp_static_wep->key[3] = (u_char *) $3;
                     }
                     | TK_STATIC_KEY4 '=' TK_QUOTED_STR {
 		        set_current_static_wep();
                         parameter_debug("Static Key 4 : %s\n", $3);
                         if (!tmp_static_wep->key[4])
-                          tmp_static_wep->key[4] = $3;
+                          tmp_static_wep->key[4] = (u_char *) $3;
                     }
                     | TK_WEP_TX_KEY '=' TK_NUMBER {
                         set_current_static_wep();


Index: .cvsignore
===================================================================
RCS file: /cvs/extras/rpms/xsupplicant/FC-3/.cvsignore,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- .cvsignore	19 Aug 2005 18:58:19 -0000	1.2
+++ .cvsignore	4 Sep 2005 13:17:38 -0000	1.3
@@ -1 +1,2 @@
 xsupplicant-1.2.tar.gz
+xsupplicant-1.2.1.tar.gz


Index: sources
===================================================================
RCS file: /cvs/extras/rpms/xsupplicant/FC-3/sources,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- sources	19 Aug 2005 18:58:19 -0000	1.2
+++ sources	4 Sep 2005 13:17:38 -0000	1.3
@@ -1 +1,2 @@
 e1eee37899b49ed238648699d0a01c5b  xsupplicant-1.2.tar.gz
+c44300f798a3317c06e501eb0dd98a23  xsupplicant-1.2.1.tar.gz


Index: xsupplicant.spec
===================================================================
RCS file: /cvs/extras/rpms/xsupplicant/FC-3/xsupplicant.spec,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- xsupplicant.spec	19 Aug 2005 18:58:19 -0000	1.1
+++ xsupplicant.spec	4 Sep 2005 13:17:38 -0000	1.2
@@ -1,6 +1,6 @@
 Name:		xsupplicant
 Summary:	Open Source Implementation of IEEE 802.1x
-Version:	1.2
+Version:	1.2.1
 Release:	1%{?dist}
 License:	GPL
 Group:		System Environment/Base
@@ -8,6 +8,8 @@
 Source0:	http://download.sourceforge.net/open1x/xsupplicant-%{version}.tar.gz
 BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRequires:	openssl-devel, bison, flex
+Patch0:		xsupplicant-1.2.1-docsfix.patch
+Patch1:		xsupplicant-1.2.1-gcc4-cleanups.patch
 
 %description
 This software allows a GNU/Linux or BSD workstation to authenticate with
@@ -17,12 +19,17 @@
 
 %prep
 %setup -q
+%patch0 -p1
+%patch1 -p1
 
 perl -pi.orig -e 's|/lib\b|/%{_lib}|g' configure*
 
 %build
 %configure
 make %{?_smp_mflags}
+cd doc
+./builddocs.sh
+cd ..
 
 %install
 rm -rf $RPM_BUILD_ROOT
@@ -35,7 +42,7 @@
 
 %files 
 %defattr(-,root,root,-)
-%doc AUTHORS COPYING README doc/html/ doc/txt/ doc/README* etc/*.conf
+%doc AUTHORS COPYING README doc/html/ doc/txt/ doc/pdf doc/README* etc/*.conf
 %config(noreplace) %{_sysconfdir}/xsupplicant.conf
 %{_bindir}/config-parser
 %{_bindir}/xsup_monitor
@@ -44,6 +51,9 @@
 %{_sbindir}/xsupplicant
 
 %changelog
+* Sat Sep  3 2005 Tom "spot" Callaway <tcallawa at redhat.com> 1.2.1-1
+- bump to 1.2.1 release
+
 * Fri Aug 19 2005 Tom "spot" Callaway <tcallawa at redhat.com> 1.2-1
 - bump to 1.2 final
 




More information about the fedora-extras-commits mailing list