-
-
Notifications
You must be signed in to change notification settings - Fork 5.1k
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
[WIP] 4373 - document security events #5303
[WIP] 4373 - document security events #5303
Conversation
Fudge. I just realized that I used the RequestStack in the cookbook page, which was introduced in 2.4 not 2.3. Alas... |
|
||
When a provider authenticates the user, a ``security.authentication.success`` | ||
event is dispatched. Likewise, when no providers authenticate the user, | ||
a ``security.authentication.failure`` event is dispatched. You |
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 sentence kind of makes it sound like this event will happen when no providers authentication versus "1 authenticator fails authentication". How about:
Likewise, when a provider attempts authentication but fails (i.e. throws an
``AuthenticationException``), a ``security.authentication.failure`` event is dispatched.
@kevintweber don't worry about the |
Ping @kevintweber! Will you have some time to finish this? Thanks! |
@weaverryan Yeah, I'll do it now. I'm going to remove the cookbook entry because it's rather contrived, and no application should implement such functionality. It's just a bad example. |
…r/symfony-docs into 4373_Document_Security_Events
The text is ready to go. I cannot see the merge conflicts, so you may need to massage it a bit. (And sorry about the huge delay.) If you want me to squash the commits, just say so. |
You did a VERY nice job explaining this - a really nice addition. Thanks so much Kevin! |
This PR was merged into the 2.3 branch. Discussion ---------- [WIP] 4373 - document security events This is documentation for #4373. This pull request has two parts: * The component/security/authentication additions * The new cookbook security cookbook page. The new cookbook page is designed to give an example of how to use authentication events in an application. I have given example code for two of the four classes needed to throttle failed login attempts. The other two classes are a doctrine entity, and a class containing throttle domain logic, both of which are outside the scope of this documentation. I would welcome any comments and suggestions. Thank you. Commits ------- 0dbabfe Security - Cookbook - removed bad example. 69c0089 Merge branch '4373_Document_Security_Events' of github.com:kevintweber/symfony-docs into 4373_Document_Security_Events a14bd07 Security - Authentication - removed inaccurate tip. f15bea4 Added new cookbook page to security index. 5bdfd71 Better formatting for authentication tip. 9b2e9d8 Better section titles for security events on authentication page. 286f00c Added security event descriptions to security component authentication page.
This is documentation for #4373. This pull request has two parts:
The new cookbook page is designed to give an example of how to use authentication events in an application. I have given example code for two of the four classes needed to throttle failed login attempts. The other two classes are a doctrine entity, and a class containing throttle domain logic, both of which are outside the scope of this documentation.
I would welcome any comments and suggestions. Thank you.