Skip to content

Documented the security:check command #4651

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

Merged

Conversation

javiereguiluz
Copy link
Member

Q A
Doc fix? no
New docs? yes
Applies to all
Fixed tickets #4051

@xabbuh
Copy link
Member

xabbuh commented Dec 14, 2014

We need to be careful, to only merge this into the 2.5 branch and higher since the command isn't part of the 2.3 version of the SensioDistributionBundle.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

.. versionadded:: 2.6
The ``security:check`` command was introduced in Symfony 2.6.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's actually available in Symfony 2.5 too (it's part of SensioDistributionBundle in version 3.0 which is compatible with Symfony 2.5 and higher).

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Fixed.

@xabbuh
Copy link
Member

xabbuh commented Dec 14, 2014

Thanks for your work @javiereguiluz. I'm just wondering if we should also add a note in /contributing/code/security.rst. What do you think?

@javiereguiluz
Copy link
Member Author

A comment to the doc merger (probably @weaverryan): I wrongly made this PR against 2.3 and it should be 2.5 because security:check command was introduced in Symfony 2.5.

@javiereguiluz
Copy link
Member Author

@xabbuh I've added a note in 20de27e Please, let me know if that was what you were thinking or not. Thanks!

@@ -38,6 +38,8 @@ confirmed, the core-team works on a solution following these steps:
8. Publish the post on the official Symfony `blog`_ (it must also be added to
the "`Security Advisories`_" category);
9. Update the security advisory list (see below).
10. Update the public `security advisories database`_ maintained by the
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You'll have to add the referenced URL.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed. Thanks.

@xabbuh
Copy link
Member

xabbuh commented Dec 14, 2014

I thought we could also add a note at "Security Advisories" which explains that you can use the security:check command to test for known vulnerabilities.

@javiereguiluz
Copy link
Member Author

I thought we could also add a note at "Security Advisories" which explains that you can use the security:check command to test for known vulnerabilities.

I'm afraid that I do't understand your last comment. Where else should we mention this security:check command?

@xabbuh
Copy link
Member

xabbuh commented Dec 16, 2014

I thought about adding the following block in /contributing/code/security.rst (before or after the list of security releases):

.. tip::

    You can check your Symfony application for known security vulnerabilities
    using the ``security:check`` command.

This might be valuable because issues not only occur in the Symfony core, but do also happen in third-party bundle code.

When using lots of dependencies in your Symfony projects, odds are that some of
them contain security vulnerabilities. That's why Symfony includes a command
called ``security:check`` that checks whether any of your installed dependencies
contain a known security vulnerability:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you should add a note that the command is provided by SensioDistributionBundle, so it will be available only when it is registered

@wouterj
Copy link
Member

wouterj commented Dec 28, 2014

ping @javiereguiluz

@javiereguiluz javiereguiluz force-pushed the document_security_check_command branch from 847b8ce to fdfb1a0 Compare December 29, 2014 16:18
@javiereguiluz
Copy link
Member Author

@wouterj I've rebased the PR and fixed everything that reviewers told me. If you agree, we can move this PR to Finished state. Thanks!

.. versionadded:: 2.5
The ``security:check`` command was introduced in Symfony 2.5. This command is
included in ``SensioDistributionBundle``, which has to be registered in your
application in order to use this command.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The reference to the SensioDistributionBundle should probably also be added in the installation chapter.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you really think is necessary? The installation chapter is for people that know nothing about Symfony. They're going to use the installer and they're going to install the standard edition, so everything works out of the box. My feel is that this note is only for advanced users doing custom installations.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hm, I guess you're right now that I think about it again.

@weaverryan weaverryan merged commit 897dc70 into symfony:2.3 Jan 1, 2015
weaverryan added a commit that referenced this pull request Jan 1, 2015
This PR was merged into the 2.3 branch.

Discussion
----------

Documented the security:check command

