-
Notifications
You must be signed in to change notification settings - Fork 1
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
policy review document #8
Conversation
Co-authored-by: LeoTM <[email protected]>
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.
ah formatting remaining, i'll fix
3ea03c3
to
4aa1355
Compare
- markdownlint: specify json in fenced code block - prettier: format doc, except powerful APIs table
4aa1355
to
e7ee012
Compare
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.
lgtm
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.
|
||
The Policy File generated by LavaMoat is based on a scan of your codebase, identifying all the powers it uses. The initial policy doesn't provide security on its own. Instead, it's your review of the initial policy and the subsequent updates (with new or updated dependencies) that makes your application secure. | ||
|
||
Reviewing diffs as you go lets you spot suspicious packages or limit the powers you wish newly added packages can use. |
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.
Reviewing diffs as you go lets you spot suspicious packages or limit the powers you wish newly added packages can use. | |
Reviewing diffs as dependencies change lets you spot suspicious packages and/or limit the powers granted to new dependencies. |
- again unsure about "powers"
- "granted" may not be the right/consistent terminology
Reviewing diffs as you go lets you spot suspicious packages or limit the powers you wish newly added packages can use. | ||
|
||
The review of your initial policy may seem like a lot of effort, but it's an investment in a good starting point for your application. | ||
If you generate the initial policy from a known uncompromised version of your application, the main purpose of the initial review is to potentially take away some of the excessive powers from packages you don't use in their full capacity. |
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.
this is kind of a run-on sentence. maybe break up into something like
The purpose of the initial review is twofold:
1. It helps you build confidence that the current state of your app is not compromised
2. You may deny powers to dependencies if you determine they are excessive (assuming it does not break your app)
|
||
The goal of reviewing the diff is to spot a malicious package being added. | ||
|
||
#### TL;DR |
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.
this usually comes first 😄
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.
It's a TLDR of this paragraph - what to look for.
- check `globals` and `builtins` for new powers and investigate if you're surprised the package would need them | ||
- check if new relationships in `packages` are pointing to packages with very [powerful APIs](#powerful-apis) (e.g. spawning child processes in Node.js) | ||
- be aware that the identifier may change to `pkgC>actual-name` from `pkgB>pkgA>actual-name` BUT! If the package now also has totally different powers, it's likely a different package of the same name. Investigate! `npm ls actual-name` should help. | ||
- when a new package is added, consider limiting its powers to what you actually use. |
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.
- I'd capitalize the first letter of each list item
- remove periods at the end of the last two items
- he fourth item is unclear to me. you mean: identify the powers my app uses? (how do I do this?) I want to disallow anything that isn't in that my list of powers?
I hereby give you the explicit (altho not new) permission to add a commit with grammar/style edits to a branch where I write prose without asking first. |
Co-authored-by: Christopher Hiller <[email protected]>
Co-authored-by: Christopher Hiller <[email protected]>
No description provided.