--- old/usr/src/common/crypto/aes/aes_impl.c	Thu Aug 28 11:51:45 2008
+++ new/usr/src/common/crypto/aes/aes_impl.c	Thu Aug 28 11:51:42 2008
@@ -1488,7 +1488,7 @@
 
 #else	/* byte swap */
 	for (i = 0, j = 0; j < keysize; i++, j += 4) {
-		keyarr.ka32[i] = htonl(*(uint32_t *)&cipherKey[j]);
+		keyarr.ka32[i] = htonl(*(uint32_t *)(void *)&cipherKey[j]);
 	}
 #endif
 
@@ -1525,10 +1525,10 @@
 		bcopy(pt, &buffer, AES_BLOCK_LEN);
 
 #else	/* byte swap */
-		buffer[0] = htonl(*(uint32_t *)&pt[0]);
-		buffer[1] = htonl(*(uint32_t *)&pt[4]);
-		buffer[2] = htonl(*(uint32_t *)&pt[8]);
-		buffer[3] = htonl(*(uint32_t *)&pt[12]);
+		buffer[0] = htonl(*(uint32_t *)(void *)&pt[0]);
+		buffer[1] = htonl(*(uint32_t *)(void *)&pt[4]);
+		buffer[2] = htonl(*(uint32_t *)(void *)&pt[8]);
+		buffer[3] = htonl(*(uint32_t *)(void *)&pt[12]);
 #endif
 
 		AES_ENCRYPT_IMPL(&ksch->encr_ks.ks32[0], ksch->nr,
@@ -1540,10 +1540,10 @@
 	}
 
 #else	/* byte swap */
-		*(uint32_t *)&ct[0] = htonl(buffer[0]);
-		*(uint32_t *)&ct[4] = htonl(buffer[1]);
-		*(uint32_t *)&ct[8] = htonl(buffer[2]);
-		*(uint32_t *)&ct[12] = htonl(buffer[3]);
+		*(uint32_t *)(void *)&ct[0] = htonl(buffer[0]);
+		*(uint32_t *)(void *)&ct[4] = htonl(buffer[1]);
+		*(uint32_t *)(void *)&ct[8] = htonl(buffer[2]);
+		*(uint32_t *)(void *)&ct[12] = htonl(buffer[3]);
 #endif
 /* EXPORT DELETE END */
 	return (CRYPTO_SUCCESS);
@@ -1578,10 +1578,10 @@
 		bcopy(ct, &buffer, AES_BLOCK_LEN);
 
 #else	/* byte swap */
-		buffer[0] = htonl(*(uint32_t *)&ct[0]);
-		buffer[1] = htonl(*(uint32_t *)&ct[4]);
-		buffer[2] = htonl(*(uint32_t *)&ct[8]);
-		buffer[3] = htonl(*(uint32_t *)&ct[12]);
+		buffer[0] = htonl(*(uint32_t *)(void *)&ct[0]);
+		buffer[1] = htonl(*(uint32_t *)(void *)&ct[4]);
+		buffer[2] = htonl(*(uint32_t *)(void *)&ct[8]);
+		buffer[3] = htonl(*(uint32_t *)(void *)&ct[12]);
 #endif
 
 		AES_DECRYPT_IMPL(&ksch->decr_ks.ks32[0], ksch->nr,
@@ -1593,10 +1593,10 @@
 	}
 
 #else	/* byte swap */
-	*(uint32_t *)&pt[0] = htonl(buffer[0]);
-	*(uint32_t *)&pt[4] = htonl(buffer[1]);
-	*(uint32_t *)&pt[8] = htonl(buffer[2]);
-	*(uint32_t *)&pt[12] = htonl(buffer[3]);
+	*(uint32_t *)(void *)&pt[0] = htonl(buffer[0]);
+	*(uint32_t *)(void *)&pt[4] = htonl(buffer[1]);
+	*(uint32_t *)(void *)&pt[8] = htonl(buffer[2]);
+	*(uint32_t *)(void *)&pt[12] = htonl(buffer[3]);
 #endif
 
 /* EXPORT DELETE END */
