Skip to content
Info disclosure Write-up Beginner

🛰️ How I Found FTP Credentials in a Python Script on a NASA Subdomain

A publicly accessible Python script on a NASA subdomain contained plaintext FTP credentials, an internal IP address and an internal upload path. Anyone who found the file could read those secrets and use them to reach internal infrastructure.

Batraju Sairam Follow

Published on medium.com

Bug bounty hunting is often about persistence, pattern recognition, and sometimes, a bit of luck. This is a write-up of a real experience where my recon process led me to discover FTP credentials, internal IPs, and internal paths — all hidden inside a publicly accessible Python script hosted on a NASA subdomain.

Batraju Sairam, on medium.com

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely a script containing hard-coded FTP credentials and internal paths was deployed to a public web directory instead of being kept private or using configuration secrets.

Impact

The exposed credentials and internal details could let an attacker access internal file storage; the author states no systems were accessed and the file was taken down after disclosure.

What the attacker needed

None

The fix

The file was taken down promptly after responsible disclosure.

How it was found

  1. Enumerate subdomains of the target with subdomain discovery tools.
  2. Crawl the subdomains and collect URLs and JavaScript files into lists.
  3. Search the collected URLs for sensitive keywords such as ftp.
  4. Open the URL that pointed to a Python script on a NASA subdomain.
  5. Read the script and find the FTP host, username, password and upload path.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

A Python script is a small program file that a website may leave on its server. This one still had the login details for an FTP server (a service for moving files) written inside it in plain text. Because anyone could open the file, anyone could read those details and try to log in to the internal file server.

What is Info disclosure?

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.

Similar reports

View all

Same bug class and techniques, clearest first.

Information disclosure

The lesson behind this report.

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.