/*****************************************************************************
* md5.c: not so strong MD5 hashing
*****************************************************************************
/*****************************************************************************
* md5.c: not so strong MD5 hashing
*****************************************************************************
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
( w += f(x, y, z) + data, w = w<<s | w>>(32-s), w += x )
/*****************************************************************************
( w += f(x, y, z) + data, w = w<<s | w>>(32-s), w += x )
/*****************************************************************************
/*****************************************************************************
* AddMD5: add i_len bytes to an MD5 message
*****************************************************************************/
/*****************************************************************************
* AddMD5: add i_len bytes to an MD5 message
*****************************************************************************/
- memcpy( p_tmp, p_src + i_offset, 64 );
- Digest( p_md5, p_tmp );
+ memcpy( p_tmp, ((const uint8_t *)p_src) + i_offset, 64 );
+ DigestMD5( p_md5, p_tmp );
- memcpy( ((uint8_t *)p_md5->p_data) + i_current, p_src + i_offset, i_len );
+ memcpy( ((uint8_t *)p_md5->p_data) + i_current,
+ ((const uint8_t *)p_src) + i_offset, i_len );
p_md5->p_data[ 15 ] = (p_md5->i_bits >> 32);
REVERSE( &p_md5->p_data[ 14 ], 2 );
p_md5->p_data[ 15 ] = (p_md5->i_bits >> 32);
REVERSE( &p_md5->p_data[ 14 ], 2 );