Skip to main content

Exploring Spring Security 3

I am finally back to writing again after an absence of almost year and half. I will try to be more regular from now now. In this edition I will start with Spring Security 3. This will be a series of posts where I will try to build a very simple photo uploading and sharing service. This is actually my PoC with Spring Security 3.

Spring Security unlike most Spring product portfolio is a not at all well documented. The tutorials available on googling are mostly outdated. Spring Security 3 certainly by look of things seems to be a very good feature rich product yet hefty beast. So here is my attempt to conquer it.




Skyphoto Basic Requirements

  1. Securely upload photos into your account
  2. Download photos
  3. Share photos with friends and other application



In the course of this simple application development I will try to uncover most of the features of Spring Security. I will use Restful services support provided by Spring MVC so that I can expose a simple API for external applications which will consume the services of Skyphoto.

Comments

  1. Thank you for doing this. I have always been interested in learning about Spring Security, but kept putting it off. I will be following your posts closely with the hope of quickly learning important concepts.

    ReplyDelete

Post a Comment

Popular posts from this blog

CKEDITOR 3.x - Simplest Ajax Submit Plugin

  I have assumed that you have downloaded and got started with CKEDITOR. Step 1 – The html file is shown below: <html> <head> <title>Writer</title> <meta content="text/html; charset=utf-8" http-equiv="content-type" /> <script type="text/javascript" src="ckeditor/ckeditor.js"></script> <script type="text/javascript" src="js/jquery-1.4.2.min.js"></script> <style> .cke_contents { height: 400px !important; } </style> </head> <body> <form action="sample_posteddata.php" method="post"> <textarea id="editor" > </textarea> <script type="text/javascript"> //<![CDATA[ CKEDITOR.replace( 'editor', { fullPage : true, uiColor : '#9AB8F3', toolbar : 'MyToolbar' }); //]]> </script> </form> </body> </html> Note that the jquery js...

Part 3 - Integrating Tiles, Thymeleaf and Spring MVC 3

In this post I will demonstrate how to integrate Apache Tiles with Thymeleaf. This is very simple. The first step is to include the tiles and thymeleaf-tiles extension dependencies. I will include them in the pom.xml. Note we wil lbe using Tiles 2.2.2 Listing 1 - parent/pom.xml --- thymeleaf-tiles and tiles dependencies <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ --> <!-- Tiles --> <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ --> <dependency> <groupId>org.apache.tiles</groupId> <artifactId>tiles-core</artifactId> <version>${tiles.version}</version> <scope>compile</scope> </dependency> <dependency> <groupId>org.apache.tiles</groupId> <artifactId>tiles-template</artifactId> <version>${tiles.version}</version> <scope>compile</s...

How to implement Cache Aside Pattern with Spring?

Problem You want to boost application performance by loading data from a cache and prevent the network trip to the persistent store (and also the query execution). This can be achieved by loading data from a cache. However, you want to load data on demand or lazily. Also, you want the application to control the cache data management – loading, eviction, and retrieval. Forces Improve performance by loading data from cache lazily. Application code controls cache data management. The underlying caching system does not provide read-through, write-through/write-behind strategies (strange really ??). Solution Use cache aside design pattern to solve the problems outlined above. This is also one of many caching patterns/strategies. I believe it is named in this because aside from managing the data store, application code is responsible for managing the cache also. Let's now try to understand how this caching technique works and then explore how it solves the proble...