Skip to content

Commit ec5086f

Browse files
api shield partials
1 parent 44ae33d commit ec5086f

File tree

9 files changed

+65
-105
lines changed

9 files changed

+65
-105
lines changed

src/content/docs/api-shield/index.mdx

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,14 @@ Identify and address your API vulnerabilities.
2121

2222
## Why care about API security?
2323

24-
<Render file="why-care" product="api-shield" />
24+
APIs have become the [backbone of popular web services](https://blog.postman.com/intro-to-apis-history-of-apis/), helping the Internet become more accessible and useful.
25+
26+
As APIs have become more prevalent, however, so have their problems:
27+
28+
* Many companies have [thousands of APIs](/api-shield/security/api-discovery/), including ones they do not even know about.
29+
* To support a large base of users, many APIs are protected by a negative security model that makes them vulnerable to credential-stuffing attacks and automated scanning tools.
30+
* With so many endpoints and users, it’s difficult to recognize brute-force attacks against [specific endpoints](/api-shield/security/volumetric-abuse-detection/).
31+
* Sophisticated attacks are even harder to recognize, often because even development teams are unaware of common and uncommon [usage patterns](/api-shield/security/sequence-analytics/).
2532

2633
Refer to the [Get started](/api-shield/get-started/) guide to set up API Shield.
2734

src/content/docs/api-shield/management-and-monitoring/api-routing.mdx

Lines changed: 56 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ sidebar:
77

88
---
99

10-
import { Render, Steps } from "~/components"
10+
import { Markdown, Render, Steps, Tabs, TabItem } from "~/components"
1111

1212
API Shield Routing enables customers to create a unified external-facing API that routes requests to different back-end services that may have different paths and hosts than the existing zone and DNS configuration.
1313

@@ -18,15 +18,62 @@ The term **Source Endpoint** refers to the endpoint managed by API Shield in End
1818

1919
## Process
2020

21-
<Render file="source-endpoints" />
21+
22+
You must add Source Endpoints to Endpoint Management through established methods, including [uploading a schema](/api-shield/security/schema-validation/#add-validation-by-uploading-a-schema), via [API Discovery](/api-shield/security/api-discovery/), or by [adding manually](/api-shield/management-and-monitoring/#add-endpoints-manually), before creating a route.
23+
24+
To create a route, you will need the operation ID of the Source Endpoint. To find the operation ID in the dashboard:
25+
26+
<Tabs syncKey="dashNewNav">
27+
<TabItem label="Old dashboard">
28+
<Steps>
29+
1. Log in to the [Cloudflare dashboard](https://dash.cloudflare.com/), and select your account and domain.
30+
2. Select **Security** > **API Shield**.
31+
3. Filter the endpoints to find your **Source Endpoint**.
32+
4. Expand the row for your Source Endpoint and note the **operation ID** field.
33+
5. Select the copy icon to copy the operation ID to your clipboard.
34+
</Steps>
35+
</TabItem>
36+
<TabItem label="New dashboard" icon="rocket">
37+
<Steps>
38+
1. Log in to the [Cloudflare dashboard](https://dash.cloudflare.com/login), and select your account and domain.
39+
2. Select **Security** > **Web assets**.
40+
3. Filter the endpoints to find your **Source Endpoint**.
41+
4. Expand the row for your Source Endpoint and note the **operation ID** field.
42+
5. Select the copy icon to copy the operation ID to your clipboard.
43+
</Steps>
44+
</TabItem>
45+
</Tabs>
2246

2347
Once your Source Endpoints are added to Endpoint Management, use the following steps to create and verify routes on any given operation ID:
2448

2549
### Create a route
2650

27-
<Render file="routing" />
51+
<Tabs syncKey="dashNewNav">
52+
<TabItem label="Old dashboard">
53+
<Steps>
54+
1. Log in to the [Cloudflare dashboard](https://dash.cloudflare.com/), and select your account and domain.
55+
2. Go to **Security** > **API Shield**.
56+
3. In **Endpoint Management**, select an existing endpoint and expand its details.
57+
4. Under **Routing**, select **Create route**.
58+
5. Enter the target URL or IP address to route your endpoint to.
59+
6. Select **Deploy route**.
60+
</Steps>
61+
</TabItem>
62+
<TabItem label="New dashboard" icon="rocket">
63+
<Steps>
64+
1. Log in to the [Cloudflare dashboard](https://dash.cloudflare.com/login), and select your account and domain.
65+
2. Go to **Security** > **Web assets**.
66+
3. In **Endpoints**, select an existing endpoint and expand its details.
67+
4. Under **Routing**, select **Create route**.
68+
5. Enter the target URL or IP address to route your endpoint to.
69+
6. Select **Deploy route**.
70+
</Steps>
71+
</TabItem>
72+
</Tabs>
2873

29-
<Render file="routing-path-variables" />
74+
:::note
75+
You can reorder path variables if they are present. For example, you can route `/api/{var1}/users/{var2}` to `/{var2}/users/{var1}`. Segments of the path that are not variables may be added or omitted entirely.
76+
:::
3077

3178
You can also edit or delete a route by selecting **Edit route** on an existing route.
3279

@@ -47,4 +94,8 @@ API Shield Routing is currently in an open beta and is only available for Enterp
4794

4895
## Limitations
4996

50-
<Render file="routing-limitations" />
97+
The Target Endpoint cannot be routed to a Worker if the route is to the same zone.
98+
99+
You cannot change the method of a request. For example, a `GET` Source Endpoint will always send a `GET` request to the Target Endpoint.
100+
101+
You must use all of the variables in the Target Endpoint that appear in the Source Endpoint. For example, routing `/api/{var1}/users/{var2}` to `/api/users/{var2}` is not allowed and will result in an error since `{var1}` is present in the Source Endpoint but not in the Target Endpoint.

src/content/docs/api-shield/security/api-discovery.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ jp-api.example.com/api/v1/users/{var1}
4343

4444
We will consolidate to `{hostVar1}.example.com/api/v1/users/{var1}`.
4545

46-
<Render file="blog-post" />
46+
For more technical details, see our [blog post](https://blog.cloudflare.com/ml-api-discovery-and-schema-learning/).
4747

4848
### Inbox view
4949

src/content/partials/api-shield/blog-post.mdx

Lines changed: 0 additions & 6 deletions
This file was deleted.

src/content/partials/api-shield/routing-limitations.mdx

Lines changed: 0 additions & 10 deletions
This file was deleted.

src/content/partials/api-shield/routing-path-variables.mdx

Lines changed: 0 additions & 9 deletions
This file was deleted.

src/content/partials/api-shield/routing.mdx

Lines changed: 0 additions & 29 deletions
This file was deleted.

src/content/partials/api-shield/source-endpoints.mdx

Lines changed: 0 additions & 31 deletions
This file was deleted.

src/content/partials/api-shield/why-care.mdx

Lines changed: 0 additions & 13 deletions
This file was deleted.

0 commit comments

Comments
 (0)