MintM: Smartphone Based Loyalty System Hosted on the Cloud