You are correct that SYSTEM_SHELL is not a standard Android role. The error "Unknown role: SYSTEM_SHELL" confirms that this role does not exist in the Android system's role management system. Android roles are predefined and documented, and SYSTEM_SHELL is not among them. Instead, Android roles are used for specific system-level purposes, such as default apps for SMS, browser, or assistant roles, and are not intended for shell access or general privilege escalation.
Why are you getting this error?
SYSTEM_SHELL role does not exist in Android's role system, so you cannot add a role holder for it.WRITE_SECURE_SETTINGS or READ_LOGS for Termux API, as documented in Termux API's GitHub issues.What should you do instead?
bashadb shell pm grant com.termux.api android.permission.WRITE_SECURE_SETTINGS adb shell pm grant com.termux.api android.permission.READ_LOGS
su or root access, as the standard Android shell does not grant elevated privileges by default.Would you like help with a specific use case or permission setup?