Module for managing permissions on per node basis integrated with shopping cart or checkout
Content Access module restricts users per node basis or per content type basis.


  This module allows you to manage permissions for content types by role
  and author. It allows you to specifiy custom view, edit and delete
  permissions for each content type. Optionally you can enable per
  content access settings, so you can customize the access for each
  content node.


You need to use commerce checkout hooks and Content Access API to achieve this. Try rules modules too it may help with out using coding also.