CVE-2022-20230: CRLF Injection in KeyChainActivity can trick user into disclosing keys in KeyChain

Summary

01/07/2022
Yes i
High
Not published

CVE-2022-20230: In choosePrivateKeyAlias of KeyChain.java, there is a possible access to the user's certificate due to improper input validation. Affects platform/packages/apps/KeyChain across 4 version ranges.

>= 10:0, < 10:2022-07-01 >= 11:0, < 11:2022-07-01 >= 12:0, < 12:2022-07-01 >= 12L:0, < 12L:2022-07-01

Fixed in 10:2022-07-01. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

The KeyChain package is a part of the Android ecosystem and is responsible for managing the secure storage of cryptographic keys, certificates, and credentials. It provides a secure and convenient way for applications to access and use these sensitive resources. However, a vulnerability has been discovered in the KeyChainActivity component, which can be exploited to trick users into disclosing their keys stored in the KeyChain.

Vulnerability Detail

The vulnerability exists in the choosePrivateKeyAlias function of KeyChain.java. Due to improper input validation, an attacker can inject CRLF (Carriage Return Line Feed) characters into the input, leading to a CRLF injection vulnerability. By manipulating the input, an attacker can trick the user into selecting a malicious certificate, which can then be used to access sensitive information stored in the KeyChain. This vulnerability does not require any additional execution privileges and can be exploited with user interaction.

How To Fix

Minimum fixed version

10:2022-07-01

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

There is no known workaround for this vulnerability. It is recommended to apply the fix provided by the KeyChain package as soon as possible.

Conclusion

In conclusion, the KeyChainActivity component in the KeyChain package is vulnerable to CRLF injection, which can be exploited to trick users into disclosing their keys stored in the KeyChain. Developers should update their applications to use the latest version of the KeyChain package to mitigate this vulnerability. For further support on vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for platform/packages/apps/KeyChain →

Share this vulnerability

FAQ

This vulnerability can lead to local information disclosure, allowing an attacker to access sensitive information stored in the KeyChain.

No, this vulnerability can be exploited with user interaction and does not require any additional execution privileges.

This vulnerability affects Android versions 10, 11, 12, and 12L.

Yes, a fix has been released by the KeyChain package. Developers should update their applications to use the latest version of the KeyChain package.

More information about this vulnerability can be found in the Android Open Source Vulnerability database: https://storage.googleapis.com/android-osv/ASB-A-221859869.json

Related vulnerabilities

Recent vulnerabilities recorded for platform/packages/apps/KeyChain.

How To Fix

Minimum fixed version

10:2022-07-01

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback