🛡️ Google GCE Network allows unrestricted FTP traffic🟢
- Contextual name: 🛡️ Google GCE Network allows unrestricted FTP traffic🟢
- ID: /ce/ca/google/vpc/network-ftp-access
- Tags:
- Policy Type: COMPLIANCE_POLICY
- Policy Categories: SECURITY
Logic
Description
Description
This policy identifies Google GCE Networks that have Firewall Rules allowing unrestricted incoming traffic (
0.0.0.0/0) from the internet to the standard FTP ports:TCP/20(data) andTCP/21(control).In GCP, Firewall Rules are defined at the VPC Network level. Each rule either allows or denies traffic based on its configuration. These configurations specify the type of traffic (e.g., protocols and ports) and the source or destination (e.g., IP addresses, subnets, and instances).
Rationale
File Transfer Protocol (FTP) is a legacy protocol that transmits data, including usernames and passwords, in cleartext. Exposing FTP servers to the public internet creates significant security risks, including credential theft via network sniffing, brute-force attacks, and unauthorized access. Such exposure can result in data exfiltration, unauthorized file uploads, or compromise of internal resources.
Impact
All FTP connections from outside the affected VPC(s) can be blocked. If there is a legitimate business requirement for remote access, specific trusted source IP addresses should be explicitly defined in firewall rules to whitelist access only to the required FTP ports.
... see more
Remediation
Remediation
From Google Cloud Console
- Go to
VPC Network.- Go to the
Firewall Rules.- Click the
Firewall Ruleto be modified.- Click
Edit.- Modify
Source IP rangesto specificIP.- Click
Save.From Google Cloud CLI
Identify Firewall Rules Allowing Public Access
gcloud compute networks get-effective-firewalls default \
--format="table(NAME, DIRECTION, IP_RANGES)" \
--filter="IP_RANGES:0.0.0.0/0 AND DIRECTION:INGRESS"
Restrict the Source Range
Once you have identified the firewall rules, update each one to restrict access to trusted CIDR ranges:
gcloud compute firewall-rules update {{firewall-rule-name}} \
--source-ranges={{cidr-range1}},{{cidr-range2}}