Impact
A specially crafted container image manifest, fetched from a registry, can be used to trigger a shell escape flaw in the anchore engine analyzer service during an image analysis process. The image analysis operation can only be executed by an authenticated user via a valid API request to anchore engine, or if an already added image that anchore is monitoring has its manifest altered to exploit the same flaw. A successful attack can be used to execute commands that run in the analyzer environment, with the same permissions as the user that anchore engine is run as - including access to the credentials that Engine uses to access its own database which have read-write ability, as well as access to the running engien analyzer service environment. By default Anchore Engine is released and deployed as a container where the user is non-root, but if users run Engine directly or explicitly set the user to 'root' then that level of access may be gained in the execution environment where Engine runs.
Patches
Issue fixed in 0.7.1 release, users of 0.7.0 of anchore-engine should upgrade to 0.7.1.
The fix removes the shell input path from any external source, thus removing the attack vector completely.
Workarounds
None
References
#430
For more information
If you have any questions or comments about this advisory:
Special thanks to Gabor Matuz ([email protected]) for discovering, responsibly disclosing, and working with Anchore to resolve the issue.
Impact
A specially crafted container image manifest, fetched from a registry, can be used to trigger a shell escape flaw in the anchore engine analyzer service during an image analysis process. The image analysis operation can only be executed by an authenticated user via a valid API request to anchore engine, or if an already added image that anchore is monitoring has its manifest altered to exploit the same flaw. A successful attack can be used to execute commands that run in the analyzer environment, with the same permissions as the user that anchore engine is run as - including access to the credentials that Engine uses to access its own database which have read-write ability, as well as access to the running engien analyzer service environment. By default Anchore Engine is released and deployed as a container where the user is non-root, but if users run Engine directly or explicitly set the user to 'root' then that level of access may be gained in the execution environment where Engine runs.
Patches
Issue fixed in 0.7.1 release, users of 0.7.0 of anchore-engine should upgrade to 0.7.1.
The fix removes the shell input path from any external source, thus removing the attack vector completely.
Workarounds
None
References
#430
For more information
If you have any questions or comments about this advisory:
Special thanks to Gabor Matuz ([email protected]) for discovering, responsibly disclosing, and working with Anchore to resolve the issue.