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

SEC-2416: Hello Spring MVC Security Java Config documentation is incorrect #2632

Closed
spring-issuemaster opened this issue Nov 26, 2013 · 2 comments

Comments

Projects
None yet
2 participants
@spring-issuemaster
Copy link

commented Nov 26, 2013

Michael Power (Migrated from SEC-2416) said:

The directions for a basic intro into securing a spring mvc web application seem to be wrong. I cannot follow them and produce the expected results.

  1. It says "Enter SecurityWebApplicationInitializer for the Name" of a the class. But the source code for the class has the class name as:
    public class MessageSecurityWebApplicationInitializer
    This is easy enough to fix.

  2. It says "our Spring root application context is initialized using MessageWebApplicationInitializer which is included with our spring-security-samples-messages-jc " However I cannot find a class by this name any where. In fact I did a search for usages of the super class "AbstractAnnotationConfigDispatcherServletInitializer". I did not find any usages of that class.

I followed as many instructions as I could, but in the end I could not get a login screen. I like Spring and I am sure you did a good job at the security library. I just have a hard time getting an idea of what it does without a working intro.

As an aside I recommend when you give people the git command, clone from a tag instead of cloning from the tip.
git clone https://github.com/SpringSource/spring-security.git -b 3.2.0.RC2

@spring-issuemaster

This comment has been minimized.

Copy link
Author

commented Dec 5, 2013

Rob Winch said:

Thank you for the feedback. I have fixed the guides at http://docs.spring.io/spring-security/site/docs/3.2.x-SNAPSHOT/guides/hellomvc.html I went through the guide and it works well for me now. Can you see if this works better for you? If not, please provide any additional issues you have.

  1. It says "Enter SecurityWebApplicationInitializer for the Name" of a the class. But the source code for the class has the class name as:
    public class MessageSecurityWebApplicationInitializer

I have corrected this in master. You can see the update here

  1. It says "our Spring root application context is initialized using MessageWebApplicationInitializer which is included with our spring-security-samples-messages-jc " However I cannot find a class by this name any where. In fact I did a search for usages of the super class "AbstractAnnotationConfigDispatcherServletInitializer". I did not find any usages of that class.

I'm guessing this was not working due to SEC-2388 which has since been fixed. MessageWebApplicationInitializer can be found here, but since the dependency was missing I'm guessing it was not added to your workspace.

As an aside I recommend when you give people the git command, clone from a tag instead of cloning from the tip.
git clone https://github.com/SpringSource/spring-security.git -b 3.2.0.RC2

I removed the clone example to keep the samples as simple and concise as possible. See here

@spring-issuemaster

This comment has been minimized.

Copy link
Author

commented Dec 10, 2013

Rob Winch said:

Resolving as fixed as per the updates and no additional feedback. Please feel free to create a new JIRA with additional details if you experience more problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.