Ubiquitous computing involves computers and technology that blend seamlessly into day to day living. RFID (Radio Frequency Identification) is an ideal technology for ubiquitous computing. A number of indicative examples of using RFID for developing ubiquitous environments were presented. However, before RFID becomes a truly ubiquitous technology, there are still many challenges to be faced, such as security, privacy and so on. In this paper, we propose and implement security architecture for RFID middleware. At the end of this paper, we apply the RFID middleware in future store based on RFID and evaluate the performance.