Skip to content

Commit 4caed42

Browse files
committed
Merge branch 'production' of github.com:cloudflare/cloudflare-docs into korinne-vite-plugin-docs
2 parents b09d283 + 55ad66c commit 4caed42

File tree

3 files changed

+22
-16
lines changed

3 files changed

+22
-16
lines changed

src/content/docs/waf/detections/leaked-credentials/index.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,14 @@ Once enabled, leaked credentials detection will scan incoming HTTP requests for
1919

2020
If Cloudflare detects authentication credentials in the request, those credentials are checked against a list of known leaked credentials. This list of credentials consists of Cloudflare-collected credentials, in addition to the [Have I been Pwned (HIBP)](https://haveibeenpwned.com) matched passwords dataset.
2121

22-
Cloudflare will populate the existing [leaked credentials fields](#leaked-credentials-fields) based on the scan results. You can check these results in the [Security Analytics](/waf/analytics/security-analytics/) dashboard, and use these fields in rule expressions ([custom rules](/waf/custom-rules/) or [rate limiting rules](/waf/rate-limiting-rules/)) to protect your application against the usage of compromised credentials by your end users, and also against leaked credential attacks.
22+
Cloudflare will populate the existing [leaked credentials fields](#leaked-credentials-fields) based on the scan results. You can check these results in the [Security Analytics](/waf/analytics/security-analytics/) dashboard, and use these fields in rule expressions ([custom rules](/waf/custom-rules/) or [rate limiting rules](/waf/rate-limiting-rules/)) to protect your application against the usage of compromised credentials by your end users, and also against leaked credential attacks. Cloudflare may detect leaked credentials either because an attacker is performing a [credential stuffing](https://www.cloudflare.com/learning/bots/what-is-credential-stuffing/) attack or because a legitimate end user is reusing a previously leaked password.
2323

2424
In addition, leaked credentials detection provides a [managed transform](/rules/transform/managed-transforms/reference/#add-leaked-credentials-checks-header) that adds an `Exposed-Credential-Check` request header with a value indicating which field was leaked. For example, if both username and password were previously leaked, the header value will be `1`; if only the password was leaked, the value will be `4`.
2525

2626
One common approach used in web applications when detecting the use of stolen credentials is to warn end users about the situation and ask them to update their password. You can do this based on the managed header received at your origin server.
2727

2828
:::note
29-
Cloudflare may detect leaked credentials either because an attacker is performing a [credential stuffing](https://www.cloudflare.com/learning/bots/what-is-credential-stuffing/) attack or because a legitimate end user is reusing a previously leaked password.
29+
Cloudflare does not store, log, or retain plaintext end-user passwords when performing leaked credential checks. Passwords are hashed, converted into a cryptographic representation, and then compared against a database of leaked credentials.
3030
:::
3131

3232
## Availability

src/content/docs/workers/tutorials/postgres/index.mdx

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -103,14 +103,10 @@ npx wrangler secret put DB_URL
103103

104104
Set your `DB_URL` secret locally in a `.dev.vars` file as documented in [Local Development with Secrets](/workers/configuration/secrets/).
105105

106-
<WranglerConfig>
107-
108-
```toml
106+
```toml title='.dev.vars'
109107
DB_URL="<ENTER YOUR POSTGRESQL CONNECTION STRING>"
110108
```
111109

112-
</WranglerConfig>
113-
114110
### Set explicit parameters
115111

116112
Configure each database parameter as an [environment variable](/workers/configuration/environment-variables/) via the [Cloudflare dashboard](/workers/configuration/environment-variables/#add-environment-variables-via-the-dashboard) or in your Wrangler file. Refer to an example of aWrangler file configuration:
@@ -379,4 +375,4 @@ Your Worker application is now live and accessible at `<YOUR_WORKER>.<YOUR_SUBDO
379375

380376
To build more with databases and Workers, refer to [Tutorials](/workers/tutorials) and explore the [Databases documentation](/workers/databases).
381377

382-
If you have any questions, need assistance, or would like to share your project, join the Cloudflare Developer community on [Discord](https://discord.cloudflare.com) to connect with fellow developers and the Cloudflare team.
378+
If you have any questions, need assistance, or would like to share your project, join the Cloudflare Developer community on [Discord](https://discord.cloudflare.com) to connect with fellow developers and the Cloudflare team.

src/util/container.ts

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { experimental_AstroContainer } from "astro/container";
2-
import { getContainerRenderer } from "@astrojs/mdx";
3-
import { loadRenderers } from "astro:container";
2+
import reactRenderer from "@astrojs/react/server.js";
3+
import mdxRenderer from "@astrojs/mdx/server.js";
44
import { render, type CollectionEntry } from "astro:content";
55
import type { AstroComponentFactory } from "astro/runtime/server/index.js";
66

@@ -12,9 +12,14 @@ export async function entryToString(
1212
return entry.rendered.html;
1313
}
1414

15-
const renderers = await loadRenderers([getContainerRenderer()]);
16-
const container = await experimental_AstroContainer.create({
17-
renderers,
15+
const container = await experimental_AstroContainer.create({});
16+
container.addServerRenderer({
17+
name: "astro:jsx",
18+
renderer: mdxRenderer,
19+
});
20+
container.addServerRenderer({
21+
name: "@astrojs/react",
22+
renderer: reactRenderer,
1823
});
1924

2025
const { Content } = await render(entry);
@@ -31,9 +36,14 @@ export async function componentToString(
3136
component: AstroComponentFactory,
3237
props: any,
3338
) {
34-
const renderers = await loadRenderers([getContainerRenderer()]);
35-
const container = await experimental_AstroContainer.create({
36-
renderers,
39+
const container = await experimental_AstroContainer.create({});
40+
container.addServerRenderer({
41+
name: "astro:jsx",
42+
renderer: mdxRenderer,
43+
});
44+
container.addServerRenderer({
45+
name: "@astrojs/react",
46+
renderer: reactRenderer,
3747
});
3848

3949
const html = await container.renderToString(component, {

0 commit comments

Comments
 (0)