Get a Prefix List

Returns a Prefix List that can be referenced in firewall rules. Prefix Lists are named lists of CIDRs that can represent such things as subnets, VPC's, data center DNS resolvers or other service endpoints.

Updates to a Prefix List are automatically applied to all rules that use it.

Prefix List names start with pl and follow this format: pl:{scope}:{list}:{key}

  • {scope}: Can be blank (account-level scope) or set to system (platform-wide scope).
    • Prefix Lists with a blank scope must be unique within each account. For example, you can have different pl::foo:bar Prefix Lists in separate accounts. Prefix List names starting with pl:: are always private.
    • Prefix Lists with system as the scope must be unique across the entire platform. For example, only one pl:system:foo:bar can exist platform-wide. Prefix List names starting with pl:system: are visible to all enabled customers on the platform.
  • {list}: Represents the platform service, such as vpcs.
  • {key}: Identifies the specific instance of the service element with endpoint addresses to be accessed. You may further subdivide {key} (e.g., adding :staging or :test).

Special Prefix List names include pl::vpcs:<current> and pl::subnets:<current>. These are generated Prefix Lists that provide access to VPC or VPC subnet perimeter addresses. When used in firewall rules for IPv4 or IPv6 addresses and applied to a VPC interface, the Prefix List automatically adds the CIDRs for the VPC or VPC subnet perimeter to control access to the interface.

Examples of Prefix List names:

  • VPC:
    • pl::vpcs:{vpc_id} (e.g., pl::vpcs:101)
    • pl::subnets:{subnet_id} (e.g., pl::subnets:202)
    • Special Prefix Lists:
      • pl::vpcs:<current>
      • pl::subnets:<current>
  • Object Storage:
    • pl:system:object-storage:{region} (e.g., pl:system:object-storage:us-iad)
    • pl:system:object-storage:{region}:staging (e.g., pl:system:object-storage:no-osl-1:staging)
  • DNS:
    • pl:system:resolvers:{region} (e.g., pl:system:resolvers:us-iad)
    • pl:system:resolvers:{region}:staging (e.g., pl:system:resolvers:no-osl-1:staging)

Permissions and scopes

To call this operation, you need the following:

  • OAuth scopes. Your user needs these scopes assigned. Learn more.

    • Scopes: prefixlist:read_only

CLI

linode-cli  prefixlists view 123

Learn more

Path Params
string
enum
required

Enum Call either the v4 URL, or v4beta for operations still in Beta.

Allowed:
integer
required

The unique Prefix List ID.

Responses

Language
Credentials
LoadingLoading…
Response
Choose an example:
application/json