How to encrypt server URL in android? -
hi working android.i had created library project in data fetched server.now need provide library project third party developer, how can encrypt server url others??
try way :
string stringthatneedstobeencrpyted = "putyoururl"; messagedigest mdenc = null; try { mdenc = messagedigest.getinstance("md5"); } catch (nosuchalgorithmexception e) { // todo auto-generated catch block e.printstacktrace(); } // encryption algorithm mdenc.update(stringthatneedstobeencrpyted.getbytes(), 0, stringthatneedstobeencrpyted.length()); string md5 = new biginteger(1, mdenc.digest()).tostring(16); system.out.println(md5);
Comments
Post a Comment