M1—Improper Credential Usage
>Control Description
**Application Specific**
Threat agents exploiting hardcoded credentials and improper credential usage in mobile applications can include automated attacks using publicly available or custom-built tools. Such agents could potentially locate and exploit hardcoded credentials or exploit weaknesses due to improper credential usage.
>Prevention & Mitigation Strategies
- 1.Avoid hardcoded credentials in the app's source code or configuration files; use secure credential vaults or environment-based injection instead.
- 2.Encrypt credentials during transmission using TLS and never send them over insecure channels.
- 3.Do not store user credentials on the device; use secure, revocable access tokens instead.
- 4.Implement strong user authentication protocols such as multi-factor authentication (MFA).
- 5.Regularly update and rotate any API keys or tokens used by the application.
- 6.Use platform-provided secure storage mechanisms (Keychain on iOS, Keystore on Android) for any secrets that must be stored locally.
>Attack Scenarios
#1
#2
#3
>References
Ask AI
Configure your API key to use AI features.