| Q             | A
| ------------- | ---
| Doc fix?      | no
| New docs?     | yes
| Applies to    | all
| Fixed tickets | #4051

Commits
-------

897dc70 Added a lot of changes suggested by reviewers
fdfb1a0 Added a note about the SensioDistributionBundle necessary for security:check
3c9a962 Added a note about the security:check command
e552369 Added a missing link reference
0e7d0cd Added a note about the security advisories database
36d3f2b This command is available sin Symfony 2.5
7f3fb71 Documented the security:check command
weaverryan added a commit that referenced this pull request Jan 1, 2015
@weaverryan
Copy link
Member

Thanks Javier! I merged this in and am fixing the build error right now :)

weaverryan added a commit that referenced this pull request Jan 1, 2015
* 2.3:
  fixing bad link
  Fixing bad merge - this section should not have been left in
  [#4651] Fixing build error
  Update by_reference.rst.inc
  Added a lot of changes suggested by reviewers
  Added a note about the SensioDistributionBundle necessary for security:check
  Added a note about the security:check command
  Added a missing link reference
  Added a note about the security advisories database
  This command is available sin Symfony 2.5
  Documented the security:check command
weaverryan added a commit that referenced this pull request Jan 1, 2015
* 2.5:
  fixing bad link
  Fixing bad merge - this section should not have been left in
  [#4651] Fixing build error
  Update by_reference.rst.inc
  Added a lot of changes suggested by reviewers
  Added a note about the SensioDistributionBundle necessary for security:check
  Added a note about the security:check command
  Added a missing link reference
  Added a note about the security advisories database
  This command is available sin Symfony 2.5
  Documented the security:check command
weaverryan added a commit that referenced this pull request Jan 1, 2015
* 2.7:
  fixing bad link
  Fixing bad merge - this section should not have been left in
  [#4651] Fixing build error
  Update by_reference.rst.inc
  Added a lot of changes suggested by reviewers
  Added a note about the SensioDistributionBundle necessary for security:check
  Added a note about the security:check command
  Added a missing link reference
  Added a note about the security advisories database
  This command is available sin Symfony 2.5
  Documented the security:check command
xelaris added a commit to xelaris/symfony-docs that referenced this pull request Jan 3, 2015
weaverryan added a commit that referenced this pull request Jan 16, 2015
This PR was merged into the 2.3 branch.

Discussion
----------

Revert #4651 for 2.3 branch

| Q             | A
| ------------- | ---
| Doc fix?      | yes
| New docs?     | no
| Applies to    |  2.3 (only)
| Fixed tickets |

#4651 was merged in 2.3 but should be 2.5 as mentioned in #4651 (comment). This PR reverts the changes for the 2.3 branch.

Commits
-------

f2d3223 Revert #4651 for 2.3 branch
weaverryan added a commit that referenced this pull request Jan 16, 2015
* 2.3:
  Revert #4651 for 2.3 branch
weaverryan added a commit that referenced this pull request Jan 18, 2015
* 2.5:
  fix merge after removing @Security in 2.3
  Reverting a commit on 2.5 branch, as it was only meant to be on 2.3 (so reverting after the merge)
  [#4735] Reverting what was left on the 2.5 branch after the merge conflict had already put back some of it
  Typo Fix: "allows to" should be "allows you to"
  move cautions to make them visible
  bump required PHPUnit version
  remove @Security annotation for Symfony 2.3
  Revert #4651 for 2.3 branch
  Use AppBundle whenever it's possible

Conflicts:
	components/console/helpers/map.rst.inc
	cookbook/form/create_custom_field_type.rst
	cookbook/form/dynamic_form_modification.rst
	cookbook/form/form_customization.rst
	cookbook/profiler/matchers.rst
	cookbook/security/custom_authentication_provider.rst
	cookbook/security/securing_services.rst
@javiereguiluz javiereguiluz deleted the document_security_check_command branch February 18, 2015 16:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants