-
Notifications
You must be signed in to change notification settings - Fork 37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CDN #657
Merged
Merged
CDN #657
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
# CSAF and Content Delivery Networks (CDNs) | ||
|
||
If you want to use a CDN to provide your CSAF files, please find some remarks below: | ||
|
||
- **Activate caching**: Most files are more or less static - activate caching to minimize risk for (D)DoS. | ||
- **Include path exemption**: The path `.well-known/csaf/` and potentially `.well-known/security.txt` need to be accessible for all HTTP-clients (also those that are usually detected as bots). | ||
|
||
*Specifically, at least the files in this path ending on `.json`, `.asc`, `.sha256` and `.sha512` should be excluded.* | ||
- **Flush cache when updating files**: When new files are written or old files updated, the cache must be updated. Usually, this can be done through the API the CDN provides. Instead of flushing the whole cache (easy way), a more precise way can be used as files that need to be updated in the cache depend on the distribution method: | ||
|
||
**Directory-based distribution:** | ||
|
||
``` | ||
<path-to-updated-CSAF-document>.json | ||
<path-to-updated-CSAF-document>.json.asc | ||
<path-to-updated-CSAF-document>.json.sha256 | ||
<path-to-updated-CSAF-document>.json.sha512 | ||
<path-of-index>.txt | ||
<path-of-changes>.csv | ||
``` | ||
|
||
*Example:* | ||
|
||
The CSAF advisory `ESA-2023-31816` was changed. Consequently, the following files in the cache need to be updated. | ||
|
||
``` | ||
.well-known/csaf/white/2023/esa-2023-31816.json | ||
.well-known/csaf/white/2023/esa-2023-31816.json.asc | ||
.well-known/csaf/white/2023/esa-2023-31816.json.sha256 | ||
.well-known/csaf/white/2023/esa-2023-31816.json.sha512 | ||
.well-known/csaf/white/index.txt | ||
.well-known/csaf/white/changes.csv | ||
``` | ||
|
||
**ROLIE-based distribution:** | ||
|
||
``` | ||
<path-to-updated-CSAF-document>.json | ||
<path-to-updated-CSAF-document>.json.asc | ||
<path-to-updated-CSAF-document>.json.sha256 | ||
<path-to-updated-CSAF-document>.json.sha512 | ||
<path-of-ROLIE-feed>.json | ||
<path-of-ROLIE-categories>.json | ||
<path-of-ROLIE-services>.json | ||
``` | ||
|
||
*Example:* | ||
|
||
The CSAF advisory `ESA-2023-31816` was changed. Consequently, the following files in the cache need to be updated. | ||
|
||
``` | ||
.well-known/csaf/white/2023/esa-2023-31816.json | ||
.well-known/csaf/white/2023/esa-2023-31816.json.asc | ||
.well-known/csaf/white/2023/esa-2023-31816.json.sha256 | ||
.well-known/csaf/white/2023/esa-2023-31816.json.sha512 | ||
.well-known/csaf/white/csaf-feed-tlp-white.json | ||
.well-known/csaf/white/csaf-categories-tlp-white.json | ||
.well-known/csaf/service.json | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe move the common "The CSAF advisory
ESA-2023-31816
was changed." sentence in front of the two scenarios and make the "Consequently, ..." sentences different so that they do not look like a failed CPSR coding. As the first four paths are identical it took me some time to see that both examples look indeed correct.