Skip to content

Commit 091acc4

Browse files
Add a .well-known/security.txt that links to our security page (#9048)
And expires on crates.io's birthday, which everyone knows is June 25. Generated using https://securitytxt.org/.
1 parent 6b90fbb commit 091acc4

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

public/.well-known/security.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Contact: https://crates.io/policies/security
2+
Expires: 2025-06-25T00:00:00.000Z

src/middleware/common_headers.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,12 @@ pub async fn add_common_headers(
2323

2424
let path = request.uri().path();
2525

26-
const STATIC_FILES: [&str; 4] = [
26+
const STATIC_FILES: [&str; 5] = [
2727
"/github-redirect.html",
2828
"/favicon.ico",
2929
"/robots.txt",
3030
"/opensearch.xml",
31+
"/.well-known/security.txt",
3132
];
3233
if STATIC_FILES.contains(&path) {
3334
expires(&mut headers, ONE_DAY);

0 commit comments

Comments
 (0)