Any method similar to CCHMac of iPhone in Android?
<p>I have a problem that I have a code of iPhone to convert something in MD5 and I have to write the same code in Android. But the problem is that there is a method name <strong>CCHMac</strong>, I don't know what is that? what functionality it performed on two string as <strong>key &amp; data</strong>. and Is there any method in JAVA/Android similar to that? Please suggest me any solution regarding the same.</p>

<p>*<em>iPhone Code:</em></p>

<pre><code>secret  = @"e24a6167409288f486a78271cc316c4f";
data = @"/v1/vehicles/get-make-models.json?sort=mpg&amp;to=&amp;filter=category&amp;client-id=10030812&amp;from=convertible";
(NSString  *)signRequestNSString  *)data
{
const  char  *cKey  = [secret  cStringUsingEncoding:NSASCIIStringEncoding];       
const  char  *cData = [data cStringUsingEncoding:NSASCIIStringEncoding];
unsigned  char  cHMAC[CC_MD5_DIGEST_LENGTH];
CCHmac(kCCHmacAlgMD5, cKey, strlen(cKey), cData, strlen(cData), cHMAC);
NSData  *HMAC = [[NSData  alloc] initWithBytes:cHMAC length:sizeof(cHMAC)];
NSString  *hash = [HMAC base64EncodedString];
    [HMAC release];
return  hash;
}
</code></pre>

<p>Thanks in advance.</p>
