• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
  • Rob Spoor
  • Junilu Lacar
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Piet Souris
  • Carey Brown
Bartenders:

Need to skip spring/ldap authentication to be able to develop at home

 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
So my goal is to be able to continue development on my works application if i have to work from home.
Right now we have it set up to use spring to get authentication from a LDAP server. And of course i get an error when i try to run the app without being connected to the network.
Right now we actually have 2 different applications that both use spring to get authentication from an LDAP server and the are set up slightly different in each instance. But hopefully i can figure out how to fix both once i fix the first one.

one app has a applicationContext-security.xml file which specifies


And there are 2 files that have to do with the authentication.
LdapAuthenticationProvider.java which has an authenticate method:

LdapAuthenticationToke.java has another authenticate method:


Or i could just switch the authentication to pull from oracle since i have a local copy of the database running on my laptop. This would probably be easier than completely removing the authentication.

Any help or suggestions will be greatly appreciated!
 
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Your Spring Security setup is all through configuration. So you can create your own spring security config file, where you use the built in security classes and instead of pointing Authenication UserDetailsService to LDAP, point it to a properties file, or even in text in your config file.

I recommend reading the Spring Security documentation to understand that all you need to change is the UserDetailsService that you are using. The UserDetailsService is what looks up your user data wherever it is stored, and can be changed without changing the rest of your configuration.

Mark
 
Mark Spritzler
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Matter of fact this was in the thread right next to yours here



Mark
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic