microg/GmsCore · error · IllegalArgumentException
Required caller information missing
Error message
Required caller information missing
What it means
AskPermissionActivity.verify() validates the extras the activity was launched with before showing the permission consent UI. This IllegalArgumentException is thrown when the callerUid extra is missing or 0, meaning microG cannot identify which app is requesting the account permission. It is a fail-fast guard: without the caller UID the package/UID check (PackageUtils.getAndCheckPackage) cannot run.
Source
Thrown at play-services-core/src/main/java/org/microg/gms/auth/AskPermissionActivity.java:107
callerPid = intent.getIntExtra(KEY_CALLER_PID, 0);
fromAccountManager = intent.hasExtra(EXTRA_FROM_ACCOUNT_MANAGER);
if (intent.hasExtra(EXTRA_CONSENT_DATA)) {
try {
consentData = ConsentData.ADAPTER.decode(intent.getByteArrayExtra(EXTRA_CONSENT_DATA));
} catch (Exception e) {
Log.w(TAG, "ConsentData decode failed", e);
}
}
}
if (accountName != null && accountType != null) {
account = new Account(accountName, accountType);
}
}
private void verify(Context context) throws Exception {
if (accountName == null || accountType == null || account == null) throw new IllegalArgumentException("Required account information missing");
if (packageName == null || service == null) throw new IllegalArgumentException("Required request information missing");
if (callerUid == 0) throw new IllegalArgumentException("Required caller information missing");
PackageUtils.getAndCheckPackage(context, packageName, callerUid, callerPid);
PackageManager packageManager = context.getPackageManager();
ApplicationInfo applicationInfo = packageManager.getApplicationInfo(packageName, 0);
appLabel = packageManager.getApplicationLabel(applicationInfo);
appIcon = packageManager.getApplicationIcon(applicationInfo);
}
}
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.ask_permission);
data = new IntentData(getIntent());
try {
data.verify(this);
} catch (Exception e) {
Log.w(TAG, "Verification failed", e);View on GitHub (pinned to 157c9d86ac)
Solutions
- Set the callerUid extra on the Intent launching AskPermissionActivity, typically from Binder.getCallingUid() in the authenticator's getRequestIntent implementation.
- Also verify callerPid is provided, since verify() passes it to PackageUtils.getAndCheckPackage alongside callerUid.
- If you control neither side, update the client app to use the standard AccountManager.requestAuthToken flow so microG populates the extras itself.
Example fix
// before
Intent i = new Intent("com.google.android.gms.auth.ASK_PERMISSION");
i.putExtra("account", account);
i.putExtra("packageName", ctx.getPackageName());
// after
Intent i = new Intent("com.google.android.gms.auth.ASK_PERMISSION");
i.putExtra("account", account);
i.putExtra("packageName", ctx.getPackageName());
i.putExtra("callerUid", Binder.getCallingUid());
i.putExtra("callerPid", Binder.getCallingPid()); Defensive patterns
Strategy: validation
Validate before calling
int callerUid = intent.getIntExtra("callerUid", 0);
if (callerUid == 0) throw new IllegalStateException("callerUid extra required before launching AskPermissionActivity"); Try / catch
try { activity.verifyFlow(); } catch (IllegalArgumentException e) { if (e.getMessage().contains("caller information")) { /* rebuild intent with Binder.getCallingUid() */ } } Prevention
- Always derive callerUid from Binder.getCallingUid() inside the authenticator, never hardcode it.
- Include all required extras (callerUid, callerPid) alongside account/packageName/service.
- Test the permission flow against a real AccountManager round-trip, not just a hand-built Intent.
When it happens
Trigger: Launching AskPermissionActivity via Intent without the callerUid integer extra set (or explicitly setting it to 0), even when accountName, accountType, account, packageName, and service extras are all present.
Common situations: Hand-crafted or partially copied auth Intents that mimic Google Play Services' getRequestIntent response; custom account authenticator code that builds the permission Intent manually and forgets to put the calling UID; a third-party client app built against a different protocol version.
Understand the failure class
Background: "missing required argument" and "the following required arguments were not provided": what required-argument errors mean and how to fix them — this error's family across 20 libraries.
Related errors
- Failed to obtain login token.
- Access denied, missing google package permission for
- Required account information missing
- Required request information missing
- ERROR_MISSING_INSTANCEID_SERVICE
AI-assisted analysis of microg/GmsCore@157c9d86ac (2026-09-06).
Data as JSON: /api/errors/a9b499c8fa13c882.
Report an issue: GitHub.