Skip to content

Instantly share code, notes, and snippets.

View Scienticious's full-sized avatar
💙
Fluttering

Mirza Jaun Scienticious

💙
Fluttering
View GitHub Profile
okhttp3.Address: can't find referenced class javax.annotation.Nullable
okhttp3.Authenticator: can't find referenced class javax.annotation.Nullable
okhttp3.Authenticator$1: can't find referenced class javax.annotation.Nullable
okhttp3.Cache: can't find referenced class javax.annotation.Nullable
okhttp3.Cache$2: can't find referenced class javax.annotation.Nullable
okhttp3.Cache$CacheResponseBody: can't find referenced class javax.annotation.Nullable
okhttp3.Cache$Entry: can't find referenced class javax.annotation.Nullable
okhttp3.CacheControl: can't find referenced class javax.annotation.Nullable
okhttp3.CertificatePinner: can't find referenced class javax.annotation.Nullable
okhttp3.Challenge: can't find referenced class javax.annotation.Nullable
try {
PackageInfo info = getPackageManager().getPackageInfo(
getPackageName(),
PackageManager.GET_SIGNATURES);
for (Signature signature : info.signatures) {
MessageDigest md = MessageDigest.getInstance("SHA");
md.update(signature.toByteArray());
Log.d("KeyHash:", Base64.encodeToString(md.digest(), Base64.DEFAULT));
}