Now using upsert method in security manager.