CWE-552: Files or Directories Accessible to External Parties
Web servers, FTP servers, and similar servers may store a set of files underneath a "root" directory that is accessible to the server's users. Applications may store sensitive files underneath this root without also using access control to limit which users may request those files, if any. Alternately, an application might package multiple files or directories into an archive file (e.g., ZIP or tar), but the application might not exclude sensitive files that are underneath those directories.
In cloud technologies and containers, this weakness might present itself in the form of misconfigured storage accounts that can be read or written by a public or anonymous user.
Read Files or Directories; Modify Files or Directories
Implementation; System Configuration; Operation
Class: Not Language-Specific (Undetermined Prevalence)
Class: Not Technology-Specific (Undetermined Prevalence)
Class: Cloud Computing (Often Prevalent)
The following Azure command updates the settings for a storage account:
However, "Allow Blob Public Access" is set to true, meaning that anonymous/public users can access blobs.
The command could be modified to disable "Allow Blob Public Access" by setting it to false.
The following Google Cloud Storage command gets the settings for a storage account named 'BUCKET_NAME':
Suppose the command returns the following result:
This result includes the "allUsers" or IAM role added as members, causing this policy configuration to allow public access to cloud storage resources. There would be a similar concern if "allAuthenticatedUsers" was present.
The command could be modified to remove "allUsers" and/or "allAuthenticatedUsers" as follows:
Note: this is a curated list of examples for users to understand the variety of ways in which this weakness can be introduced. It is not a complete list of all CVEs that are related to this CWE entry.
The full story
This article is one source in a clustered incident — the cluster page carries the summary, timeline and every other outlet covering it.
