Subversion Repositories SmartDukaan

Rev

Rev 30228 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 30228 Rev 35033
Line 22... Line 22...
22
 
22
 
23
	@Override
23
	@Override
24
	protected void configure(HttpSecurity http) throws Exception {
24
	protected void configure(HttpSecurity http) throws Exception {
25
		http.logout().logoutUrl("logmeout").and().cors().disable().csrf().disable().authorizeRequests()
25
		http.logout().logoutUrl("logmeout").and().cors().disable().csrf().disable().authorizeRequests()
26
				// .antMatchers("/**").hasRole("hdfc")
26
				// .antMatchers("/**").hasRole("hdfc")
-
 
27
				.antMatchers("/hdfc/**").hasRole("hdfc")
27
				.antMatchers("/hdfc/**").hasRole("hdfc").antMatchers("/imei/validate").hasRole("paytail")
28
				.antMatchers("/imei/validate").hasRole("paytail")
28
				.antMatchers("/spicemoney/callback").hasRole("spicemoney").antMatchers("/hdfctest/**")
29
				.antMatchers("/sales/logix").hasRole("logix")
29
				.hasRole("hdfctest").antMatchers("/**").permitAll().and().httpBasic()
30
				.antMatchers("/hdfctest/**").hasRole("hdfctest").antMatchers("/**").permitAll().and().httpBasic()
30
				.authenticationEntryPoint(myBasicAuthenticationEntryPoint);
31
				.authenticationEntryPoint(myBasicAuthenticationEntryPoint);
31
	}
32
	}
32
 
33
 
33
	@Autowired
34
	@Autowired
34
	protected void configureGlobal(AuthenticationManagerBuilder auth) throws Exception {
35
	protected void configureGlobal(AuthenticationManagerBuilder auth) throws Exception {
-
 
36
		auth.inMemoryAuthentication()
35
		auth.inMemoryAuthentication().withUser("hdfcuser").password("sd123$%^aGg").roles("hdfc").and()
37
				.withUser("hdfcuser").password("sd123$%^aGg").roles("hdfc").and()
36
				.withUser("hdfctestuser").password("test").roles("hdfctest").and().withUser("spicemoney")
38
				.withUser("hdfctestuser").password("test").roles("hdfctest").and()
37
				.password("$SMT123MONEY").roles("spicemoney").and().withUser("paytail").password("$SDP@yTa!l")
39
				.withUser("paytail").password("$SDP@yTa!l").roles("paytail").and()
38
				.roles("paytail");
40
				.withUser("logix").password("L()G!xM@!!").roles("logix");
39
	}
41
	}
40
 
42
 
41
}
43
}