--- old/usr/src/common/crypto/blowfish/blowfish_impl.c	Thu Aug 28 11:51:57 2008
+++ new/usr/src/common/crypto/blowfish/blowfish_impl.c	Thu Aug 28 11:51:55 2008
@@ -399,8 +399,8 @@
 	 * Read input block and place in left/right in big-endian order.
 	 */
 #ifdef UNALIGNED_POINTERS_PERMITTED
-	left = htonl(*(uint32_t *)&block[0]);
-	right = htonl(*(uint32_t *)&block[4]);
+	left = htonl(*(uint32_t *)(void *)&block[0]);
+	right = htonl(*(uint32_t *)(void *)&block[4]);
 #else
 	left = ((uint32_t)block[0] << 24)
 	    | ((uint32_t)block[1] << 16)
@@ -447,8 +447,8 @@
 	{
 		/* Put the block back into the user's block with final swap */
 #ifdef UNALIGNED_POINTERS_PERMITTED
-		*(uint32_t *)&out_block[0] = htonl(left);
-		*(uint32_t *)&out_block[4] = htonl(right);
+		*(uint32_t *)(void *)&out_block[0] = htonl(left);
+		*(uint32_t *)(void *)&out_block[4] = htonl(right);
 #else
 		out_block[0] = left >> 24;
 		out_block[1] = left >> 16;
@@ -496,8 +496,8 @@
 	 * Read input block and place in left/right in big-endian order.
 	 */
 #ifdef UNALIGNED_POINTERS_PERMITTED
-	left = htonl(*(uint32_t *)&block[0]);
-	right = htonl(*(uint32_t *)&block[4]);
+	left = htonl(*(uint32_t *)(void *)&block[0]);
+	right = htonl(*(uint32_t *)(void *)&block[4]);
 #else
 	left = ((uint32_t)block[0] << 24)
 	    | ((uint32_t)block[1] << 16)
@@ -544,8 +544,8 @@
 	{
 	/* Put the block back into the user's block with final swap */
 #ifdef UNALIGNED_POINTERS_PERMITTED
-		*(uint32_t *)&out_block[0] = htonl(left);
-		*(uint32_t *)&out_block[4] = htonl(right);
+		*(uint32_t *)(void *)&out_block[0] = htonl(left);
+		*(uint32_t *)(void *)&out_block[4] = htonl(right);
 #else
 		out_block[0] = left >> 24;
 		out_block[1] = left >> 16;
--- old/usr/src/common/crypto/des/des_impl.c	Thu Aug 28 11:52:09 2008
+++ new/usr/src/common/crypto/des/des_impl.c	Thu Aug 28 11:52:05 2008
@@ -534,7 +534,7 @@
 		uint64_t tmp;
 
 #ifdef UNALIGNED_POINTERS_PERMITTED
-		tmp = htonll(*(uint64_t *)&block[0]);
+		tmp = htonll(*(uint64_t *)(void *)&block[0]);
 #else
 		tmp = (((uint64_t)block[0] << 56) | ((uint64_t)block[1] << 48) |
 		    ((uint64_t)block[2] << 40) | ((uint64_t)block[3] << 32) |
@@ -548,7 +548,7 @@
 			tmp = des_crypt_impl(ksch->ksch_encrypt, tmp, 3);
 
 #ifdef UNALIGNED_POINTERS_PERMITTED
-		*(uint64_t *)&out_block[0] = htonll(tmp);
+		*(uint64_t *)(void *)&out_block[0] = htonll(tmp);
 #else
 		out_block[0] = tmp >> 56;
 		out_block[1] = tmp >> 48;
@@ -596,7 +596,7 @@
 		uint64_t tmp;
 
 #ifdef UNALIGNED_POINTERS_PERMITTED
-		tmp = htonll(*(uint64_t *)&block[0]);
+		tmp = htonll(*(uint64_t *)(void *)&block[0]);
 #else
 		tmp = (((uint64_t)block[0] << 56) | ((uint64_t)block[1] << 48) |
 		    ((uint64_t)block[2] << 40) | ((uint64_t)block[3] << 32) |
@@ -611,7 +611,7 @@
 			tmp = des_crypt_impl(ksch->ksch_encrypt, tmp, 1);
 
 #ifdef UNALIGNED_POINTERS_PERMITTED
-		*(uint64_t *)&out_block[0] = htonll(tmp);
+		*(uint64_t *)(void *)&out_block[0] = htonll(tmp);
 #else
 		out_block[0] = tmp >> 56;
 		out_block[1] = tmp >> 48;
@@ -673,7 +673,7 @@
 		return (B_FALSE);
 
 #ifdef UNALIGNED_POINTERS_PERMITTED
-	key_so_far = htonll(*(uint64_t *)&key[0]);
+	key_so_far = htonll(*(uint64_t *)(void *)&key[0]);
 #else
 	/*
 	 * The code below reverses the bytes on LITTLE_ENDIAN machines.
@@ -699,7 +699,7 @@
 
 	if (corrected_key != NULL) {
 #ifdef UNALIGNED_POINTERS_PERMITTED
-		*(uint64_t *)&corrected_key[0] = htonll(key_so_far);
+		*(uint64_t *)(void *)&corrected_key[0] = htonll(key_so_far);
 #else
 		/*
 		 * The code below reverses the bytes on LITTLE_ENDIAN machines.
@@ -808,7 +808,7 @@
 	while (strength > i) {
 		offset = 8 * i;
 #ifdef UNALIGNED_POINTERS_PERMITTED
-		key_so_far = htonll(*(uint64_t *)&paritied_key[offset]);
+		key_so_far = htonll(*(uint64_t *)(void *)&paritied_key[offset]);
 #else
 		key_so_far = (((uint64_t)paritied_key[offset + 0] << 56) |
 		    ((uint64_t)paritied_key[offset + 1] << 48) |
@@ -823,7 +823,7 @@
 		fix_des_parity(&key_so_far);
 
 #ifdef UNALIGNED_POINTERS_PERMITTED
-		*(uint64_t *)&paritied_key[offset] = htonll(key_so_far);
+		*(uint64_t *)(void *)&paritied_key[offset] = htonll(key_so_far);
 #else
 		paritied_key[offset + 0] = key_so_far >> 56;
 		paritied_key[offset + 1] = key_so_far >> 48;
@@ -890,7 +890,8 @@
 	{
 		for (i = 0, j = 0; j < keysize; i++, j += 8) {
 #ifdef UNALIGNED_POINTERS_PERMITTED
-			key_uint64[i] = htonll(*(uint64_t *)&cipherKey[j]);
+			key_uint64[i] =
+			    htonll(*(uint64_t *)(void *)&cipherKey[j]);
 #else
 			key_uint64[i] = (((uint64_t)cipherKey[j] << 56) |
 			    ((uint64_t)cipherKey[j + 1] << 48) |
--- old/usr/src/common/crypto/md4/md4.c	Thu Aug 28 11:52:23 2008
+++ new/usr/src/common/crypto/md4/md4.c	Thu Aug 28 11:52:20 2008
@@ -270,7 +270,7 @@
 
 	for (i = 0, j = 0; j < len; i++, j += 4) {
 #if defined(_LITTLE_ENDIAN) && defined(UNALIGNED_POINTERS_PERMITTED)
-		*(uint32_t *)&output[j] = input[i];
+		*(uint32_t *)(void *)&output[j] = input[i];
 #else
 		/* endian-independent code */
 		output[j] = (unsigned char)(input[i] & 0xff);
@@ -292,7 +292,7 @@
 
 	for (i = 0, j = 0; j < len; i++, j += 4) {
 #if defined(_LITTLE_ENDIAN) && defined(UNALIGNED_POINTERS_PERMITTED)
-		output[i] = *(uint32_t *)&input[j];
+		output[i] = *(uint32_t *)(void *)&input[j];
 #else
 		/* endian-independent code */
 		output[i] = ((uint32_t)input[j]) |
--- old/usr/src/common/crypto/modes/ccm.c	Thu Aug 28 11:52:39 2008
+++ new/usr/src/common/crypto/modes/ccm.c	Thu Aug 28 11:52:36 2008
@@ -376,9 +376,6 @@
 	uint64_t counter;
 	size_t pt_len, total_decrypted_len, mac_len, pm_len, pd_len;
 	uint8_t *resultp;
-#ifdef _LITTLE_ENDIAN
-	uint8_t *p;
-#endif	/* _LITTLE_ENDIAN */
 
 
 	pm_len = ctx->ccm_processed_mac_len;
--- old/usr/src/common/crypto/modes/ctr.c	Thu Aug 28 11:52:52 2008
+++ new/usr/src/common/crypto/modes/ctr.c	Thu Aug 28 11:52:49 2008
@@ -59,9 +59,6 @@
 	uint8_t *out_data_2;
 	size_t out_data_1_len;
 	uint64_t counter;
-#ifdef _LITTLE_ENDIAN
-	uint8_t *p;
-#endif
 
 	if (length + ctx->ctr_remainder_len < block_size) {
 		/* accumulate bytes here and return */
--- old/usr/src/common/crypto/sha1/sha1.c	Thu Aug 28 11:53:01 2008
+++ new/usr/src/common/crypto/sha1/sha1.c	Thu Aug 28 11:52:59 2008
@@ -630,22 +630,22 @@
 	sha1word	w_8, w_9, w_10, w_11, w_12, w_13, w_14, w_15;
 #endif	/* !defined(W_ARRAY) */
 
-	W(0)  = LOAD_BIG_32(blk +  0);
-	W(1)  = LOAD_BIG_32(blk +  4);
-	W(2)  = LOAD_BIG_32(blk +  8);
-	W(3)  = LOAD_BIG_32(blk + 12);
-	W(4)  = LOAD_BIG_32(blk + 16);
-	W(5)  = LOAD_BIG_32(blk + 20);
-	W(6)  = LOAD_BIG_32(blk + 24);
-	W(7)  = LOAD_BIG_32(blk + 28);
-	W(8)  = LOAD_BIG_32(blk + 32);
-	W(9)  = LOAD_BIG_32(blk + 36);
-	W(10) = LOAD_BIG_32(blk + 40);
-	W(11) = LOAD_BIG_32(blk + 44);
-	W(12) = LOAD_BIG_32(blk + 48);
-	W(13) = LOAD_BIG_32(blk + 52);
-	W(14) = LOAD_BIG_32(blk + 56);
-	W(15) = LOAD_BIG_32(blk + 60);
+	W(0)  = LOAD_BIG_32((void *)(blk +  0));
+	W(1)  = LOAD_BIG_32((void *)(blk +  4));
+	W(2)  = LOAD_BIG_32((void *)(blk +  8));
+	W(3)  = LOAD_BIG_32((void *)(blk + 12));
+	W(4)  = LOAD_BIG_32((void *)(blk + 16));
+	W(5)  = LOAD_BIG_32((void *)(blk + 20));
+	W(6)  = LOAD_BIG_32((void *)(blk + 24));
+	W(7)  = LOAD_BIG_32((void *)(blk + 28));
+	W(8)  = LOAD_BIG_32((void *)(blk + 32));
+	W(9)  = LOAD_BIG_32((void *)(blk + 36));
+	W(10) = LOAD_BIG_32((void *)(blk + 40));
+	W(11) = LOAD_BIG_32((void *)(blk + 44));
+	W(12) = LOAD_BIG_32((void *)(blk + 48));
+	W(13) = LOAD_BIG_32((void *)(blk + 52));
+	W(14) = LOAD_BIG_32((void *)(blk + 56));
+	W(15) = LOAD_BIG_32((void *)(blk + 60));
 
 #endif	/* !defined(__sparc) */
 
