For all of the flags and options available for cloudlist be sure to check out the Usage page. On this page you can find some examples with output, details of what ‘cloudlist’ supports, and details on configuration.

If you have questions, reach out to us through Help.

Basic Examples

cloudlist

This will list all the assets from configured providers in the configuration file. Specific providers and asset type can also be specified using provider and id filter.

cloudlist -provider aws,gcp

   ________                _____      __ 
  / ____/ /___  __  ______/ / (_)____/ /_
 / /   / / __ \/ / / / __  / / / ___/ __/
/ /___/ / /_/ / /_/ / /_/ / / (__  ) /_  
\____/_/\____/\__,_/\__,_/_/_/____/\__/  v0.0.1        

    projectdiscovery.io

[WRN] Use with caution. You are responsible for your actions
[WRN] Developers assume no liability and are not responsible for any misuse or damage.
[INF] Listing assets from AWS (prod) provider.
example.com
example2.com
example3.com
1.1.1.1
2.2.2.2
3.3.3.3
4.4.4.4
5.5.5.5
6.6.6.6
[INF] Found 2 hosts and 6 IPs from AWS service (prod)

Running cloudlist with Nuclei

Scanning assets from various cloud providers with nuclei for security assessments:-

cloudlist -silent | httpx -silent | nuclei -t cves/

Supported providers

  • AWS (Amazon web services)
    • EC2
    • Route53
    • S3
  • GCP (Google Cloud Platform)
    • Cloud DNS
    • GKE
  • DO (DigitalOcean)
    • Instances
  • SCW (Scaleway)
    • Instances
  • Fastly
    • Services
  • Heroku
    • Applications
  • Linode
    • Instances
  • Azure
    • Virtual Machines
  • Namecheap
    • Domain List
  • Alibaba Cloud
    • ECS Instances
  • Cloudflare
    • DNS
  • Hashistack
    • Nomad
    • Consul
    • Terraform
  • Hetzner Cloud
    • Instances
  • Openstack
    • Instances
  • Kubernetes
    • Services
    • Ingresses

Configuration file

The default provider config file should be located at $HOME/.config/cloudlist/provider-config.yaml and has the following contents as an example. In order to run this tool, the keys need to updated in the config file for the desired providers.

Contribution

Please check PROVIDERS.md and DESIGN.md to include support for new cloud providers in Cloudlist.

  • Fork this project
  • Create your feature branch (git checkout -b new-provider)
  • Commit your changes (git commit -am 'Added new cloud provider')
  • Push to the branch (git push origin new-provider)
  • Create new Pull Request

Cloudlist as a library

It’s possible to use the library directly in your go programs. The following code snippets outline how to list assets from all or given cloud provider.

package main

import (
  "context"
  "log"

  "github.com/projectdiscovery/cloudlist/pkg/inventory"
  "github.com/projectdiscovery/cloudlist/pkg/schema"
)

func main() {
  inventory, err := inventory.New(schema.Options{
    schema.OptionBlock{"provider": "digitalocean", "digitalocean_token": "ec405badb974fd3d891c9223245f9ab5871c127fce9e632c8dc421edd46d7242"},
  })
  if err != nil {
    log.Fatalf("%s\n", err)
  }

  for _, provider := range inventory.Providers {
    resources, err := provider.Resources(context.Background())
    if err != nil {
      log.Fatalf("%s\n", err)
    }
    for _, resource := range resources.Items {
      _ = resource // Do something with the resource
    }
  }
}

Acknowledgments

Thank you for inspiration

License

cloudlist is made with 🖤 by the projectdiscovery team and licensed under MIT