Skip to content
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

Shareable config for the strict security rules? #142

Closed
beaugunderson opened this issue Nov 13, 2017 · 5 comments
Closed

Shareable config for the strict security rules? #142

beaugunderson opened this issue Nov 13, 2017 · 5 comments

Comments

@beaugunderson
Copy link

I think it would be nice to have a sharable config that turns on all of the new security rules, so teams can turn off just the ones they don't want and automatically get new ones turned on as they're included (as a way to keep abreast of new best practices)

@duaraghav8
Copy link
Owner

@beaugunderson if you simply specify"plugins: ["security"] in your soliumrc, then by default ALL non-deprecated rules inside that plugin will be enabled (all security rules are by default specified as error).

Any new rule that we add to the plugin WILL be automatically enabled when the user updates solium (provided that they have the "plugins" property set).

To turn off or change a specific security rule to warning, user needs to separately modify the rule like "security/no-throw": "off".

Is this^ what you wanted to achieve? If yes, then its already covered. If no, could you point out the diff.?

@duaraghav8
Copy link
Owner

@beaugunderson does the above resolve your issue or did I miss something?

@beaugunderson
Copy link
Author

@duaraghav8 i think 'everything on' works for Augur, but not sure if it should be default behavior of specifying the plugin, since some of the rules are more draconian (like no-user-defined-modifiers)

@duaraghav8
Copy link
Owner

you're right. I think we can write a sharable config solium-config-augur which augur can use since not all the security are desirable to all devs.

How this will work is

  • If you just use solium with default settings, it will apply some security rules and turn off some (especially the [Optional] ones)
  • If you apply augur sharable config on top, it applies all security rules. Otherwise you can choose to enable whatever rules you like inside soliumrc.json

I can publish this config, but I believe it is better suited for augur to keep it in their organisation?

@duaraghav8
Copy link
Owner

duaraghav8 commented Jan 16, 2018

security plugin is now configured to only enable general purpose rules by default - https://github.com/duaraghav8/solium-plugin-security#list-of-rules
will set up sharable config when need arises

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants